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.

A380421 a(n) is the inverse of 2^3 modulo prime(n).

This page as a plain text file.
%I A380421 #32 Feb 24 2025 22:44:40
%S A380421 2,2,1,7,5,15,12,3,11,4,14,36,27,6,20,37,23,42,9,64,10,52,78,85,38,13,
%T A380421 67,41,99,16,82,120,87,56,19,59,102,21,65,112,68,24,169,74,25,132,28,
%U A380421 142,86,204,30,211,157,225,33,101,34,104,246,177,110,192,39,274
%N A380421 a(n) is the inverse of 2^3 modulo prime(n).
%H A380421 Robert Israel, <a href="/A380421/b380421.txt">Table of n, a(n) for n = 2..10000</a>
%F A380421 a(n) = 8^(-1) (mod prime(n)) for n >= 2.
%F A380421 a(n) = (A006254(n) * A292411(n)) (mod prime(n)) for n >= 2.
%F A380421 If prime(n) mod 8 = j in {1, 3, 5, 7}, then a(n) = (1 + (8-j)*prime(n))/8. - _Robert Israel_, Feb 24 2025
%p A380421 seq(1/8 mod ithprime(n), n=2..65);  # _Alois P. Heinz_, Feb 14 2025
%t A380421 a[n_] := ModularInverse[8, Prime[n]]; Array[a, 100, 2] (* _Amiram Eldar_, Feb 05 2025 *)
%o A380421 (PARI) a(n) = lift(1/Mod(8, prime(n))); \\ _Michel Marcus_, Jan 25 2025
%o A380421 (Python)
%o A380421 from sympy import prime
%o A380421 def A380421(n): return pow(8,-1,prime(n)) # _Chai Wah Wu_, Feb 14 2025
%Y A380421 Cf. A006254, A292411.
%K A380421 nonn,look
%O A380421 2,1
%A A380421 _R. J. Cintra_, Jan 25 2025