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

A192176 Index array for A192175 (distance up to next prime), by antidiagonals.

Original entry on oeis.org

1, 2, 4, 3, 6, 9, 5, 8, 11, 24, 7, 12, 15, 72, 34, 10, 14, 16, 77, 42, 46, 13, 19, 18, 79, 53, 47, 30, 17, 22, 21, 87, 61, 91, 62, 282, 20, 25, 23, 92, 68, 97, 66, 295, 99, 26, 27, 32, 94, 80, 114, 137, 319, 180, 154, 28, 29, 36, 124, 82, 121, 146, 331, 205, 259, 189
Offset: 1

Views

Author

Clark Kimberling, Jun 24 2011

Keywords

Comments

Row 1: numbers k such that p + 1 or p + 2 is a prime,
where p = (k-th prime).
Row r > 1: numbers k such that if p = (k-th prime) then r = (least h for which p + 2 h) is a prime.
Every positive integer occurs exactly once, so that as a sequence, A192176 is a permutation of the positive integers.

Examples

			Northwest corner:
1....2....3....5....7....10....13
4....6....8....12...14...19....22
9....11...15...16...18...21....23
24...72...77...79...87...92....94
34...42...53...61...68...80....82
...
These are the index numbers of the primes displayed in the Example at A192175; e.g., in that display, the top row begins with 2,3,5,11,17,29,41.
		

Crossrefs

Programs

A192179 Array determined by distance to next prime, by antidiagonals.

Original entry on oeis.org

1, 2, 3, 4, 5, 8, 6, 9, 14, 7, 10, 11, 20, 13, 24, 12, 15, 26, 19, 32, 23, 16, 17, 34, 25, 48, 31, 90, 18, 21, 38, 33, 54, 47, 120, 89, 22, 27, 44, 37, 62, 53, 142, 119, 118, 28, 29, 50, 43, 74, 61, 184, 141, 140, 117, 30, 35, 56, 49, 84, 73, 204, 183, 182, 139, 116
Offset: 1

Views

Author

Clark Kimberling, Jun 24 2011

Keywords

Comments

Row r : numbers k such that r = (least positive integer h for which k + h is a prime).
Every positive integer occurs exactly once, so that as a sequence, A192179 is a permutation of the positive integers.
For r>1, the numbers in row r have the parity of r-1; e.g., the numbers in row 2 are odd.

Examples

			Northwest corner:
1....2....4....6....10....12
3....5....9....11...15....17
8....14...20...26...34....38
7....13...19...25...33....37
24...32...48...54...62....74
...
For example, 14 is in row 3 because 14 + 3 is a prime, unlike 14 + 1 and 14 + 2.
		

Crossrefs

Programs

  • Mathematica
    z = 5000;  (* z = number of primes used *)
    Do[row[x] = Complement[(#1[[1]] &) /@ Cases[({#1 - x, PrimeQ[#1]} &) /@ (Range[z] + x), {_, True}],
       Flatten[Array[row, {x - 1}]]], {x, 1, 10}]
    TableForm[Array[row, {10}]]    (* A192179 array *)
    Flatten[Table[row[k][[n - k + 1]], {n, 1, 11}, {k, 1,
       n}]]   (* A192179 sequence *)
    (* Peter J. C. Moses, Jun 24 2011 *)

A192177 Array determined by distance down to nearest prime.

Original entry on oeis.org

1, 2, 5, 3, 7, 10, 4, 9, 16, 11, 6, 13, 22, 17, 28, 8, 15, 26, 23, 36, 29, 12, 19, 34, 27, 52, 37, 96, 14, 21, 40, 35, 58, 53, 120, 97, 18, 25, 46, 41, 66, 59, 146, 121, 122, 20, 31, 50, 47, 78, 67, 188, 147, 148, 123, 24, 33, 56, 51, 88, 79, 206, 189, 190, 149, 11
Offset: 1

Views

Author

Clark Kimberling, Jun 24 2011

Keywords

Comments

Row 1: numbers k such that k = 1 or k = 2 or k - 1 is a prime.
Row r > 1: numbers k such that k - r is a prime and k - q is not, for q = 1, 2, ..., r - 1.
Every positive integer occurs exactly once, so that as a sequence, A192177 is a permutation of the positive integers.
For r>1, the numbers in row r have the parity of r-1; e.g., the numbers in row 2 are odd.

Examples

			Northwest corner:
1....2....3....4....6....8
5....7....9....13...15...19
10...16...22...26...34...40
11...17...23...27...35...41
28...36...52...58...66...78
...
For example, 16 is in row 3 because 16 - 3 is prime, unlike 16 - 1 and 16 - 2.
		

Crossrefs

Programs

  • Mathematica
    z = 5000; (* z = number of primes used *)
    row[1] = (#1[[1]] &) /@ Cases[Array[{#1, PrimeQ[#1 - 1] || #1 == 1 || #1 == 2} &, {z}], {_, True}];
    Do[row[x] = Complement[(#1[[1]] &) /@  Cases[Array[{#1, PrimeQ[#1 - x]} &, {z}], {_, True}], Flatten[Array[row, {x - 1}]]], {x, 2, 10}];
    TableForm[Array[row, {10}]]  (* A192177 array *)
    Flatten[Table[row[k][[n - k + 1]], {n, 1, 11}, {k, 1,
       n}]]  (* A192177 sequence *)
    (* by Peter J. C. Moses, Jun 24 2011 *)

A192178 Array by distance to nearest prime, by antidiagonals.

Original entry on oeis.org

1, 2, 5, 3, 7, 26, 4, 9, 34, 23, 6, 11, 50, 37, 118, 8, 13, 56, 47, 122, 53, 10, 15, 64, 67, 144, 89, 120, 12, 17, 76, 79, 186, 119, 300, 409, 14, 19, 86, 83, 204, 121, 324, 479, 532, 16, 21, 92, 93, 206, 157, 530, 531, 896, 293, 18, 25, 94, 97, 216, 173, 534, 533, 898, 631, 11
Offset: 1

Views

Author

Clark Kimberling, Jun 24 2011

Keywords

Comments

Row 1: numbers k such that k = 1 or k = 2 or (k - 1 or k + 1) is a prime.
Row r > 1: numbers k such that k + r or k - r is a prime but k + q and k - q are not, for q = 1, 2, ..., r - 1.
Every positive integer occurs exactly once, so that as a sequence, A192178 is a permutation of the positive integers.
For r > 1, the numbers in row r have the parity of r - 1; e.g., the numbers in row 2 are odd.

Examples

			Northwest corner:
1....2....3....4....6....8....10
5....7....9....11...13...15...17
26...34...50...56...64...76...86
23...37...47...67...79...83...93
118..122..144..186..204..206..216
...
For example, 34 is in row 3 recause its distance to the nearest prime is 3.
		

Crossrefs

Programs

  • Mathematica
    z = 5000; (* z = number of primes used *)
    row[1] = (#1[[1]] &) /@ Cases[Array[{#1, PrimeQ[#1 - 1] || PrimeQ[#1 + 1] || #1 == 1 || #1 == 2} &, {z}], {_, True}];
    Do[row[x] = Complement[(#1[[1]] &) /@ Cases[Array[{#1, PrimeQ[#1 - x] || PrimeQ[#1 + x]} &, {z}], {_, True}], Flatten[Array[row, {x - 1}]]], {x, 2, 10}];
    TableForm[Array[row, {10}]]  (* A192178 array *)
    Flatten[Table[row[k][[n - k + 1]], {n, 1, 11}, {k, 1,
       n}]]   (* A192178 sequence *)
    (* by Peter J. C. Moses, Jun 24 2011 *)
Showing 1-4 of 4 results.