A158086 Number of occurrences of n as an entry in rows <= 2n of Losanitsch's triangle (A034851).
4, 4, 5, 4, 6, 4, 4, 6, 5, 4, 6, 4, 4, 4, 6, 4, 4, 6, 6, 4, 4, 4, 4, 6, 4, 4, 6, 4, 6, 4, 4, 4, 4, 4, 6, 4, 5, 4, 4, 4, 6, 4, 6, 4, 4, 4, 4, 6, 4
Offset: 2
Examples
a(4) = 5 because 4 occurs five times in Losanitsch's triangle: the first time at row 4, column 2, being the sum of the two 2's in the row above; and at column 1 of rows 7 and 8, which are symmetrically duplicated at row 7, column 6 and row 8, column 7.
Crossrefs
Cf. A003016, Number of occurrences of n as an entry in rows <= n of Pascal's triangle.
Programs
-
Mathematica
(* The following assumes a[n, k] has already been defined to give Losanitsch's triangle; see for example the program given for A153046 *) tallyLozOccs[1] := Infinity; tallyLozOccs[n_Integer?Positive] := Module[{i, searchMax, tally}, i = 0; searchMax = 2n; tally = 0; While[i <= searchMax, tally = tally + Length[Select[Table[a[i, m], {m, 0, i}], # == n &]]; i++ ]; Return[tally]]; Table[tallyLozOccs[n], {n, 2, 50}] (* this program also assumes a(n,k) has been defined for Losanitsch's triangle*) Table[Length[Select[Flatten[Table[a[i,m], {i,0,2n}, {m,0,i}]],#==n&]], {n,2,50}] (* Wilfredo Lopez (chakotay147138274(AT)yahoo.com), Mar 18 2009 *)
Comments