This site is supported by donations to The OEIS Foundation.

Thanks to everyone who made a donation during our annual appeal!
To see the list of donors, or make a donation, see the OEIS Foundation home page.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A213126 Rows of triangle formed using Pascal's rule, except sums in the n-th row are modulo n: T(n,0) = T(n,n) = 1 and T(n,k) = (T(n-1,k-1) + T(n-1,k)) mod n. 1
 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 2, 2, 2, 1, 1, 3, 4, 4, 3, 1, 1, 4, 1, 2, 1, 4, 1, 1, 5, 5, 3, 3, 5, 5, 1, 1, 6, 2, 0, 6, 0, 2, 6, 1, 1, 7, 8, 2, 6, 6, 2, 8, 7, 1, 1, 8, 5, 0, 8, 2, 8, 0, 5, 8, 1, 1, 9, 2, 5, 8, 10, 10, 8, 5, 2, 9, 1, 1, 10, 11, 7, 1, 6, 8, 6 (list; table; graph; refs; listen; history; text; internal format)
 OFFSET 0,12 LINKS EXAMPLE 1 1 1 1 0 1 1 1 1 1 1 2 2 2 1 1 3 4 4 3 1 1 4 1 2 1 4 1 1 5 5 3 3 5 5 1 1 6 2 0 6 0 2 6 1 1 7 8 2 6 6 2 8 7 1 1 8 5 0 8 2 8 0 5 8 1 1 9 2 5 8 10 10 8 5 2 9 1 MATHEMATICA T[n_, k_]:=If[k==0 || k==n, 1, Mod[T[n - 1, k - 1] + T[n- 1, k], n]]; Table[T[n, k], {n, 0, 15}, {k, 0, n}] // Flatten (* Indranil Ghosh, Apr 29 2017 *) PROG (Python) src = [0]*1024 dst = [0]*1024 for n in range(0, 19): .    dst[0] = dst[n] = 1 .    for k in range(1, n): .    .    dst[k] = (src[k-1]+src[k]) % n .    for k in range(0, n+1): .    .    src[k] = dst[k] .    .    print dst[k], CROSSREFS Cf. A007318 - Pascal's triangle read by rows. Cf. A047999, A083093, A034931, A034930, A034932, A008975. Sequence in context: A076545 A162246 A277447 * A118400 A159853 A087698 Adjacent sequences:  A213123 A213124 A213125 * A213127 A213128 A213129 KEYWORD nonn,tabl AUTHOR Alex Ratushnyak, Jun 06 2012 EXTENSIONS Offset corrected by Joerg Arndt, Dec 05 2016 STATUS approved

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.

Last modified January 18 13:50 EST 2019. Contains 319271 sequences. (Running on oeis4.)