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

A278716
Triangle read by rows: T(k, h) gives the denominators of the Dedekind sums s(h, k) with gcd(h, k) = 1 or 0 otherwise.
2
1, 18, 18, 8, 1, 8, 5, 1, 1, 5, 18, 1, 1, 1, 18, 14, 14, 14, 14, 14, 14, 16, 1, 16, 1, 16, 1, 16, 27, 27, 1, 27, 27, 1, 27, 27, 5, 1, 1, 1, 1, 1, 1, 1, 5, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 72, 1, 1, 1, 72, 1, 72, 1, 1, 1, 72, 13, 13, 13, 13, 1, 13, 13, 1, 13, 13, 13, 13
OFFSET
2,2
COMMENTS
For the numerators see A278715, also for references and details of the Dedekind sums s(h, k).
FORMULA
T(k ,h) = denominator(s(h,k)) with the Dedekind sums s(h,k) given in a comment on A278715 and gcd(h,k) = 1. k >= 2, h = 1, 2, ..., k-1. If gcd(h,k) > 1 then T(h, k) = 1 (from s(h,k) put to 0).
EXAMPLE
The triangle T(k, h) begins (here l is used if gcd(h, k) > 1 instead of 1):
k\h 1 2 3 4 5 6 7 8 9 10 11 12
2: 1
3: 18 18
4: 8 l 8
5: 5 1 1 5
6: 18 l l l 18
7: 14 14 14 14 14 14
8: 16 l 16 l 16 l 16
9: 27 27 l 27 27 l 27 27
10: 5 l 1 l l l 1 l 5
11: 22 22 22 22 22 22 22 22 22 22
12: 72 l l l 72 l 72 l l l 72
13: 13 13 13 13 1 13 13 1 13 13 13 13
...
n = 14: 14 l 14 l 14 l l l 14 l 14 l 14,
n = 15: 90 18 l 90 l l 18 18 l l 90 l 18 90.
...
MATHEMATICA
T[n_, k_]:= If[GCD[n, k] == 1, Sum[(j/n)*(k*j/n - Floor[k*j/n] - 1/2), {j, 1, n - 1}], 0]; Denominator[Table[T[n, k], {n, 2, 15}, {k, 1, n - 1}]]//Flatten (* G. C. Greubel, Nov 22 2018 *)
PROG
(PARI) {T(n, k) = if(gcd(n, k)==1, sum(j=1, n-1, (j/n)*(k*j/n - floor(k*j/n) - 1/2)), 0)};
for(n=2, 15, for(k=1, n-1, print1(denominator(T(n, k)), ", "))) \\ G. C. Greubel, Nov 22 2018
(Magma) [[GCD(n, k) eq 1 select Denominator((&+[(j/n)*(k*j/n - Floor(k*j/n) - 1/2): j in [1..(n-1)]])) else 0: k in [1..(n-1)]]: n in [2..10]]; // G. C. Greubel, Nov 22 2018
(Sage)
def T(n, k):
if gcd(n, k)==1:
return denominator(sum((j/n)*(k*j/n - floor(k*j/n) - 1/2) for j in (1..(n-1))))
elif gcd(n, k)!=1:
return 0
else:
0
[[T(n, k) for k in (1..n-1)] for n in (2..15)] # G. C. Greubel, Nov 22 2018
CROSSREFS
Cf. A278715.
Sequence in context: A070742 A304260 A176064 * A282814 A010857 A369860
KEYWORD
nonn,tabl,frac,easy
AUTHOR
Wolfdieter Lang, Nov 28 2016
STATUS
approved