cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A061676 Triangle T(n,k) of number of ways of throwing k standard dice to produce a total of n.

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 3, 3, 1, 1, 4, 6, 4, 1, 1, 5, 10, 10, 5, 1, 0, 6, 15, 20, 15, 6, 1, 0, 5, 21, 35, 35, 21, 7, 1, 0, 4, 25, 56, 70, 56, 28, 8, 1, 0, 3, 27, 80, 126, 126, 84, 36, 9, 1, 0, 2, 27, 104, 205, 252, 210, 120, 45, 10, 1, 0, 1, 25, 125, 305, 456, 462, 330, 165, 55, 11, 1
Offset: 1

Views

Author

Henry Bottomley, Apr 01 2002

Keywords

Examples

			Rows start:
1;
1,1;
1,2,1;
1,3,3,1;
1,4,6,4,1;
1,5,10,10,5,1;
0,6,15,20,15,6,1;
0,5,21,35,35,21,7,1;
etc.
T(8,2)=5 since 8 =2+6 =3+5 =4+4 =5+3 =6+2.
		

Crossrefs

First 21 terms as A007318 (see formula). Cf. A001592, A069713.
Cf. A030528 (2-sided dice), A078803 (3-sided), A213887 (4-sided), A213888 (5-sided).

Programs

  • Maple
    pts := 6; # A213889 and A061676
    g := 1/(1-t*z*add(z^i,i=0..pts-1)) ;
    for n from 1 to 13 do
        for k from 1 to n do
            coeftayl(g,z=0,n) ;
            coeftayl(%,t=0,k) ;
            printf("%d ",%) ;
        end do:
        printf("\n") ;
    end do: # R. J. Mathar, May 28 2025

Formula

T(n, k)=T(n-1, k-1)+T(n-2, k-1)+T(n-3, k-1)+T(n-4, k-1)+T(n-5, k-1)+T(n-6, k-1) starting with T(0, 0)=1. T(n, k)=T(7k-n, k); if n>6k or n6k-6, T(n, k)=C(7k-n-1, k-1); T([7k/2], k)=A018901(k).