A077049 Left summatory matrix, T, by antidiagonals upwards.
1, 1, 0, 1, 1, 0, 1, 0, 0, 0, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 1, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0
Offset: 1
Examples
T(4,2) = 1 since 2 divides 4. Northwest corner: 1 0 0 0 0 0 1 1 0 0 0 0 1 0 1 0 0 0 1 1 0 1 0 0 1 0 0 0 1 0 1 1 1 0 0 1 From _Gary W. Adamson_, Apr 28 2010: (Start) First few rows of the triangle (when T is read by antidiagonals upwards): 1; 1, 0; 1, 1, 0; 1, 0, 0, 0; 1, 1, 1, 0, 0; 1, 0, 0, 0, 0, 0; 1, 1, 0, 1, 0, 0, 0; 1, 0, 1, 0, 0, 0, 0, 0; 1, 1, 0, 0, 1, 0, 0, 0, 0; ... (End)
Links
- Michael De Vlieger, Table of n, a(n) for n = 1..11325 (Rows 1 <= n <= 150).
- Clark Kimberling, Matrix Transformations of Integer Sequences, J. Integer Seqs., Vol. 6, 2003.
Crossrefs
Programs
-
Maple
A077049 := proc(n,k) if modp(n,k) = 0 then 1; else 0 ; end if; end proc: for d from 2 to 10 do for k from 1 to d-1 do n := d-k ; printf("%d,",A077049(n,k)) ; end do: end do: # R. J. Mathar, Jul 22 2017
-
Mathematica
With[{nn = 14}, DeleteCases[#, -1] & /@ Transpose@ Table[Take[#, nn] &@ Flatten@ Join[ConstantArray[-1, k - 1], ConstantArray[Reverse@ IntegerDigits[2^(k - 1), 2], Ceiling[(nn - k + 1)/k]]], {k, nn}]] // Flatten (* Michael De Vlieger, Jul 22 2017 *)
-
PARI
nn=10; matrix(nn, nn, n, k, if (n % k, 0, 1)) \\ Michel Marcus, May 21 2015
-
Python
def T(n, k): return 1 if n%k==0 else 0 for n in range(1, 11): print([T(n - k + 1, k) for k in range(1, n + 1)]) # Indranil Ghosh, Jul 22 2017
Formula
T(n,k)=1 if k|n, otherwise T(n,k)=0, k >= 1, n >= 1.
From Boris Putievskiy, May 08 2013: (Start)
As table T(n,k) = floor(k/n) - floor((k-1)/n).
Extensions
Name edited by Petros Hadjicostas, Jul 27 2019
Comments