Lehmer sequence
{{hatnote|"Lehmer number" redirects here. It can also refer to a hypothetical solution to Lehmer's totient problem.}}
In mathematics, a Lehmer sequence or is a generalization of a Lucas sequence or , allowing the square root of an integer R in place of the integer P.{{Cite web|last=Weisstein|first=Eric W.|title=Lehmer Number|url=https://mathworld.wolfram.com/LehmerNumber.html|access-date=2020-08-11|website=mathworld.wolfram.com|language=en}}
To ensure that the value is always an integer, every other term of a Lehmer sequence is divided by {{radic|R}} compared to the corresponding Lucas sequence. That is, when R = P2 the Lehmer and Lucas sequences are related as:
:
P\,U_{2n}(\sqrt{P^2},Q) &= U_{2n}(P,Q) & U_{2n+1}(\sqrt{P^2},Q) &= U_{2n+1}(P,Q) \\
V_{2n}(\sqrt{P^2},Q) &= V_{2n}(P,Q) & P\,V_{2n+1}(\sqrt{P^2},Q) &= V_{2n+1}(P,Q)
\end{align}
Algebraic relations
If a and b are complex numbers with
:
:
under the following conditions:
- Q and R are relatively prime nonzero integers
- is not a root of unity.
Then, the corresponding Lehmer numbers are:
:
for n odd, and
:
for n even.
Their companion numbers are:
:
for n odd and
:
for n even.
Recurrence
Lehmer numbers form a linear recurrence relation with
:
with initial values . Similarly the companion sequence satisfies
:
with initial values
All Lucas sequence recurrences apply to Lehmer sequences if they are divided into cases for even and odd n and appropriate factors of {{radic|R}} are incorporated. For example,
:
U_{2n}(\sqrt R,Q) &= \phantom{R\,} U_{2n-1}(\sqrt R,Q) - Q\, U_{2n-2}(\sqrt R,Q) &
U_{2n+1}(\sqrt R,Q) &= R\, U_{2n}(\sqrt R,Q) - Q\, U_{2n-1}(\sqrt R,Q) \\
V_{2n}(\sqrt R,Q) &= R\, V_{2n-1}(\sqrt R,Q) - Q\, V_{2n-2}(\sqrt R,Q) &
V_{2n+1}(\sqrt R,Q) &= \phantom{R\,} V_{2n}(\sqrt R,Q) - Q\, V_{2n-1}(\sqrt R,Q)
\end{align}