Metamath Proof Explorer


Theorem sseqval

Description: Value of the strong sequence builder function. The set W represents here the words of length greater than or equal to the lenght of the initial sequence M . (Contributed by Thierry Arnoux, 21-Apr-2019)

Ref Expression
Hypotheses sseqval.1 φ S V
sseqval.2 φ M Word S
sseqval.3 W = Word S . -1 M
sseqval.4 φ F : W S
Assertion sseqval φ M seq str F = M lastS seq M x V , y V x ++ ⟨“ F x ”⟩ 0 × M ++ ⟨“ F M ”⟩

Proof

Step Hyp Ref Expression
1 sseqval.1 φ S V
2 sseqval.2 φ M Word S
3 sseqval.3 W = Word S . -1 M
4 sseqval.4 φ F : W S
5 df-sseq seq str = m V , f V m lastS seq m x V , y V x ++ ⟨“ f x ”⟩ 0 × m ++ ⟨“ f m ”⟩
6 5 a1i φ seq str = m V , f V m lastS seq m x V , y V x ++ ⟨“ f x ”⟩ 0 × m ++ ⟨“ f m ”⟩
7 simprl φ m = M f = F m = M
8 7 fveq2d φ m = M f = F m = M
9 simp1rr φ m = M f = F x V y V f = F
10 9 fveq1d φ m = M f = F x V y V f x = F x
11 10 s1eqd φ m = M f = F x V y V ⟨“ f x ”⟩ = ⟨“ F x ”⟩
12 11 oveq2d φ m = M f = F x V y V x ++ ⟨“ f x ”⟩ = x ++ ⟨“ F x ”⟩
13 12 mpoeq3dva φ m = M f = F x V , y V x ++ ⟨“ f x ”⟩ = x V , y V x ++ ⟨“ F x ”⟩
14 simprr φ m = M f = F f = F
15 14 7 fveq12d φ m = M f = F f m = F M
16 15 s1eqd φ m = M f = F ⟨“ f m ”⟩ = ⟨“ F M ”⟩
17 7 16 oveq12d φ m = M f = F m ++ ⟨“ f m ”⟩ = M ++ ⟨“ F M ”⟩
18 17 sneqd φ m = M f = F m ++ ⟨“ f m ”⟩ = M ++ ⟨“ F M ”⟩
19 18 xpeq2d φ m = M f = F 0 × m ++ ⟨“ f m ”⟩ = 0 × M ++ ⟨“ F M ”⟩
20 8 13 19 seqeq123d φ m = M f = F seq m x V , y V x ++ ⟨“ f x ”⟩ 0 × m ++ ⟨“ f m ”⟩ = seq M x V , y V x ++ ⟨“ F x ”⟩ 0 × M ++ ⟨“ F M ”⟩
21 20 coeq2d φ m = M f = F lastS seq m x V , y V x ++ ⟨“ f x ”⟩ 0 × m ++ ⟨“ f m ”⟩ = lastS seq M x V , y V x ++ ⟨“ F x ”⟩ 0 × M ++ ⟨“ F M ”⟩
22 7 21 uneq12d φ m = M f = F m lastS seq m x V , y V x ++ ⟨“ f x ”⟩ 0 × m ++ ⟨“ f m ”⟩ = M lastS seq M x V , y V x ++ ⟨“ F x ”⟩ 0 × M ++ ⟨“ F M ”⟩
23 elex M Word S M V
24 2 23 syl φ M V
25 wrdexg S V Word S V
26 inex1g Word S V Word S . -1 M V
27 1 25 26 3syl φ Word S . -1 M V
28 3 27 eqeltrid φ W V
29 4 28 fexd φ F V
30 df-lsw lastS = x V x x 1
31 30 funmpt2 Fun lastS
32 31 a1i φ Fun lastS
33 seqex seq M x V , y V x ++ ⟨“ F x ”⟩ 0 × M ++ ⟨“ F M ”⟩ V
34 33 a1i φ seq M x V , y V x ++ ⟨“ F x ”⟩ 0 × M ++ ⟨“ F M ”⟩ V
35 cofunexg Fun lastS seq M x V , y V x ++ ⟨“ F x ”⟩ 0 × M ++ ⟨“ F M ”⟩ V lastS seq M x V , y V x ++ ⟨“ F x ”⟩ 0 × M ++ ⟨“ F M ”⟩ V
36 32 34 35 syl2anc φ lastS seq M x V , y V x ++ ⟨“ F x ”⟩ 0 × M ++ ⟨“ F M ”⟩ V
37 unexg M V lastS seq M x V , y V x ++ ⟨“ F x ”⟩ 0 × M ++ ⟨“ F M ”⟩ V M lastS seq M x V , y V x ++ ⟨“ F x ”⟩ 0 × M ++ ⟨“ F M ”⟩ V
38 24 36 37 syl2anc φ M lastS seq M x V , y V x ++ ⟨“ F x ”⟩ 0 × M ++ ⟨“ F M ”⟩ V
39 6 22 24 29 38 ovmpod φ M seq str F = M lastS seq M x V , y V x ++ ⟨“ F x ”⟩ 0 × M ++ ⟨“ F M ”⟩