A094540 Last digit of the n-th perfect number.
6, 8, 6, 8, 6, 6, 8, 8, 6, 6, 8, 8, 6, 8, 8, 8, 6
Offset: 1
References
- David Wells, The Penguin Dictionary of Curious and Interesting Numbers. Penguin Books, NY, 1986, Revised edition 1987. See p. 107.
Links
- Math Forum at Drexel, List of Perfect Numbers.
- Eric Weisstein's World of Mathematics, Perfect Number.
Programs
-
Maple
# (Maple code from N. J. A. Sloane) # let s1 := list of terms in A000043 f:=n->if n mod 4 = 0 then 4 else n mod 4; fi; g:= x->2^f(x-1)*(2^f(x)-1); map(g,s1);
-
Mathematica
p={ the list of the Mersenne exponents (A000043) }; Mod[(PowerMod[2, p, 10] - 1)(PowerMod[2, p - 1, 10]), 10] (* Robert G. Wilson v, May 23 2004 *)
Comments