Users' Mathboxes Mathbox for Alexander van der Vekens < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >   Mathboxes  >  cshwoor Structured version   Unicode version

Theorem cshwoor 28259
Description: A cyclically shifted word is the empty set if the number of shifts is out of the range of the word. (Contributed by Alexander van der Vekens, 16-May-2018.) (Revised by Alexander van der Vekens, 21-May-2018.)
Assertion
Ref Expression
cshwoor  |-  ( ( W  e. Word  V  /\  N  e.  NN0 )  -> 
( ( # `  W
)  <  N  ->  ( W CyclShift  N )  =  (/) ) )

Proof of Theorem cshwoor
StepHypRef Expression
1 cshword 28257 . . . 4  |-  ( ( W  e. Word  V  /\  N  e.  NN0 )  -> 
( W CyclShift  N )  =  ( ( W substr  <. N , 
( # `  W )
>. ) concat  ( W substr  <. 0 ,  N >. ) ) )
21adantr 453 . . 3  |-  ( ( ( W  e. Word  V  /\  N  e.  NN0 )  /\  ( # `  W
)  <  N )  ->  ( W CyclShift  N )  =  ( ( W substr  <. N ,  ( # `  W ) >. ) concat  ( W substr  <. 0 ,  N >. ) ) )
3 simpl 445 . . . . . . 7  |-  ( ( W  e. Word  V  /\  N  e.  NN0 )  ->  W  e. Word  V )
4 nn0z 10306 . . . . . . . 8  |-  ( N  e.  NN0  ->  N  e.  ZZ )
54adantl 454 . . . . . . 7  |-  ( ( W  e. Word  V  /\  N  e.  NN0 )  ->  N  e.  ZZ )
6 lencl 11737 . . . . . . . . 9  |-  ( W  e. Word  V  ->  ( # `
 W )  e. 
NN0 )
76nn0zd 10375 . . . . . . . 8  |-  ( W  e. Word  V  ->  ( # `
 W )  e.  ZZ )
87adantr 453 . . . . . . 7  |-  ( ( W  e. Word  V  /\  N  e.  NN0 )  -> 
( # `  W )  e.  ZZ )
93, 5, 83jca 1135 . . . . . 6  |-  ( ( W  e. Word  V  /\  N  e.  NN0 )  -> 
( W  e. Word  V  /\  N  e.  ZZ  /\  ( # `  W
)  e.  ZZ ) )
109adantr 453 . . . . 5  |-  ( ( ( W  e. Word  V  /\  N  e.  NN0 )  /\  ( # `  W
)  <  N )  ->  ( W  e. Word  V  /\  N  e.  ZZ  /\  ( # `  W
)  e.  ZZ ) )
116nn0red 10277 . . . . . . . 8  |-  ( W  e. Word  V  ->  ( # `
 W )  e.  RR )
12 nn0re 10232 . . . . . . . 8  |-  ( N  e.  NN0  ->  N  e.  RR )
13 ltle 9165 . . . . . . . 8  |-  ( ( ( # `  W
)  e.  RR  /\  N  e.  RR )  ->  ( ( # `  W
)  <  N  ->  (
# `  W )  <_  N ) )
1411, 12, 13syl2an 465 . . . . . . 7  |-  ( ( W  e. Word  V  /\  N  e.  NN0 )  -> 
( ( # `  W
)  <  N  ->  (
# `  W )  <_  N ) )
1514imp 420 . . . . . 6  |-  ( ( ( W  e. Word  V  /\  N  e.  NN0 )  /\  ( # `  W
)  <  N )  ->  ( # `  W
)  <_  N )
16 3mix2 1128 . . . . . 6  |-  ( (
# `  W )  <_  N  ->  ( N  <  0  \/  ( # `  W )  <_  N  \/  ( # `  W
)  <  ( # `  W
) ) )
1715, 16syl 16 . . . . 5  |-  ( ( ( W  e. Word  V  /\  N  e.  NN0 )  /\  ( # `  W
)  <  N )  ->  ( N  <  0  \/  ( # `  W
)  <_  N  \/  ( # `  W )  <  ( # `  W
) ) )
18 swrdnd 28204 . . . . 5  |-  ( ( W  e. Word  V  /\  N  e.  ZZ  /\  ( # `
 W )  e.  ZZ )  ->  (
( N  <  0  \/  ( # `  W
)  <_  N  \/  ( # `  W )  <  ( # `  W
) )  ->  ( W substr  <. N ,  (
# `  W ) >. )  =  (/) ) )
1910, 17, 18sylc 59 . . . 4  |-  ( ( ( W  e. Word  V  /\  N  e.  NN0 )  /\  ( # `  W
)  <  N )  ->  ( W substr  <. N , 
( # `  W )
>. )  =  (/) )
20 0z 10295 . . . . . . . 8  |-  0  e.  ZZ
2120a1i 11 . . . . . . 7  |-  ( ( W  e. Word  V  /\  N  e.  NN0 )  -> 
0  e.  ZZ )
223, 21, 53jca 1135 . . . . . 6  |-  ( ( W  e. Word  V  /\  N  e.  NN0 )  -> 
( W  e. Word  V  /\  0  e.  ZZ  /\  N  e.  ZZ ) )
2322adantr 453 . . . . 5  |-  ( ( ( W  e. Word  V  /\  N  e.  NN0 )  /\  ( # `  W
)  <  N )  ->  ( W  e. Word  V  /\  0  e.  ZZ  /\  N  e.  ZZ ) )
24 3mix3 1129 . . . . . 6  |-  ( (
# `  W )  <  N  ->  ( 0  <  0  \/  N  <_  0  \/  ( # `  W )  <  N
) )
2524adantl 454 . . . . 5  |-  ( ( ( W  e. Word  V  /\  N  e.  NN0 )  /\  ( # `  W
)  <  N )  ->  ( 0  <  0  \/  N  <_  0  \/  ( # `  W
)  <  N )
)
26 swrdnd 28204 . . . . 5  |-  ( ( W  e. Word  V  /\  0  e.  ZZ  /\  N  e.  ZZ )  ->  (
( 0  <  0  \/  N  <_  0  \/  ( # `  W
)  <  N )  ->  ( W substr  <. 0 ,  N >. )  =  (/) ) )
2723, 25, 26sylc 59 . . . 4  |-  ( ( ( W  e. Word  V  /\  N  e.  NN0 )  /\  ( # `  W
)  <  N )  ->  ( W substr  <. 0 ,  N >. )  =  (/) )
2819, 27oveq12d 6101 . . 3  |-  ( ( ( W  e. Word  V  /\  N  e.  NN0 )  /\  ( # `  W
)  <  N )  ->  ( ( W substr  <. N , 
( # `  W )
>. ) concat  ( W substr  <. 0 ,  N >. ) )  =  ( (/) concat  (/) ) )
29 wrd0 11734 . . . 4  |-  (/)  e. Word  _V
30 ccatlid 11750 . . . 4  |-  ( (/)  e. Word  _V  ->  ( (/) concat  (/) )  =  (/) )
3129, 30mp1i 12 . . 3  |-  ( ( ( W  e. Word  V  /\  N  e.  NN0 )  /\  ( # `  W
)  <  N )  ->  ( (/) concat  (/) )  =  (/) )
322, 28, 313eqtrd 2474 . 2  |-  ( ( ( W  e. Word  V  /\  N  e.  NN0 )  /\  ( # `  W
)  <  N )  ->  ( W CyclShift  N )  =  (/) )
3332ex 425 1  |-  ( ( W  e. Word  V  /\  N  e.  NN0 )  -> 
( ( # `  W
)  <  N  ->  ( W CyclShift  N )  =  (/) ) )
Colors of variables: wff set class
Syntax hints:    -> wi 4    /\ wa 360    \/ w3o 936    /\ w3a 937    = wceq 1653    e. wcel 1726   _Vcvv 2958   (/)c0 3630   <.cop 3819   class class class wbr 4214   ` cfv 5456  (class class class)co 6083   RRcr 8991   0cc0 8992    < clt 9122    <_ cle 9123   NN0cn0 10223   ZZcz 10284   #chash 11620  Word cword 11719   concat cconcat 11720   substr csubstr 11722   CyclShift ccsh 28252
This theorem was proved from axioms:  ax-1 5  ax-2 6  ax-3 7  ax-mp 8  ax-gen 1556  ax-5 1567  ax-17 1627  ax-9 1667  ax-8 1688  ax-13 1728  ax-14 1730  ax-6 1745  ax-7 1750  ax-11 1762  ax-12 1951  ax-ext 2419  ax-rep 4322  ax-sep 4332  ax-nul 4340  ax-pow 4379  ax-pr 4405  ax-un 4703  ax-cnex 9048  ax-resscn 9049  ax-1cn 9050  ax-icn 9051  ax-addcl 9052  ax-addrcl 9053  ax-mulcl 9054  ax-mulrcl 9055  ax-mulcom 9056  ax-addass 9057  ax-mulass 9058  ax-distr 9059  ax-i2m1 9060  ax-1ne0 9061  ax-1rid 9062  ax-rnegex 9063  ax-rrecex 9064  ax-cnre 9065  ax-pre-lttri 9066  ax-pre-lttrn 9067  ax-pre-ltadd 9068  ax-pre-mulgt0 9069
This theorem depends on definitions:  df-bi 179  df-or 361  df-an 362  df-3or 938  df-3an 939  df-tru 1329  df-ex 1552  df-nf 1555  df-sb 1660  df-eu 2287  df-mo 2288  df-clab 2425  df-cleq 2431  df-clel 2434  df-nfc 2563  df-ne 2603  df-nel 2604  df-ral 2712  df-rex 2713  df-reu 2714  df-rab 2716  df-v 2960  df-sbc 3164  df-csb 3254  df-dif 3325  df-un 3327  df-in 3329  df-ss 3336  df-pss 3338  df-nul 3631  df-if 3742  df-pw 3803  df-sn 3822  df-pr 3823  df-tp 3824  df-op 3825  df-uni 4018  df-int 4053  df-iun 4097  df-br 4215  df-opab 4269  df-mpt 4270  df-tr 4305  df-eprel 4496  df-id 4500  df-po 4505  df-so 4506  df-fr 4543  df-we 4545  df-ord 4586  df-on 4587  df-lim 4588  df-suc 4589  df-om 4848  df-xp 4886  df-rel 4887  df-cnv 4888  df-co 4889  df-dm 4890  df-rn 4891  df-res 4892  df-ima 4893  df-iota 5420  df-fun 5458  df-fn 5459  df-f 5460  df-f1 5461  df-fo 5462  df-f1o 5463  df-fv 5464  df-ov 6086  df-oprab 6087  df-mpt2 6088  df-1st 6351  df-2nd 6352  df-riota 6551  df-recs 6635  df-rdg 6670  df-1o 6726  df-oadd 6730  df-er 6907  df-en 7112  df-dom 7113  df-sdom 7114  df-fin 7115  df-card 7828  df-pnf 9124  df-mnf 9125  df-xr 9126  df-ltxr 9127  df-le 9128  df-sub 9295  df-neg 9296  df-nn 10003  df-n0 10224  df-z 10285  df-uz 10491  df-fz 11046  df-fzo 11138  df-hash 11621  df-word 11725  df-concat 11726  df-substr 11728  df-csh 28254
  Copyright terms: Public domain W3C validator