login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A155031 Triangle T(n, k) = 0 if n==0 (mod k) otherwise -1 with T(n, n) = 1 and T(n, 0) = 0, read by rows. 3

%I

%S 1,0,1,0,-1,1,0,0,-1,1,0,-1,-1,-1,1,0,0,0,-1,-1,1,0,-1,-1,-1,-1,-1,1,

%T 0,0,-1,0,-1,-1,-1,1,0,-1,0,-1,-1,-1,-1,-1,1,0,0,-1,-1,0,-1,-1,-1,-1,

%U 1,0,-1,-1,-1,-1,-1,-1,-1,-1,-1,1,0,0,0,0,-1,0,-1,-1,-1,-1,-1,1,0,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,1

%N Triangle T(n, k) = 0 if n==0 (mod k) otherwise -1 with T(n, n) = 1 and T(n, 0) = 0, read by rows.

%H G. C. Greubel, <a href="/A155031/b155031.txt">Rows n = 1..30 of the triangle, flattened</a>

%F T(n, k) = A154990(n, k) * A155029(n, k).

%F T(n, k) = 0 if n==0 (mod k) otherwise -1 with T(n, n) = 1 and T(n, 0) = 0.

%e Table begins:

%e 1;

%e 0, 1;

%e 0, -1, 1;

%e 0, 0, -1, 1;

%e 0, -1, -1, -1, 1;

%e 0, 0, 0, -1, -1, 1;

%e 0, -1, -1, -1, -1, -1, 1;

%e 0, 0, -1, 0, -1, -1, -1, 1;

%e 0, -1, 0, -1, -1, -1, -1, -1, 1;

%t T[n_, k_]:= If[k==n, 1, If[k==1 || Mod[n, k]==0, 0, -1]];

%t Table[T[n, k], {n, 12}, {k, n}] //Flatten (* _G. C. Greubel_, Mar 08 2021 *)

%o (Sage) flatten([[1 if k==n else 0 if (k==1 or n%k==0) else -1 for k in [1..n]] for n in [1..12]]) # _G. C. Greubel_, Mar 08 2021

%o (Magma) [k eq n select 1 else (k eq 1 or n mod k eq 0) select 0 else -1: k in [1..n], n in [1..12]]; // _G. C. Greubel_, Mar 08 2021

%Y Cf. A154990, A155029.

%K sign,tabl

%O 1,1

%A _Mats Granvik_, Jan 19 2009

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 17 05:36 EDT 2021. Contains 343059 sequences. (Running on oeis4.)