A329534 Irregular triangle read by rows: for n >= 1 row n lists the k from [1, 2, ... , n] such that A002378(k-1) = (k-1)*k == 0 (mod n).
1, 1, 2, 1, 3, 1, 4, 1, 5, 1, 3, 4, 6, 1, 7, 1, 8, 1, 9, 1, 5, 6, 10, 1, 11, 1, 4, 9, 12, 1, 13, 1, 7, 8, 14, 1, 6, 10, 15, 1, 16, 1, 17, 1, 9, 10, 18, 1, 19, 1, 5, 16, 20, 1, 7, 15, 21, 1, 11, 12, 22, 1, 23, 1, 9, 16, 24, 1, 25
Offset: 1
Examples
The irregular triangle T(n,k) begins n\k 1 2 3 4 ... 1: 1 2: 1 2 3: 1 3 4: 1 4 5: 1 5 6: 1 3 4 6 7: 1 7 8: 1 8 9: 1 9 10: 1 5 6 10 11: 1 11 12: 1 4 9 12 13: 1 13 14: 1 7 8 14 15: 1 6 10 15 16: 1 16 17: 1 17 18: 1 9 10 18 19: 1 19 20: 1 5 16 20 ...
References
- Tom M. Apostol, Introduction to Analytic Number Theory, Springer-Verlag, 1986.
Crossrefs
Programs
-
Magma
[[k: k in [1..n] | k^2 mod n eq k]: n in [1..38]];
-
Mathematica
Table[Select[Range@ n, Mod[-n + # (# - 1), n] == 0 &], {n, 25}] // Flatten (* Michael De Vlieger, Nov 18 2019 *)
-
PARI
row(n) = select(x->(Mod(x, n) == Mod(x, n)^2), [1..n]); \\ Michel Marcus, Nov 19 2019
Extensions
Edited by Wolfdieter Lang, Feb 05 2020
Comments