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.

A239868 Sum of sigma(i) mod i for i from 1 to n.

This page as a plain text file.
%I A239868 #20 Jan 12 2025 11:10:57
%S A239868 0,1,2,5,6,6,7,14,18,26,27,31,32,42,51,66,67,70,71,73,84,98,99,111,
%T A239868 117,133,146,146,147,159,160,191,206,226,239,258,259,281,298,308,309,
%U A239868 321,322,362,395,421,422,450,458,501,522,568,569,581,598,606,629,661
%N A239868 Sum of sigma(i) mod i for i from 1 to n.
%H A239868 Jaroslav Krizek, <a href="/A239868/b239868.txt">Table of n, a(n) for n = 1..1000</a>
%F A239868 a(n) = Sum_{k = 1...n} sigma(k) mod k = Sum_{k = 1...n} A054024(k).
%F A239868 a(n) = a(n - 1) for multiply-perfect numbers n (A007691).
%F A239868 a(p) = a(p - 1) + 1 for prime p.
%e A239868 a(3) = 2 because sigma(3) = 4 = 1 mod 3 and a(2) + 1 = 2.
%e A239868 a(4) = 5 because sigma(4) = 7 = 3 mod 4 and a(3) + 3 = 5.
%e A239868 a(5) = 6 because sigma(5) = 6 = 1 mod 5 and a(4) + 1 = 6.
%t A239868 Table[Sum[Mod[DivisorSigma[1, i], i], {i, n}], {n, 60}] (* _Alonso del Arte_, Mar 30 2014 *)
%t A239868 Accumulate[Table[Mod[DivisorSigma[1,n],n],{n,60}]] (* _Harvey P. Dale_, Jun 06 2021 *)
%o A239868 (Magma) [&+[SumOfDivisors (k) mod k: k in [1..n]]: n in [1..1000]]
%o A239868 (PARI) a(n) = sum(i=1, n, sigma(i) % i); \\ _Michel Marcus_, Jan 12 2025
%Y A239868 Cf. A000203, A054024, A239869 (values of n for which a(n)/n is an integer).
%K A239868 nonn
%O A239868 1,3
%A A239868 _Jaroslav Krizek_, Mar 28 2014