%I #24 Mar 15 2021 06:30:21
%S 4,9,10,12,17,18,19,20,25,26,28,35,36,37,44,45,46,49,50,52,53,55,60,
%T 62,63,68,71,73,75,76,82,84,89,90,91,92,98,99,100,107,109,116,117,118,
%U 121,124,126,127,132,134,140,143,145,147,148,150,153,154,156,161
%N Cubefree numbers a > 1 such that the ring of integers of Q(a^(1/3)) is not Z[a^(1/3)].
%C Cubefree numbers that are not squarefree or are congruent to 1 or 8 modulo 9.
%C For k > 1, a != 1 being a squarefree number (a != -1 unless k is a power of 2), then the ring of integers of Q(a^(1/k)) is Z[a^(1/k)] if and only if: for every p dividing k, we have a^(p-1) !== 1 (mod p^2). In other words, O_Q(a^(1/k)) = Z[a^(1/k)] if and only if none of the prime factors of k is a Wieferich prime of base a. See Theorem 5.3 of the paper of Keith Conrad.
%C In general, if a^d == 1 (mod p^2) for some d|(p-1), then it is easy to show that x = (1 + a^(d/p) + a^(2*d/p) + ... + a^((p-1)*d/p))/p is an algebraic integer not in Z[a^(1/p)].
%C There is no consecutive run of 8 numbers in this sequence since every 8 consecutive numbers must contain a multiple of 8, which is not cubefree. The first consecutive run of 7 numbers in this sequence is 59921 ~ 59927: 59922, 59924, 59925, 59926 and 59927 are not squarefree, 59921 == 8 (mod 9) and 59923 == 1 (mod 9).
%C The asymptotic density of this sequence is 1/zeta(3) - 9/(2*Pi^2) = 0.375962... - _Amiram Eldar_, Mar 11 2021
%H Jianing Song, <a href="/A342393/b342393.txt">Table of n, a(n) for n = 1..15000</a>
%H Keith Conrad, <a href="https://kconrad.math.uconn.edu/blurbs/gradnumthy/integersradical.pdf">The ring of integers in a radical extension</a>
%e The ring of integers of Q(4^(1/3)) = Q(2^(1/3)) is not Z[4^(1/3)] but Z[2^(1/3)], so 4 is a term.
%e The ring of integers of Q(12^(1/3)) = Q(18^(1/3)) is not Z[12^(1/3)] nor Z[18^(1/3)] but Z[12^(1/3)+18^(1/3)], so both 12 and 18 are terms. Note that if x = 12^(1/3) + 18^(1/3), then 12^(1/3) = x^2 - 2*x - 12, 18^(1/3) = -x^2 + 3*x + 12, and the minimal polynomial of x is x^3 - 18*x - 30.
%e For a = 9c+1, x = (1 + a^(1/3) + a^(2/3))/3 satisfies the monic cubic x^3 - x^2 - 3c*x - 3c^2 = 0; For a = 9c-1, x = (1 - a^(1/3) + a^(2/3))/3 satisfies the monic cubic x^3 - x^2 + 3c*x - 3c^2 = 0. In both cases, x is an algebraic integer not in Z[a^(1/3)].
%o (PARI) isA342393(n) = if(n>1, my(e=vecmax(factor(n)[, 2]~)); if(e<3, e==2 || (n^2%9==1)), 0)
%Y Cf. A004709 (cubefree numbers), A342392.
%K nonn,easy
%O 1,1
%A _Jianing Song_, Mar 10 2021