Metamath Proof Explorer


Theorem ccat2s1fvw

Description: Extract a symbol of a word from the concatenation of the word with two single symbols. (Contributed by AV, 22-Sep-2018) (Revised by AV, 13-Jan-2020) (Proof shortened by AV, 1-May-2020) (Revised by AV, 28-Jan-2024)

Ref Expression
Assertion ccat2s1fvw W Word V I 0 I < W W ++ ⟨“ X ”⟩ ++ ⟨“ Y ”⟩ I = W I

Proof

Step Hyp Ref Expression
1 ccatw2s1ass W Word V W ++ ⟨“ X ”⟩ ++ ⟨“ Y ”⟩ = W ++ ⟨“ X ”⟩ ++ ⟨“ Y ”⟩
2 1 3ad2ant1 W Word V I 0 I < W W ++ ⟨“ X ”⟩ ++ ⟨“ Y ”⟩ = W ++ ⟨“ X ”⟩ ++ ⟨“ Y ”⟩
3 2 fveq1d W Word V I 0 I < W W ++ ⟨“ X ”⟩ ++ ⟨“ Y ”⟩ I = W ++ ⟨“ X ”⟩ ++ ⟨“ Y ”⟩ I
4 simp1 W Word V I 0 I < W W Word V
5 s1cli ⟨“ X ”⟩ Word V
6 ccatws1clv ⟨“ X ”⟩ Word V ⟨“ X ”⟩ ++ ⟨“ Y ”⟩ Word V
7 5 6 mp1i W Word V I 0 I < W ⟨“ X ”⟩ ++ ⟨“ Y ”⟩ Word V
8 simp2 W Word V I 0 I < W I 0
9 lencl W Word V W 0
10 9 3ad2ant1 W Word V I 0 I < W W 0
11 nn0ge0 I 0 0 I
12 11 adantl W Word V I 0 0 I
13 0red W Word V I 0 0
14 nn0re I 0 I
15 14 adantl W Word V I 0 I
16 9 nn0red W Word V W
17 16 adantr W Word V I 0 W
18 lelttr 0 I W 0 I I < W 0 < W
19 13 15 17 18 syl3anc W Word V I 0 0 I I < W 0 < W
20 12 19 mpand W Word V I 0 I < W 0 < W
21 20 3impia W Word V I 0 I < W 0 < W
22 elnnnn0b W W 0 0 < W
23 10 21 22 sylanbrc W Word V I 0 I < W W
24 simp3 W Word V I 0 I < W I < W
25 elfzo0 I 0 ..^ W I 0 W I < W
26 8 23 24 25 syl3anbrc W Word V I 0 I < W I 0 ..^ W
27 ccatval1 W Word V ⟨“ X ”⟩ ++ ⟨“ Y ”⟩ Word V I 0 ..^ W W ++ ⟨“ X ”⟩ ++ ⟨“ Y ”⟩ I = W I
28 4 7 26 27 syl3anc W Word V I 0 I < W W ++ ⟨“ X ”⟩ ++ ⟨“ Y ”⟩ I = W I
29 3 28 eqtrd W Word V I 0 I < W W ++ ⟨“ X ”⟩ ++ ⟨“ Y ”⟩ I = W I