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.

Showing 1-2 of 2 results.

A338935 a(n) = Sum_{d|n} (d^2 mod n).

Original entry on oeis.org

0, 1, 1, 1, 1, 8, 1, 5, 1, 10, 1, 18, 1, 12, 20, 5, 1, 23, 1, 26, 17, 16, 1, 58, 1, 18, 10, 42, 1, 70, 1, 21, 32, 22, 40, 39, 1, 24, 23, 90, 1, 106, 1, 54, 71, 28, 1, 98, 1, 55, 44, 34, 1, 104, 37, 106, 29, 34, 1, 240, 1, 36, 77, 21, 65, 160, 1, 38, 56, 200, 1, 175, 1, 42, 60, 78, 94, 154, 1, 146
Offset: 1

Views

Author

J. M. Bergot and Robert Israel, Nov 16 2020

Keywords

Examples

			a(6) = (1^2 mod 6) + (2^2 mod 6) + (3^2 mod 6) + (6^2 mod 6) = 1+4+3+0 = 8.
		

Crossrefs

Cf. A000430 (a(n)=1), A338930 (a(n) is prime).

Programs

  • Maple
    f:= n -> add(t^2 mod n, t = numtheory:-divisors(n)):
    map(f, [$1..100]);
  • Mathematica
    Table[Total[Mod[Divisors[n]^2,n]],{n,80}] (* Harvey P. Dale, Oct 11 2021 *)
  • PARI
    a(n) = sumdiv(n, d, lift(Mod(d, n)^2)); \\ Michel Marcus, Nov 16 2020

A338936 Primes in A338935.

Original entry on oeis.org

5, 5, 23, 17, 23, 71, 37, 29, 41, 103, 113, 71, 47, 101, 53, 359, 227, 293, 71, 79, 67, 83, 709, 89, 271, 149, 643, 107, 113, 401, 97, 257, 137, 227, 149, 1051, 167, 577, 263, 173, 127, 269, 839, 263, 191, 599, 359, 1399, 401, 709, 659, 1213, 157, 233, 359, 239, 223, 577, 353, 727, 251, 677, 257
Offset: 1

Views

Author

J. M. Bergot and Robert Israel, Nov 16 2020

Keywords

Examples

			a(3) = A338935(18) = 23 is the third prime in A338935.
		

Crossrefs

Programs

  • Maple
    f:= n -> add(t^2 mod n, t = numtheory:-divisors(n)):
    select(isprime, map(f, [$1..1000]));

Formula

a(n) = A338935(A338930(n)).
Showing 1-2 of 2 results.