login
Elements in A126988 (by row) that are not 1.
2

%I #7 Jan 28 2023 12:34:35

%S 0,2,0,3,0,0,4,2,0,0,5,0,0,0,0,6,3,2,0,0,0,7,0,0,0,0,0,0,8,4,0,2,0,0,

%T 0,0,9,0,3,0,0,0,0,0,0,10,5,0,0,2,0,0,0,0,0,11,0,0,0,0,0,0,0,0,0,0,12,

%U 6,4,3,0,2,0,0,0,0,0,0,13,0,0,0,0,0,0,0,0,0,0,0,0,14,7,0,0,0,0,2,0,0,0,0,0,0,0

%N Elements in A126988 (by row) that are not 1.

%C GCD of rows is A014963.

%H G. C. Greubel, <a href="/A167990/b167990.txt">Rows n = 1..50 of the triangle, flattened</a>

%F From _G. C. Greubel_, Jan 13 2023: (Start)

%F T(n, k) = 0 if k = n or (n mod k) != 0, otherwise T(n, k) = n/k.

%F T(n, 1) = n - [n=1].

%F T(m*n, n) = m, m >= 2.

%F Sum_{k=1..n} T(n, k) = A039653(n). (End)

%e Table begins:

%e 0;

%e 2, 0;

%e 3, 0, 0;

%e 4, 2, 0, 0;

%e 5, 0, 0, 0, 0;

%e 6, 3, 2, 0, 0, 0;

%e 7, 0, 0, 0, 0, 0, 0;

%e 8, 4, 0, 2, 0, 0, 0, 0;

%e 9, 0, 3, 0, 0, 0, 0, 0, 0;

%e 10, 5, 0, 0, 2, 0, 0, 0, 0, 0;

%e 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0;

%e 12, 6, 4, 3, 0, 2, 0, 0, 0, 0, 0, 0;

%t Table[If[k==n || Mod[n, k]!=0, 0, n/k], {n,15}, {k,n}]//Flatten (* _G. C. Greubel_, Jan 13 2023 *)

%o (Magma) [k eq n or (n mod k) ne 0 select 0 else n/k: k in [1..n], n in [1..15]]; // _G. C. Greubel_, Jan 13 2023

%o (SageMath)

%o def A167990(n, k):

%o if (k==n or n%k!=0): return 0

%o else: return n/k

%o flatten([[A167990(n, k) for k in (1..n)] for n in (1..12)]) # _G. C. Greubel_, Jan 13 2023

%Y Cf. A014963, A039653, A126988.

%K nonn,tabl

%O 1,2

%A _Mats Granvik_, Nov 16 2009