A lot of work has been done on patterns in permutations, where a permutation is said to match a given pattern if it contains a subsequence of elements ordered according to the pattern (e.g., $\pi=(2\ 1\ 7\ 5\ 3\ 6\ 4)$ matches $4\ 1\ 3\ 2$ -- consider the subsequence $7\ 3\ 6\ 4$).
One could be more restrictive and require that the subsequence of elements to be tested against the pattern not only follows the same order, but that the gaps between the elements (or between some, but not all, pairs of elements) is the same. In the above example, for instance, $7\ 3\ 6\ 4$ would no longer be a match for $4\ 1\ 3\ 2$ (but $6\ 3\ 5\ 4$ would, had it been a subsequence of $\pi$).
Has there been work on such constrained patterns? If so, what are they called, and what would be good references to check?
(I would have tagged this
pattern-matching, but I cannot create those tags)