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.

A356296 a(n) = Fibonacci(n)^2 mod n.

Original entry on oeis.org

0, 1, 1, 1, 0, 4, 1, 1, 4, 5, 1, 0, 1, 1, 10, 9, 1, 10, 1, 5, 4, 1, 1, 0, 0, 1, 22, 9, 1, 10, 1, 25, 4, 1, 25, 0, 1, 1, 4, 25, 1, 22, 1, 9, 40, 1, 1, 0, 22, 25, 4, 9, 1, 10, 25, 49, 4, 1, 1, 0, 1, 1, 22, 25, 25, 64, 1, 9, 4, 15, 1, 0, 1, 1, 25, 9, 4, 64, 1, 25, 49, 1, 1, 72, 25, 1
Offset: 1

Views

Author

R. J. Mathar, Aug 03 2022

Keywords

Crossrefs

Cf. A000045, A002708, A023172 (location of zeros), A337231, A337232.

Programs

  • Maple
    A356296 := proc(n)
        modp(combinat[fibonacci](n)^2,n) ;
    end proc:
    seq(A356296(n),n=1..120) ;
  • Mathematica
    Array[PowerMod[Fibonacci[#], 2, #] &, 86] (* Michael De Vlieger, Aug 03 2022 *)
  • PARI
    a(n) = lift(Mod(fibonacci(n), n)^2); \\ Michel Marcus, Aug 03 2022
    
  • Python
    from sympy import fibonacci
    def a(n): return pow(fibonacci(n), 2, n)
    print([a(n) for n in range(1, 87)]) # Michael S. Branicky, Aug 04 2022

Formula

a(n) = A000045(n)^2 mod n.