OFFSET
1,2
COMMENTS
If k is allowed to be 0, the sequence would be 1,1,1... - Chai Wah Wu, Mar 27 2020
LINKS
Robert Israel, Table of n, a(n) for n = 1..12
EXAMPLE
a(5) = 961 = 15*64 + 1 where a(4) = 64.
MATHEMATICA
a[1] = 1; a[2] = 4; a[n_] := a[n] = (r = Reduce[k > Sqrt[a[n - 1]] && Mod[k^2, a[n - 1]] == 1, k, Integers] /. C[_] -> c; sel = Select[Table[r, {c, -1, 1}], #1 =!= False & ]; Min[k^2 /. ToRules /@ sel]); Table[a[n], {n, 1, 9}] (* Jean-François Alcover, Jan 12 2012 *)
CROSSREFS
KEYWORD
nonn,nice
AUTHOR
Amarnath Murthy, Jul 03 2001
EXTENSIONS
More terms from Larry Reeves (larryr(AT)acm.org), Jul 10 2001
a(7) from Vladeta Jovovic, Jan 17 2004
a(9) from Jean-François Alcover, Jan 12 2012
a(10) from Robert Israel, Sep 18 2016
STATUS
approved