Inversions in sequences: Difference between revisions
imported>Watchduck |
(No difference)
|
Latest revision as of 20:59, 12 October 2024
| Inversion (discrete mathematics) Template:Rdrup |
This page shows the 44 = 256 sequences of length 4 with possible entries from 0...3. These are the integers 0...255 in base 4.
It shows their place-based and element based inversion sets, and all four possible vectors related to them.
Template:Invvect and Template:Invvect are the left and right inversion counts, and Template:Invvect is the inversion vector. The fourth possible vector is unused, but added as Template:Invvect for completeness' sake.
While inversion sets and the related vectors uniquely define permutations, this is not true for sequences in general.
The place-based inversion sets are the same as those of permutations.
There are 35 sequences with the inversion set of permutation , while that of is unique.
The inversion sets of the permutations , , , , , , , , , and appear 15 times each, while those of , , , , , , , , , and appear 5 times each.
The element-based inversion sets are multisets, as different pairs of places can have the same pair of elements.
There are 103 different multisets, corresponding to 40 different inversion vectors Template:Invvect.
So there are 40 − 24 = 16 inversion vectors that permutations can not have — e.g. (4, 0, 0, 0), (0, 3, 0, 0) and (0, 0, 2, 0).
Permutations
| 24 permutations of 0 1 2 3 |
|---|
|
This list is like the one in the inversion article, but more detailed. Srev colex = Template:Invvectcolex
Slex = Template:Invvectlex This table also allows to sort by the inversion sets. The column to the left of the images brings them in lex order, the right one in colex order. The unlabelled columns on the right bring the permutations in the orders generated by Heap's and Steinhaus–Johnson–Trotter algorithm. |
| 12 permutations of 0 0 1 3 |
|---|
|
These are essentially the the 12 permutations of 1 1 2 4 Narayana has listed in reverse colex order in Ganita Kaumudi, as mentioned by Knuth in volume 4 of TAoCP. Template:Cite book — The work of Narayana (p. 62) Singh, Parmanand (1998): "The Ganita Kaumudi of Narayana Pandita" — Expansion (i.e., Serial Arrangement of Permutations) (p. 47) |
| 6 permutations of 0 0 1 1 |
|---|
|
|
Place based inversion sets
| 15 sequences with inversion set 1 |
|---|
|
These 15 sequences have the place-based inversion set of permutation in common, i.e. or |
| 5 sequences with inversion set 5 |
|---|
|
These 5 sequences have the place-based inversion set of permutation in common, i.e. or |


