|   | Metamath Proof Explorer | < Previous  
      Next > Nearby theorems | |
| Mirrors > Home > MPE Home > Th. List > lswccats1fst | Structured version Visualization version GIF version | ||
| Description: The last symbol of a nonempty word concatenated with its first symbol is the first symbol. (Contributed by AV, 28-Jun-2018.) (Proof shortened by AV, 1-May-2020.) | 
| Ref | Expression | 
|---|---|
| lswccats1fst | ⊢ ((𝑃 ∈ Word 𝑉 ∧ 1 ≤ (♯‘𝑃)) → (lastS‘(𝑃 ++ 〈“(𝑃‘0)”〉)) = ((𝑃 ++ 〈“(𝑃‘0)”〉)‘0)) | 
| Step | Hyp | Ref | Expression | 
|---|---|---|---|
| 1 | wrdsymb1 14592 | . . 3 ⊢ ((𝑃 ∈ Word 𝑉 ∧ 1 ≤ (♯‘𝑃)) → (𝑃‘0) ∈ 𝑉) | |
| 2 | lswccats1 14673 | . . 3 ⊢ ((𝑃 ∈ Word 𝑉 ∧ (𝑃‘0) ∈ 𝑉) → (lastS‘(𝑃 ++ 〈“(𝑃‘0)”〉)) = (𝑃‘0)) | |
| 3 | 1, 2 | syldan 591 | . 2 ⊢ ((𝑃 ∈ Word 𝑉 ∧ 1 ≤ (♯‘𝑃)) → (lastS‘(𝑃 ++ 〈“(𝑃‘0)”〉)) = (𝑃‘0)) | 
| 4 | simpl 482 | . . 3 ⊢ ((𝑃 ∈ Word 𝑉 ∧ 1 ≤ (♯‘𝑃)) → 𝑃 ∈ Word 𝑉) | |
| 5 | 1 | s1cld 14642 | . . 3 ⊢ ((𝑃 ∈ Word 𝑉 ∧ 1 ≤ (♯‘𝑃)) → 〈“(𝑃‘0)”〉 ∈ Word 𝑉) | 
| 6 | lencl 14572 | . . . . 5 ⊢ (𝑃 ∈ Word 𝑉 → (♯‘𝑃) ∈ ℕ0) | |
| 7 | elnnnn0c 12573 | . . . . . 6 ⊢ ((♯‘𝑃) ∈ ℕ ↔ ((♯‘𝑃) ∈ ℕ0 ∧ 1 ≤ (♯‘𝑃))) | |
| 8 | 7 | biimpri 228 | . . . . 5 ⊢ (((♯‘𝑃) ∈ ℕ0 ∧ 1 ≤ (♯‘𝑃)) → (♯‘𝑃) ∈ ℕ) | 
| 9 | 6, 8 | sylan 580 | . . . 4 ⊢ ((𝑃 ∈ Word 𝑉 ∧ 1 ≤ (♯‘𝑃)) → (♯‘𝑃) ∈ ℕ) | 
| 10 | lbfzo0 13740 | . . . 4 ⊢ (0 ∈ (0..^(♯‘𝑃)) ↔ (♯‘𝑃) ∈ ℕ) | |
| 11 | 9, 10 | sylibr 234 | . . 3 ⊢ ((𝑃 ∈ Word 𝑉 ∧ 1 ≤ (♯‘𝑃)) → 0 ∈ (0..^(♯‘𝑃))) | 
| 12 | ccatval1 14616 | . . 3 ⊢ ((𝑃 ∈ Word 𝑉 ∧ 〈“(𝑃‘0)”〉 ∈ Word 𝑉 ∧ 0 ∈ (0..^(♯‘𝑃))) → ((𝑃 ++ 〈“(𝑃‘0)”〉)‘0) = (𝑃‘0)) | |
| 13 | 4, 5, 11, 12 | syl3anc 1372 | . 2 ⊢ ((𝑃 ∈ Word 𝑉 ∧ 1 ≤ (♯‘𝑃)) → ((𝑃 ++ 〈“(𝑃‘0)”〉)‘0) = (𝑃‘0)) | 
| 14 | 3, 13 | eqtr4d 2779 | 1 ⊢ ((𝑃 ∈ Word 𝑉 ∧ 1 ≤ (♯‘𝑃)) → (lastS‘(𝑃 ++ 〈“(𝑃‘0)”〉)) = ((𝑃 ++ 〈“(𝑃‘0)”〉)‘0)) | 
| Colors of variables: wff setvar class | 
| Syntax hints: → wi 4 ∧ wa 395 = wceq 1539 ∈ wcel 2107 class class class wbr 5142 ‘cfv 6560 (class class class)co 7432 0cc0 11156 1c1 11157 ≤ cle 11297 ℕcn 12267 ℕ0cn0 12528 ..^cfzo 13695 ♯chash 14370 Word cword 14553 lastSclsw 14601 ++ cconcat 14609 〈“cs1 14634 | 
| This theorem was proved from axioms: ax-mp 5 ax-1 6 ax-2 7 ax-3 8 ax-gen 1794 ax-4 1808 ax-5 1909 ax-6 1966 ax-7 2006 ax-8 2109 ax-9 2117 ax-10 2140 ax-11 2156 ax-12 2176 ax-ext 2707 ax-rep 5278 ax-sep 5295 ax-nul 5305 ax-pow 5364 ax-pr 5431 ax-un 7756 ax-cnex 11212 ax-resscn 11213 ax-1cn 11214 ax-icn 11215 ax-addcl 11216 ax-addrcl 11217 ax-mulcl 11218 ax-mulrcl 11219 ax-mulcom 11220 ax-addass 11221 ax-mulass 11222 ax-distr 11223 ax-i2m1 11224 ax-1ne0 11225 ax-1rid 11226 ax-rnegex 11227 ax-rrecex 11228 ax-cnre 11229 ax-pre-lttri 11230 ax-pre-lttrn 11231 ax-pre-ltadd 11232 ax-pre-mulgt0 11233 | 
| This theorem depends on definitions: df-bi 207 df-an 396 df-or 848 df-3or 1087 df-3an 1088 df-tru 1542 df-fal 1552 df-ex 1779 df-nf 1783 df-sb 2064 df-mo 2539 df-eu 2568 df-clab 2714 df-cleq 2728 df-clel 2815 df-nfc 2891 df-ne 2940 df-nel 3046 df-ral 3061 df-rex 3070 df-reu 3380 df-rab 3436 df-v 3481 df-sbc 3788 df-csb 3899 df-dif 3953 df-un 3955 df-in 3957 df-ss 3967 df-pss 3970 df-nul 4333 df-if 4525 df-pw 4601 df-sn 4626 df-pr 4628 df-op 4632 df-uni 4907 df-int 4946 df-iun 4992 df-br 5143 df-opab 5205 df-mpt 5225 df-tr 5259 df-id 5577 df-eprel 5583 df-po 5591 df-so 5592 df-fr 5636 df-we 5638 df-xp 5690 df-rel 5691 df-cnv 5692 df-co 5693 df-dm 5694 df-rn 5695 df-res 5696 df-ima 5697 df-pred 6320 df-ord 6386 df-on 6387 df-lim 6388 df-suc 6389 df-iota 6513 df-fun 6562 df-fn 6563 df-f 6564 df-f1 6565 df-fo 6566 df-f1o 6567 df-fv 6568 df-riota 7389 df-ov 7435 df-oprab 7436 df-mpo 7437 df-om 7889 df-1st 8015 df-2nd 8016 df-frecs 8307 df-wrecs 8338 df-recs 8412 df-rdg 8451 df-1o 8507 df-er 8746 df-en 8987 df-dom 8988 df-sdom 8989 df-fin 8990 df-card 9980 df-pnf 11298 df-mnf 11299 df-xr 11300 df-ltxr 11301 df-le 11302 df-sub 11495 df-neg 11496 df-nn 12268 df-n0 12529 df-z 12616 df-uz 12880 df-rp 13036 df-fz 13549 df-fzo 13696 df-hash 14371 df-word 14554 df-lsw 14602 df-concat 14610 df-s1 14635 | 
| This theorem is referenced by: clwlkclwwlk2 30023 | 
| Copyright terms: Public domain | W3C validator |