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.

A352996 a(n) = n*(n+1)/2 mod (sum (with multiplicity) of prime factors of n).

Original entry on oeis.org

1, 0, 2, 0, 1, 0, 0, 3, 6, 0, 1, 0, 6, 0, 0, 0, 3, 0, 3, 1, 6, 0, 3, 5, 6, 0, 10, 0, 5, 0, 8, 1, 6, 6, 6, 0, 6, 12, 6, 0, 3, 0, 0, 1, 6, 0, 10, 7, 3, 6, 1, 0, 0, 4, 10, 3, 6, 0, 6, 0, 6, 1, 4, 3, 3, 0, 15, 23, 7, 0, 0, 0, 6, 3, 5, 15, 3, 0, 3, 9, 6, 0, 0, 3, 6, 20, 6, 0, 0, 6, 12, 19, 6, 0, 2, 0
Offset: 2

Views

Author

J. M. Bergot and Robert Israel, Apr 14 2022

Keywords

Comments

If n is an odd prime, a(n) = 0.
If n is prime, a(n^2) = n.

Examples

			For n = 6, A000217(6) = 6*7/2 = 21 and A001414(6) = 2+3 = 5, so a(6) = 21 mod 5 = 1.
		

Crossrefs

Programs

  • Maple
    seq((n*(n+1)/2) mod add(t[1]*t[2],t=ifactors(n)[2]), n=2..100);
  • Mathematica
    a[n_] := Mod[n*(n + 1)/2, Plus @@ Times @@@ FactorInteger[n]]; Array[a, 100, 2] (* Amiram Eldar, Apr 15 2022 *)
  • Python
    from sympy import factorint
    def a(n): return (n*(n+1)//2)%sum(p*e for p, e in factorint(n).items())
    print([a(n) for n in range(2, 98)]) # Michael S. Branicky, Apr 24 2022

Formula

a(n) = A000217(n) mod A001414(n).

A352990 Numbers k such that the k-th triangular number == 1 mod the integer log of k.

Original entry on oeis.org

2, 6, 12, 21, 33, 45, 52, 63, 136, 162, 201, 205, 208, 225, 245, 253, 301, 304, 344, 441, 494, 531, 550, 637, 697, 720, 742, 806, 901, 910, 918, 1078, 1233, 1242, 1274, 1333, 1376, 1540, 1566, 1573, 1625, 1680, 1695, 1792, 1863, 1909, 2025, 2041, 2107, 2295, 2466, 2497, 2774, 2896, 2926, 2965
Offset: 1

Views

Author

J. M. Bergot and Robert Israel, Apr 13 2022

Keywords

Comments

Numbers k such that A000217(k) == 1 (mod A001414(k)).

Examples

			a(3) = 12 = 2*2*3 is a term because 12*13/2 = 78 == 1 (mod 2+2+3 = 7).
		

Crossrefs

Programs

  • Maple
    filter:= proc(n) local t; (n*(n+1)/2) mod add(t[1]*t[2],t=ifactors(n)[2]) = 1 end proc:
    select(filter, [$2..3000]);
  • Mathematica
    Select[Range[3000], Mod[#*(# + 1)/2, Plus @@ Times @@@ FactorInteger[#]] == 1 &] (* Amiram Eldar, Apr 14 2022 *)
Showing 1-2 of 2 results.