cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A182625 Numbers n for which Fibonacci(n) mod n is a Fibonacci number.

This page as a plain text file.
%I A182625 #40 Oct 27 2023 21:57:27
%S A182625 1,2,3,4,5,6,8,10,11,12,14,19,20,21,22,24,25,29,31,32,33,36,38,41,42,
%T A182625 48,54,55,56,58,59,60,61,62,71,72,76,77,79,80,82,89,92,93,95,96,101,
%U A182625 104,105,108,109,110,118,119,120,121,122,123,124,125,131,133,139,142
%N A182625 Numbers n for which Fibonacci(n) mod n is a Fibonacci number.
%H A182625 Alois P. Heinz, <a href="/A182625/b182625.txt">Table of n, a(n) for n = 1..10000</a> (first 2241 terms from Klaus Brockhaus)
%F A182625 {n: A002708(n) in A000045}. - _R. J. Mathar_, Apr 02 2011
%e A182625 Fibonacci(12) = 144, 144 mod 12 = 0, and 0 is a Fibonacci number. Therefore 12 is in the sequence.
%e A182625 Fibonacci(14) = 377, 377 mod 14 = 13, and 13 is a Fibonacci number. Therefore 14 is in the sequence.
%p A182625 isA000045 := proc(n) local F,i; for i from 0 do F := combinat[fibonacci](i) ; if F> n then return false; elif F = n then return true; end if; end do;end proc:
%p A182625 isA182625 := proc(n) isA000045(combinat[fibonacci](n) mod n) ; end proc:
%p A182625 for n from 1 to 300 do if isA182625(n) then printf("%d,",n) ; end if; end do: # _R. J. Mathar_, Apr 02 2011
%p A182625 # second Maple program:
%p A182625 b:= proc(n) local r, M, p; r, M, p:=
%p A182625       <<1|0>, <0|1>>, <<0|1>, <1|1>>, n;
%p A182625       do if irem(p, 2, 'p')=1 then r:= r.M mod n fi;
%p A182625          if p=0 then break fi; M:= M.M mod n
%p A182625       od; r[1, 2]
%p A182625     end:
%p A182625 a:= proc(n) option remember; local k;
%p A182625       for k from 1+`if`(n=1, 0, a(n-1)) while (t->
%p A182625          not (issqr(t+4) or issqr(t-4)))(5*b(k)^2)
%p A182625       do od; k
%p A182625     end:
%p A182625 seq(a(n), n=1..100);  # _Alois P. Heinz_, Nov 26 2016
%t A182625 nn=12; f=Table[Fibonacci[n], {n,0,nn}]; Select[Range[f[[-1]]], MemberQ[f, Mod[Fibonacci[#],#]]&] (* _T. D. Noe_, Apr 02 2011 *)
%o A182625 (PARI) is(n)=my(k=(fibonacci(n)%n)^2);k+=(k+1)<<2; issquare(k) || issquare(k-8) \\ _Charles R Greathouse IV_, Jul 30 2012
%Y A182625 Cf. A000045, A002708.
%K A182625 nonn,easy
%O A182625 1,2
%A A182625 _Carmine Suriano_, Mar 30 2011