cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A357913 Inverse of 10 modulo prime(n).

This page as a plain text file.
%I A357913 #54 Feb 07 2025 15:55:04
%S A357913 5,10,4,12,2,7,3,28,26,37,13,33,16,6,55,47,64,22,8,25,9,68,91,31,75,
%T A357913 11,34,89,118,96,14,15,136,110,49,117,52,18,163,172,58,138,20,190,67,
%U A357913 159,23,70,24,217,226,180,79,27,244,194,253,85,88,215,280,94,222,298,236,243
%N A357913 Inverse of 10 modulo prime(n).
%C A357913 Original definition: "Another test for divisibility by the n-th prime (see Comments for precise definition)."
%C A357913 Given a number M, delete its last digit d, then add d*a(n). If the result is divisible by prime(n), then M is also divisible by prime(n). This process may be repeated.
%C A357913 a(n) can be quickly calculated by finding the smallest multiple of prime(n) ending in 9, adding one, and dividing that result by 10. E.g., 7 -> 49 -> 5, 11 -> 99 -> 10, 13 -> 39 -> 4, 17 -> 119 -> 12, 19 -> 19 -> 2.
%C A357913 Equivalent definition: a(n) = 10^(p - 2) mod p, where p = prime(n). - _Mauro Fiorentini_, Feb 06 2025
%H A357913 Paolo Xausa, <a href="/A357913/b357913.txt">Table of n, a(n) for n = 4..10000</a>
%F A357913 a(n) = prime(n) - A103876(n).
%F A357913 a(n) = (A114013(n) + 1)/10. - _Hugo Pfoertner_, Jan 28 2023
%t A357913 PowerMod[10, -1, Prime[Range[4, 100]]] (* _Paolo Xausa_, Feb 07 2025 *)
%o A357913 (Python)
%o A357913 import sympy
%o A357913 [pow(10, -1, p) for p in sympy.primerange(7,348)]
%o A357913 (PARI) apply( {A357913(n)=lift(1/Mod(10,prime(n)))}, [4..49]) \\ _M. F. Hasler_, Feb 03 2025
%Y A357913 Cf. A103876, A078606, A114013.
%K A357913 nonn,base
%O A357913 4,1
%A A357913 _Nicholas Stefan Georgescu_, Jan 18 2023
%E A357913 Better definition from _M. F. Hasler_, Feb 03 2025