login
A277915
A(n,k) is the n-th number m such that a nontrivial prime(k)-th root of unity modulo m exists; square array A(n,k), n>=1, k>=1, read by antidiagonals.
6
8, 7, 12, 11, 9, 15, 29, 22, 13, 16, 23, 43, 25, 14, 20, 53, 46, 49, 31, 18, 21, 103, 79, 67, 58, 33, 19, 24, 191, 137, 106, 69, 71, 41, 21, 28, 47, 229, 206, 131, 89, 86, 44, 26, 30, 59, 94, 361, 239, 157, 92, 87, 50, 27, 32, 311, 118, 139, 382, 274, 158, 115, 98, 55, 28, 33
OFFSET
1,1
COMMENTS
The trivial square roots of unity modulo m are {1, m-1} and for an odd prime p the trivial p-th root of unity modulo m is 1.
There is no prime in the first column.
Column k>1 contains prime(k)^2.
EXAMPLE
Square array A(n,k) begins:
: 8, 7, 11, 29, 23, 53, 103, 191, ...
: 12, 9, 22, 43, 46, 79, 137, 229, ...
: 15, 13, 25, 49, 67, 106, 206, 361, ...
: 16, 14, 31, 58, 69, 131, 239, 382, ...
: 20, 18, 33, 71, 89, 157, 274, 419, ...
: 21, 19, 41, 86, 92, 158, 289, 457, ...
: 24, 21, 44, 87, 115, 159, 307, 458, ...
: 28, 26, 50, 98, 121, 169, 309, 571, ...
MAPLE
with(numtheory):
A:= proc() local j, l; l:= proc() [] end;
proc(n, k)
while nops(l(k))<n do
for j from 1+`if`(l(k)=[], 0, l(k)[-1]) do
if k=1 and phi(j)> lambda(j) or k>1 and
irem(phi(j), ithprime(k))=0 then
l(k):= [l(k)[], j]; break fi
od
od: l(k)[n]
end
end():
seq(seq(A(n, 1+d-n), n=1..d), d=1..15);
MATHEMATICA
A[n_, k_] := Module[{j, l = {}}, While[Length[l]<n, For[j = 1+If[l == {}, 0, l[[-1]]], True, j++, If[k==1 && EulerPhi[j]>CarmichaelLambda[j] || k>1 && Mod[EulerPhi[j], Prime[k]]==0, AppendTo[l, j]; Break[]]]]; l[[n]]];
Table[A[n, 1 + d - n], {d, 1, 15}, {n, 1, d}] // Flatten (* Jean-François Alcover, May 29 2018, from Maple *)
CROSSREFS
Columns k=1-4 give: A033949, A066498, A066500, A066502.
Row n=1 gives A066674 for k>1.
Main diagonal gives A305828.
Sequence in context: A212911 A019326 A286839 * A051011 A298666 A309628
KEYWORD
nonn,look,tabl
AUTHOR
Alois P. Heinz, Nov 03 2016
STATUS
approved