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 11-18 of 18 results.

A238711 Product of all primes p such that 2n - p is also prime.

Original entry on oeis.org

2, 3, 15, 105, 35, 231, 2145, 5005, 4641, 53295, 1616615, 119301, 21505, 7436429, 21489, 57998985, 3038795305, 4123, 13844919, 10393190665, 12838371, 299859855, 7292509103495, 12023917269, 70691995, 37198413949697, 62483343, 2769282065, 98755025688454681
Offset: 2

Views

Author

Reinhard Zumkeller, Mar 06 2014

Keywords

Comments

Product of n-th row in triangle A171637;
All terms greater than 3 are odd, composite and squarefree numbers, cf. A024556.
n is prime iff n is a factor of a(n).
Product of the distinct primes in the Goldbach partitions of 2n. - Wesley Ivan Hurt, Sep 29 2020

Crossrefs

Cf. A000040, A010051, A238778, subsequence of A056911.

Programs

  • Haskell
    a238711 n = product $ filter ((== 1) . a010051') $
       map (2 * n -) $ takeWhile (<= 2 * n) a000040_list
  • Mathematica
    Table[Times@@Select[Select[Prime[Range[2 n]], # < 2 n &], PrimeQ[2 n - #] &], {n, 2, 30}] (* Robert Price, Apr 26 2025 *)

Formula

A020639(a(n)) = A020481(n); A006530(a(n)) = A020482(n);
A001221(a(n)) = A035026(n); A008472(a(n)) = A238778(n);
A027748(a(n),k) + A027748(a(n),l+1-k) = 2*n for k=1..l, with l=A001221(a(n)); particulary A020639(a(n))+A006530(a(n)) = 2*n;
a(n) = n^c(n) * Product_{i=1..n-1} (i*(2*n-i))^(c(i)*c(2*n-i)), where c is the prime characteristic (A010051). - Wesley Ivan Hurt, Sep 29 2020

A238778 Sum of all primes p such that 2n - p is also a prime.

Original entry on oeis.org

2, 3, 8, 15, 12, 21, 32, 36, 40, 55, 72, 65, 56, 90, 64, 119, 144, 57, 120, 168, 132, 161, 240, 200, 156, 270, 168, 203, 360, 155, 320, 396, 136, 350, 432, 333, 380, 546, 320, 369, 672, 387, 352, 810, 368, 423, 672, 294, 600, 816, 520, 583, 864, 660, 784
Offset: 2

Views

Author

Reinhard Zumkeller, Mar 06 2014

Keywords

Comments

Sum of n-th row in triangle A171637.

Crossrefs

Programs

  • Haskell
    a238778 n = sum $ filter ((== 1) . a010051') $
       map (2 * n -) $ takeWhile (<= 2 * n) a000040_list
    
  • Mathematica
    Table[Total@Select[Select[Prime[Range[2 n]], # < 2 n &], PrimeQ[2 n - #] &], {n, 2, 56}] (* Robert Price, Apr 26 2025 *)
  • PARI
    a(n) = my(s=0); forprime(p=2, 2*n, if(isprime(2*n-p), s+=p)); s; \\ Michel Marcus, Jan 24 2022

Formula

a(n) = A008472(A238711(n)).
a(n) mod 2 = A010051(n).
a(n) = n*A035026(n). - Robert G. Wilson v, Apr 28 2018

A199331 Number of ordered ways of writing n as the sum of two semiprimes.

Original entry on oeis.org

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

Views

Author

Robert G. Wilson v, Nov 05 2011

Keywords

Comments

Conjecture: Only the integers 1, 2, 3, 4, 5, 6, 7, 9, 11, 17, 22, 33 (A072966) cannot be partitioned into a set of two semiprimes.

Crossrefs

Programs

  • Maple
    sp:= select(t -> numtheory:-bigomega(t)=2, [$1..100]):
    G:= expand(add(x^t,t=sp)^2):
    seq(coeff(G,x,i),i=1..100); # Robert Israel, Nov 24 2020
  • Mathematica
    mx=200; semiPrimeQ[n_] := Plus @@ Last /@ FactorInteger@ n == 2; t = Select[ Range@ mx, semiPrimeQ]; s = Sort[Plus @@@ Tuples[t, 2]]; Transpose[ Tally@ Join[ Range@ mx, s]][[2]] - 1

Formula

a(n) = Sum_{k=1..n-1} c(k) * c(n-k), where c = A064911. - Wesley Ivan Hurt, Jan 07 2024

Extensions

Definition clarified by Robert Israel, Nov 24 2020

A341459 Number of compositions of n^2 into n prime parts.

Original entry on oeis.org

1, 0, 1, 4, 22, 241, 2696, 35218, 529888, 8998419, 169486964, 3496417024, 78344008779, 1891733424205, 48923563968087, 1347813311456319, 39371345548420060, 1214570579814316742, 39430967625404799740, 1343040950675651131103, 47862610677098010505554
Offset: 0

Views

Author

Alois P. Heinz, Feb 12 2021

Keywords

Examples

			a(3) = 4: 333, 225, 252, 522.
		

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(n^2, n):
    seq(a(n), n=0..22);
  • Mathematica
    b[n_, t_] := b[n, t] =
         If[n == 0, If[t == 0, 1, 0], If[t < 1, 0, Sum[
         If[PrimeQ[j], b[n-j, t-1], 0], {j, 1, n}]]];
    a[n_] := b[n^2, n];
    Table[a[n], {n, 0, 22}] (* Jean-François Alcover, May 02 2022, after Alois P. Heinz *)

Formula

a(n) = A121303(n^2,n).

A094113 Total area of all 1-histograms of length n.

Original entry on oeis.org

1, 7, 44, 268, 1609, 9583, 56792, 335448, 1976689, 11627735, 68308580, 400870468, 2350563097, 13773547487, 80663415344, 472175746096, 2762854639585, 16160861104423, 94502471413916, 552472329537660
Offset: 1

Views

Author

Ralf Stephan, May 03 2004

Keywords

Comments

Arises in analysis of first-come-first-served (FCFS) printer policy.

Crossrefs

Programs

  • Mathematica
    Rest[CoefficientList[Series[(1+x-Sqrt[1-6*x+x^2])/(4*(1-6*x+x^2)), {x, 0, 20}], x]] (* Vaclav Kotesovec, Feb 23 2014 *)

Formula

G.f.: (1+x-sqrt(1-6*x+x^2))/(4*(1-6*x+x^2)).
Recurrence: (n+1)*a(n) = (8-n)*a(n-10) + 3*(10*n-71)*a(n-9) + (2263-365*n)*a(n-8) + 4*(570*n-3021)*a(n-7) + 2*(16654-3785*n)*a(n-6) + 6138*(2*n-7)*a(n-5) + 2*(9841-3785*n)*a(n-4) + 4*(570*n-969)*a(n-3) + (292-365*n)*a(n-2) + 3*(10*n+1)*a(n-1), n>=10. - Fung Lam, Feb 07 2014
Recurrence (of order 4): n*a(n) = 3*(4*n-3)*a(n-1) - 19*(2*n-3)*a(n-2) + 3*(4*n-9)*a(n-3) - (n-3)*a(n-4). - Vaclav Kotesovec, Feb 23 2014
a(n) ~ (sqrt(2)-1)/8 * (3+2*sqrt(2))^(n+1). - Vaclav Kotesovec, Feb 23 2014

A254713 All numbers k such that the number of distinct parts of all A045917(k) Goldbach partitions of 2k is prime.

Original entry on oeis.org

4, 5, 6, 7, 11, 13, 17, 19, 23, 29, 31, 53, 59, 61, 67, 73, 83, 89, 97, 101, 103, 109, 113, 127, 131, 139, 151, 157, 163, 173, 179, 191, 193, 199, 223, 227, 229, 251, 263, 271, 307, 313, 337, 347, 353, 359, 367, 379, 389, 401, 449, 479, 521, 523, 577, 587, 599, 601, 607, 613, 631, 643
Offset: 1

Views

Author

Ivan N. Ianakiev, Feb 06 2015

Keywords

Comments

Conjecture: a(k) is prime for k > 3. Tested for k up to 3*10^4.

Examples

			For k = 4, 2k = 8. The number of the distinct Goldbach parts of 8 (3 and 5) is prime, therefore 4 is in the sequence.
5 is in the sequence because the 2 = A045917(5) Goldbach partitions of 10 are 5 + 5 and 3 + 7, and there are 3 distinct parts, namely 3, 5 and 7. - _Wolfdieter Lang_, Feb 23 2015
		

Crossrefs

Programs

  • Mathematica
    lstIn={};lstFin={};
    goldPart[x_]:=Module[{h=x/2},While[h>1,If[And[PrimeQ[h],PrimeQ[x-h]],AppendTo[lstIn,{h,x-h}]];h--];
    lstFin=Length[Union[Flatten[lstIn]]];lstIn={};lstFin];
    a254713=Flatten[Position[PrimeQ[goldPart/@Range[2,2002,2]],True]]

Extensions

Edited. Wolfdieter Lang, Feb 23 2015

A280667 a(n) = number of primes of the form 4k + 1 such that 2n - 4k - 1 is prime.

Original entry on oeis.org

0, 0, 0, 1, 1, 1, 0, 2, 2, 2, 2, 3, 1, 2, 2, 2, 3, 4, 0, 3, 4, 3, 4, 5, 2, 3, 4, 3, 5, 6, 0, 5, 6, 2, 4, 6, 3, 5, 6, 4, 3, 8, 2, 4, 6, 4, 4, 7, 2, 6, 8, 5, 5, 8, 4, 7, 10, 6, 6, 12, 3, 5, 10, 3, 6, 9, 4, 5, 6, 7, 8, 11, 3, 5, 10, 4, 8, 11, 2, 8, 10, 5, 6, 13, 6, 6, 8, 7, 7, 14, 2, 8, 12, 5
Offset: 1

Views

Author

Juri-Stepan Gerasimov, Jan 07 2017

Keywords

Comments

Primes p such that a(p) = 0: 2, 3, 7, 19, 31.

Examples

			a(8) = 2 because 2*8 - 4*1 - 1 = 11 is prime where 4*1 + 1 = 5 is prime of the form 4k+1 and 2*8 - 4*3 - 1 = 3 is prime where 4*3 + 1 = 13 is prime of the form 4k+1.
		

Crossrefs

Programs

  • Magma
    A280667 := func; [A280667(n):n in[1..100]];
    
  • PARI
    a(n) = sum(k=1, 2*n, isprime(k) && isprime(2*n-k) && ((2*n-k) % 4 == 1)); \\ Michel Marcus, Jan 07 2017

A306196 Irregular triangle read by rows where row n lists the primes 2n - k, with 1 < k < 2n-1, and if k is composite also 2n - p has to be prime for some prime divisor p of k.

Original entry on oeis.org

2, 3, 2, 3, 5, 3, 5, 7, 2, 5, 7, 2, 3, 5, 7, 11, 3, 5, 7, 11, 13, 3, 5, 7, 11, 13, 2, 3, 5, 7, 11, 13, 17, 2, 3, 5, 7, 11, 13, 17, 19, 2, 3, 5, 7, 11, 13, 17, 19, 2, 3, 5, 7, 11, 13, 17, 19, 23, 3, 5, 11, 13, 17, 23, 2, 7, 11, 13, 17, 19, 23, 2, 3, 5, 11, 13, 17, 19, 23, 29
Offset: 2

Views

Author

Juri-Stepan Gerasimov, Jan 28 2019

Keywords

Comments

Conjectures:
(i) 1 <= A035026(n) <= (n-th row length of this triangle) for n >= 2;
(ii) a(n,1) < A171637(n,1) for n >= 4.
Numbers m such that m-th row length of this triangle is equal to A000720(m): 1, 2, 11, 13, 25, 56, 60, ...

Examples

			Row 2 = [2] because 2*2 = 2 + 2;
Row 3 = [3] because 2*3 = 3 + 3;
Row 4 = [2,3,5] because 2*4 - 2 = 6 = 2*3 and 2*4 = 3 + 5;
Row 5 = [3,5,7] because 2*5 = 3 + 7 = 5 + 5.
The table starts:
  2;
  3;
  2,  3,  5;
  3,  5,  7;
  2,  5,  7;
  2,  3,  5,  7, 11;
  3,  5,  7, 11, 13;
  3,  5,  7, 11, 13;
  2,  3,  5,  7, 11, 13, 17;
  2,  3,  5,  7, 11, 13, 17, 19;
  2,  3,  5,  7, 11, 13, 17, 19;
  2,  3,  5,  7, 11, 13, 17, 19, 23;
  3,  5, 11, 13, 17, 23;
  2,  7, 11, 13, 17, 19, 23;
  2,  3,  5, 11, 13, 17, 19, 23, 29;
		

Crossrefs

Supersequence of A171637.

Programs

  • PARI
    isok(k,n) = {if (isprime(2*n-k), pf = factor(k)[,1]; for (j=1, #pf, if (isprime(2*n-pf[j]), return (1));););}
    row(n) = {my(v = []); for (k=1, 2*n, if (isok(k,n), v = concat(v, 2*n-k))); vecsort(v);} \\ Michel Marcus, Mar 02 2019
Previous Showing 11-18 of 18 results.