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.
%I A078730 #32 Nov 29 2022 13:41:17 %S A078730 0,2,3,10,5,26,7,42,30,62,11,116,13,114,93,170,17,242,19,280,171,266, %T A078730 23,476,130,366,273,528,29,713,31,682,399,614,285,1070,37,762,549, %U A078730 1150,41,1342,43,1264,873,1106,47,1916,350,1562,921,1752,53,2186,665,2166,1143 %N A078730 Sum of products of two successive divisors of n. %C A078730 a(n) = dot_product (d_1,d_2,...,d_(tau(n)-1))*(d_2,d_3,...d_tau(n)), where d_1<d_2<...<d_tau(n), is increasing sequence of divisors of n. a(10) = dot_product (1,2,5)*(2,5,10) = 2+10+50 = 62. %C A078730 a(n) = n if and only if n is prime. - _Robert Israel_, May 05 2014 %C A078730 The 4th problem of the 43rd International Mathematical Olympiad asked to prove that a(n) < n^2 and determine when a(n) is a divisor of n^2? (answer is: iff n is prime). - _Bernard Schott_, Nov 28 2022 %H A078730 Robert Israel, <a href="/A078730/b078730.txt">Table of n, a(n) for n = 1..10000</a>. %H A078730 The IMO Compendium, <a href="https://imomath.com/othercomp/I/Imo2002.pdf">Problem 4</a>, 43rd IMO 2002, Glasgow, UK. %H A078730 <a href="/index/O#Olympiads">Index to sequences related to Olympiads</a>. %F A078730 a(p^e) = p * (p^(2e) - 1) / (p^2 -1). - _Bernard Schott_, Nov 28 2022 %F A078730 n <= a(n) < n^2 for n > 1. a(n)/n^2 can be arbitrarily close to n (proof: let n be divisible by the numbers up to k, for large enough k). a(n) > n^(3/2) for n composite. - _Charles R Greathouse IV_, Nov 29 2022 %p A078730 A078730:= proc(n) %p A078730 local d,i; %p A078730 d:= numtheory[divisors](n); %p A078730 add(d[i]*d[i+1], i=1..nops(d)-1) %p A078730 end proc; %p A078730 seq(A078730(n),n=1..100); # _Robert Israel_, May 05 2014 %t A078730 f[n_] := Module[{d, l, s, i}, d = Divisors[n]; l = Length[d]; s = 0; For[i = 1, i < l, i++, s = s + d[[i + 1]]*d[[i]]]; s]; Table[ f[n], {n, 1, 100}] %t A078730 f[n_] := Plus @@ Times @@@ Partition[ Divisors@ n, 2, 1]; Array[f, 57] (* _Robert G. Wilson v_, Dec 18 2014 *) %o A078730 (Haskell) %o A078730 a078730 n = sum $ zipWith (*) ps $ tail ps where ps = a027750_row n %o A078730 -- _Reinhard Zumkeller_, Dec 20 2014 %o A078730 (PARI) a(n) = my(d = divisors(n)); sum(k=1, #d-1, d[k]*d[k+1]); \\ _Michel Marcus_, Feb 15 2015 %Y A078730 Cf. A078713(n) = 2*A001157(n)-2*a(n)-n^2-1. %Y A078730 Cf. A027750. %K A078730 nonn %O A078730 1,2 %A A078730 _Vladeta Jovovic_, Dec 20 2002