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 31-40 of 42 results. Next

A322981 If n is the k-th prime power > 1, a(n) = k, otherwise a(n) = 0.

Original entry on oeis.org

0, 1, 2, 3, 4, 0, 5, 6, 7, 0, 8, 0, 9, 0, 0, 10, 11, 0, 12, 0, 0, 0, 13, 0, 14, 0, 15, 0, 16, 0, 17, 18, 0, 0, 0, 0, 19, 0, 0, 0, 20, 0, 21, 0, 0, 0, 22, 0, 23, 0, 0, 0, 24, 0, 0, 0, 0, 0, 25, 0, 26, 0, 0, 27, 0, 0, 28, 0, 0, 0, 29, 0, 30, 0, 0, 0, 0, 0, 31, 0, 32, 0, 33, 0, 0, 0, 0, 0, 34, 0, 0, 0, 0, 0, 0, 0, 35
Offset: 1

Views

Author

Antti Karttunen, Jan 01 2019

Keywords

Comments

This is a ("corrected") variant of A095874, which uses the list of "powers of primes" A000961 instead of prime powers A246655. - M. F. Hasler, Jun 16 2021

Crossrefs

Cf. A000961 (powers of primes, including 1), A010055, A025528, A069513, A095874 (analog based on A000961), A246655 (prime powers > 1).
Cf. A049084.

Programs

  • PARI
    up_to = 16384;
    A322981list(up_to) = { my(v=vector(up_to), k=0); for(n=1,up_to,if(isprimepower(n),k++; v[n] = k, v[n] = 0)); (v); };
    v322981 = A322981list(up_to);
    A322981(n) = v322981[n];
    
  • PARI
    A322981(n)=if(isprimepower(n),sum(i=1,exponent(n),primepi(sqrtnint(n,i)))) \\ M. F. Hasler, Jun 16 2021

Formula

a(n) = A010055(n) * A025528(n) = A069513(n) * A025528(n).
a(n) = A025528(A069513(n)*n), when assuming that A025528(0) = 0.
a(A000961(1+n)) = n for all n >= 1.

A333235 a(n) is the product of indices of unitary prime power divisors of n.

Original entry on oeis.org

1, 1, 2, 3, 4, 2, 5, 6, 7, 4, 8, 6, 9, 5, 8, 10, 11, 7, 12, 12, 10, 8, 13, 12, 14, 9, 15, 15, 16, 8, 17, 18, 16, 11, 20, 21, 19, 12, 18, 24, 20, 10, 21, 24, 28, 13, 22, 20, 23, 14, 22, 27, 24, 15, 32, 30, 24, 16, 25, 24, 26, 17, 35, 27, 36, 16, 28, 33, 26, 20
Offset: 1

Views

Author

Ilya Gutkovskiy, Mar 12 2020

Keywords

Comments

Equivalently: replace each prime power p^e in the prime factorization of n by its index in A246655. - M. F. Hasler, Jun 16 2021

Examples

			a(600) = a(2^3 * 3 * 5^2) = a(A246655(6) * A246655(2) * A246655(14)) = 6 * 2 * 14 = 168.
		

Crossrefs

Cf. A322981 (the index of n = p^e in A246655).

Programs

  • Maple
    N:= 1000: # for a(1)..a(N)
    R:= NULL: p:= 2:
    while p < N do
      R:= R,  seq(p^k,k=1..ilog[p](N));
      p:= nextprime(p);
    od:
    L:= sort([R]):
    f:= proc(n) local F, t;
      F:= ifactors(n)[2];
      mul(ListTools:-BinarySearch(L,t[1]^t[2]),t=F)
    end proc:
    map(f, [$1..N]); # Robert Israel, Feb 11 2021
  • Mathematica
    PrimePowerPi[n_] := Sum[Boole[PrimePowerQ[k]], {k, 1, n}]; a[1] = 1; a[n_] := Times @@ (PrimePowerPi[#[[1]]^#[[2]]] & /@ FactorInteger[n]); Table[a[n], {n, 1, 70}]
  • PARI
    apply( {A333235(n)=vecprod([A322981(f[1]^f[2])|f<-factor(n)~])}, [1..99]) \\ M. F. Hasler, Jun 16 2021

Formula

If n = Product (p_j^k_j) then a(n) = Product (A025528(p_j^k_j)).
a(prime(n)) = A027883(n).
a(2^n) = A182908(n).
a(A246655(n)) = n.

A378615 Number of non prime powers <= prime(n).

Original entry on oeis.org

1, 1, 1, 2, 3, 4, 6, 7, 10, 13, 14, 18, 21, 22, 25, 29, 34, 35, 39, 42, 43, 48, 50, 55, 62, 65, 66, 69, 70, 73, 84, 86, 91, 92, 101, 102, 107, 112, 115, 119, 124, 125, 134, 135, 138, 139, 150, 161, 164, 165, 168, 173, 174, 182, 186, 191, 196, 197, 202, 205
Offset: 1

Views

Author

Gus Wiseman, Dec 06 2024

Keywords

Examples

			The non prime powers counted under each term:
  n=1  n=2  n=3  n=4  n=5  n=6  n=7  n=8  n=9  n=10
  -------------------------------------------------
   1    1    1    6   10   12   15   18   22   28
                  1    6   10   14   15   21   26
                       1    6   12   14   20   24
                            1   10   12   18   22
                                 6   10   15   21
                                 1    6   14   20
                                      1   12   18
                                          10   15
                                           6   14
                                           1   12
                                               10
                                                6
                                                1
		

Crossrefs

Restriction of A356068 (first-differences A143731).
First-differences are A368748.
Maxima are A378616.
Other classes of numbers (instead of non prime powers):
- prime: A000027 (diffs A000012), restriction of A000720 (diffs A010051)
- squarefree: A071403 (diffs A373198), restriction of A013928 (diffs A008966)
- nonsquarefree: A378086 (diffs A061399), restriction of A057627 (diffs A107078)
- prime power: A027883 (diffs A366833), restriction of A025528 (diffs A010055)
- composite: A065890 (diffs A046933), restriction of A065855 (diffs A005171)
A000040 lists the primes, differences A001223
A000961 and A246655 list the prime powers, differences A057820.
A024619 lists the non prime powers, differences A375735, seconds A376599.
A080101 counts prime powers between primes (exclusive), inclusive A366833.
A361102 lists the non powers of primes, differences A375708.

Programs

  • Mathematica
    Table[Length[Select[Range[Prime[n]],Not@*PrimePowerQ]],{n,100}]
  • Python
    from sympy import prime, primepi, integer_nthroot
    def A378615(n): return int((p:=prime(n))-n-sum(primepi(integer_nthroot(p,k)[0]) for k in range(2,p.bit_length()))) # Chai Wah Wu, Dec 07 2024

Formula

a(n) = prime(n) - A027883(n). - Chai Wah Wu, Dec 08 2024

A082998 a(n) = card{ x <= n : omega(x) = 3 }.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 10
Offset: 1

Views

Author

Benoit Cloitre, May 30 2003

Keywords

References

  • G. Tenenbaum, Introduction à la théorie analytique et probabiliste des nombres, p. 203, Publications de l'Institut Cartan, 1990.

Crossrefs

Programs

  • PARI
    a(n)=sum(i=1,n,if(omega(i)-3,0,1))
    
  • PARI
    a(n, k = 3, m = 1, p = 2, s = sqrtnint(n\m, k), j = 1) = my(count = 0); if (k==2, while(p <= s, my(r = nextprime(p+1)); my(t = m*p); while (t <= n, my(w = n\t); if(r > w, break); count += primepi(w) - j; my(r2 = r); while(r2 <= w, my(u = t*r2*r2); if(u > n, break); while (u <= n, count += 1; u *= r2); r2 = nextprime(r2+1)); t *= p); p = r; j += 1); return(count)); while(p <= s, my(r = nextprime(p+1)); my(t = m*p); while(t <= n, my(s = sqrtnint(n\t, k-1)); if(r > s, break); count += a(n, k-1, t, r, s, j+1); t *= p); p = r; j += 1); count; \\ Daniel Suteu, Jul 21 2021
    
  • Python
    from sympy import factorint
    from itertools import accumulate
    def cond(n): return int(len(factorint(n))==3)
    def aupto(nn): return list(accumulate(map(cond, range(1, nn+1))))
    print(aupto(105)) # Michael S. Branicky, Jul 21 2021

Formula

a(n) ~ (1/2)*(n/log(n))*log(log(n))^2.
a(A033992(n)) = n. - Daniel Suteu, Jul 21 2021

A025532 a(n) is the sum of exponents in the prime factorization of lcm{C(n,0), C(n,1), ..., C(n,n)}.

Original entry on oeis.org

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

Views

Author

Keywords

Programs

  • Mathematica
    {0, 0}~Join~Table[Total@ FactorInteger[LCM @@ Array[Binomial[n, #] &, n]][[All, -1]], {n, 2, 74}] (* Michael De Vlieger, Jan 13 2018 *)
  • PARI
    for(n=0, 100, l=1; for(k=0, n, l=lcm(l,binomial(n,k))); v=factor(l); s=0; for(k=1, matsize(v)[1], s=s+v[k,2]); print1(s","))
    
  • PARI
    a(n) = bigomega(lcm(vector(n+1, k, binomial(n, k-1)))); \\ Michel Marcus, Jan 06 2018

Formula

a(n) = A025528(n + 1) - A001222(n + 1). - Luc Rousseau, Jan 04 2018
a(n) = A001222(A002944(n+1)). - Michel Marcus, Jan 05 2018

Extensions

More terms from Ralf Stephan, Mar 28 2003

A330292 a(n) = number of integers 1 <= k < n such that omega(k) <= omega(n), where omega = A001221.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 5, 6, 7, 9, 8, 11, 9, 13, 14, 10, 11, 17, 12, 19, 20, 21, 13, 23, 14, 25, 15, 27, 16, 29, 17, 18, 31, 32, 33, 34, 19, 36, 37, 38, 20, 41, 21, 41, 42, 43, 22, 45, 23, 47, 48, 49, 24, 51, 52, 53, 54, 55, 25, 59, 26, 58, 59, 27, 61, 65, 28, 63, 64
Offset: 1

Views

Author

Dilshod Urazov, Dec 10 2019

Keywords

Comments

Any natural number n can be represented as n = (k_1)^p_1 * (k_2)^p_2 * ... * (k_h)^p_h, where k_i is prime for any i from 1 to h. Let us consider the function omega(n) = h, which represents the number of distinct prime factors of n. Then a(k) is the number of positive integers j less than k for which the value of function omega(j) is <= omega(k).
a(P) = A025528(P) for P a prime power in A246655.
a(Q) = Q - 1 for Q a primorial number in A002110.
Let us consider n > k such that omega(n) = omega(k) = omega and there is no w such that n > w > k and omega(w) > omega. Hence a(n) - a(k) = n - k.

Examples

			a(1) = 0: 1 has no predecessor, omega(1) = 0 by convention;
a(2) = 1 because omega(2) = 1, 1 >= omega(0);
a(3) = 2 because omega(3) = 1 and none of omega(1), omega(2) >= 1;
a(4) = 3 because omega(4) = 1 and none of omega(1), omega(2), omega(3) >= 1.
		

Crossrefs

Cf. A001221 (omega), A025528, A246655, A002110.

Programs

  • Mathematica
    a[n_] := Block[{t = PrimeNu[n]}, Length@ Select[Range[n - 1], PrimeNu[#] <= t &]]; Array[a, 70] (* Giovanni Resta, Dec 10 2019 *)
  • PARI
    for(n=1,70,my(omn=omega(n),m=0);for(k=1,n-1,if(omega(k)<=omn,m++));print1(m,", ")) \\ Hugo Pfoertner, Dec 10 2019
    
  • PARI
    a(n) = my(omn=omega(n)); sum(k=1, n-1, omega(k) <= omn); \\ Michel Marcus, Dec 11 2019
  • Python
    def primes(n):
        divisors = [ d for d in range(2,n//2+1) if n % d == 0 ]
        return [ d for d in divisors if \
                 all( d % od != 0 for od in divisors if od != d ) ]
    pprimes = {}
    for i in range(1, 10000):
        res = len(primes(i))
        if res == 0:
            res = 1
        pprimes[i] = res
    for k in range(1, 10000):
        s = 0
        for i in range(1, k):
            if pprimes[i] <= pprimes[k]:
                s+=1
        print(s)
    

Extensions

More terms from Giovanni Resta, Dec 10 2019

A341416 a(n) is the least k such that the product of indices of unitary prime power divisors of k is n.

Original entry on oeis.org

1, 3, 4, 5, 7, 8, 9, 11, 13, 16, 17, 19, 23, 25, 27, 29, 31, 32, 37, 35, 36, 47, 49, 40, 59, 61, 52, 45, 71, 56, 79, 55, 68, 89, 63, 65, 103, 107, 92, 77, 121, 72, 127, 85, 91, 137, 139, 88, 151, 112, 124, 115, 169, 104, 119, 99, 148, 193, 197, 133, 211, 223, 117, 145, 161, 136, 241, 155, 196
Offset: 1

Views

Author

Robert Israel, Feb 11 2021

Keywords

Comments

a(n) is the least k such that A333235(k) = n.
a(p) = A246655(p) for prime p.

Examples

			a(3) = 4 because A333235(4) = 3 and this is the first occurrence of 3 in A333235.
		

Crossrefs

Programs

  • Maple
    N:= 1000: # for a(1) to a(A025528(N))
    R:= NULL: p:= 2:
    while p < N do
      R:= R,  seq(p^k,k=1..ilog[p](N));
      p:= nextprime(p);
    od:
    L:= sort([R]):
    M:= nops(L):
    f:= proc(n) local F, t;
      F:= ifactors(n)[2];
      mul(ListTools:-BinarySearch(L,t[1]^t[2]),t=F)
    end proc:
    V:= Vector(M): count:= 0:
    for n from 1 while count < M do
      v:= f(n);
    if v <= M and V[v] = 0 then count:= count+1; V[v]:= n fi;
    od:
    convert(V,list);

Formula

A333235(a(n)) = n.

A025556 a(n) = sum of the exponents in the prime factorization of LCM{1,3,6,...,C(n+1,2)}.

Original entry on oeis.org

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

Views

Author

Keywords

Crossrefs

Programs

Formula

a(n) = A001222(A025555(n)). - Sean A. Irvine, Sep 06 2019
a(n) = A025528(n+1)-1. - Pontus von Brömssen, Sep 28 2024

Extensions

More terms from Sean A. Irvine, Sep 06 2019

A143039 a(n) = m-th prime power (not counting 1), where m = 10^n.

Original entry on oeis.org

16, 419, 7517, 103511, 1295953, 15474787, 179390821, 2037968761, 22801415981, 252096675073, 2760723662941, 29996212395727, 323780470283789, 3475385632514321, 37124507635789309, 394906912575042053, 4185296577158764117, 44211790220874464021
Offset: 1

Views

Author

Lekraj Beedassy, Jul 18 2008

Keywords

References

  • J.-M. De Koninck, Ces nombres qui nous fascinent, Entry 455, pp 84, Ellipses, Paris 2008.

Crossrefs

Cf. A000961.

Formula

a(n)=A000961(10^n + 1).
A025528(a(n)) = 10^n.

Extensions

Edited and extended by Max Alekseyev, May 13 2009

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 31-40 of 42 results. Next