NOTES ON THE PISANO SEMIPERIOD
TOM HARRIS
Introduction
Fix a positive integer m > 1. The modulo m Fibonacci sequence is the sequence
fm,− of elements of Z/mZ defined by the recurrence:
fm,0 = 0
fm,1 = 1
fm,i+2 = fm,i + fm,i+1 .
That is, fm,r is the class of the usual rth Fibonacci number Fr taken modulo m.
It is a straightforward exercise to show that this sequence is periodic for every m.
We call its period the Pisano period modulo m, which we denote by π(m). There
is no initial segment of the sequence fm,− before it becomes periodic, which leads
to the following formal definition.
Definition 1. The Pisano period π(m) of an integer m > 1 is the least integer
r > 0 such that fm,r = 0 and fm,r+1 = 1.
Example 2. The Fibonacci numbers modulo 3 are:
0, 1, 1, 2, 0, 2, 2, 1, 0, 1, 1, 2, 0, 2, 2, 1, 0, 1, . . . ;
the period of this sequence is 8, so π(3) = 8.
The Pisano period is often studied using the Fibonacci matrix P = ( 01 11 ) considered
modulo m. Since
fm,r−1
fm,r
r
P =
,
fm,r
fm,r+1
it follows that π(m) is equal the order of P in GL2 (Z/mZ). The Pisano period has
been studied fairly extensively, but much is still unknown about its behaviour. In
section 1 we review some of the simpler known results about π(m) together with
their proofs. None of this material is original. It can be found variously in [Wal60],
[Rob63], [FB92], and others.
Recently Singerman & Strudwick [SS16] have shown an application of a variant
of the Pisano period to the study of Petrie polygons on quotients of the Farey
map. Whereas the Pisano period π(m) is the order of the Fibonacci matrix P in
GL2 (Z/mZ), the Pisano semiperiod σ(m) is the order of P in (GL2 (Z/mZ))/{±I}.
This is equivalent to the following definition of σ(m) as the period of the modulo
m Fibonacci sequence up to a sign.
Definition 3. The Pisano semiperiod σ(m) of an integer m > 1 is the least integer
r > 0 such that fm,r = 0 and fm,r+1 = ±1.
Date: February 10, 2017.
1
2
TOM HARRIS
The reader can verify that if σ(m) 6= π(m), then we must have σ(m) = 21 π(m).
Since 2 ≡ −1 mod (3), we see in Example 2 that σ(3) = 4 = 12 π(3). This is not
always the case.
Example 4. The Fibonacci numbers modulo 11 are:
0, 1, 1, 2, 3, 5, 8, 2, 10, 1, 0, 1, 1, 2, 3, . . . ;
the period of this sequence is 10, so π(11) = 10. The consecutive pair 0, 10 never
appears in the sequence, so σ(11) = π(11) = 10.
We expect the behaviour of σ(m) to be at least as hard to determine as the behaviour of π(m). In section 2 we study results about σ(m) that are analogous to
those results about π(m) proven in section 1. Our main interest is in determining
when σ(m) = 21 π(m). We introduce a little terminology to describe this situation.
Definition 5. For an integer m > 1, we say m has Pisano signature −1 and
write θ(m) = −1 if the consecutive pair 0, −1 (equivalently −1, 0) appears in the
Fibonacci numbers modulo m. If this pair never occurs then we say m has Pisano
signature 1 and write θ(m) = 1.
Remark. Since 1 ≡ −1 mod (2), this definition gives θ(2) = −1. Instead of the
above formulation we could have chosen the definition
“θ(m) = −1 if and only if σ(m) = 12 π(m), otherwise θ(m) = 1”,
in which case θ(2) = 1. Either choice leads to results whose statements have exceptions at m = 2, so we have made the choice that seems to lead to fewer exceptions.
Away from 2 this does not present any problems, as the two formulations are equivalent for m 6= 2.
1. The Pisano period
In this section we review some elementary results about the Pisano period. It is often the case that some detail in the proof of a result about π(m) yields a a stronger
result about σ(m), so in most places we have given more detailed proofs than is
strictly necessary.
Apart from the first case π(2) = 3, all Pisano periods are even. There are many
proofs of this elementary fact. The following short proof is due to David Singerman.
Proposition 6. If m > 2, then π(m) is even.
Proof. We have seen that π(m) is equal the order of P = ( 01 11 ) in GL2 (Z/mZ).
Considering the determinant homomorphism det : GL2 (Z/mZ) → (Z/mZ)× , we
see that det(P ) = −1, so (−1)π(m) = 1 in Z/mZ. Since m 6= 2, we have −1 6= 1 in
Z/mZ, so π(m) must be even.
The following lemma is a direct application of the Chinese remainder theorem.
Lemma 7. Let m1 , m2 be coprime. Then π(m1 m2 ) = lcm(π(m1 ), π(m2 )).
Proof. Since m1 and m2 are coprime, the Chinese remainder theorem tells us that:
Fr ≡ 0 mod (m) ⇐⇒
and Fr+1 ≡ 1 mod (m) ⇐⇒
Fr ≡ 0 mod (mi ), i = 1, 2
Fr ≡ 1 mod (mi ), i = 1, 2.
Thus fm,r = 0 and fm,r+1 = 1 when r = lcm(π(m1 ), π(m2 )), and not before. So
π(m1 m2 ) = lcm(π(m1 ), π(m2 )).
NOTES ON THE PISANO SEMIPERIOD
3
The least common multiple is associative, so it follows that for mutually coprime
m1 , . . . , mr we have π(m1 m2 · · · mr ) = lcm(π(m1 ), π(m2 ), . . . , π(mr )) This is also
proven directly by the same argument as above.
So the calculation of π(m) reduces trivially to the calculation of π(pe ) for p a
prime. The picture for prime powers is more complicated. The following conjecture is widely expected to be true, and has been verified for primes up to 2.8 × 1016 ,
but no proof is known. Any counterexample to the conjecture would have to be a
Wall–Sun–Sun prime. 1 No Wall–Sun–Sun primes are known to exist.
Conjecture 8. For a prime p and an integer e > 1, we have π(pe ) = pe−1 π(p).
To establish the conjecture it is in fact enough to show that π(p2 ) = pπ(p), as Wall
already showed in 1960 that if π(p2 ) 6= π(p), then π(pe ) = pe−1 π(p) (Theorem 5 of
[Wal60]). In the same theorem, Wall also shows that if t is the largest integer with
π(pt ) = π(p), then π(pe ) = pe−t π(p) for e > t. In particular, π(pe ) always divides
π(pe−1 ). The interested reader may prove this fact directly as an exercise.
So to find bounds on π(m) it suffices to bound π(p) for p prime, and to calculate π(m) it suffices conjecturally to calculate π(p) for primes as well. There is no
known formula for π(p), but there are effective bounds that limit the possibilities.
This is not to say that it is difficult to calculate individual periods, just that the
overall behaviour is not well understood.
As we have already noted, the prime 2 is an anomaly in the study of Pisano periods,
having π(2) = 3 odd. Since we are dealing with series derived from the Fibonacci
numbers, it should come as no surprise that π(5) = 20 is also anomalous. We
will establish the reasons for this shortly. For p a prime not equal to 2 or 5, let
Fp = Z/pZ be the finite field with p elements, and let Rp be the quotient ring
Fp [t]/(t2 − t − 1). We denote the image of t in Rp by φp , and note that φp is a unit
with inverse φp − 1. By definition φp is a root of the polynomial x2 − x − 1 = 0 in
Rp . We calculate also that 1 − φp is also a root. An easy argument by induction
shows that
φrp = fp,r−1 + fp,r φp
in Rp for r > 0. From the definition of the Pisano period, it now follows that π(p)
is equal to the order of φp in the group of units R×
p.
Remark. We could of course define a ring Rm := (Z/mZ)[t]/(t2 − t − 1) and
corresponding element φm for any m > 1. It remains true that π(m) is equal to
the order of φm in R×
m . However the ring Rp is much better behaved for p prime,
as Z/pZ is a field. Since calculations of π(m) reduce to calculations of π(pk ) and
(conjecturally) to π(p) we do not consider the ring Rm for composite m here.
Proposition 9. Let p be prime that is not 2 or 5.
(i) If p ≡ ±1 mod (5), then π(p) divides p − 1.
(i) If p ≡ ±2 mod (5), then π(p) divides 2(p + 1).
1A prime p 6= 2, 5 is called a Wall–Sun–Sun prime if p2 divides the Fibonacci number f
,
p−( p
5)
where p5 is the Legendre symbol. Wall–Sun–Sun primes were originally studied in connection
to potential counterexamples to Fermat’s Last Theorem.
4
TOM HARRIS
Proof. The proof goes by considering the structure of Rp . In either case Rp
is a commutative ring of characteristic p, so it has a Frobenius endomorphism
Frobp (a) = ap which fixes all elements of the prime field Fp ⊂ Rp . Let ρ(t) ∈ Fp [t]
be the polynomial t2 − t − 1. The structure of Rp depends on whether or not ρ(t) is
irreducible in Fp [t]. For quadratic polynomials, reducibility over a field is equivalent
to having a root in the field. The class of 4 is invertible modulo odd primes, so
ρ(t) = t2 − t − 1 has a root in Fp if and only if 4t2 − 4t − 4 = (2t − 1)2 − 5 does.
This happens whenever 5 is a quadratic residue mod p, which is case (i) where
p ≡ ±1 mod (5) (note that in this case the two roots are distinct: for p = 5 there
is one repeated root, which explains why 5 is anomalous). When 5 is a quadratic
non-residue mod p, then we are in case (ii) where p ≡ ±2 mod (5).
(i) p ≡ ±1 mod (5): In the first case, ρ(t) is reducible over Fp , so ρ(t) =
(t − a)(t − b) for some distinct a and b in Fp . Since a and b are elements
of the prime field, they are fixed by the Frobenius, so they are roots of
tp − t. It follows that ρ(t) divides tp − t, so there is a containment of ideals
(tp − t) ⊂ (ρ(t)) = (t2 − t − 1), hence the relation xp = x holds for every
element of Rp = Fp [t]/(t2 − t − 1). In particular we have φpp = φp , so
= 1. Therefore the order of φp in R×
φp−1
p is a divisor of p − 1, proving the
p
first claim.
(ii) p ≡ ±2 mod (5): In the second case, ρ(t) is irreducible quadratic over Fp ,
and therefore Rp = Fp [t]/(ρ(t)) ∼
= Fp2 . Since Rp is a field, the only fixed
points of its Frobenius are the elements of the prime subfield. We have
φ2p − φp − 1 = 0 in Rp , so
p
2
φ2p
p − φp − 1 = Frobp (φp − φp − 1) = 0.
This shows that φpp is a root of x2 − x − 1 in Rp , and so must be equal
to φp or 1 − φp . But we cannot have φpp = φp , else φp would be a fixed
point of Frobp and would have to be in the prime field, contradicting the
irreducibility of ρ(t). So φpp = 1 − φp , hence
φp+1
= φp − φ2p = −1,
p
2(p+1)
= 1. Therefore the order of φp in R×
and finally φp
p is a divisor of
2(p + 1), proving the second claim.
We call primes that are of the form p ≡ ±1 mod (5) reducible primes, and those
that are of the form p ≡ ±2 mod (5) (excluding p = 2) irreducible primes. We
now have upper bounds for π(p) in each case, more strongly we know that π(p)
divides its upper bound. We also know that 2 divides π(p) for p > 2. It is clear
that π(p) ≥ 4 for p > 2. In fact we can say more: if p is an irreducible prime, then 4
divides π(p). We’ll derive this result as Corollary 16 from of a result about Pisano
semiperiods later: the reader is invited to supply a direct proof as an exercise.
Taken together, the preceding results are enough to determine a total bound on
π(m). The proof of the following result was outlined in [FB92].
Theorem 10. The Pisano period satisfies π(m) ≤ 6m, with equality if and only if
m = 2 · 5j for some j > 0. Furthermore, if m 6= 2 · 5j , then π(m) ≤ 4m.
NOTES ON THE PISANO SEMIPERIOD
5
Proof. We decompose m as a product
m = 2i · 5j .pe11 · · · pe1r · q1f1 · · · qsfs ,
where p1 , . . . , pr are odd primes congruent to ±2 mod (5), q1 , . . . , qs are odd primes
congruent to ±1 mod (5). Using Lemma 7 we have
π(m) = lcm(π(2i · 5j · pe11 · · · perr ), π(q1f1 · · · qsfs )) ≤ π(2i · 5j · pe11 · · · perr ) · π(q1f1 · · · qsfs ).
By Lemma 7 again, and the assertion following Conjecture 8 that π(pe )|pe−1 π(p),
we have
π(q1f1 · · · qsfs ) = lcm(π(q1f1 ), . . . , π(qsfs ))
≤ π(q1f1 ) · · · π(qsfs )
≤ q1f1 −1 · π(q1 ) · · · qsfs −1 · π(qs ).
By Proposition 9 (i), each π(qi ) ≤ qj − 1, so for products of reducible primes:
π(q1f1 · · · qsfs ) ≤ q1f1 · · · qsfs .
Therefore we can disregard reducible primes when looking for upper bounds, as
π(m)
π(2i · 5j · pe11 · · · pe1r )
≤
.
m
2i · 5j · pe11 · · · pe1r
So we consider integers that are divisible only by irreducible primes, and the anomalous primes 2 and 5. It is useful to note here that π(2i ) = 3 · 2i−1 and π(5j ) = 4 · 5j .
First suppose that 2 does not divide m, and let m = 5j · pe11 · · · perr . We have
π(5j · pe11 · · · perr ) ≤ lcm(π(5j ), π(pe11 ), . . . , π(perr ))
= lcm(4 · 5j , π(pe11 ), . . . , π(perr ))
≤ 5j · p1e1 −1 · · · prer −1 · lcm(4, π(p1 ), . . . , π(pr )),
for the same reasons as above. From Proposition 9 (ii), each pi divides 2(pi + 1), so
π(5j · pe11 · · · perr ) ≤ 5j · p1e1 −1 · · · prer −1 · lcm(4, 2(p1 + 1), . . . , 2(pr + 1)).
Furthermore, each 2(pi + 1) is divisible by 4, so we have
π(pe11 · · · perr ) ≤ 4 · 5j · p1e1 −1 · · · perr −1 · lcm (p12+1) , . . . , (pr2+1)
Q
≤ 4 · 5j · p1e1 −1 · · · prer −1 · i pi2+1
Q i +1
≤ 4m · i p2p
i
≤ 4m.
Q
The product i pi2+1 is always less that 1, so equality is achieved if and only if
m = 5j . If m 6= 5j , then the maximum value of the product occurs when the only
other prime involved is 3. In this case π(m) ≤ 38 m, with equality if and only if
m = 5j · 3k (here we are using π(3k ) = 8 · 3k−1 ).
Now suppose that 2 divides m, say m = 2i m0 with m0 coprime to 2. We note that
4 divides π(m0 ), since 4 divides π(p) for any irreducible prime and 4 divides π(5j ).
We have
π(m) = lcm(π(2i ), π(m0 )) = lcm(3 · 2i−1 , π(m0 )).
6
TOM HARRIS
If i ≥ 3, then we can divide all terms by 4 as before:
π(m) = lcm(3 · 2i−1 , π(m0 )) = 4 lcm 3 · 2i−3 , 41 π(m0 )
≤ 4 · 3 · 2i−3 · 14 π(m0 )
≤
3
8
· 2i · 4m0
= 32 m.
If i = 2, then
π(m) = lcm(6, π(m0 )) = 2 lcm 3, 12 π(m0 )
≤ 2 · 3 · 21 π(m0 )
≤ 3 · 4m0
= 3m.
Finally, if i = 1, we have
π(m) = lcm(3, π(m0 ))
≤ 3π(m0 )
≤ 3 · 4m0
= 6m.
Since the equality π(m0 ) = 4m0 with m0 coprime to 2 is achieved only when m0 = 5j ,
it follows that π(m) = 6m is achieved only when m = 2 · 5j .
2. The Pisano semiperiod
In this section we use the results of the previous section give bounds on σ(m) and
to decide, where possible, whether σ(m) = π(m) or 21 π(m).
We begin our analysis of the Pisano semiperiod with a straightforward strengthening of Proposition 6.
Proposition 11. If m > 2, then σ(m) is even.
Proof. As in the proof of Proposition 6, we have a determinant homomorphism
det : GL2 (Z/mZ) → (Z/mZ)× . Since det(±I) = 1, the induced homomorphism
det : GL2 (Z/mZ)/{±I} → (Z/mZ)×
is well-defined. Recall that σ(m) is preciely the order of the image of the Fibonacci
matrix P = ( 01 11 ) in GL2 (Z/mZ)/{±I}. Then, as before, we have det(P ) = −1, so
(−1)σ(m) = 1 in Z/mZ. As m 6= 2, this implies that σ(m) is even.
Next we attempt to mimic Lemma 7 for σ(m). Determining the semiperiod of
composite numbers almost reduces to determining the semiperiod of prime powers,
but we are left with an ambiguous factor of 2.
Lemma 12. Let m1 , . . . , mr be coprime. Then σ(m1 · · · mr ) is equal to one of:
lcm(σ(m1 ), . . . , σ(mr )),
2 lcm(σ(m1 ), . . . , σ(mr )).
NOTES ON THE PISANO SEMIPERIOD
7
Proof. Let m = m1 · · · mr . The semiperiod σ(m) is equal to either π(m) or 12 π(m).
In either case, we have π(m) = lcm(π(m1 ), . . . , π(mr )). Each π(mi ) is equal to
either σ(mi ) or 2σ(mi ), so the highest power of 2 occurring in the divisors of the
collection {π(m1 ), . . . , π(mr )} can be at most one power higher than that occurring
among the divisors of {σ(m1 ), . . . , σ(mr )}. Hence π(m) = lcm(π(m1 ), . . . , π(mr ))
is equal to one of
lcm(σ(m1 ), . . . , σ(mr )),
2 lcm(σ(m1 ), . . . , σ(mr )).
If σ(m) = π(m), then this is the desired result. If σ(m) = 21 π(m), then σ(m) is
equal to one of
1
2 lcm(σ(m1 ), . . . , σ(mr )),
lcm(σ(m1 ), . . . , σ(mr )).
We will show that the first of these is impossible. By definition, σ(m) satisfies fm,σ(m) ≡ 0 mod (m1 · · · mr ) and fm,σ(m)+1 ≡ ±1 mod (m1 · · · mr ). But
then fm,σ(m) ≡ 0 mod (mi ) and fm,σ(m)+1 ≡ ±1 mod (mi ) for i = 1, . . . , r. So
σ(mi ) divides σ(m) for each m, and therefore σ(m) must be an integer multiple of
lcm(σ(m1 ), . . . , σ(mr )), ruling out the first case.
Two facts follow immediately from the proof of Lemma 12. Let m = m1 · · · mr
with the mi mutually coprime, as above. First, if σ(m) = 2 lcm(σ(m1 ), . . . , σ(mr )),
then θ(m) = 1, i.e., σ(m) = π(m). Second, if θ(m) = −1 (i.e., σ(m) = 21 π(m)
or m = 2), then σ(m) = lcm(σ(m1 ), . . . , σ(mr )). Furthermore, if θ(mi ) = −1
for every i, then the converse is true: σ(m) = lcm(σ(m1 ), . . . , σ(mr )) implies that
θ(m) = −1. Away from 2 we have, θ(mi ) = −1 if and only if π(mi ) = 2σ(mi ), so
π(m)
= lcm(π(m1 ), . . . , π(mr ))
= lcm(2σ(m1 ), . . . , 2σ(mr ))
= 2 lcm(σ(m1 ), . . . , σ(mr ))
= 2σ(m).
Very little needs to be changed to deal with the case where some mi is equal 2.
We now turn to the general problem of determining the Pisano signature of a
product of coprime factors. Let ν2 be the 2-adic valuation on the integers, given
by defining ν2 (m) to be the largest integer a such that 2a divides m.
Proposition 13. Let m1 , . . . , mr be coprime, and let m = m1 · · · mr .
(i) If θ(mi ) = 1 for some mi , then θ(m) = 1.
(ii) If θ(mi ) = −1 for every mi , and no mi is equal to 2, then θ(m) = −1 if
and only if ν2 (σ(m1 )) = ν2 (σ(m2 )) = · · · = ν2 (σ(mr )).
(iii) If θ(mi ) = −1 for every mi , and some mi is equal to 2 (wlog say m1 ), then
θ(m) = −1 if and only if ν2 (σ(m2 )) = ν2 (σ(m3 )) = · · · = ν2 (σ(mr )).
Proof. By the Chinese remainder theorem x ≡ 0 mod (m) if and only if x ≡ 0
mod (mi ) for i = 1, . . . , r. Similarly x ≡ 1 mod (m) if and only if x ≡ 1 mod (mi )
for i = 1, . . . , r, and x ≡ −1 mod (m) if and only if x ≡ −1 mod (mi ) for i =
1, . . . , r.
(i) Suppose θ(mi ) = 1 for some mi . If θ(m) = −1, then the pair 0, −1 appears
in the Fibonacci sequence modulo m. But this implies that 0, −1 appears
in the Fibonacci sequence modulo mi , contradicting θ(mi ) = 1. Hence
θ(m) = 1.
8
TOM HARRIS
(ii) Suppose θ(mi ) = −1 and mi 6= 2 for every mi . The statement θ(mi ) =
−1 is equivalent to Fσ(m) ≡ 0 mod (m) and Fσ(m)+1 ≡ −1 mod (m),
which is in turn equivalent to Fσ(m) ≡ 0 mod (mi ) and Fσ(m)+1 ≡ −1
mod (mi ) for all i. We have Fkσ(mi ) ≡ 0 mod (mi ) and Fkσ(mi )+1 ≡
(−1)k mod (mi ) for each i, and for every positive integer k, so θ(mi ) =
−1 if and only if σ(m) is an odd multiple of each σ(mi ). Since σ(m) is
a multiple of lcm(σ(m1 ), . . . , σ(mr )), if σ(m) is an odd multiple of each
σ(mi ), then so is lcm(σ(m1 ), . . . , σ(mr )). Therefore θ(mi ) = −1 implies
that lcm(σ(m1 ), . . . , σ(mr )) is an odd multiple of each σ(mi ), which is
equivalent to saying that all of the σ(mi ) have the same 2-adic valuation.
Conversely, if all of the σ(mi ) have the same 2-adic valuation, then r =
lcm(σ(m1 ), . . . , σ(mr )) is an odd multiple of each σ(mi ). It follows that
Fr ≡ 0 mod (mi ) and Fr+1 ≡ −1 mod (mi ) for all i. Therefore Fr ≡ 0
mod (m) and Fr+1 ≡ −1 mod (m), and so θ(m) = −1.
(iii) This is much the same as part (ii). Suppose θ(mi ) = −1 for every mi , and
let m1 = 2 (note that therefore mi 6= 2 for i > 1). If m = m1 = 2 the result
is trivial, so let m = 2m0 , where m0 = m2 · · · mr . We have θ(m) = −1
if and only if Fσ(m) ≡ 0 mod (m) and Fσ(m)+1 ≡ −1 mod (m). This
is equivalent to Fσ(m) ≡ 0 mod (2), Fσ(m)+1 ≡ −1 mod (2), Fσ(m) ≡ 0
mod (m0 ), and Fσ(m)+1 ≡ −1 mod (m0 ). But σ(m) is a multiple of σ(2),
and Fkσ(2) ≡ 0 mod (2) and Fkσ(2)+1 ≡ −1 mod (2) for any positive
integer k, since 1 ≡ −1 mod (2). So θ(m) = −1 implies Fσ(m) ≡ 0
mod (m0 ) and Fσ(m)+1 ≡ −1 mod (m0 ), which implies θ(m0 ) = −1. Since
m0 = m2 · · · mr , this implies the required condition on the 2-adic valuations
of m2 , . . . , mr by part (ii).
Conversely, the condition on the 2-adic valuations of m2 , . . . , mr implies
that θ(m0 ) = −1. Then r = lcm(σ(2), σ(m0 )) is equal to either σ(m0 )
or 3σ(m0 ) (since σ(2) = 3). In either case, Fr ≡ 0 mod (2), Fr ≡ 0
mod (m0 ), Fr ≡ −1 mod (2), and Fr ≡ −1 mod (m0 ). This implies
Fσ(m) ≡ 0 mod (m) and Fσ(m)+1 ≡ −1 mod (m), θ(m) = −1.
As a consequence of part (i) of the proposition, we can prove that asymptotically
the numbers with θ(m) = 1 dominate.
Having dealt with the Pisano signatures of products, we now consider the signature
of primes. For the anomalous primes 2 and 5 we have σ(2i ) = π(2i ) = 3 · 2i−1 ,
and σ(5j ) = 21 π(5j ) = 2 · 5j . The following simple lemma is a useful criterion for
determining when θ(p) = −1.
Lemma 14. Let p be prime that is not 2 or 5. Then σ(p) = 21 π(p) if and only if
−1 ∈ hφp i ≤ R×
p.
Proof. If p 6= 2, then σ(p) = 12 π(p) if and only if the consecutive pair 0, −1 appears
in the Fibonacci numbers modulo m if and only the pair −1, 0 appears (it’s the
preceding pair). As we saw in section 1, in Rp we have
φrp = fp,r−1 + fp,r φp .
From this it is clear that the pair −1, 0 appears if and only if −1 ∈ hφp i ≤ R×
p. NOTES ON THE PISANO SEMIPERIOD
9
Remark. Lemma 14 is still true for any m > 2 if we replace Rp with the more
general Rp := (Z/mZ)[t]/(t2 − t − 1).
In the proof of Proposition 9 (ii) we saw that if p ≡ ±2 mod (5), and p 6= 2,
then −1 ∈ hφp i ≤ R×
p . Lemma 14 therefore completely determines the relationship
between σ and π for irreducible primes.
Corollary 15. Let p 6= 2, 5 be prime satisfying p ≡ ±2 mod (5). Then σ(p) =
1
2 π(p), and σ(p) divides p + 1.
From Corollary 15 we can now immediately infer the stronger result about π(m)
that was promised in the discussion following the proof of Proposition 9 (ii).
Corollary 16. If p ≡ ±2 mod (5), and p 6= 2, then π(p) is a multiple of 4.
For the remaining primes p ≡ ±1 mod (5) the picture is less simple. Currently we
only have complete information for those p satisfying p ≡ 11 or p ≡ 19 mod (20).
Proposition 17. Let p 6= 2, 5 be prime satisfying p ≡ ±1 mod (5) and p ≡ 3
mod (4). Then σ(p) = π(p), and therefore divides p − 1.
Proof. Since p ≡ 3 mod (4), we can write p = 4k + 3 for some k. From Proposition
9 (i) we know that π(p) divides p − 1 = 4k + 2. if σ(p) 6= π(p), then σ(p) = 12 π(p)
and must therefore divide 2k + 1. By Proposition 11 this is a contradiction, as σ(p)
is even for p 6= 2.
For those primes equivalent to 1 or 9 modulo 20 we do not have a complete picture.
There are instances of such p with θ(p) = 1 and and instances with θ(p) = −1, in
both congruence classes. See the next section for a conjecture in this case.
The primes p ≡ 1, 9 mod (20) are reducible, so we are still able to derive a total
bound on the size of σ(m).
Theorem 18. The Pisano semiperiod satisfies σ(m) ≤ 4m, with equality if and
only if m = 2 · 3 · 5j for some j > 0.
Proof. The bound is easy to establish. We have σ(m) ≤ π(m) ≤ 6m. But π(m) =
6m if and only if m = 2 · 5j , otherwise π(m) ≤ 4m. So either σ(2 · 5j ) = π(2 · 5j ),
or σ(m) ≤ 4m. But by Proposition 13 (iii) we know that θ(2 · 5j ) = −1, so
σ(2 · 5j ) = 21 π(2 · 5j ) and the bound σ(m) ≤ 4m follows.
As discussed in the proof of Theorem 10, reducible primes can contribute a maxiσ(m)
mum of p−1
p to m , so they can once again be safely ignored. If θ(m) = −1, and
m 6= 2, then σ(m) = 21 m ≤ 21 6m = 3m. So we restrict our attention to products
m = 2i · 5j · pa1 1 · · · par r (i and j may be 0) with pi irreducible such that π(m) = 4m
and θ(m) = 1. We use the following facts from the proof of Theorem 10:
(i) If 2 does not divide m, then π(m) = 4m is achieved only when m = 5j .
(ii) If 2 does not divide m, and m 6= 5j , then π(m) ≤ 83 m, with equality if and
only if m = 3k or m = 5j · 3k .
(iii) If 4 divides m, then π(m) ≤ 3m.
(vi) For any m0 we have π(2m0 ) ≤ 3π(m0 ), with equality if 3 does not divide
π(m0 ).
j
As θ(5 ) = −1, the value m = 5j does not give σ(m) = 4m, so by the first fact we
can rule out all m such that 2 does not divide m. By the third fact we can rule
10
TOM HARRIS
out all m with a factor of 4, and consider only those numbers of the form m = 2m0
with m0 odd. By the fourth fact π(2m0 ) ≤ 3π(m0 ), so π(2m0 ) = 4m implies that
π(m0 ) ≥ 83 m0 . This is achieved only in the cases m0 = 5j , m0 = 3k or m0 = 5j · 3k ,
by the first and second facts. By Proposition 13 (ii) we can rule out the cases
m = 2 · 3k and m = 2 · 5j , as these have θ(m) = −1, so σ(m) = 12 π(m) ≤ 2m.
Therefore we can only possibly have σ(m) = 4m for m = 2 · 3k · 5j . By Proposition
13 (ii), this has θ(m) = 1, as σ(3k ) = 4 · 3k−1 and σ(5j ) = 2 · 5j have unequal 2-adic
valuations. Finally we calculate:
σ(m)
σ(m)
m
= π(m)
= π(2 · 3k · 5j )
= lcm(π(2), π(3k ), π(5j ))
= lcm(3, 8 · 3k−1 , 4 · 5j )
= 8 · 5j · 3max{1,k−1}
= (8 · 5j · 3max{1,k−1} ) · (2−1 · 3−k · 5−j )
= 4 · 3max{1−k,−1} .
Thus σ(m) = 4m is achieved exactly when k = 1, i.e., when m = 2 · 3 · 5j .
3. Unknown cases
As noted above, for primes in the congruence classes 1 and 9 modulo 20 we do not
have a good explanation of when the Pisano signature is 1 and when it is −1. There
are primes in each class with θ(m) = 1, and primes in each class with θ(m) = −1,
Computer experiments indicate that there seem to be more primes with θ(m) = −1
than θ(m) = 1 in both classes.
References
[FB92] Peter Freyd and Kevin S. Brown, Problems and Solutions: Solutions: E3410, Amer.
Math. Monthly 99 (1992), no. 3, 278–279.
[Rob63] D. W. Robinson, The Fibonacci matrix modulo m, Fibonacci Quart 1 (1963), no. 2,
29–36. MR 0158856 (28 #2079)
[SS16] David Singerman and James Strudwick, Petrie polygons and Farey maps, To appear in
Ars Math. Contemp. (2016).
[Wal60] D. D. Wall, Fibonacci series modulo m, Amer. Math. Monthly 67 (1960), 525–532.
© Copyright 2026 Paperzz