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.

A340681 The closure under squaring of A051144, the nonsquarefree nonsquares.

Original entry on oeis.org

8, 12, 18, 20, 24, 27, 28, 32, 40, 44, 45, 48, 50, 52, 54, 56, 60, 63, 64, 68, 72, 75, 76, 80, 84, 88, 90, 92, 96, 98, 99, 104, 108, 112, 116, 117, 120, 124, 125, 126, 128, 132, 135, 136, 140, 144, 147, 148, 150, 152, 153, 156, 160, 162, 164, 168, 171, 172, 175, 176, 180, 184, 188, 189, 192, 198, 200, 204, 207, 208
Offset: 1

Views

Author

Antti Karttunen and Peter Munn, Feb 07 2021

Keywords

Comments

Numbers not of the form s^(2^e), where s is a squarefree number, and e >= 0.
The categorization provided by this sequence and its complement, A340682, is an alternative extension (to all integers greater than 1) of the 2-way distinction between squarefree and nonsquarefree as it applies to nonsquares.
All positive integers have a unique factorization into powers of nonunit squarefree numbers with distinct exponents that are powers of 2. This sequence lists the numbers where this factorization has more than one term, that is numbers m such that A331591(m) > 1.
Presence in the sequence is determined by prime signature (A101296). The set of represented signatures starts: {{3}, {2,1}, {3,1}, {2,1,1}, {5}, {4,1}, {3,2}, {3,1,1}, {2,2,1}, {2,1,1,1}, {6}, {5,1}, {4,2}, {4,1,1}, {3,3}, {3,2,1}, {3,1,1,1}, {2,2,1,1}, {2,1,1,1,1}, {7}, ...}.
Gives positions of 1's in A340675 after its initial one.

Examples

			24 = 6 * 4 = 6^1 * 2^2 = 6^(2^0) * 2^(2^1), which is the factorization into powers of nonunit squarefree numbers with distinct exponents that are powers of 2. As this factorization has 2 terms, 24 is in the sequence.
The equivalent factorization for 100 is 100 = 10^2 = 10^(2^1). As this factorization has only 1 term, 100 is not in the sequence.
		

Crossrefs

Cf. A340682 (complement, apart from 1 which is in neither).
Cf. subsequences: A051144, A059404.
Subsequence of A013929.

Programs

  • PARI
    isA340681(n) = if(!issquare(n), !issquarefree(n), (n>1)&&isA340681(sqrtint(n)));
    
  • Python
    from math import isqrt
    from sympy import mobius, integer_nthroot
    def A340681(n):
        def bisection(f,kmin=0,kmax=1):
            while f(kmax) > kmax: kmax <<= 1
            kmin = kmax >> 1
            while kmax-kmin > 1:
                kmid = kmax+kmin>>1
                if f(kmid) <= kmid:
                    kmax = kmid
                else:
                    kmin = kmid
            return kmax
        def g(x): return sum(mobius(k)*(x//k**2) for k in range(1, isqrt(x)+1))
        def f(x): return int(n+1+sum(g(integer_nthroot(x,1<Chai Wah Wu, Jun 01 2025