MPE Home Metamath Proof Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >  cshwsexa Structured version   Visualization version   GIF version

Theorem cshwsexa 14518
Description: The class of (different!) words resulting by cyclically shifting something (not necessarily a word) is a set. (Contributed by AV, 8-Jun-2018.) (Revised by Mario Carneiro/AV, 25-Oct-2018.)
Assertion
Ref Expression
cshwsexa {𝑤 ∈ Word 𝑉 ∣ ∃𝑛 ∈ (0..^(♯‘𝑊))(𝑊 cyclShift 𝑛) = 𝑤} ∈ V
Distinct variable groups:   𝑛,𝑉   𝑛,𝑊,𝑤
Allowed substitution hint:   𝑉(𝑤)

Proof of Theorem cshwsexa
Dummy variable 𝑦 is distinct from all other variables.
StepHypRef Expression
1 df-rab 3074 . . 3 {𝑤 ∈ Word 𝑉 ∣ ∃𝑛 ∈ (0..^(♯‘𝑊))(𝑊 cyclShift 𝑛) = 𝑤} = {𝑤 ∣ (𝑤 ∈ Word 𝑉 ∧ ∃𝑛 ∈ (0..^(♯‘𝑊))(𝑊 cyclShift 𝑛) = 𝑤)}
2 r19.42v 3278 . . . . 5 (∃𝑛 ∈ (0..^(♯‘𝑊))(𝑤 ∈ Word 𝑉 ∧ (𝑊 cyclShift 𝑛) = 𝑤) ↔ (𝑤 ∈ Word 𝑉 ∧ ∃𝑛 ∈ (0..^(♯‘𝑊))(𝑊 cyclShift 𝑛) = 𝑤))
32bicomi 223 . . . 4 ((𝑤 ∈ Word 𝑉 ∧ ∃𝑛 ∈ (0..^(♯‘𝑊))(𝑊 cyclShift 𝑛) = 𝑤) ↔ ∃𝑛 ∈ (0..^(♯‘𝑊))(𝑤 ∈ Word 𝑉 ∧ (𝑊 cyclShift 𝑛) = 𝑤))
43abbii 2809 . . 3 {𝑤 ∣ (𝑤 ∈ Word 𝑉 ∧ ∃𝑛 ∈ (0..^(♯‘𝑊))(𝑊 cyclShift 𝑛) = 𝑤)} = {𝑤 ∣ ∃𝑛 ∈ (0..^(♯‘𝑊))(𝑤 ∈ Word 𝑉 ∧ (𝑊 cyclShift 𝑛) = 𝑤)}
5 df-rex 3071 . . . 4 (∃𝑛 ∈ (0..^(♯‘𝑊))(𝑤 ∈ Word 𝑉 ∧ (𝑊 cyclShift 𝑛) = 𝑤) ↔ ∃𝑛(𝑛 ∈ (0..^(♯‘𝑊)) ∧ (𝑤 ∈ Word 𝑉 ∧ (𝑊 cyclShift 𝑛) = 𝑤)))
65abbii 2809 . . 3 {𝑤 ∣ ∃𝑛 ∈ (0..^(♯‘𝑊))(𝑤 ∈ Word 𝑉 ∧ (𝑊 cyclShift 𝑛) = 𝑤)} = {𝑤 ∣ ∃𝑛(𝑛 ∈ (0..^(♯‘𝑊)) ∧ (𝑤 ∈ Word 𝑉 ∧ (𝑊 cyclShift 𝑛) = 𝑤))}
71, 4, 63eqtri 2771 . 2 {𝑤 ∈ Word 𝑉 ∣ ∃𝑛 ∈ (0..^(♯‘𝑊))(𝑊 cyclShift 𝑛) = 𝑤} = {𝑤 ∣ ∃𝑛(𝑛 ∈ (0..^(♯‘𝑊)) ∧ (𝑤 ∈ Word 𝑉 ∧ (𝑊 cyclShift 𝑛) = 𝑤))}
8 abid2 2883 . . . 4 {𝑛𝑛 ∈ (0..^(♯‘𝑊))} = (0..^(♯‘𝑊))
98ovexi 7302 . . 3 {𝑛𝑛 ∈ (0..^(♯‘𝑊))} ∈ V
10 tru 1545 . . . . 5
1110, 10pm3.2i 470 . . . 4 (⊤ ∧ ⊤)
12 ovexd 7303 . . . . . 6 (⊤ → (𝑊 cyclShift 𝑛) ∈ V)
13 eqtr3 2765 . . . . . . . . . . . . 13 ((𝑤 = (𝑊 cyclShift 𝑛) ∧ 𝑦 = (𝑊 cyclShift 𝑛)) → 𝑤 = 𝑦)
1413ex 412 . . . . . . . . . . . 12 (𝑤 = (𝑊 cyclShift 𝑛) → (𝑦 = (𝑊 cyclShift 𝑛) → 𝑤 = 𝑦))
1514eqcoms 2747 . . . . . . . . . . 11 ((𝑊 cyclShift 𝑛) = 𝑤 → (𝑦 = (𝑊 cyclShift 𝑛) → 𝑤 = 𝑦))
1615adantl 481 . . . . . . . . . 10 ((𝑤 ∈ Word 𝑉 ∧ (𝑊 cyclShift 𝑛) = 𝑤) → (𝑦 = (𝑊 cyclShift 𝑛) → 𝑤 = 𝑦))
1716com12 32 . . . . . . . . 9 (𝑦 = (𝑊 cyclShift 𝑛) → ((𝑤 ∈ Word 𝑉 ∧ (𝑊 cyclShift 𝑛) = 𝑤) → 𝑤 = 𝑦))
1817ad2antlr 723 . . . . . . . 8 (((⊤ ∧ 𝑦 = (𝑊 cyclShift 𝑛)) ∧ ⊤) → ((𝑤 ∈ Word 𝑉 ∧ (𝑊 cyclShift 𝑛) = 𝑤) → 𝑤 = 𝑦))
1918alrimiv 1933 . . . . . . 7 (((⊤ ∧ 𝑦 = (𝑊 cyclShift 𝑛)) ∧ ⊤) → ∀𝑤((𝑤 ∈ Word 𝑉 ∧ (𝑊 cyclShift 𝑛) = 𝑤) → 𝑤 = 𝑦))
2019ex 412 . . . . . 6 ((⊤ ∧ 𝑦 = (𝑊 cyclShift 𝑛)) → (⊤ → ∀𝑤((𝑤 ∈ Word 𝑉 ∧ (𝑊 cyclShift 𝑛) = 𝑤) → 𝑤 = 𝑦)))
2112, 20spcimedv 3532 . . . . 5 (⊤ → (⊤ → ∃𝑦𝑤((𝑤 ∈ Word 𝑉 ∧ (𝑊 cyclShift 𝑛) = 𝑤) → 𝑤 = 𝑦)))
2221imp 406 . . . 4 ((⊤ ∧ ⊤) → ∃𝑦𝑤((𝑤 ∈ Word 𝑉 ∧ (𝑊 cyclShift 𝑛) = 𝑤) → 𝑤 = 𝑦))
2311, 22mp1i 13 . . 3 (𝑛 ∈ (0..^(♯‘𝑊)) → ∃𝑦𝑤((𝑤 ∈ Word 𝑉 ∧ (𝑊 cyclShift 𝑛) = 𝑤) → 𝑤 = 𝑦))
249, 23zfrep4 5223 . 2 {𝑤 ∣ ∃𝑛(𝑛 ∈ (0..^(♯‘𝑊)) ∧ (𝑤 ∈ Word 𝑉 ∧ (𝑊 cyclShift 𝑛) = 𝑤))} ∈ V
257, 24eqeltri 2836 1 {𝑤 ∈ Word 𝑉 ∣ ∃𝑛 ∈ (0..^(♯‘𝑊))(𝑊 cyclShift 𝑛) = 𝑤} ∈ V
Colors of variables: wff setvar class
Syntax hints:  wi 4  wa 395  wal 1539   = wceq 1541  wtru 1542  wex 1785  wcel 2109  {cab 2716  wrex 3066  {crab 3069  Vcvv 3430  cfv 6430  (class class class)co 7268  0cc0 10855  ..^cfzo 13364  chash 14025  Word cword 14198   cyclShift ccsh 14482
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1801  ax-4 1815  ax-5 1916  ax-6 1974  ax-7 2014  ax-8 2111  ax-9 2119  ax-10 2140  ax-11 2157  ax-12 2174  ax-ext 2710  ax-rep 5213  ax-nul 5233
This theorem depends on definitions:  df-bi 206  df-an 396  df-or 844  df-tru 1544  df-fal 1554  df-ex 1786  df-nf 1790  df-sb 2071  df-mo 2541  df-eu 2570  df-clab 2717  df-cleq 2731  df-clel 2817  df-nfc 2890  df-ral 3070  df-rex 3071  df-rab 3074  df-v 3432  df-dif 3894  df-un 3896  df-in 3898  df-ss 3908  df-nul 4262  df-sn 4567  df-pr 4569  df-uni 4845  df-iota 6388  df-fv 6438  df-ov 7271
This theorem is referenced by: (None)
  Copyright terms: Public domain W3C validator