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.

A000189 Number of solutions to x^3 == 0 (mod n).

Original entry on oeis.org

1, 1, 1, 2, 1, 1, 1, 4, 3, 1, 1, 2, 1, 1, 1, 4, 1, 3, 1, 2, 1, 1, 1, 4, 5, 1, 9, 2, 1, 1, 1, 8, 1, 1, 1, 6, 1, 1, 1, 4, 1, 1, 1, 2, 3, 1, 1, 4, 7, 5, 1, 2, 1, 9, 1, 4, 1, 1, 1, 2, 1, 1, 3, 16, 1, 1, 1, 2, 1, 1, 1, 12, 1, 1, 5, 2, 1, 1, 1, 4, 9, 1, 1, 2, 1, 1, 1, 4, 1, 3
Offset: 1

Views

Author

Keywords

Comments

Shadow transform of the cubes A000578. - Michel Marcus, Jun 06 2013

Examples

			a(4) = 2 because 0^3 == 0, 1^3 == 1, 2^3 == 0, and 3^3 == 3 (mod 4); also, a(9) = 3 because 0^3 = 0, 3^3 == 0, and 6^3 = 0 (mod 9), while x^3 =/= 0 (mod 9) for x = 1, 2, 4, 5, 7, 8. - _Petros Hadjicostas_, Sep 16 2019
		

Crossrefs

Programs

  • Mathematica
    Array[ Function[ n, Count[ Array[ PowerMod[ #, 3, n ]&, n, 0 ], 0 ] ], 100 ]
    f[p_, e_] := p^Floor[2*e/3]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* Amiram Eldar, Sep 19 2020 *)
  • PARI
    a(n)=my(f=factor(n));prod(i=1,#f[,1],f[i,1]^(2*f[i,2]\3)) \\ Charles R Greathouse IV, Jun 06 2013
    
  • PARI
    for(n=1, 100, print1(direuler(p=2, n, (1 + X + p*X^2)/(1 - p^2*X^3))[n], ", ")) \\ Vaclav Kotesovec, Aug 30 2021

Formula

Multiplicative with a(p^e) = p^[2e/3]. - David W. Wilson, Aug 01 2001
a(n) = n/A019555(n). - Petros Hadjicostas, Sep 15 2019
Dirichlet g.f.: zeta(3*s-2) * Product_{p prime} (1 + 1/p^s + 1/p^(2*s-1)). - Amiram Eldar, Sep 09 2023
From Vaclav Kotesovec, Sep 09 2023: (Start)
Dirichlet g.f.: zeta(s) * zeta(2*s-1) * zeta(3*s-2) * Product_{p prime} (1 - 1/p^(2*s) - 1/p^(3*s-1) - 1/p^(4*s-2) + 1/p^(4*s-1) + 1/p^(5*s-2)).
Let f(s) = Product_{primes p} (1 - 1/p^(2*s) - 1/p^(3*s-1) - 1/p^(4*s-2) + 1/p^(4*s-1) + 1/p^(5*s-2)).
Sum_{k=1..n} a(k) ~ (f(1)*n/6) * (log(n)^2/2 + (6*gamma - 1 + f'(1)/f(1))*log(n) + 1 - 6*gamma + 11*gamma^2 - 14*sg1 + (6*gamma - 1)*f'(1)/f(1) + f''(1)/(2*f(1))), where
f(1) = Product_{primes p} (1 - 3/p^2 + 2/p^3) = A065473 = 0.2867474284344787341078927127898384464343318440970569956414778593366522431...,
f'(1) = f(1) * Sum_{primes p} 9*log(p) / (p^2 + p - 2) = f(1) * 4.1970213428422788650375569145777616746065054412058004220013841318980729375...,
f''(1) = f'(1)^2/f(1) + f(1) * Sum_{primes p} (-29*p^2 - 17*p + 1) * log(p)^2 / (p^2 + p - 2)^2 = f'(1)^2/f(1) + f(1) * (-21.3646716550082193262514333696570765444176783899223644201265894338042468...),
gamma is the Euler-Mascheroni constant A001620 and sg1 is the first Stieltjes constant (see A082633). (End)