[seqfan] Re: Sum of Pell numbers and companion Pell numbers

Max Alekseyev maxale at gmail.com
Sat Apr 29 14:58:17 CEST 2023


It all follows from the explicit formula:
a(n) = (1 + sqrt(2))^n + (1 - sqrt(2))^n.

For an odd prime p, we have
(1 +- sqrt(2))^(p-1) == 1 (mod p) whenever 2 is a quadratic residue modulo
p, ie. p == 1,7 (mod 8);
and
(1 +- sqrt(2))^(p+1) == 1 (mod p) whenever 2 is a non-quadratic residue
modulo p, ie. p == 3,5 (mod 8).
It follows that the period length q(p) of a() modulo p divides p-1 or p+1,
respectively.

Then, a(m) == 0 (mod p) is equivalent to
(1 + sqrt(2))/(1-sqrt(2))^m = (1 + sqrt(2))^(2m) * (-1)^m == -1 (mod p).
If m is the smallest, ie. m = r(p) is the rank of apparition, then r(p) =
q(p)/2 when it's odd; or r(p) = q(p)/4 when it's even.
In the former case, there is only one zero in the period modulo p, ie. if
a(m) == 0 (mod p) and q(p)/2 is odd, then m == q(p)/2 (mod q(p)) and thus
q(p)/2 divides m.
In the latter case, there are two zeros in the period modulo p, ie. if a(m)
== 0 (mod p) and q(p)/4 is even, then m == q(p)/4 (mod q(p)/2) and thus
q(p)/4 divides m.

Let me know if anything is still unclear.

Regards,
Max

On Sat, Apr 29, 2023 at 2:51 AM Robert Dougherty-Bliss <
robert.w.bliss at gmail.com> wrote:

> Dear Max,
>
> Thank you for the proof! I am excited about it, because this is
> exactly what I suspected was true. However, I'm having some trouble
> following the details of your argument.
>
> > Let p be the smallest prime dividing m and r(p) the rank of apparition of
> > a() modulo p, then the period of a() modulo p is either 2*r(p) or 4*r(p),
> > and it divides p-1 or p+1.
>
> Why is the period either 2 * r(p) or 4 * r(p)? And why does it divide
> p - 1 or p + 1?
>
> > That is, r(p) <= (p+1)/2 < p and r(p) divides m, which together with
> > minimality of p implies r(p)=1.
>
> Why does r(p) divide m?
>
> I know some similar facts / arguments about Fibonacci numbers, but I
> don't see how the ideas apply here.
>
> Robert
>
> > On Thu, Apr 27, 2023 at 11:05 PM Robert Dougherty-Bliss <
> > robert.w.bliss at gmail.com> wrote:
> >
> > > Dear Sequence Fans,
> > >
> > > Consider the sequence a(n) which satisfies the recurrence
> > >      a(n) = 2 * a(n - 1) + a(n - 2)
> > > with initial conditions a(0) = a(1) = 2. (This is A2203, the companion
> > > Pell numbers.)
> > >
> > > The sequence of positive n such that a(n) = 2 (mod n) begins
> > > 1, 2, 3, 4, 5, 7, 8, 11, 13, 16, 17, 19, 23, 24, 29.
> > > Except for the leading 1 and 2, this looks like A270342, the sequence
> > > of n such that n divides the sum of the first n Pell numbers, but
> > > there is no comment to this effect. Can anyone prove this?
> > >
> > > The sum of the first n Pell numbers S(n) turns out to equal (a(n) - 2)
> > > / 4, so everything in A270342 is in this sequence. For the other way,
> > > I have managed to prove that if a(n) = 2 (mod n) and n is odd or
> > > divisible by 4, then n is in A270341, but I cannot figure out the
> > > "divisible by just 2" case.
> > >
> > > Robert
> > >
> > > --
> > > Seqfan Mailing list - http://list.seqfan.eu/
> > >
> >
> > --
> > Seqfan Mailing list - http://list.seqfan.eu/
>
> --
> Seqfan Mailing list - http://list.seqfan.eu/
>


More information about the SeqFan mailing list