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

A177868 a(n) = number of 2-digit primes with digit sum n, where n runs through the non-multiples of 3 in the range [2..17].

Original entry on oeis.org

1, 2, 2, 2, 3, 3, 3, 1, 1, 2, 1
Offset: 1

Views

Author

N. J. A. Sloane, Dec 28 2010

Keywords

Examples

			Digital sums of 2-digit primes
Sum     count
2       1
4       2
5       2
7       2
8       3
10      3
11      3
13      1
14      1
16      2
17      1
		

Crossrefs

For 2- through 9-digit primes the counts are in A177868, A178183, A178447, A178571, A178605, A178876, A178879, A178884.
Cf. 2nd row of A178701.

A178183 a(n) = number of 3-digit primes with digit sum n, where n runs through the non-multiples of 3 in the range [2..26].

Original entry on oeis.org

1, 2, 4, 7, 7, 12, 13, 16, 16, 13, 18, 12, 11, 6, 4, 1, 0
Offset: 1

Views

Author

N. J. A. Sloane, Dec 28 2010

Keywords

Examples

			Digit-sums of 3-digit primes
Sum     count
2       1
4       2
5       4
7       7
8       7
10      12
11      13
13      16
14      16
16      13
17      18
19      12
20      11
22      6
23      4
25      1
26      0
		

Crossrefs

For 2- through 9-digit primes the counts are in A177868, A178183, A178447, A178571, A178605, A178876, A178879, A178884.
Cf. 3rd row of A178701.

Programs

  • Mathematica
    Join[SortBy[Tally[Total[IntegerDigits[#]]&/@Prime[Range[26,168]]],First][[;;,2]],{0}] (* Harvey P. Dale, Feb 08 2025 *)

A178701 An irregular array read by rows. The k-th entry of row r is the number of r-digit primes with digit sum k.

Original entry on oeis.org

1, 0, 1, 1, 0, 1, 2, 2, 2, 3, 3, 3, 1, 1, 2, 1, 1, 2, 4, 7, 7, 12, 13, 16, 16, 13, 18, 12, 11, 6, 4, 1, 0, 0, 4, 8, 20, 19, 31, 52, 67, 77, 93, 101, 116, 95, 92, 91, 63, 51, 29, 30, 16, 5, 0, 1, 0, 4, 12, 28, 45, 95, 143, 236, 272, 411, 479, 630, 664, 742, 757, 741, 706, 580, 528, 379, 341, 205, 166, 84, 62, 34, 13, 4, 2, 0, 2, 14, 58, 76, 204, 389, 660, 852, 1448, 1971, 2832, 3101, 4064, 4651, 5393, 5376, 5570, 5785, 5287, 4796
Offset: 1

Views

Author

Robert G. Wilson v, Dec 29 2010

Keywords

Comments

Each row, r, has 6r-1 terms. The first row does not account for the prime 3 and its count of 1.

Examples

			To begin the second row, only 11 has digit-sum 2, so the first term is 1; both 13 & 31 have digit-sum 4 so the second term is 2; both 23 & 41 have digit-sum 5, so the third term is 2; etc.
To begin the third row, only 101 -> 2, so its first term is 1, both 103 & 211 -> 4 so its second term is 2; 113, 131, 311 & 401 -> 5, so its third term is 4; etc.
  \k 2, 4,  5,  7,  8,  10,  11,  13,  14,   16,   17,   19,   20,   22,   23,   25,   26, ...
  r\
  1: 1, 0,  1,  1,  0;
  2: 1, 2,  2,  2,  3,   3,   3,   1,   1,    2,    1;
  3: 1, 2,  4,  7,  7,  12,  13,  16,  16,   13,   18,   12,   11,    6,    4,    1,    0;
  4: 0, 4,  8, 20, 19,  31,  52,  67,  77,   93,  101,  116,   95,   92,   91,   63,   51, ...
  5: 0, 4, 12, 28, 45,  95, 143, 236, 272,  411,  479,  630,  664,  742,  757,  741,  706, ...
  6: 0, 2, 14, 58, 76, 204, 389, 660, 852, 1448, 1971, 2832, 3101, 4064, 4651, 5393, 5376, ...
etc.
		

Crossrefs

Row sums (except for the first term) give A006879. The indices k are given by A001651 (beginning with 2).

Programs

  • Mathematica
    dir[n_] := Floor[(3 n + 2)/2]; inv[n_] := Floor[(2 n - 1)/3]; f[n_] := Block[{p = NextPrime[10^(n - 1)], t = Table[0, {inv[9 n]}]}, While[p < 10^n, t[[ inv[Plus @@ IntegerDigits@ p]]]++; p = NextPrime@ p]; t]; Array[f, 5] // Flatten
Showing 1-3 of 3 results.