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.

A080101 Number of prime powers in all composite numbers between n-th prime and next prime.

Original entry on oeis.org

0, 1, 0, 2, 0, 1, 0, 0, 2, 0, 1, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 2, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 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, 0, 1, 0, 0, 0, 0, 0, 0
Offset: 1

Views

Author

Reinhard Zumkeller, Jan 28 2003

Keywords

Comments

The maximum value of terms in the sequence, through the (10^5)th term, is 2. - Harvey P. Dale, Aug 24 2014
This is conjectured to be the maximum, see also A366833. - Gus Wiseman, Nov 06 2024

Examples

			There are two prime powers between 2179 = A000040(327) and 2203 = A000040(328): 2187 = 3^7 and 2197 = 13^3, therefore a(327) = 2, A080102(327) = 2187 and A080103(327) = 2197.
		

Crossrefs

For powers of 2 instead of primes we have A244508, see also A013597, A014210, A014234, A304521.
Adding one gives A366833.
For non-prime-powers instead of prime-powers we have A368748.
Positions of positive terms are A377057, primes A053607.
Positions of 0 are A377286.
Positions of 1 are A377287.
Positions of 2 are A377288, primes A053706.
For perfect-powers (instead of prime-powers) we have A377432.
A000015 gives the least prime-power >= n, difference A377282.
A000040 lists the primes, differences A001223.
A000961 lists the powers of primes, differences A057820, seconds A376596.
A031218 gives the greatest prime-power <= n, difference A276781.
A046933(n) counts the interval from A008864(n) to A006093(n+1).
A065514 gives the greatest prime-power < prime(n), difference A377289.
A246655 lists the prime-powers not including 1, complement A361102.
A345531 gives the least prime-power > prime(n), difference A377281.

Programs

  • Maple
    a := proc(n) local c, k, p: c, p := 0, ithprime(n): for k from p+1 to nextprime(p)-1 do if nops(numtheory:-factorset(k)) = 1 then c := c+1: fi: od: c: end:
    seq(a(n), n = 1 .. 105); # Lorenzo Sauras Altuzarra, Jul 08 2022
  • Mathematica
    prpwQ[n_]:=Module[{fi=FactorInteger[n]},Length[fi]==1&&fi[[1,2]]>1]; nn=600;With[{pwrs=Table[If[prpwQ[n],1,0],{n,nn}]},Table[Total[ Take[ pwrs,{Prime[n],Prime[n+1]}]],{n,PrimePi[nn]-1}]] (* Harvey P. Dale, Aug 24 2014 *)
    Table[Length[Select[Range[Prime[n]+1,Prime[n+1]-1],PrimePowerQ]],{n,30}] (* Gus Wiseman, Nov 06 2024 *)

Formula

a(n) = A366833(n) - 1. - Gus Wiseman, Nov 06 2024