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

A048448 a(n) = prime(n-1) + prime(n+1) (assuming prime(i) = 0 for i < 1).

Original entry on oeis.org

2, 3, 7, 10, 16, 20, 28, 32, 40, 48, 54, 66, 72, 80, 88, 96, 106, 114, 126, 132, 140, 150, 156, 168, 180, 190, 200, 208, 212, 220, 236, 244, 264, 270, 286, 290, 306, 314, 324, 336, 346, 354, 370, 374, 388, 392, 408, 422, 438, 452, 460, 468, 474, 490, 498, 514
Offset: 0

Views

Author

Patrick De Geest, May 15 1999

Keywords

Comments

Starting from prime sequence add previous and next term yielding generation 2.
a(n) = A116366(n,n-2) for n>2. - Reinhard Zumkeller, Feb 06 2006
Arithmetic derivative (see A003415) of prime(n-1)*prime(n+1) for n > 1. - Giorgio Balzarotti, May 26 2011

Crossrefs

Generation 1 is the 'prime sequence A000040'. See A048449-A048466. See also A047844.

Programs

  • GAP
    Concatenation([2,3], List([2..60], n-> Primes[n-1] + Primes[n+1])); # G. C. Greubel, May 18 2019
  • Magma
    [2,3] cat [NthPrime(n-1) + NthPrime(n+1): n in [2..60]];  // G. C. Greubel, May 18 2019
    
  • Mathematica
    Table[If[n < 2, Prime[n+1], Prime[n+1] + Prime[n-1]], {n, 0, 60}]
    Join[{2,3},First[#]+Last[#]&/@Partition[Prime[Range[60]],3,1]] (* Harvey P. Dale, Jan 25 2016 *)
  • MuPAD
    ithprime(i)+ithprime(i+2) $ i = 1..54 // Zerinvary Lajos, Feb 26 2007
    
  • PARI
    je=[2,3]; for(n=1,60,je=concat(je, prime(n)+prime(n+2))); je \\ modified by G. C. Greubel, May 18 2019
    
  • Sage
    [2,3] + [nth_prime(n-1) + nth_prime(n+1) for n in (2..60)] # G. C. Greubel, May 18 2019
    

A047844 Patrick De Geest's "Generations" array read by antidiagonals: a(n,1) = n-th prime, a(1,k+1) = a(2,k), a(n,k+1) = a(n-1,k) + a(n+1,k).

Original entry on oeis.org

2, 3, 3, 5, 7, 7, 7, 10, 13, 13, 11, 16, 23, 30, 30, 13, 20, 30, 43, 56, 56, 17, 28, 44, 67, 97, 127, 127, 19, 32, 52, 82, 125, 181, 237, 237, 23, 40, 68, 112, 179, 276, 403, 530, 530, 29, 48, 80, 132, 214, 339, 520, 757, 994, 994, 31, 54, 94, 162, 274
Offset: 1

Views

Author

Keywords

Examples

			Array begins:
  2,    3,    7,   13,   30,   56,  127,  237,  530, ...
  3,    7,   13,   30,   56,  127,  237,  530,  994, ...
  5,   10,   23,   43,   97,  181,  403,  757, 1662, ...
  7,   16,   30,   67,  125,  276,  520, 1132, 2156, ...
		

Crossrefs

Columns give A000040, A048448-A048455. See also A048456-A048466.

Programs

  • Maple
    A047844:=proc(n,k)global a:if(type(a[n,k],integer))then return a[n,k]:elif(k=1)then a[n,k]:=ithprime(n):elif(n=1)then a[n,k]:=A047844(2,k-1):else a[n,k]:=A047844(n-1,k-1)+A047844(n+1,k-1):fi:return a[n,k]:end:
    for d from 1 to 8 do for m from 1 to d do print(A047844(d-m+1,m)):od:od: # Nathaniel Johnston, Apr 11 2011
  • Mathematica
    a[n_, 1] := a[n, 1] = Prime[n]; a[1, k_] := a[1, k] = a[2, k-1]; a[n_, k_] := a[n, k] = a[n-1, k-1] + a[n+1, k-1]; Table[a[n-k+1, k], {n, 1, 11}, {k, 1, n}] // Flatten (* Jean-François Alcover, Nov 26 2013 *)
  • PARI
    a(n,k)=if(k==1,prime(n),n==1,a(2,k-1),a(n-1,k-1)+a(n+1,k-1))
    for(s=2,9,for(k=1,s-1,print1(a(s-k,k)", "))) \\ Charles R Greathouse IV, Nov 26 2013

Extensions

a(46)-a(60) from Nathaniel Johnston, Apr 11 2011

A048455 Starting from generation 8 add previous and next term yielding generation 9.

Original entry on oeis.org

530, 994, 1662, 2156, 2970, 3598, 4491, 5335, 6231, 7278, 8178, 9308, 10290, 11382, 12502, 13530, 14738, 15768, 16960, 18082, 19228, 20462, 21608, 22870, 24050, 25238, 26522, 27600, 29148, 30120, 32004, 32880, 34930, 35772, 37724, 38646
Offset: 0

Views

Author

Patrick De Geest, May 15 1999

Keywords

Crossrefs

Generation 8 is A048454. See A048448-A048466. See also A047844.

A048449 Starting from generation 2 add previous and next term yielding generation 3.

Original entry on oeis.org

7, 13, 23, 30, 44, 52, 68, 80, 94, 114, 126, 146, 160, 176, 194, 210, 232, 246, 266, 282, 296, 318, 336, 358, 380, 398, 412, 428, 448, 464, 500, 514, 550, 560, 592, 604, 630, 650, 670, 690, 716, 728, 758, 766, 796, 814, 846, 874, 898, 920, 934, 958, 972, 1004
Offset: 0

Views

Author

Patrick De Geest, May 15 1999

Keywords

Crossrefs

Generation 2 is A048448. See A048448-A048466. See also A047844.

A048450 Starting from generation 3 add previous and next term yielding generation 4.

Original entry on oeis.org

13, 30, 43, 67, 82, 112, 132, 162, 194, 220, 260, 286, 322, 354, 386, 426, 456, 498, 528, 562, 600, 632, 676, 716, 756, 792, 826, 860, 892, 948, 978, 1050, 1074, 1142, 1164, 1222, 1254, 1300, 1340, 1386, 1418, 1474, 1494, 1554, 1580, 1642, 1688, 1744
Offset: 0

Views

Author

Patrick De Geest, May 15 1999

Keywords

Crossrefs

Generation 3 is A048449. See A048448-A048466. See also A047844.

A048451 Starting from generation 4 add previous and next term yielding generation 5.

Original entry on oeis.org

30, 56, 97, 125, 179, 214, 274, 326, 382, 454, 506, 582, 640, 708, 780, 842, 924, 984, 1060, 1128, 1194, 1276, 1348, 1432, 1508, 1582, 1652, 1718, 1808, 1870, 1998, 2052, 2192, 2238, 2364, 2418, 2522, 2594, 2686, 2758, 2860, 2912, 3028, 3074, 3196, 3268
Offset: 0

Views

Author

Patrick De Geest, May 15 1999

Keywords

Crossrefs

Generation 4 is A048450. See A048448-A048466. See also A047844.

A048452 Starting from generation 5 add previous and next term yielding generation 6.

Original entry on oeis.org

56, 127, 181, 276, 339, 453, 540, 656, 780, 888, 1036, 1146, 1290, 1420, 1550, 1704, 1826, 1984, 2112, 2254, 2404, 2542, 2708, 2856, 3014, 3160, 3300, 3460, 3588, 3806, 3922, 4190, 4290, 4556, 4656, 4886, 5012, 5208, 5352, 5546, 5670, 5888, 5986, 6224
Offset: 0

Views

Author

Patrick De Geest, May 15 1999

Keywords

Crossrefs

Generation 5 is A048451. See A048448-A048466. See also A047844.

A048453 Starting from generation 6 add previous and next term yielding generation 7.

Original entry on oeis.org

127, 237, 403, 520, 729, 879, 1109, 1320, 1544, 1816, 2034, 2326, 2566, 2840, 3124, 3376, 3688, 3938, 4238, 4516, 4796, 5112, 5398, 5722, 6016, 6314, 6620, 6888, 7266, 7510, 7996, 8212, 8746, 8946, 9442, 9668, 10094, 10364, 10754, 11022, 11434, 11656
Offset: 0

Views

Author

Patrick De Geest, May 15 1999

Keywords

Crossrefs

Generation 6 is A048452. See A048448-A048466. See also A047844.

A048454 Starting from generation 7 add previous and next term yielding generation 8.

Original entry on oeis.org

237, 530, 757, 1132, 1399, 1838, 2199, 2653, 3136, 3578, 4142, 4600, 5166, 5690, 6216, 6812, 7314, 7926, 8454, 9034, 9628, 10194, 10834, 11414, 12036, 12636, 13202, 13886, 14398, 15262, 15722, 16742, 17158, 18188, 18614, 19536, 20032, 20848
Offset: 0

Views

Author

Patrick De Geest, May 15 1999

Keywords

Crossrefs

Generation 7 is A048453. See A048448-A048466. See also A047844.

Extensions

Missing a(5) inserted by Sean A. Irvine, Jun 16 2021
Showing 1-9 of 9 results.