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 A038388 #28 Jul 08 2025 22:23:51 %S A038388 1,2,3,4,5,6,7,4,3,10,11,12,13,14,15,8,17,6,19,20,21,22,23,12,5,26,9, %T A038388 28,29,30,31,8,33,34,35,12,37,38,39,20,41,42,43,44,15,46,47,24,7,10, %U A038388 51,52,53,18,55,28,57,58,59,60,61,62,21,16,65,66,67,68,69,70,71,12,73,74,15 %N A038388 Let f(n) be the smallest number such that the arithmetic mean (A) and geometric mean (G) of n and f(n) are both integers; sequence gives G values. %H A038388 Amiram Eldar, <a href="/A038388/b038388.txt">Table of n, a(n) for n = 1..10000</a> %F A038388 Multiplicative with a(p^e) = p^((e+1)/2) if e is odd, 2^(e/2+1) if p=2 and e is even, p^(e/2) if p>2 and e is even. - _Vladeta Jovovic_, May 15 2003 %F A038388 Sum_{k=1..n} a(k) ~ c * n^2, where c = (13/24)*zeta(3)/zeta(2) = 0.395829... . - _Amiram Eldar_, Oct 27 2022 %t A038388 Table[k = 1; While[Nand @@ IntegerQ /@ {(n + k)/2, g = Sqrt[n*k]}, k++]; g, {n, 75}] (* _Jayanta Basu_, Jul 14 2013 *) %t A038388 f[p_, e_] := If[OddQ[e], p^((e + 1)/2), If[p == 2, 2^(e/2 + 1), p^(e/2)]]; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* _Amiram Eldar_, Sep 09 2020*) %o A038388 (PARI) a(n) = {my(f = factor(n)); prod(i = 1, #f~, if(f[i,2]%2, f[i,1]^((f[i,2]+1)/2), if(f[i,1]==2, 2^(f[i,2]/2+1), f[i,1]^(f[i,2]/2))));} \\ _Amiram Eldar_, Oct 27 2022 %Y A038388 Cf. A038387, A038389. %Y A038388 Cf. A053626, A053627, A253905. %K A038388 nonn,easy,mult %O A038388 1,2 %A A038388 _N. J. A. Sloane_ %E A038388 More terms from _Vladeta Jovovic_, May 15 2003