A127093 Triangle read by rows: T(n,k)=k if k is a divisor of n; otherwise, T(n,k)=0 (1 <= k <= n).
1, 1, 2, 1, 0, 3, 1, 2, 0, 4, 1, 0, 0, 0, 5, 1, 2, 3, 0, 0, 6, 1, 0, 0, 0, 0, 0, 7, 1, 2, 0, 4, 0, 0, 0, 8, 1, 0, 3, 0, 0, 0, 0, 0, 9, 1, 2, 0, 0, 5, 0, 0, 0, 0, 10, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 1, 2, 3, 4, 0, 6, 0, 0, 0, 0, 0, 12, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 1, 2, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 14
Offset: 1
Examples
T(8,4) = 4 since 4 divides 8. T(9,3) = 3 since 3 divides 9. First few rows of the triangle: 1; 1, 2; 1, 0, 3; 1, 2, 0, 4; 1, 0, 0, 0, 5; 1, 2, 3, 0, 0, 6; 1, 0, 0, 0, 0, 0, 7; 1, 2, 0, 4, 0, 0, 0, 8; 1, 0, 3, 0, 0, 0, 0, 0, 9; ...
References
- David Wells, "Prime Numbers, the Most Mysterious Figures in Math", John Wiley & Sons, 2005, appendix.
- L. Euler, "Discovery of a Most Extraordinary Law of the Numbers Concerning the Sum of Their Divisors"; pp. 358-367 of Robert M. Young, "Excursions in Calculus, An Interplay of the Continuous and the Discrete", MAA, 1992. See p. 366.
Links
- Reinhard Zumkeller, Rows n = 1..100 of triangle, flattened
- Grant Sanderson, Pi hiding in prime regularities
- Leonhard Euler, Découverte d'une loi tout extraordinaire des nombres par rapport à la somme de leurs diviseurs, 1747, The Euler Archive, (Eneström Index) E175.
- Leonhard Euler, Observatio de summis divisorum
- Eric Weisstein's World of Mathematics, Divisor
Crossrefs
Reversal = A127094
Cf. A127094, A123229, A127096, A127097, A127098, A127099, A000203, A126988, A127013, A127057, A038040, A024916, A060640, A001001.
Cf. A027750.
Programs
-
Excel
mod(row()-1;column()) - mod(row();column()) + 1 - Mats Granvik, Aug 31 2007
-
Haskell
a127093 n k = a127093_row n !! (k-1) a127093_row n = zipWith (*) [1..n] $ map ((0 ^) . (mod n)) [1..n] a127093_tabl = map a127093_row [1..] -- Reinhard Zumkeller, Jan 15 2011
-
Maple
A127093:=proc(n,k) if type(n/k, integer)=true then k else 0 fi end: for n from 1 to 16 do seq(A127093(n,k),k=1..n) od; # yields sequence in triangular form - Emeric Deutsch, Jan 20 2007
-
Mathematica
t[n_, k_] := k*Boole[Divisible[n, k]]; Table[t[n, k], {n, 1, 14}, {k, 1, n}] // Flatten (* Jean-François Alcover, Jan 17 2014 *) Table[ SeriesCoefficient[k*x^k/(1 - x^k), {x, 0, n}], {n, 1, 14}, {k, 1, n}] // Flatten (* Jean-François Alcover, Apr 14 2015 *)
-
PARI
trianglerows(n) = for(x=1, n, for(k=1, x, if(x%k==0, print1(k, ", "), print1("0, "))); print("")) /* Print initial 9 rows of triangle as follows: */ trianglerows(9) \\ Felix Fröhlich, Mar 26 2019
Formula
k-th column is composed of "k" interspersed with (k-1) zeros.
Let M = A127093 as an infinite lower triangular matrix and V = the harmonic series as a vector: [1/1, 1/2, 1/3, ...]. then M*V = d(n), A000005: [1, 2, 2, 3, 2, 4, 2, 4, 3, 4, ...]. M^2 * V = A060640: [1, 5, 7, 17, 11, 35, 15, 49, 34, 55, ...]. - Gary W. Adamson, May 10 2007
T(n,k) = ((n-1) mod k) - (n mod k) + 1 (1 <= k <= n). - Mats Granvik, Aug 31 2007
T(n,k) = k * 0^(n mod k). - Reinhard Zumkeller, Jan 15 2011
G.f.: Sum_{k>=1} k * x^k * y^k/(1-x^k) = Sum_{m>=1} x^m * y/(1 - x^m*y)^2. - Robert Israel, Aug 08 2016
T(n,k) = Sum_{d|k} mu(k/d)*sigma(gcd(n,d)). - Ridouane Oudra, Apr 05 2025
Comments