// output of ./demo/comb/composition-nz-first-max-demo.cc: // Description: //% Compositions of n into positive parts where no part is greater than the first. //% Lexicographic order. //% See OEIS sequencs A079500 and A007059. arg 1: 8 == n [compositions of n] default=8 arg 2: 0 == tq [Whether to print level sequences for corresponding (balanced) trees] default=0 0: [ 1 1 1 1 1 1 1 1 ] 1: [ 2 1 1 1 1 1 1 ] 2: [ 2 1 1 1 1 2 ] 3: [ 2 1 1 1 2 1 ] 4: [ 2 1 1 2 1 1 ] 5: [ 2 1 1 2 2 ] 6: [ 2 1 2 1 1 1 ] 7: [ 2 1 2 1 2 ] 8: [ 2 1 2 2 1 ] 9: [ 2 2 1 1 1 1 ] 10: [ 2 2 1 1 2 ] 11: [ 2 2 1 2 1 ] 12: [ 2 2 2 1 1 ] 13: [ 2 2 2 2 ] 14: [ 3 1 1 1 1 1 ] 15: [ 3 1 1 1 2 ] 16: [ 3 1 1 2 1 ] 17: [ 3 1 1 3 ] 18: [ 3 1 2 1 1 ] 19: [ 3 1 2 2 ] 20: [ 3 1 3 1 ] 21: [ 3 2 1 1 1 ] 22: [ 3 2 1 2 ] 23: [ 3 2 2 1 ] 24: [ 3 2 3 ] 25: [ 3 3 1 1 ] 26: [ 3 3 2 ] 27: [ 4 1 1 1 1 ] 28: [ 4 1 1 2 ] 29: [ 4 1 2 1 ] 30: [ 4 1 3 ] 31: [ 4 2 1 1 ] 32: [ 4 2 2 ] 33: [ 4 3 1 ] 34: [ 4 4 ] 35: [ 5 1 1 1 ] 36: [ 5 1 2 ] 37: [ 5 2 1 ] 38: [ 5 3 ] 39: [ 6 1 1 ] 40: [ 6 2 ] 41: [ 7 1 ] 42: [ 8 ] ct=43