OFFSET
1,1
COMMENTS
Related to hyperperfect numbers of a certain form.
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
J. S. McCranie, A study of hyperperfect numbers, J. Int. Seqs. Vol. 3 (2000) #P00.1.3.
EXAMPLE
7 and 43 are both terms since (6*7+1)/(7-6) = 43.
MAPLE
filter:= proc(p) local g, m, q;
if not isprime(p) then return false fi;
g:= p^2+1;
for m in select(`<`, numtheory:-divisors(g), p) do
q:= g/m-p;
if isprime(q) then return true fi;
od;
false
end proc:
select(filter, [seq(i, i=3..1000, 2)]); # Robert Israel, Oct 06 2020
PROG
(PARI) isok(p) = {for (k=1, p-1, my(q = (k*p+1)/(p-k)); if ((denominator(q)==1) && isprime(q), return (1)); ); }
lista(nn) = {forprime(p=3, nn, if (isok(p), print1(p, ", ")); ); } \\ Michel Marcus, Mar 11 2016
CROSSREFS
KEYWORD
nonn
AUTHOR
EXTENSIONS
Name edited by Michel Marcus, Mar 11 2016
STATUS
approved