login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Number of primes of the form k*n + k - n, 1 <= k <= n.
10

%I #19 Jan 26 2022 14:20:43

%S 0,0,1,1,3,1,2,2,5,3,6,3,5,4,4,3,9,2,6,5,8,4,9,4,9,7,10,4,17,3,10,9,

%T 11,9,15,4,9,10,13,5,20,7,11,10,16,8,19,6,18,12,17,5,23,9,18,9,15,8,

%U 26,7,15,12,16,13,29,8,18,13,26,9,25,10,19,18,16

%N Number of primes of the form k*n + k - n, 1 <= k <= n.

%C Number of primes in n-th row of the triangle in A209297.

%C Number of primes along the main diagonal of an n X n square array whose elements are the numbers from 1..n^2, listed in increasing order by rows (see square arrays in example). - _Wesley Ivan Hurt_, May 15 2021

%H Reinhard Zumkeller, <a href="/A221490/b221490.txt">Table of n, a(n) for n = 1..1000</a>

%F a(n) = Sum_{k=1..n} A010051(A209297(n,k)).

%F a(n) = Sum_{k=1..n} c(n*(k-1)+k), where c is the prime characteristic. - _Wesley Ivan Hurt_, May 15 2021

%e Row 10 of A209297 = [1,12,23,34,45,56,67,78,89,100] containing three primes: [23,67,89], therefore a(10) = 3;

%e row 11 of A209297 = [1,13,25,37,49,61,73,85,97,109,121] containing six primes: [13,37,61,73,97,109], therefore a(11) = 6.

%e From _Wesley Ivan Hurt_, May 15 2021: (Start)

%e [1 2 3 4 5]

%e [1 2 3 4] [6 7 8 9 10]

%e [1 2 3] [5 6 7 8] [11 12 13 14 15]

%e [1 2] [4 5 6] [9 10 11 12] [16 17 18 19 20]

%e [1] [3 4] [7 8 9] [13 14 15 16] [21 22 23 24 25]

%e ------------------------------------------------------------------------

%e n 1 2 3 4 5

%e ------------------------------------------------------------------------

%e a(n) 0 0 1 1 3

%e ------------------------------------------------------------------------

%e (End)

%t Count[#,_?PrimeQ]&/@Table[k*n+k-n,{n,75},{k,n}] (* _Harvey P. Dale_, Apr 03 2015 *)

%o (Haskell)

%o a221490 n = sum [a010051 (k*n + k - n) | k <- [1..n]]

%o (PARI) a(n) = sum(k=1, n, isprime(k*n + k - n)); \\ _Michel Marcus_, Jan 26 2022

%Y Cf. A010051, A209297, A221491, A344316, A344349.

%K nonn

%O 1,5

%A _Reinhard Zumkeller_, Jan 19 2013