login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A261694 a(n) = Fibonacci(n) mod 21. 1
0, 1, 1, 2, 3, 5, 8, 13, 0, 13, 13, 5, 18, 2, 20, 1, 0, 1, 1, 2, 3, 5, 8, 13, 0, 13, 13, 5, 18, 2, 20, 1, 0, 1, 1, 2, 3, 5, 8, 13, 0, 13, 13, 5, 18, 2, 20, 1, 0, 1, 1, 2, 3, 5, 8, 13, 0, 13, 13, 5, 18, 2, 20, 1, 0, 1, 1, 2, 3, 5, 8, 13, 0, 13, 13, 5, 18, 2, 20, 1, 0, 1, 1, 2, 3, 5, 8, 13, 0, 13 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,4
COMMENTS
Sequence is periodic with Pisano period 16; Pisano number 21 in the sequence A001175. The only other sequence with Pisano period 16 is that of A105870 which is the Fibonacci sequence mod 7. This is Pisano number 7.
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..1000 [a(391) = 13 corrected by Georg Fischer, May 24 2019]
FORMULA
G.f.: x*(1 + x + 2*x^2 + 3*x^3 + 5*x^4 + 8*x^5 + 13*x^6 + 13*x^8 + 13*x^9 + 5*x^10 + 18*x^11 + 2*x^12 + 20*x^13 + x^14)/(1-x^16).
MATHEMATICA
Table[Mod[Fibonacci[n], 21], {n, 0, 100}]
PadRight[{}, 120, {0, 1, 1, 2, 3, 5, 8, 13, 0, 13, 13, 5, 18, 2, 20, 1}] (* Harvey P. Dale, May 16 2020 *)
PROG
(Magma) [Fibonacci(n) mod 21: n in [0..120]]; // Vincenzo Librandi, Nov 19 2015
(PARI) a(n) = fibonacci(n)%21; \\ Altug Alkan, Nov 19 2015
(Python)
A261694_list, a, b, = [], 0, 1
for _ in range(10**3):
A261694_list.append(a)
a, b = b, (a+b) % 21 # Chai Wah Wu, Nov 26 2015
CROSSREFS
Sequence in context: A152909 A328597 A118604 * A287533 A072123 A135102
KEYWORD
nonn,easy
AUTHOR
G. C. Greubel, Nov 18 2015
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified March 28 16:12 EDT 2024. Contains 371254 sequences. (Running on oeis4.)