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”).

A177226
Triangle read by rows: T(n, k) = 2^(prime(n) - prime(k)) mod prime(n), 1 <= k <= n.
8
1, 2, 1, 3, 4, 1, 4, 2, 4, 1, 6, 3, 9, 5, 1, 7, 10, 9, 12, 4, 1, 9, 13, 16, 4, 13, 16, 1, 10, 5, 6, 11, 9, 7, 4, 1, 12, 6, 13, 9, 2, 12, 18, 16, 1, 15, 22, 20, 5, 13, 25, 7, 9, 6, 1, 16, 8, 2, 16, 1, 8, 16, 4, 8, 4, 1, 19, 28, 7, 11, 3, 10, 33, 36, 30, 34, 27, 1, 21, 31, 18, 25, 40, 10, 16, 4, 31, 37, 40, 16, 1
OFFSET
1,2
FORMULA
From G. C. Greubel, Apr 09 2024: (Start)
T(n, 1) = A111333(n).
T(n, 2) = A292411(n). (End)
EXAMPLE
Triangle begins:
1;
2, 1;
3, 4, 1;
4, 2, 4, 1;
6, 3, 9, 5, 1;
7, 10, 9, 12, 4, 1;
9, 13, 16, 4, 13, 16, 1;
10, 5, 6, 11, 9, 7, 4, 1;
12, 6, 13, 9, 2, 12, 18, 16, 1;
MATHEMATICA
Flatten[Table[PowerMod[2, Prime[n]-Prime[k], Prime[n]], {n, 20}, {k, n}]] (* Harvey P. Dale, May 10 2014 *)
PROG
(Magma)
A177226:= func< n, k | Modexp(2, NthPrime(n) - NthPrime(k), NthPrime(n)) >;
[A177226(n, k): k in [1..n], n in [1..12]]; // G. C. Greubel, Apr 09 2024
(SageMath)
def A177226(n, k): return pow(2, nth_prime(n) - nth_prime(k), nth_prime(n))
flatten([[A177226(n, k) for k in range(1, n+1)] for n in range(1, 13)]) # G. C. Greubel, Apr 09 2024
KEYWORD
nonn,tabl
AUTHOR
EXTENSIONS
Corrected by D. S. McNeil, Dec 10 2010
STATUS
approved