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.

A185373 The numerator of the fraction |n^2/A049417(n)-A064380(n)|.

Original entry on oeis.org

1, 1, 1, 1, 0, 1, 4, 1, 5, 1, 1, 1, 1, 3, 1, 1, 1, 1, 1, 7, 5, 1, 2, 1, 2, 9, 3, 1, 1, 1, 4, 11, 11, 25, 2, 1, 1, 9, 2, 1, 11, 1, 4, 3, 7, 1, 2, 1, 2, 1, 13, 1, 3, 1, 13, 49, 17, 1, 0, 1, 1, 49, 16, 25, 1, 1, 17, 19, 35, 1, 14, 1, 2
Offset: 2

Views

Author

Vladimir Shevelev, Feb 17 2011

Keywords

Comments

n^2/A049417(n) is a multiplicative function, whereas A064380 is not. This sequence here measures the (small) differences n^2/A049417(n)-A064380(n) = 1/3, 1/4, 1/5, 1/6, 0, 1/8, 4/15, 1/10, 5/9, 1/12, 1/5 ...

Crossrefs

Cf. A064380, A049417, A185383 (denominators)

Programs

  • Mathematica
    f[p_, e_] := p^(2^(-1 + Position[Reverse @ IntegerDigits[e, 2], ?(# == 1 &)])); isigma[1] = 1; isigma[n] := Times @@ (Flatten@(f @@@ FactorInteger[n]) + 1);
    infCoprimeQ[n1_, n2_] := Module[{g = GCD[n1, n2]}, If[g == 1, True, AllTrue[ FactorInteger[g][[;; , 1]], BitAnd @@ IntegerExponent[{n1, n2}, #] == 0 &]]];
    a[n_] := Abs[Numerator[n^2 / isigma[n] - Sum[Boole[infCoprimeQ[j, n]], {j, 1, n-1}]]]; Array[a, 100, 2] (* Amiram Eldar, Mar 20 2025 *)