OFFSET
1,1
COMMENTS
If a(n) = 0 then prime(n) is both a Wieferich prime (A001220) and a Wall-Sun-Sun (Fibonacci-Wieferich) prime.
If the first case of Fermat's last theorem fails for a prime p, that prime is both a Wieferich prime (cf. Wieferich, 1909) and a Wall-Sun-Sun prime (cf. Sun, 1992).
LINKS
Zhi-Wei Sun, Fibonacci numbers and Fermat's last theorem, Acta Arithemtica, Vol. 60, No. 4 (1992), 371-388.
A. Wieferich, Zum letzten Fermat'schen Theorem, Journal für die reine und angewandte Mathematik, 136 (1909), 293-302, DOI:10.1515/crll.1909.136.293.
PROG
(PARI) a(n) = my(p=prime(n)); lift(Mod([1, 1; 1, 0]^(p-kronecker(p, 5)), p^2)[1, 2]) + lift(Mod(2, p^2)^(p-1)) - 1
CROSSREFS
KEYWORD
nonn
AUTHOR
Felix Fröhlich, Dec 11 2020
STATUS
approved