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.

A158299 Numerators of averages of squares of the divisors of n.

This page as a plain text file.
%I A158299 #32 Sep 01 2025 18:27:41
%S A158299 1,5,5,7,13,25,25,85,91,65,61,35,85,125,65,341,145,455,181,91,125,305,
%T A158299 265,425,217,425,205,175,421,325,481,455,305,725,325,637,685,905,425,
%U A158299 1105,841,625,925,427,1183,1325,1105,341,817,1085,725,595,1405,1025
%N A158299 Numerators of averages of squares of the divisors of n.
%C A158299 Because Mathematica represents rational numbers with the smallest possible denominator, the terms of the sequence are numerators appropriate to such denominators. For example, the divisors of 3 are 1 and 3, so their squares are 1 and 9. The mean of those squares could be represented as 10/2 or 5/1. Mathematica selects the latter so a(3) is 5 rather than 10. - _Harvey P. Dale_, Oct 13 2011
%C A158299 If m and n are coprime, f(m*n) divides f(m)*f(n). - _Robert Israel_, Jul 15 2019
%H A158299 Amiram Eldar, <a href="/A158299/b158299.txt">Table of n, a(n) for n = 1..10000</a> (terms 1..1000 from Harvey P. Dale)
%p A158299 f:= proc(n) local D;
%p A158299   D:= map(t -> t^2,numtheory:-divisors(n));
%p A158299   numer(convert(D,`+`)/nops(D));
%p A158299 end proc:
%p A158299 map(f, [$1..100]); # _Robert Israel_, Jul 15 2019
%t A158299 Numerator[Mean/@(Divisors[Range[60]]^2)] (* _Harvey P. Dale_, Oct 13 2011 *)
%t A158299 Array[Numerator[DivisorSigma[2, #]/DivisorSigma[0, #]] &, 100]; (* _Amiram Eldar_, Jul 15 2019 *)
%Y A158299 Cf. A001157, A000005, A158298 (for denominators).
%K A158299 nonn,frac,changed
%O A158299 1,2
%A A158299 _Jaroslav Krizek_, Mar 15 2009
%E A158299 Corrected and extended by _Harvey P. Dale_, Oct 13 2011