|
EXAMPLE
|
Triangle begins:
[1],
[1],
[1,1],
[2,1],
[2,2,1],
[3,2,2,1],
[4,3,3,2,1],
[5,4,4,3,3,1,1],
[7,5,5,5,4,3,3,1,1],
[9,7,7,7,5,5,5,4,3,1,1,1],
[12,9,9,9,8,7,7,7,5,4,4,4,1,1,1,1],
[16,12,12,12,12,9,9,9,8,8,8,7,5,4,4,4,1,1,1,1,1],
[21,16,16,16,16,13,12,12,12,12,12,11,9,8,8,8,5,5,5,5,4,1,1,1,1,1,1,1],
[28,21,21,21,21,20,16,16,16,16,16,16,13,13,12,12,12,12,11,11,8,6,5,5,5,5,5,5,1,1,1,1,1,1,1,1,1],
[37,28,28,28,28,28,22,21,21,21,21,21,20,20,20,20,18,16,16,16,14,13,12,12,12,12,12,11,6,6,6,6,6,5,5,5,5,1,1,1,1,1,1,1,1,1,1,1,1],
[49,37,37,37,37,37,33,28,28,28,28,28,28,28,28,28,27,22,22,21,21,21,20,20,20,20,20,18,17,17,16,16,14,12,12,12,12,7,6,6,6,6,6,6,6,6,6,6,5,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1],
...
ILLUSTRATION OF RECURRENCE.
Start out with row 0 and row 1 consisting of a single '1'.
To obtain any given row of this irregular triangle, first
sum the prior two rows term-by-term; for rows 7 and 8 we get:
[5,4,4,3,3,1,1] + [7,5,5,5,4,3,3,1,1] = [12,9,9,8,7,4,4,1,1].
Place markers in an array so that the number of contiguous markers
in each row correspond to the term-by-term sums like so:
--------------------------
12:o o o o o o o o o o o o
9: o o o o o o o o o - - -
9: o o o o o o o o o - - -
8: o o o o o o o o - - - -
7: o o o o o o o - - - - -
4: o o o o - - - - - - - -
4: o o o o - - - - - - - -
1: o - - - - - - - - - - -
1: o - - - - - - - - - - -
--------------------------
Then count the markers by columns to obtain the desired row;
here, the number of markers in each column yields row 9:
[9,7,7,7,5,5,5,4,3,1,1,1].
Continuing in this way generates all the rows of this triangle.
|