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.

Previous Showing 21-25 of 25 results.

A379771 Number of k <= n that are neither squarefree nor prime powers.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 8, 9, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13, 14, 14, 14, 14, 15, 15, 15, 16, 16, 16, 16, 16, 17, 17, 17, 17, 18, 18, 18, 19, 20, 20
Offset: 1

Views

Author

Michael De Vlieger, Jan 10 2025

Keywords

Comments

Partial sums of A355447.

Examples

			a(n) = 0 for n = 1..11, since 12 is the smallest number that is neither squarefree nor a prime power.
a(n) = 1 for n = 12..17, since the only k <= n that is neither squarefree nor a prime power is 12.
a(n) = 2 for n = 18..19, since 12 and 18 are the only numbers in A126706 that do not exceed n.
a(n) = 3 for n = 20..23, since 12, 18, and 20 are the only numbers in A126706 that do not exceed n, etc.
		

Crossrefs

Programs

  • Mathematica
    Array[Count[Range[#], _?(Nor[SquareFreeQ[#], PrimePowerQ[#]] &)] &, 120]
  • PARI
    a(n) = sum(k=1, n, !issquarefree(k) && !isprimepower(k)); \\ Michel Marcus, Jan 11 2025
    
  • Python
    from math import isqrt
    from sympy import mobius, integer_nthroot, primepi
    def A379771(n): return -sum(mobius(k)*(n//k**2) for k in range(2,isqrt(n)+1))-sum(primepi(integer_nthroot(n,k)[0]) for k in range(2,n.bit_length())) # Chai Wah Wu, Jan 22 2025

Formula

A126706(n) = m = positions of 1's in A355447; a(m) - a(m-1) = 1.

A380757 Powers of primes that have a primitive root.

Original entry on oeis.org

1, 2, 3, 4, 5, 7, 9, 11, 13, 17, 19, 23, 25, 27, 29, 31, 37, 41, 43, 47, 49, 53, 59, 61, 67, 71, 73, 79, 81, 83, 89, 97, 101, 103, 107, 109, 113, 121, 125, 127, 131, 137, 139, 149, 151, 157, 163, 167, 169, 173, 179, 181, 191, 193, 197, 199, 211, 223, 227, 229
Offset: 1

Views

Author

Michael De Vlieger, Feb 01 2025

Keywords

Comments

Proper subset of A033948.
A046022 is a proper subset of this sequence.

Crossrefs

Programs

  • Mathematica
    With[{nn = 2^8},
      Complement[#, Array[2^# &, Floor@ Log2[#[[-1]]] + 2, 3]] &@
      Union[{1}, Prime@ Range@ PrimePi[#[[-1]] ], #] &@
      Select[Union@ Flatten@
        Table[a^2*b^3, {b, Surd[#, 3]}, {a, Sqrt[nn/b^3]}],
        PrimePowerQ] ]
  • Python
    from sympy import primepi, integer_nthroot
    def A380757(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 f(x): return n if x<6 else int(n+x-3-sum(primepi(integer_nthroot(x,k)[0])-1 for k in range(1,x.bit_length())))
        return bisection(f,n,n) # Chai Wah Wu, Feb 03 2025

Formula

Union of {1, 2, 4} and A061345.
This sequence is A000961 without A000079(k) for k > 2.
A033948 = union of {a(n)} and {2*a(n)} without 8 = union of {a(n)} and A278568, where {a(n)} represents this sequence.
Intersection of A000961 and A033948.
Define c(m) to be the number of terms that do not exceed m. Then for m >= 4, c(m) = 3 + (Sum_{k = 1..floor(log_2(m))} pi(floor(m^(1/k)))) - floor(log_2(m)) = 3 + A065515(m) - A113473(m).

A025471 Position of 5^n among the powers of primes (A000961).

Original entry on oeis.org

1, 5, 15, 43, 137, 483, 1881, 7772, 33292, 146014, 650688, 2935909, 13377899, 61448617, 284148766, 1321470026, 6175996065, 28988110806, 136575209239, 645621236243, 3061130340023, 14552991533455, 69354804657255, 331251331834172, 1585299655420744, 7600886382041555, 36504944105963117
Offset: 0

Views

Author

Keywords

Crossrefs

Cf. A000351 (powers of 5), A000961, A065515.

Programs

  • PARI
    a(n) = n=5^n; 1+sum(k=1, logint(n,2), primepi(sqrtnint(n,k))); \\ Daniel Suteu, Dec 15 2019

Formula

a(n) = A065515(5^n). - Michel Marcus, Mar 24 2013

Extensions

a(13)-a(20) from Robert G. Wilson v, Dec 13 2019
a(21)-a(26) from Daniel Suteu, Dec 15 2019

A025472 a(n) is the position of 7^n among the powers of primes (A000961).

Original entry on oeis.org

1, 6, 24, 87, 393, 2002, 11212, 65907, 398221, 2454882, 15355483, 97168563, 620657849, 3995177593, 25885249943, 168651040452, 1104127513216, 7259026757936, 47901525960522, 317140345586299, 2105877518905780, 14020561598521781, 93570332415595735, 625829903112713938
Offset: 0

Views

Author

Keywords

Comments

The number of prime powers <= 7^n. - Robert G. Wilson v, Dec 16 2019

Crossrefs

Cf. A000420 (7^n), A000961, A065515.

Programs

  • PARI
    a(n)= n=7^n+.5; 1+sum(k=1, log(n)\log(2), primepi(n^(1/k))) \\ Michel Marcus, Mar 25 2013

Formula

a(n) = A065515(7^n). - Michel Marcus, Mar 24 2013

Extensions

a(11)-a(17) from Robert G. Wilson v, Dec 13 2019
a(18)-a(22) from Daniel Suteu, Dec 15 2019
a(23) from Robert G. Wilson v, Dec 15 2019

A327247 Number of odd prime powers <= n (with exponents > 0).

Original entry on oeis.org

0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 6, 6, 7, 7, 8, 8, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 15, 15, 16, 16, 16, 16, 17, 17, 18, 18, 18, 18, 19, 19, 19, 19, 19, 19, 20, 20, 21, 21, 21, 21, 21, 21, 22, 22, 22, 22, 23, 23, 24, 24, 24
Offset: 1

Views

Author

Ilya Gutkovskiy, Sep 14 2019

Keywords

Crossrefs

Programs

  • Mathematica
    Table[Sum[Boole[OddQ[k] && PrimePowerQ[k]], {k, 1, n}], {n, 1, 75}]
  • PARI
    a(n) = {sum(k=2, primepi(n), logint(n, prime(k)))} \\ Andrew Howroyd, Sep 14 2019

Formula

a(n) = A025528(n) - A000523(n).
Previous Showing 21-25 of 25 results.