login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A056968
10^(n-1) modulo n.
2
0, 0, 1, 0, 0, 4, 1, 0, 1, 0, 1, 4, 1, 10, 10, 0, 1, 10, 1, 0, 16, 10, 1, 16, 0, 10, 19, 20, 1, 10, 1, 0, 1, 10, 25, 28, 1, 10, 22, 0, 1, 40, 1, 32, 10, 10, 1, 16, 8, 0, 49, 12, 1, 46, 45, 24, 43, 10, 1, 40, 1, 10, 37, 0, 55, 10, 1, 48, 31, 20, 1, 64, 1, 10, 25, 12, 67, 4, 1, 0, 73, 10, 1
OFFSET
1,6
LINKS
FORMULA
If n is of form 2^i*5^j then a(n)=0, otherwise a(n)=10^(n-1)+n-A053041(n)
From Robert Israel, Nov 25 2024: (Start)
If n is prime other than 2 or 5, then a(n) = 1.
If n = 2^i * 5^j * p where p is a prime > 10^(2^i * 5^j), then a(n) = 10^(2^i * 5^j).
If n = 2^i * 5^j * p where p is a prime and
2^(2^i * 5^j - 1 - i) * 5^(2^i * 5^j -1 - j) > p > 2^(2^i * 5^j-2 - u) * 5^(2^i * 5^j-1-j),
then a(n) = 10^(2^i * 5^j - 1) - 2^i * 5^j * p.
For example, with i = 0 and j = 1 we get a(5*p) = 10^4 - 5*p if p is a prime between 1000 and 2000.
(End)
EXAMPLE
a(6)=4 since 100000=6*16666+4
MAPLE
0, seq(10&^(n-1) mod n, n=2..100); # Robert Israel, Nov 25 2024
MATHEMATICA
Table[PowerMod[10, n-1, n], {n, 100}] (* Harvey P. Dale, Jul 17 2021 *)
CROSSREFS
KEYWORD
nonn,look
AUTHOR
Henry Bottomley, Jul 20 2000
STATUS
approved