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-34 of 34 results.

A247558 Smallest integer x > 0 such that the number of semiprimes in the interval (x/2, x] equals n.

Original entry on oeis.org

4, 6, 10, 15, 25, 26, 35, 38, 39, 57, 58, 62, 65, 86, 87, 91, 94, 95, 121, 122, 123, 134, 142, 143, 145, 146, 159, 161, 169, 202, 203, 205, 206, 209, 214, 215, 217, 218, 219, 221, 262, 265, 278, 299, 301, 302, 303, 305, 309, 326, 327, 329, 335, 341, 346, 361, 362, 365, 382, 386, 393, 394, 395, 398
Offset: 1

Views

Author

Keywords

Comments

Analogous to A080359: the Labos Elemer primes.

Examples

			a(6) = 26 because in the interval, (13, 26], {14, 15, 21, 22, 25, 26} are six semiprimes.
		

Crossrefs

Programs

  • Mathematica
    SemiPrimeQ[n_] := PrimeOmega[n] == 2; mx = 1000; t = Table[0, {mx + 1}]; s = 0; Do[ If[ SemiPrimeQ[k], s++]; If[ SemiPrimeQ[k/2], s--]; If[s <= mx && t[[s + 1]] == 0, t[[s + 1]] = k], {k, 8*mx}]; Rest[t]

A334940 Partial sums of A230595.

Original entry on oeis.org

0, 0, 0, 1, 1, 3, 3, 3, 4, 6, 6, 6, 6, 8, 10, 10, 10, 10, 10, 10, 12, 14, 14, 14, 15, 17, 17, 17, 17, 17, 17, 17, 19, 21, 23, 23, 23, 25, 27, 27, 27, 27, 27, 27, 27, 29, 29, 29, 30, 30, 32, 32, 32, 32, 34, 34, 36, 38, 38, 38, 38, 40, 40, 40, 42, 42, 42, 42, 44, 44, 44, 44, 44, 46
Offset: 1

Views

Author

Daniel Suteu, May 17 2020

Keywords

Comments

Sum of the Dirichlet convolution of the characteristic function of primes (A010051) with itself from 1 to n.
(a(n) + A000720(floor(sqrt(n))))/2 equals the number of semiprimes <= n.

Crossrefs

Programs

  • Maple
    a:= proc(n) option remember; `if`(n<4, 0, a(n-1) +
         `if`(numtheory[bigomega](n)=2, `if`(issqr(n), 1, 2), 0))
        end:
    seq(a(n), n=1..80);  # Alois P. Heinz, May 20 2020
  • Mathematica
    f[n_] := DivisorSum[n, 1 &, PrimeQ[#] && PrimeQ[n/#] &]; Accumulate @ Array[f, 100] (* Amiram Eldar, May 20 2020 *)
  • PARI
    a(n) = my(s=sqrtint(n)); 2*sum(k=1, s, if(isprime(k), primepi(n\k), 0)) - primepi(s)^2;
    
  • Python
    from math import isqrt
    from sympy import primepi, prime
    def A334940(n): return (int(sum(primepi(n//prime(k))-k+1 for k in range(1,primepi(isqrt(n))+1)))<<1) - primepi(isqrt(n)) # Chai Wah Wu, Jul 23 2024

Formula

a(n) = Sum_{k=1..n} Sum_{d|k} A010051(d) * A010051(k/d).
a(n) = 2*Sum_{p prime <= sqrt(n)} A000720(floor(n/p)) - A000720(floor(sqrt(n)))^2.
a(n) = 2*A072000(n) - A000720(floor(sqrt(n))).
a(n) = 2*A072613(n) + A000720(floor(sqrt(n))). - Vaclav Kotesovec, May 21 2020
a(n) ~ 2*n*log(log(n))/log(n). - Vaclav Kotesovec, May 21 2020

A108216 Number of semiprimes between 10n and 10n + 9.

Original entry on oeis.org

3, 3, 4, 5, 2, 4, 3, 2, 4, 4, 1, 4, 4, 2, 5, 3, 3, 2, 3, 1, 6, 6, 2, 2, 2, 3, 3, 2, 2, 4, 5, 2, 5, 3, 2, 2, 3, 2, 3, 5, 2, 4, 2, 1, 3, 4, 2, 3, 4, 2, 3, 5, 3, 4, 3, 4, 3, 2, 4, 2, 0, 2, 4, 3, 1, 1, 3, 3, 4, 5, 3, 3, 2, 3, 3, 3, 3, 3, 3, 4, 3, 4, 0, 3, 4, 1, 4, 3, 2, 4, 2, 3, 4, 3, 2, 4, 2, 3, 3, 3, 3, 2, 1, 1, 5
Offset: 0

Views

Author

Giovanni Teofilatto, Jun 16 2005

Keywords

Comments

a(60) = a(82) = a(142) = 0. - Jonathan Vos Post, Jun 16 2005

Examples

			a(0) = 3 because between 0 and 9 there are three semiprimes: 4, 6 and 9.
a(1) = 3 because between 10 and 19 there are three semiprimes: 10, 14 and 15.
		

Crossrefs

Cf. A038800 number of primes between 10n and 10n+9.

Programs

  • Mathematica
    f[n_] := Sum[ PrimePi[n/Prime[i]] - (i - 1), {i, PrimePi[ Sqrt[n]]}]; Table[f[10n + 9] - f[Max[10n - 1, 0]], {n, 0, 104}] (* Robert G. Wilson v, Ray Chandler *)

Extensions

Edited and extended by Ray Chandler, Jul 07 2005

A115854 Difference between number of semiprimes <= 10^n and the asymptotic approximation round(10^n*loglog(10^n)/log(10^n)).

Original entry on oeis.org

0, 0, 0, 19, 214, 2154, 19974, 179590, 1610937, 14515403, 131560754, 1199914216, 11009605949, 101581094033, 942018562525
Offset: 0

Views

Author

Jonathan Vos Post, Mar 14 2006

Keywords

Examples

			a(5) = A036352(5) - round(...10^5...) = 23378 - 21224 = 2154.
		

Crossrefs

Extensions

Edited by Don Reble, Mar 29 2006
Previous Showing 31-34 of 34 results.