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

A154804 Number of ways to represent 2*n as the sum of two distinct primes (counting 1 as a prime).

Original entry on oeis.org

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

Views

Author

Omar E. Pol, Jan 16 2009

Keywords

Comments

Number of ways to represent 2*n as the sum of two distinct noncomposite numbers. - Omar E. Pol, Dec 11 2024

Crossrefs

Formula

a(n) = A101264(n-1) + A061357(n). [From R. J. Mathar, Jan 21 2009]
a(n) = A001031(n) - A080339(n).

Extensions

More terms from R. J. Mathar, Jan 21 2009
Edited by Franklin T. Adams-Watters, Jan 31 2009

A154799 Records in A154804.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 9, 10, 11, 12, 13, 14, 15, 19, 20, 21, 24, 28, 31, 33, 41, 42, 44, 52, 58, 69, 73, 76, 83, 92, 98, 115, 129, 138, 139, 154, 164, 165, 166, 172, 190, 198, 218, 223, 241, 268, 274, 292, 304, 330, 331, 341, 362, 394, 434, 447, 448, 466, 478
Offset: 1

Views

Author

Omar E. Pol, Feb 01 2009

Keywords

Crossrefs

Programs

  • Maple
    read("transforms") ; A008578 := proc(n) RETURN( n=1 or isprime(n) ) ; end : A154804 := proc(n) local a,d; a := 0 ; for d from 1 to n-1 do if A008578(n-d) and A008578(n+d) then a := a+1; fi; od: a ; end: a804 := [seq(A154804(n),n=1..5000)] ; r := RECORDS(a804)[1] ; # R. J. Mathar, Mar 14 2009

Extensions

More terms from R. J. Mathar, Mar 14 2009
a(53) and beyond from Michael S. Branicky, Dec 11 2024

A154791 Triangle read by rows in which row n lists all the pairs of noncomposite numbers that are equidistant from n, with 0's inserted, as shown below in the example.

Original entry on oeis.org

0, 1, 3, 1, 0, 5, 1, 3, 5, 7, 0, 3, 0, 7, 0, 1, 0, 5, 7, 0, 11, 1, 3, 0, 0, 0, 11, 13, 0, 3, 5, 0, 0, 11, 13, 0, 1, 0, 5, 7, 0, 11, 13, 0, 17, 1, 3, 0, 7, 0, 0, 13, 0, 17, 19, 0, 3, 5, 0, 0, 0, 0, 0, 17, 19, 0, 1, 0, 5, 7, 0, 11, 13, 0, 17, 19, 0, 23
Offset: 1

Views

Author

Omar E. Pol, Jan 25 2009

Keywords

Examples

			Triangle begins:
n ....... Pairs
1 ..........0
2 ........ 1,3
3 ....... 1,0,5
4 ...... 1,3,5,7
5 ..... 0,3,0,7,0
6 .... 1,0,5,7,0,11
		

Crossrefs

Programs

  • PARI
    iscomp(n) = (n!=1) && !isprime(n);
    vecp(n) = {v = vector(n, i, 2*i-1); for (i = 1, n\2, if (iscomp(v[i]) || iscomp(v[n-i+1]), v[i] = 0; v[n-i+1] = 0);); if ((n % 2), v[n\2+1] = 0); v;}
    trgp(nn) = {for (n = 1, nn, v = vecp(n); for (k = 1, n, print1(v[k], ", ");); print(););} \\ Michel Marcus, Feb 13 2014

Extensions

More terms from Michel Marcus, Feb 13 2014

A154800 List of pairs of primes that are equidistant from and nearest to n, or the pair (0,0) if there is no such pair.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 3, 5, 3, 7, 5, 7, 3, 11, 5, 11, 7, 11, 7, 13, 5, 17, 11, 13, 7, 19, 11, 17, 13, 17, 13, 19, 11, 23, 17, 19, 7, 31, 17, 23, 19, 23, 13, 31, 17, 29, 19, 29, 19, 31, 23, 29, 23, 31, 19, 37, 17, 41, 29, 31, 19, 43, 23, 41, 29, 37, 31, 37, 29, 41, 31, 41, 31, 43, 29, 47
Offset: 1

Views

Author

Omar E. Pol, Jan 15 2009, Jan 18 2009

Keywords

Comments

Conjecture: There are only six 0's in this sequence.

Examples

			Array begins:
n ............... Pair
1 .............. 0 . 0
2 .............. 0 . 0
3 .............. 0 . 0
4 .............. 3 . 5
5 ............ 3 . . . 7
6 .............. 5 . 7
7 ........ 3 . . . . . . . 11
8 .......... 5 . . . . . 11
9 ............ 7 . . . 11
10 ......... 7 . . . . . 13
		

Crossrefs

Programs

  • Maple
    A154800 := proc(n) local d; for d from 1 to n-1 do if isprime(n-d) and isprime(n+d) then printf("%d,%d,",n-d,n+d); RETURN() ; fi; od: printf("0,0,") ; end: seq(A154800(n),n=1..80) ; # R. J. Mathar, Jul 13 2009

Extensions

More terms from R. J. Mathar, Jul 13 2009

A154891 Where records occurs in A154804.

Original entry on oeis.org

1, 2, 4, 9, 12, 21, 24, 30, 42, 45, 57, 60, 75, 84, 90, 105, 135, 150, 165, 195, 210, 255, 315, 330, 390, 420, 525, 630, 735, 825, 840, 945, 1050, 1155, 1365, 1575, 1680, 1785, 1995, 2100, 2145, 2205, 2310, 2625, 2730, 3045, 3255, 3465, 3990, 4095, 4515, 4620
Offset: 1

Views

Author

Omar E. Pol, Feb 01 2009

Keywords

Crossrefs

Programs

  • Maple
    A008578 := proc(n) RETURN( n=1 or isprime(n) ) ; end : A154804 := proc(n) local a,d; a := 0 ; for d from 1 to n-1 do if A008578(n-d) and A008578(n+d) then a := a+1; fi; od: a ; end: a804 := [seq(A154804(n),n=1..4000)] ; r := RECORDS(a804)[2] ; # R. J. Mathar, Mar 14 2009

Extensions

More terms from R. J. Mathar, Mar 14 2009
a(50) and beyond from Michael S. Branicky, Dec 11 2024

A154792 Triangle read by rows in which row n lists the pair of noncomposite numbers that are equidistant from and nearest to n, with 0's inserted, as shown below in the example.

Original entry on oeis.org

0, 1, 3, 1, 0, 5, 0, 3, 5, 0, 0, 3, 0, 7, 0, 0, 0, 5, 7, 0, 0, 0, 3, 0, 0, 0, 11, 0, 0, 0, 5, 0, 0, 11, 0, 0, 0, 0, 0, 7, 0, 11, 0, 0, 0, 0, 0, 0, 7, 0, 0, 13, 0, 0, 0
Offset: 1

Views

Author

Omar E. Pol, Jan 25 2009

Keywords

Examples

			Triangle begins:
n ........ Pair
1 ..........0
2 ........ 1,3
3 ....... 1,0,5
4 ...... 0,3,5,0
5 ..... 0,3,0,7,0
6 .... 0,0,5,7,0,0
		

Crossrefs

Previous Showing 11-16 of 16 results.