A226441 T(n,k) = number of permutations of {1..n} with fewer than k interior elements having values lying between the values of their neighbors.
1, 1, 2, 1, 2, 4, 1, 2, 6, 10, 1, 2, 6, 22, 32, 1, 2, 6, 24, 90, 122, 1, 2, 6, 24, 118, 422, 544, 1, 2, 6, 24, 120, 658, 2226, 2770, 1, 2, 6, 24, 120, 718, 4078, 13102, 15872, 1, 2, 6, 24, 120, 720, 4914, 27724, 85170, 101042, 1, 2, 6, 24, 120, 720, 5038, 37300, 205134, 606542, 707584
Offset: 1
Examples
Some solutions for n=8 k=4 ..5....8....1....7....5....5....8....4....7....5....3....4....7....6....5....1 ..8....1....7....3....1....4....1....7....2....4....5....2....2....5....3....2 ..6....5....2....6....3....8....7....5....1....3....7....1....5....4....7....7 ..7....6....6....8....6....6....6....1....5....8....2....7....1....7....6....4 ..3....7....3....2....7....3....3....3....6....1....6....5....8....1....1....3 ..4....3....8....1....4....7....2....8....4....7....4....8....3....8....2....6 ..1....4....5....5....8....2....5....6....3....6....1....6....4....3....4....8 ..2....2....4....4....2....1....4....2....8....2....8....3....6....2....8....5
Links
- R. H. Hardin, Table of n, a(n) for n = 1..9999
Comments