You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A follow-up: this may be an issue of different definitions? When I said "incorrect output" above, the definition I was using is that a permutation avoids a pattern if, in matrix notation, the permutation matrix doesn't contain the pattern's permutation matrix as a submatrix (or equivalently, that the "relative order" of the pattern never appears in the permutation).
But upon more experimenting, it seems that this code is checking for what I would think of as avoiding the inverse of the pattern? If that's intentional, then I'd like to just change my request to be a documentation clarification---the current sample pattern to avoid is it's own inverse! Could an additional sample be added where this difference in definition will be more immediately noticeable? E.g., that by this definition, 312-avoiding means that we never have i < j < k with w_k < w_i < w_j (instead of the "relative order" definition where it would mean never having w_j < w_k < w_i)
The function
isPatternAvoiding
(and the relatedavoidsAllPatterns
) from theMatrixSchubert
package sometimes gives the incorrect output. For example:Of course, sometimes it is also correct!
The text was updated successfully, but these errors were encountered: