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 51-60 of 106 results. Next

A298602 Expansion of (1 - x)*Product_{k>=1} (1 - x^prime(k)).

Original entry on oeis.org

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

Views

Author

Ilya Gutkovskiy, Jan 22 2018

Keywords

Comments

The difference between the number of partitions of n into an even number of distinct prime parts (including 1) and the number of partitions of n into an odd number of distinct prime parts (including 1).
Convolution inverse of A034891.

Crossrefs

Cf. A000586, A000607, A034891, A036497, A046675 (partial sums).

Programs

  • Mathematica
    nmax = 82; CoefficientList[Series[(1 - x) Product[(1 - x^Prime[k]), {k, 1, nmax}], {x, 0, nmax}], x]

Formula

G.f.: (1 - x)*Product_{k>=1} (1 - x^prime(k)).

A299168 Number of ordered ways of writing n-th prime number as a sum of n primes.

Original entry on oeis.org

1, 0, 0, 0, 5, 6, 42, 64, 387, 5480, 10461, 113256, 507390, 1071084, 4882635, 44984560, 382362589, 891350154, 7469477771, 33066211100, 78673599501, 649785780710, 2884039365010, 22986956007816, 306912836483025, 1361558306986280, 3519406658042964
Offset: 1

Views

Author

Ilya Gutkovskiy, Feb 04 2018

Keywords

Examples

			a(5) = 5 because fifth prime number is 11 and we have [3, 2, 2, 2, 2], [2, 3, 2, 2, 2], [2, 2, 3, 2, 2], [2, 2, 2, 3, 2] and [2, 2, 2, 2, 3].
		

Crossrefs

Programs

  • Maple
    b:= proc(n, t) option remember;
          `if`(n=0, `if`(t=0, 1, 0), `if`(t<1, 0, add(
          `if`(isprime(j), b(n-j, t-1), 0), j=1..n)))
        end:
    a:= n-> b(ithprime(n), n):
    seq(a(n), n=1..30);  # Alois P. Heinz, Feb 13 2021
  • Mathematica
    Table[SeriesCoefficient[Sum[x^Prime[k], {k, 1, n}]^n, {x, 0, Prime[n]}], {n, 1, 27}]

Formula

a(n) = [x^prime(n)] (Sum_{k>=1} x^prime(k))^n.

A316202 Number of integer partitions of n into Fermi-Dirac primes.

Original entry on oeis.org

1, 0, 1, 1, 2, 2, 3, 4, 5, 7, 8, 11, 13, 17, 20, 25, 31, 37, 45, 54, 65, 77, 92, 109, 128, 152, 177, 208, 242, 283, 327, 380, 439, 506, 583, 669, 768, 878, 1004, 1144, 1303, 1482, 1681, 1906, 2156, 2438, 2750, 3101, 3490, 3924, 4407, 4942, 5538, 6197, 6929
Offset: 0

Views

Author

Gus Wiseman, Jun 26 2018

Keywords

Comments

A Fermi-Dirac prime (A050376) is a number of the form p^(2^k) where p is prime and k >= 0.

Examples

			The a(12) = 13 integer partitions of 12 into Fermi-Dirac primes:
(75), (93),
(444), (543), (552), (732),
(3333), (4332), (4422), (5322),
(33222), (42222),
(222222).
		

Crossrefs

Programs

  • Mathematica
    nn=60;
    FDpQ[n_]:=With[{f=FactorInteger[n]},n>1&&Length[f]==1&&MatchQ[FactorInteger[2f[[1,2]]],{{2,_}}]]
    FDprimeList=Select[Range[nn],FDpQ];
    ser=Product[1/(1-x^d),{d,FDprimeList}];
    Table[SeriesCoefficient[ser,{x,0,n}],{n,0,nn}]

Formula

O.g.f.: Product_d 1/(1 - x^d) where the product is over all Fermi-Dirac primes (A050376).

A339382 Number of partitions of n into an even number of distinct primes (counting 1 as a prime).

Original entry on oeis.org

1, 0, 0, 1, 1, 1, 1, 1, 2, 1, 1, 1, 2, 2, 2, 2, 3, 2, 3, 3, 4, 4, 4, 4, 6, 5, 5, 5, 6, 6, 7, 7, 9, 8, 9, 8, 11, 10, 11, 12, 14, 12, 15, 14, 17, 16, 17, 17, 22, 20, 22, 21, 25, 24, 28, 27, 31, 30, 33, 31, 39, 36, 40, 40, 46, 42, 49, 47, 54, 53, 58, 55, 67, 63, 70, 68
Offset: 0

Views

Author

Ilya Gutkovskiy, Dec 02 2020

Keywords

Examples

			a(16) = 3 because we have [13, 3], [11, 5] and [7, 5, 3, 1].
		

Crossrefs

Programs

  • Maple
    s:= proc(n) option remember;
          `if`(n<1, n+1, ithprime(n)+s(n-1))
        end:
    b:= proc(n, i, t) option remember; (p-> `if`(n=0, t,
          `if`(n>s(i), 0, b(n, i-1, t)+ `if`(p>n, 0,
           b(n-p, i-1, 1-t)))))(`if`(i<1, 1, ithprime(i)))
        end:
    a:= n-> b(n, numtheory[pi](n), 1):
    seq(a(n), n=0..100);  # Alois P. Heinz, Dec 02 2020
  • Mathematica
    nmax = 75; CoefficientList[Series[(1/2) ((1 + x) Product[(1 + x^Prime[k]), {k, 1, nmax}] + (1 - x) Product[(1 - x^Prime[k]), {k, 1, nmax}]), {x, 0, nmax}], x]

Formula

G.f.: (1/2) * ((1 + x) * Product_{k>=1} (1 + x^prime(k)) + (1 - x) * Product_{k>=1} (1 - x^prime(k))).
a(n) = (A036497(n) + A298602(n)) / 2.

A339383 Number of partitions of n into an odd number of distinct primes (counting 1 as a prime).

Original entry on oeis.org

0, 1, 1, 1, 0, 1, 1, 1, 1, 1, 2, 2, 1, 2, 2, 2, 2, 3, 3, 4, 3, 4, 4, 5, 4, 5, 6, 6, 5, 7, 6, 8, 7, 8, 9, 10, 9, 12, 11, 12, 11, 14, 14, 16, 15, 17, 17, 20, 17, 21, 22, 24, 22, 27, 25, 30, 28, 31, 31, 36, 33, 40, 39, 42, 40, 47, 46, 53, 49, 55, 54, 63, 58, 68, 67, 73
Offset: 0

Views

Author

Ilya Gutkovskiy, Dec 02 2020

Keywords

Examples

			a(21) = 4 because we have [17, 3, 1], [13, 7, 1], [13, 5, 3] and [11, 7, 3].
		

Crossrefs

Programs

  • Maple
    s:= proc(n) option remember;
          `if`(n<1, n+1, ithprime(n)+s(n-1))
        end:
    b:= proc(n, i, t) option remember; (p-> `if`(n=0, t,
          `if`(n>s(i), 0, b(n, i-1, t)+ `if`(p>n, 0,
           b(n-p, i-1, 1-t)))))(`if`(i<1, 1, ithprime(i)))
        end:
    a:= n-> b(n, numtheory[pi](n), 0):
    seq(a(n), n=0..100);  # Alois P. Heinz, Dec 02 2020
  • Mathematica
    nmax = 75; CoefficientList[Series[(1/2) ((1 + x) Product[(1 + x^Prime[k]), {k, 1, nmax}] - (1 - x) Product[(1 - x^Prime[k]), {k, 1, nmax}]), {x, 0, nmax}], x]

Formula

G.f.: (1/2) * ((1 + x) * Product_{k>=1} (1 + x^prime(k)) - (1 - x) * Product_{k>=1} (1 - x^prime(k))).
a(n) = (A036497(n) - A298602(n)) / 2.

A111902 Number of partitions of n into distinct parts that are primes or squares of primes.

Original entry on oeis.org

1, 0, 1, 1, 1, 2, 1, 3, 1, 4, 2, 4, 4, 4, 6, 4, 8, 5, 9, 7, 10, 9, 11, 12, 12, 15, 14, 17, 17, 20, 20, 23, 24, 26, 28, 30, 32, 35, 36, 40, 41, 46, 47, 52, 54, 58, 62, 65, 71, 73, 80, 82, 90, 93, 101, 104, 113, 117, 125, 132, 139, 148, 154, 165, 171, 183, 191
Offset: 1

Views

Author

Reinhard Zumkeller, Aug 20 2005

Keywords

Examples

			G.f. = 1 + x^2 + x^3 + x^4 + 2*x^5 + x^6 + 3*x^7 + x^8 + 4*x^9 + 2*x^10 + ...
a(12) = #{3^2+3, 7+5, 7+3+2, 5+2^2+3} = 4.
		

Crossrefs

Programs

  • PARI
    {a(n) = if(n < 0, 0, polcoeff( prod(k=1, primepi(n), (1 + x^prime(k)^2 + x*O(x^n)) * (1 + x^prime(k))), n))}; /* Michael Somos, Dec 26 2016 */

Formula

G.f.: Product_{k>=1} (1 + x^prime(k))*(1 + x^(prime(k)^2)). - Ilya Gutkovskiy, Dec 26 2016

A184083 Decimal expansion of product_{p=primes} (1+1/2^p).

Original entry on oeis.org

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

Views

Author

R. J. Mathar, Jan 09 2011

Keywords

Comments

Inverse of the constant A184084.

Examples

			(1+1/2^2) *(1+1/2^3) *(1+1/2^5) *(1+1/2^7) *(1+1/2^11)* .... = 1.4624312190069598013...
		

Programs

Formula

Equals product_{p in A000040} (1+2^(-p)) = sum_{n>=0} A000586(n)/2^n.

A281273 Expansion of Product_{j>=1} 1/(1 - x^(Sum_{i=1..j} prime(i))).

Original entry on oeis.org

1, 0, 1, 0, 1, 1, 1, 1, 1, 1, 3, 1, 3, 1, 3, 3, 3, 4, 3, 4, 6, 4, 7, 4, 7, 7, 7, 9, 8, 9, 12, 9, 14, 10, 15, 14, 15, 17, 17, 18, 22, 19, 25, 21, 27, 27, 28, 31, 31, 33, 38, 36, 42, 39, 45, 47, 49, 52, 55, 55, 64, 61, 70, 67, 74, 77, 81, 84, 91, 89, 102, 98, 110, 109, 116, 123, 126, 133, 141, 141, 156, 153, 168, 169, 178, 188, 193
Offset: 0

Views

Author

Ilya Gutkovskiy, Jan 18 2017

Keywords

Comments

Number of partitions of n into nonzero partial sums of primes (A007504).

Examples

			a(10) = 3 because we have [10], [5, 5] and [2, 2, 2, 2, 2], where 2 = prime(1), 5 = prime(1) + prime(2), 10 = prime(1) + prime(2) + prime(3).
		

Crossrefs

Programs

  • Mathematica
    nmax = 86; CoefficientList[Series[Product[1/(1 - x^Sum[Prime[i], {i, 1, j}]), {j, 1, nmax}], {x, 0, nmax}], x]

Formula

G.f.: Product_{j>=1} 1/(1 - x^(Sum_{i=1..j} prime(i))).

A300852 L.g.f.: log(Product_{k>=1} (1 + x^prime(k))) = Sum_{n>=1} a(n)*x^n/n.

Original entry on oeis.org

0, 2, 3, -2, 5, -1, 7, -2, 3, -3, 11, -5, 13, -5, 8, -2, 17, -1, 19, -7, 10, -9, 23, -5, 5, -11, 3, -9, 29, -6, 31, -2, 14, -15, 12, -5, 37, -17, 16, -7, 41, -8, 43, -13, 8, -21, 47, -5, 7, -3, 20, -15, 53, -1, 16, -9, 22, -27, 59, -10, 61, -29, 10, -2, 18, -12, 67, -19, 26, -10, 71, -5, 73, -35, 8
Offset: 1

Views

Author

Ilya Gutkovskiy, Mar 13 2018

Keywords

Examples

			L.g.f.: L(x) = 2*x^2/2 + 3*x^3/3 - 2*x^4/4 + 5*x^5/5 - x^6/6 + 7*x^7/7 - 2*x^8/8 + 3*x^9/9 - 3*x^10/10 + ...
exp(L(x)) = 1 + x^2 + x^3 + 2*x^5 + 2*x^7 + x^8 + x^9 + 2*x^10 + ... + A000586(n)*x^n + ...
		

Crossrefs

Cf. A000040 (fixed points), A000586, A008472, A300893, A300894.

Programs

  • Mathematica
    nmax = 75; Rest[CoefficientList[Series[Log[Product[(1 + x^Prime[k]), {k, 1, nmax}]], {x, 0, nmax}],x] Range[0, nmax]]
    nmax = 75; Rest[CoefficientList[Series[Sum[Prime[k] x^Prime[k]/(1 + x^Prime[k]), {k, 1, nmax}], {x, 0, nmax}], x]]
    Table[DivisorSum[n, (-1)^(n/# + 1) # &, PrimeQ[#] &], {n, 75}]

Formula

G.f.: Sum_{k>=1} prime(k)*x^prime(k)/(1 + x^prime(k)).
a(n) = Sum_{p|n, p prime} p * (-1)^(n/p + 1). [See Mmca prog.]

A302236 Expansion of Product_{k>=1} (1 + x^prime(k))/(1 + x^k).

Original entry on oeis.org

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

Views

Author

Ilya Gutkovskiy, Apr 03 2018

Keywords

Comments

The difference between the number of partitions of n into an even number of nonprime parts and the number of partitions of n into an odd number of nonprime parts.
Convolution of the sequences A000586 and A081362.

Crossrefs

Programs

  • Mathematica
    nmax = 80; CoefficientList[Series[Product[(1 + x^Prime[k])/(1 + x^k), {k, 1, nmax}], {x, 0, nmax}], x]
    nmax = 80; CoefficientList[Series[Product[1/(1 + Boole[!PrimeQ[k]] x^k), {k, 1, nmax}], {x, 0, nmax}], x]

Formula

G.f.: Product_{k>=1} 1/(1 + x^A018252(k)).
Previous Showing 51-60 of 106 results. Next