OFFSET
1,1
EXAMPLE
a(2) = 47 as f(2) = 5, f(5) = 11,f(11) = 23, f(23) = 47 is the largest such prime . f(47) = 95 is not a prime. a(4) = 0 as f(4) = 9 is composite.
MAPLE
for k from 1 to 500 do a := 2*k+1; while(isprime(a)) do a := 2*a+1; end do; c[k] := (a-1)/2; if(not isprime(c[k])) then c[k] := 0; end if; if(c[k]<2*k+1) then c[k] := 0; end if; end do:q := seq(c[i], i=1..500);
CROSSREFS
KEYWORD
nonn
AUTHOR
Amarnath Murthy, Feb 27 2002
EXTENSIONS
More terms from Sascha Kurz, Mar 17 2002
STATUS
approved