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.

A277802 The least k > 0 such that k*A004709(n) is a cube.

Original entry on oeis.org

1, 4, 9, 2, 25, 36, 49, 3, 100, 121, 18, 169, 196, 225, 289, 12, 361, 50, 441, 484, 529, 5, 676, 98, 841, 900, 961, 1089, 1156, 1225, 6, 1369, 1444, 1521, 1681, 1764, 1849, 242, 75, 2116, 2209, 7, 20, 2601, 338, 2809, 3025, 3249, 3364, 3481, 450, 3721, 3844
Offset: 1

Views

Author

Peter Kagey, Oct 31 2016

Keywords

Comments

This is a permutation of the cubefree numbers (A004709).
a(n) <= A004709(n)^2, with equality iff A004709(n) is squarefree. - Robert Israel, Nov 09 2016

Examples

			a(8) = 3 because 3 * A004709(8) = 3 * 9 = 3^3.
a(16) = 12 because A004709(16) = 18 = 2^1 * 3^2. The least k such that k * 2^1 * 3^2 is a cube is 2^(3 - (1 mod 3)) * 3^(3 - (2 mod 3)) = 12. - _David A. Corneth_, Nov 01 2016
		

Crossrefs

Programs

  • Maple
    f:= proc(n) local F,E;
       F:= ifactors(n)[2];
       E:= F[..,2];
       if max(E) >= 3 then return NULL fi;
       mul(F[i,1]^(3-E[i]),i=1..nops(F));
    end proc:
    map(f, [$1..1000]); # Robert Israel, Nov 09 2016
  • Mathematica
    Table[k = 1; While[! IntegerQ[(k #)^(1/3)], k++] &@ #[[n]]; k, {n, 53}] &@ Select[Range[10^4], FreeQ[FactorInteger@ #, {, k /; k > 2}] &] (* Michael De Vlieger, Nov 01 2016, after Jan Mangaldan at A004709 *)
    f[p_, e_] := If[e > 2, 0, p^(Mod[-e, 3])]; s[n_] := Times @@ f @@@ FactorInteger[n]; Select[Array[s, 100], # > 0 &] (* Amiram Eldar, Feb 20 2024 *)
  • PARI
    \\ A list of about n terms (a little more probably).
    lista(n) = {n = ceil(1.21*n); my(l=List([1]), f); forprime(p=2, n, for(i=1, #l, if(l[i] * p<=n, listput(l, l[i]*p); if(l[i]*p^2<=n, listput(l,l[i]*p^2)))));listsort(l); for(i=2, #l, f=factor(l[i]); f[, 2] = vector(#f[,2],i,3-(f[i,2] % 3))~; l[i] = factorback(f));l} \\ David A. Corneth, Nov 01 2016
    
  • Python
    from math import prod
    from sympy import mobius, factorint, integer_nthroot
    def A277802(n):
        def f(x): return n+x-sum(mobius(k)*(x//k**3) for k in range(1, integer_nthroot(x,3)[0]+1))
        m, k = n, f(n)
        while m != k:
            m, k = k, f(k)
        return prod(p**(-e%3) for p, e in factorint(m).items()) # Chai Wah Wu, Aug 05 2024

Formula

a(n) = A048798(A004709(n)).
Sum_{k=1..n} a(k) ~ c * zeta(3)^3 * n^3 / 3, where c = Product_{p prime} (1 - 1/p^2 + 1/p^5 - 1/p^6) = 0.36052971192705404983... . - Amiram Eldar, Feb 20 2024