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.

A384040 The number of integers k from 1 to n such that gcd(n,k) is a cubefull number.

This page as a plain text file.
%I A384040 #7 May 18 2025 04:24:26
%S A384040 1,1,2,2,4,2,6,5,6,4,10,4,12,6,8,10,16,6,18,8,12,10,22,10,20,12,19,12,
%T A384040 28,8,30,20,20,16,24,12,36,18,24,20,40,12,42,20,24,22,46,20,42,20,32,
%U A384040 24,52,19,40,30,36,28,58,16,60,30,36,40,48,20,66,32,44,24
%N A384040 The number of integers k from 1 to n such that gcd(n,k) is a cubefull number.
%C A384040 The number of integers k from 1 to n such that the cubefree part (A360539) of gcd(n,k) is 1.
%H A384040 Amiram Eldar, <a href="/A384040/b384040.txt">Table of n, a(n) for n = 1..10000</a>
%F A384040 Multiplicative with a(p^e) = (p^3-p^2+1)*p^(e-3) if e >= 3, p*(p-1) if e = 2, and p-1 otherwise.
%F A384040 a(n) >= A384039(n), with equality if and only if n is squarefree (A005117).
%F A384040 Dirichlet g.f.: zeta(s-1) * Product_{p prime} (1 - 1/p^s + 1/p^(3*s)).
%F A384040 Sum_{k=1..n} a(k) ~ c * n^2 / 2, where c = Product_{p prime} (1 - 1/p^2 + 1/p^6) = 0.62159731307414305346... .
%t A384040 f[p_, e_] := Switch[e, 1, p-1, 2, p^2-p, _, (p^3-p^2+1)*p^(e-3)]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100]
%o A384040 (PARI) a(n) = {my(f = factor(n)); prod(i = 1, #f~, if(f[i,2] == 1, f[i,1]-1, if(f[i,2] == 2, f[i,1]*(f[i,1]-1), (f[i,1]^3-f[i,1]^2+1)*f[i,1]^(f[i,2]-3))));}
%Y A384040 Cf. A005117, A036966, A078429, A360539, A254926.
%Y A384040 The number of integers k from 1 to n such that gcd(n,k) is: A026741 (odd), A062570 (power of 2), A063659 (squarefree), A078429 (cube), A116512 (power of a prime), A117494 (prime), A126246 (1 or 2), A206369 (square), A254926 (cubefree), A372671 (3-smooth), A384039 (powerful), this sequence (cubefull), A384041 (exponentially odd), A384042 (5-rough).
%K A384040 nonn,easy,mult
%O A384040 1,3
%A A384040 _Amiram Eldar_, May 18 2025