3
Pattern-matching with don ’ t care symbols Σ* = Σ Σ* = Σ  {*} a≈b if a=b or a=* or b=* a≈b if a=b or a=* or b=* Two strings u, w with |u|=|w|, u≈w iff u[i]≈w[i] for all I Two strings u, w with |u|=|w|, u≈w iff u[i]≈w[i] for all I Find all positions j such that P≈T[i…j+m-1] Find all positions j such that P≈T[i…j+m-1] T * * P *

4
Lemma 1. The problem of pattern- matching with don ’ t cares for a pattern P and a text T of length n over an alphabet Σ can be solved in time O(log|Σ| * IntMult(n)) Lemma 1. The problem of pattern- matching with don ’ t cares for a pattern P and a text T of length n over an alphabet Σ can be solved in time O(log|Σ| * IntMult(n))

5
Relation between δ -matching and pattern matching with don ’ t cares For small alphabet δ-matching is at least as difficult as matching with don’t cares For small alphabet δ-matching is at least as difficult as matching with don’t cares Theorem 2. String matching with don’t cares for binary alphabets {a, b} is reducible to δ-matching for the alphabet Σ={1, 2, 3} Theorem 2. String matching with don’t cares for binary alphabets {a, b} is reducible to δ-matching for the alphabet Σ={1, 2, 3} a b a b * a b c *?? *??

8
δ-regular family H is a H is a δ- regular family iff it satisfies P1 : each morphism is a form h=**…*11…1**…*22…2**…*33…**.. The internal blocks of *’s are exactly of length δ, the boundary blocks of *’s are of length at most δ P2 : For p, q  Σsuch that q – p > δ there exists h  H such that h(p)=i, h(q)=j > i, and h(r)=* for some p < r

10
δ=3 Theorem 4. The size of minimal δ-distinguising family of morphisms is at most 2δ+1:α(δ)≤2δ+1 Theorem 4. The size of minimal δ-distinguising family of morphisms is at most 2δ+1:α(δ)≤2δ+1 # * in each column is at most δ # * in each column is at most δ if p-q>δ then for every i there is a symbol between p, q in h i if p-q>δ then for every i there is a symbol between p, q in h i

11
Lemma 5. The size of a minimal 3- distinguishing family of morphisms is at most 6:α(3)≤6 Lemma 5. The size of a minimal 3- distinguishing family of morphisms is at most 6:α(3)≤6 F={{1,2,3},{1,2,4},{1,3,5},{1,4,6},{2,3,4},{2,3,6},{2,4,5},{2,5,6},{3,4,5},{3,4,6}} F={{1,2,3},{1,2,4},{1,3,5},{1,4,6},{2,3,4},{2,3,6},{2,4,5},{2,5,6},{3,4,5},{3,4,6}}

12
Special case Theorem 6. If k is divisible by 3, then α( δ)≤ 2δ Theorem 6. If k is divisible by 3, then α( δ)≤ 2δ α(r *δ)≤ r *α(δ) α(r *δ)≤ r *α(δ) Expand h i to r times Expand h i to r times Cyclically shift by j, 1≤j

13
Lower bound Theorem 7. The size of a minimal δ- distinguishing family of morphisms is at least δ+2:α(δ) ≥δ+ 2 Theorem 7. The size of a minimal δ- distinguishing family of morphisms is at least δ+2:α(δ) ≥δ+ 2

14
Claim. If there is a δ-distinguishing family of size k, then there exists a δ-regular family of k morphisms Claim. If there is a δ-distinguishing family of size k, then there exists a δ-regular family of k morphisms