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.

Showing 1-5 of 5 results.

A096139 Number of ways to write 2*n as an ordered sum of two numbers which are prime or 1.

Original entry on oeis.org

1, 3, 3, 4, 3, 4, 5, 4, 6, 6, 5, 8, 5, 4, 8, 6, 7, 8, 5, 6, 10, 8, 7, 12, 8, 6, 12, 6, 7, 14, 7, 10, 12, 6, 10, 14, 11, 10, 14, 10, 9, 18, 9, 8, 20, 8, 9, 14, 8, 12, 18, 12, 11, 18, 14, 14, 22, 12, 11, 24, 7, 10, 20, 8, 14, 20, 11, 10, 18, 16, 15, 22, 11, 10, 26, 10, 16, 22, 11, 16, 20, 12
Offset: 1

Views

Author

David Stroup, Jul 23 2004

Keywords

Comments

A001031(n) = floor((a(n)+1)/2); a(n) mod 2 = A010051(n). - Reinhard Zumkeller, Aug 28 2013

Examples

			a(2)=3 because 4=1+3 or 4=2+2 or 4=3+1;
a(3)=3 because 6=1+5 or 6=3+3 or 6=5+1;
a(4)=4 because 8=1+7 or 8=3+5 or 8=5+3 or 8=7+1;
a(5)=3 because 10=3+7 or 10=5+5 or 10=7+3.
		

Crossrefs

Programs

  • Haskell
    a096139 n = sum (map a010051 gs') + fromEnum (1 `elem` gs')
       where gs' = map (2 * n -) $ takeWhile (< 2 * n) a008578_list
    -- Reinhard Zumkeller, Aug 28 2013
    
  • PARI
    { a(n) = local(s(n) = if(n==1,1,isprime(n))); sum(i=1,2*n,s(i)*s(2*n-i)); } \\ Christian Krause, Dec 06 2022

Extensions

Example extended and typo fixed by Reinhard Zumkeller, Aug 28 2013

A347745 Number of compositions (ordered partitions) of n into at most 3 noncomposite parts.

Original entry on oeis.org

1, 1, 2, 4, 6, 9, 10, 12, 13, 15, 15, 16, 13, 18, 17, 24, 19, 25, 18, 30, 24, 36, 23, 37, 23, 44, 29, 45, 19, 43, 20, 54, 30, 54, 25, 60, 29, 67, 29, 60, 21, 70, 28, 78, 38, 77, 31, 88, 33, 95, 44, 91, 30, 100, 30, 110, 42, 97, 25, 109, 35, 129, 49, 113, 31, 135
Offset: 0

Views

Author

Ilya Gutkovskiy, Sep 11 2021

Keywords

Comments

"Noncomposite" means "1 or a prime".

Crossrefs

Programs

  • Mathematica
    Table[Length@Flatten[Permutations/@IntegerPartitions[n,3,Join[{1},Prime@Range@PrimePi@n]],1],{n,0,65}] (* Giorgos Kalogeropoulos, Sep 12 2021 *)

A347703 Number of compositions (ordered partitions) of n into at most 4 prime parts (counting 1 as a prime).

Original entry on oeis.org

1, 1, 2, 4, 7, 13, 20, 28, 36, 43, 53, 60, 68, 70, 79, 84, 103, 105, 124, 118, 147, 144, 183, 165, 207, 180, 243, 213, 280, 215, 290, 222, 334, 258, 377, 260, 411, 299, 471, 324, 491, 302, 530, 346, 595, 377, 639, 380, 705, 435, 766, 463, 819, 456, 886, 506, 942
Offset: 0

Views

Author

Ilya Gutkovskiy, Sep 12 2021

Keywords

Crossrefs

Programs

  • Mathematica
    Table[Length@Flatten[Permutations/@IntegerPartitions[n,4,Join[{1},Prime@Range@PrimePi@n]],1],{n,0,56}] (* Giorgos Kalogeropoulos, Sep 12 2021 *)

A347760 Number of compositions (ordered partitions) of n into at most 5 prime parts (counting 1 as a prime).

Original entry on oeis.org

1, 1, 2, 4, 7, 14, 25, 43, 66, 93, 124, 160, 198, 240, 274, 315, 353, 415, 464, 538, 577, 669, 718, 850, 887, 1031, 1043, 1238, 1250, 1495, 1435, 1692, 1584, 1943, 1817, 2251, 2011, 2529, 2261, 2939, 2561, 3287, 2720, 3596, 3005, 4077, 3304, 4505, 3545, 4995, 3966
Offset: 0

Views

Author

Ilya Gutkovskiy, Sep 12 2021

Keywords

Crossrefs

Programs

  • Mathematica
    Table[Length@Flatten[Permutations/@IntegerPartitions[n,5,Join[{1},Prime@Range@PrimePi@n]],1],{n,0,50}] (* Giorgos Kalogeropoulos, Sep 12 2021 *)

A347761 Number of compositions (ordered partitions) of n into at most 6 prime parts (counting 1 as a prime).

Original entry on oeis.org

1, 1, 2, 4, 7, 14, 26, 49, 87, 143, 220, 316, 435, 576, 739, 911, 1100, 1297, 1541, 1798, 2113, 2405, 2785, 3136, 3648, 4061, 4670, 5080, 5828, 6301, 7261, 7692, 8751, 9059, 10379, 10681, 12329, 12435, 14354, 14335, 16847, 16673, 19588, 18866, 22247, 21257
Offset: 0

Views

Author

Ilya Gutkovskiy, Sep 12 2021

Keywords

Crossrefs

Programs

  • Mathematica
    Table[Length@Flatten[Permutations/@IntegerPartitions[n,6,Join[{1},Prime@Range@PrimePi@n]],1],{n,0,45}] (* Giorgos Kalogeropoulos, Sep 12 2021 *)
Showing 1-5 of 5 results.