OFFSET
1,2
COMMENTS
Let b(1) = b(2) = 1, b(k) = (b(k-1) + b(k-2)) mod k; sequence gives n such that b(n) = 0.
No further terms below k = 5*10^10, at which point, A079777(k-1) = 6059364906669 and A079777(k) = 29451014544130. - Luca Armstrong, Apr 07 2023
LINKS
Zak Seidov, A073853 Four more terms [From Zak Seidov, Dec 06 2009]
EXAMPLE
b(3) = 2 mod 3 = 2; b(4) = (2+1) mod 4 = 3; b(5) = (3+2) mod 5 = 0, hence a(1) = 5.
MATHEMATICA
a = 0; b = 1; lst = {0}; Do[c = Mod[a + b, n]; If[c == 0, AppendTo[lst, n]; Print@n]; a = b; b = c, {n, 2, 2^31}] (* Robert G. Wilson v *)
PROG
(Java) class A073853 { public static void main(String [] args) { BigInteger an = BigInteger.ZERO ; BigInteger an1 = BigInteger.ONE ; BigInteger n = new BigInteger("2") ; for( ; ; n = n.add(BigInteger.ONE) ) { BigInteger an2 = an.add(an1).mod(n) ; if ( an2.compareTo(BigInteger.ZERO) == 0 ) System.out.println(n) ; an = an1 ; an1 = an2 ; } } } // R. J. Mathar, Dec 06 2009
CROSSREFS
KEYWORD
nonn
AUTHOR
Benoit Cloitre, Sep 02 2002
EXTENSIONS
Corrected and extended by John W. Layman, Jun 11 2003
a(23)-a(26) from Zak Seidov; a(27)-a(28) from John W. Layman; a(29)-a(34) from Charles R Greathouse IV, Dec 09 2009. (These new terms were added by N. J. A. Sloane, Dec 20 2009.)
a(35) from Luca Armstrong, Apr 07 2023
STATUS
approved