# Fibonacci rings modulo n

This article by Dan Polansky has a look at Fibonacci rings modulo n. The term Fibonacci ring is introduced in this article and may be terminologically unfortunate; maybe we can figure out a better term later.
There is a decent article on Fibonacci sequence modulo n in Wikipedia. This sequence has the property that it starts from 1, 1, and continues from there using the recursive formula $x_{n+2}:=x_{n+1}+x_{n}$. By contrast, what I mean by Fibonacci ring is any sequence starting from X, Y, for any X and Y. I call it a ring since, calculating on the modulo space, the sequence is guaranteed to return to where it started, and I find it arbitrary whether I start at the beginning or in the middle. Thus, I imagine the sequence to be of the shape of the letter O, a cycle/ring/loop.
I consider e.g. the sequence starting from 1, 1 and the sequence starting from 1, 2 to be the same ring: it covers the same set of pairs.
The objective of the calculation and analysis is, for each chosen modulus, find all rings (covering all pairs) and notice their properties and regularities, if any. All rings are found when all pairs are covered; it is not the purpose to list all rings taking all X,Y as a start since the result would be a massive duplication as for covered pairs.
To be done: describe the found regularities concerning the ring lengths, e.g. each ring length has to divide the length of the 1,1-ring. Make some notes about prime modulus values. Note how e.g. rings for the modulus 3 are reflected in all the modulus multiples, e.g. the rings for the modulus 15.
Finding the rings can be used as a manual calculation exercise. What is nice about the exercise is that the addition tasks are self-generating, and because of the regularities within the rings and between the rings, there is some level of quick verification/double checking.

## Terminology

The term Fibonacci ring is a provisional one and raises some concerns. For one thing, the word ring has a meaning in algebra, a very different one, as per W:Ring (mathematics); the justification for the choice is the visual image of a ring one wears on a finger. For another thing, letting the word Fibonacci refer to sequences other than the 1,1-one is uncustomary; for instance, the sequence starting at 2, 1 and using the same recursive formula is called Lucas numbers per Wikipedia and MathWorld.
Bocci and Valle 2024 use the term generalized Fibonacci sequence to refer to a sequence with generalized first two terms. Following this model, I could perhaps use the term generalized Fibonacci ring as more accurate or less misleading.

## Rings for modulus 2 through 20

Rings for modulus 2 through 20, output by the Python script below, for an impression of what we are talking about. The ring 0,0 is omitted as trivially present everywhere.

## Large language models

I asked Google Gemini the following:
* What is the Fibonacci sequence modulo 5?
** It gave a correct answer.
* What is the Fibonacci sequence modulo 10?
** It gave a correct answer.
* What is the Fibonacci sequence modulo 11 and what are other sequences using the same recursive formula but starting at values different from 1,1, e.g. 3,3?
** It gave an impressive, possibly correct answer (I did only quick verification). I have no idea how it can do so well.
I then got even more impressive answer by the following sequence of queries:
* What is the Fibonacci sequence modulo 11 and what are other sequences using the same recursive formula but starting at values different from 1,1, e.g. 3,3?
* Can you list all such generalized sequences modulo 11?
* I mean actually listing, not giving an algorithm.
* Can you list not all sequences but only so many sequences that all pairs are in at least one sequence?
The results appear too good to be true. That this is a result of mere seeking patterns in word sequences by means of artificial neural networks is hard to believe.