MPE Home Metamath Proof Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >  efgredlema Unicode version

Theorem efgredlema 15331
Description: The reduced word that forms the base of the sequence in efgsval 15322 is uniquely determined, given the ending representation. (Contributed by Mario Carneiro, 1-Oct-2015.)
Hypotheses
Ref Expression
efgval.w  |-  W  =  (  _I  ` Word  ( I  X.  2o ) )
efgval.r  |-  .~  =  ( ~FG  `  I )
efgval2.m  |-  M  =  ( y  e.  I ,  z  e.  2o  |->  <. y ,  ( 1o 
\  z ) >.
)
efgval2.t  |-  T  =  ( v  e.  W  |->  ( n  e.  ( 0 ... ( # `  v ) ) ,  w  e.  ( I  X.  2o )  |->  ( v splice  <. n ,  n ,  <" w ( M `  w ) "> >. )
) )
efgred.d  |-  D  =  ( W  \  U_ x  e.  W  ran  ( T `  x ) )
efgred.s  |-  S  =  ( m  e.  {
t  e.  (Word  W  \  { (/) } )  |  ( ( t ` 
0 )  e.  D  /\  A. k  e.  ( 1..^ ( # `  t
) ) ( t `
 k )  e. 
ran  ( T `  ( t `  (
k  -  1 ) ) ) ) } 
|->  ( m `  (
( # `  m )  -  1 ) ) )
efgredlem.1  |-  ( ph  ->  A. a  e.  dom  S A. b  e.  dom  S ( ( # `  ( S `  a )
)  <  ( # `  ( S `  A )
)  ->  ( ( S `  a )  =  ( S `  b )  ->  (
a `  0 )  =  ( b ` 
0 ) ) ) )
efgredlem.2  |-  ( ph  ->  A  e.  dom  S
)
efgredlem.3  |-  ( ph  ->  B  e.  dom  S
)
efgredlem.4  |-  ( ph  ->  ( S `  A
)  =  ( S `
 B ) )
efgredlem.5  |-  ( ph  ->  -.  ( A ` 
0 )  =  ( B `  0 ) )
Assertion
Ref Expression
efgredlema  |-  ( ph  ->  ( ( ( # `  A )  -  1 )  e.  NN  /\  ( ( # `  B
)  -  1 )  e.  NN ) )
Distinct variable groups:    a, b, A    y, a, z, b   
t, n, v, w, y, z    m, a, n, t, v, w, x, M, b    k,
a, T, b, m, t, x    W, a, b    k, n, v, w, y, z, W, m, t, x    .~ , a,
b, m, t, x, y, z    B, a, b    S, a, b    I,
a, b, m, n, t, v, w, x, y, z    D, a, b, m, t
Allowed substitution hints:    ph( x, y, z, w, v, t, k, m, n, a, b)    A( x, y, z, w, v, t, k, m, n)    B( x, y, z, w, v, t, k, m, n)    D( x, y, z, w, v, k, n)    .~ ( w, v, k, n)    S( x, y, z, w, v, t, k, m, n)    T( y, z, w, v, n)    I( k)    M( y, z, k)

Proof of Theorem efgredlema
Dummy variable  u is distinct from all other variables.
StepHypRef Expression
1 efgredlem.5 . . . . 5  |-  ( ph  ->  -.  ( A ` 
0 )  =  ( B `  0 ) )
2 efgredlem.3 . . . . . . . . 9  |-  ( ph  ->  B  e.  dom  S
)
3 efgval.w . . . . . . . . . 10  |-  W  =  (  _I  ` Word  ( I  X.  2o ) )
4 efgval.r . . . . . . . . . 10  |-  .~  =  ( ~FG  `  I )
5 efgval2.m . . . . . . . . . 10  |-  M  =  ( y  e.  I ,  z  e.  2o  |->  <. y ,  ( 1o 
\  z ) >.
)
6 efgval2.t . . . . . . . . . 10  |-  T  =  ( v  e.  W  |->  ( n  e.  ( 0 ... ( # `  v ) ) ,  w  e.  ( I  X.  2o )  |->  ( v splice  <. n ,  n ,  <" w ( M `  w ) "> >. )
) )
7 efgred.d . . . . . . . . . 10  |-  D  =  ( W  \  U_ x  e.  W  ran  ( T `  x ) )
8 efgred.s . . . . . . . . . 10  |-  S  =  ( m  e.  {
t  e.  (Word  W  \  { (/) } )  |  ( ( t ` 
0 )  e.  D  /\  A. k  e.  ( 1..^ ( # `  t
) ) ( t `
 k )  e. 
ran  ( T `  ( t `  (
k  -  1 ) ) ) ) } 
|->  ( m `  (
( # `  m )  -  1 ) ) )
93, 4, 5, 6, 7, 8efgsval 15322 . . . . . . . . 9  |-  ( B  e.  dom  S  -> 
( S `  B
)  =  ( B `
 ( ( # `  B )  -  1 ) ) )
102, 9syl 16 . . . . . . . 8  |-  ( ph  ->  ( S `  B
)  =  ( B `
 ( ( # `  B )  -  1 ) ) )
11 efgredlem.4 . . . . . . . . 9  |-  ( ph  ->  ( S `  A
)  =  ( S `
 B ) )
12 efgredlem.2 . . . . . . . . . 10  |-  ( ph  ->  A  e.  dom  S
)
133, 4, 5, 6, 7, 8efgsval 15322 . . . . . . . . . 10  |-  ( A  e.  dom  S  -> 
( S `  A
)  =  ( A `
 ( ( # `  A )  -  1 ) ) )
1412, 13syl 16 . . . . . . . . 9  |-  ( ph  ->  ( S `  A
)  =  ( A `
 ( ( # `  A )  -  1 ) ) )
1511, 14eqtr3d 2442 . . . . . . . 8  |-  ( ph  ->  ( S `  B
)  =  ( A `
 ( ( # `  A )  -  1 ) ) )
1610, 15eqtr3d 2442 . . . . . . 7  |-  ( ph  ->  ( B `  (
( # `  B )  -  1 ) )  =  ( A `  ( ( # `  A
)  -  1 ) ) )
17 oveq1 6051 . . . . . . . . 9  |-  ( (
# `  A )  =  1  ->  (
( # `  A )  -  1 )  =  ( 1  -  1 ) )
18 1m1e0 10028 . . . . . . . . 9  |-  ( 1  -  1 )  =  0
1917, 18syl6eq 2456 . . . . . . . 8  |-  ( (
# `  A )  =  1  ->  (
( # `  A )  -  1 )  =  0 )
2019fveq2d 5695 . . . . . . 7  |-  ( (
# `  A )  =  1  ->  ( A `  ( ( # `
 A )  - 
1 ) )  =  ( A `  0
) )
2116, 20sylan9eq 2460 . . . . . 6  |-  ( (
ph  /\  ( # `  A
)  =  1 )  ->  ( B `  ( ( # `  B
)  -  1 ) )  =  ( A `
 0 ) )
2211eleq1d 2474 . . . . . . . . 9  |-  ( ph  ->  ( ( S `  A )  e.  D  <->  ( S `  B )  e.  D ) )
233, 4, 5, 6, 7, 8efgs1b 15327 . . . . . . . . . 10  |-  ( A  e.  dom  S  -> 
( ( S `  A )  e.  D  <->  (
# `  A )  =  1 ) )
2412, 23syl 16 . . . . . . . . 9  |-  ( ph  ->  ( ( S `  A )  e.  D  <->  (
# `  A )  =  1 ) )
253, 4, 5, 6, 7, 8efgs1b 15327 . . . . . . . . . 10  |-  ( B  e.  dom  S  -> 
( ( S `  B )  e.  D  <->  (
# `  B )  =  1 ) )
262, 25syl 16 . . . . . . . . 9  |-  ( ph  ->  ( ( S `  B )  e.  D  <->  (
# `  B )  =  1 ) )
2722, 24, 263bitr3d 275 . . . . . . . 8  |-  ( ph  ->  ( ( # `  A
)  =  1  <->  ( # `
 B )  =  1 ) )
2827biimpa 471 . . . . . . 7  |-  ( (
ph  /\  ( # `  A
)  =  1 )  ->  ( # `  B
)  =  1 )
29 oveq1 6051 . . . . . . . . 9  |-  ( (
# `  B )  =  1  ->  (
( # `  B )  -  1 )  =  ( 1  -  1 ) )
3029, 18syl6eq 2456 . . . . . . . 8  |-  ( (
# `  B )  =  1  ->  (
( # `  B )  -  1 )  =  0 )
3130fveq2d 5695 . . . . . . 7  |-  ( (
# `  B )  =  1  ->  ( B `  ( ( # `
 B )  - 
1 ) )  =  ( B `  0
) )
3228, 31syl 16 . . . . . 6  |-  ( (
ph  /\  ( # `  A
)  =  1 )  ->  ( B `  ( ( # `  B
)  -  1 ) )  =  ( B `
 0 ) )
3321, 32eqtr3d 2442 . . . . 5  |-  ( (
ph  /\  ( # `  A
)  =  1 )  ->  ( A ` 
0 )  =  ( B `  0 ) )
341, 33mtand 641 . . . 4  |-  ( ph  ->  -.  ( # `  A
)  =  1 )
353, 4, 5, 6, 7, 8efgsdm 15321 . . . . . . . 8  |-  ( A  e.  dom  S  <->  ( A  e.  (Word  W  \  { (/)
} )  /\  ( A `  0 )  e.  D  /\  A. u  e.  ( 1..^ ( # `  A ) ) ( A `  u )  e.  ran  ( T `
 ( A `  ( u  -  1
) ) ) ) )
3635simp1bi 972 . . . . . . 7  |-  ( A  e.  dom  S  ->  A  e.  (Word  W  \  { (/) } ) )
37 eldifsn 3891 . . . . . . . 8  |-  ( A  e.  (Word  W  \  { (/) } )  <->  ( A  e. Word  W  /\  A  =/=  (/) ) )
38 lennncl 11695 . . . . . . . 8  |-  ( ( A  e. Word  W  /\  A  =/=  (/) )  ->  ( # `
 A )  e.  NN )
3937, 38sylbi 188 . . . . . . 7  |-  ( A  e.  (Word  W  \  { (/) } )  -> 
( # `  A )  e.  NN )
4012, 36, 393syl 19 . . . . . 6  |-  ( ph  ->  ( # `  A
)  e.  NN )
41 elnn1uz2 10512 . . . . . 6  |-  ( (
# `  A )  e.  NN  <->  ( ( # `  A )  =  1  \/  ( # `  A
)  e.  ( ZZ>= ` 
2 ) ) )
4240, 41sylib 189 . . . . 5  |-  ( ph  ->  ( ( # `  A
)  =  1  \/  ( # `  A
)  e.  ( ZZ>= ` 
2 ) ) )
4342ord 367 . . . 4  |-  ( ph  ->  ( -.  ( # `  A )  =  1  ->  ( # `  A
)  e.  ( ZZ>= ` 
2 ) ) )
4434, 43mpd 15 . . 3  |-  ( ph  ->  ( # `  A
)  e.  ( ZZ>= ` 
2 ) )
45 uz2m1nn 10510 . . 3  |-  ( (
# `  A )  e.  ( ZZ>= `  2 )  ->  ( ( # `  A
)  -  1 )  e.  NN )
4644, 45syl 16 . 2  |-  ( ph  ->  ( ( # `  A
)  -  1 )  e.  NN )
4734, 27mtbid 292 . . . 4  |-  ( ph  ->  -.  ( # `  B
)  =  1 )
483, 4, 5, 6, 7, 8efgsdm 15321 . . . . . . . 8  |-  ( B  e.  dom  S  <->  ( B  e.  (Word  W  \  { (/)
} )  /\  ( B `  0 )  e.  D  /\  A. u  e.  ( 1..^ ( # `  B ) ) ( B `  u )  e.  ran  ( T `
 ( B `  ( u  -  1
) ) ) ) )
4948simp1bi 972 . . . . . . 7  |-  ( B  e.  dom  S  ->  B  e.  (Word  W  \  { (/) } ) )
50 eldifsn 3891 . . . . . . . 8  |-  ( B  e.  (Word  W  \  { (/) } )  <->  ( B  e. Word  W  /\  B  =/=  (/) ) )
51 lennncl 11695 . . . . . . . 8  |-  ( ( B  e. Word  W  /\  B  =/=  (/) )  ->  ( # `
 B )  e.  NN )
5250, 51sylbi 188 . . . . . . 7  |-  ( B  e.  (Word  W  \  { (/) } )  -> 
( # `  B )  e.  NN )
532, 49, 523syl 19 . . . . . 6  |-  ( ph  ->  ( # `  B
)  e.  NN )
54 elnn1uz2 10512 . . . . . 6  |-  ( (
# `  B )  e.  NN  <->  ( ( # `  B )  =  1  \/  ( # `  B
)  e.  ( ZZ>= ` 
2 ) ) )
5553, 54sylib 189 . . . . 5  |-  ( ph  ->  ( ( # `  B
)  =  1  \/  ( # `  B
)  e.  ( ZZ>= ` 
2 ) ) )
5655ord 367 . . . 4  |-  ( ph  ->  ( -.  ( # `  B )  =  1  ->  ( # `  B
)  e.  ( ZZ>= ` 
2 ) ) )
5747, 56mpd 15 . . 3  |-  ( ph  ->  ( # `  B
)  e.  ( ZZ>= ` 
2 ) )
58 uz2m1nn 10510 . . 3  |-  ( (
# `  B )  e.  ( ZZ>= `  2 )  ->  ( ( # `  B
)  -  1 )  e.  NN )
5957, 58syl 16 . 2  |-  ( ph  ->  ( ( # `  B
)  -  1 )  e.  NN )
6046, 59jca 519 1  |-  ( ph  ->  ( ( ( # `  A )  -  1 )  e.  NN  /\  ( ( # `  B
)  -  1 )  e.  NN ) )
Colors of variables: wff set class
Syntax hints:   -. wn 3    -> wi 4    <-> wb 177    \/ wo 358    /\ wa 359    = wceq 1649    e. wcel 1721    =/= wne 2571   A.wral 2670   {crab 2674    \ cdif 3281   (/)c0 3592   {csn 3778   <.cop 3781   <.cotp 3782   U_ciun 4057   class class class wbr 4176    e. cmpt 4230    _I cid 4457    X. cxp 4839   dom cdm 4841   ran crn 4842   ` cfv 5417  (class class class)co 6044    e. cmpt2 6046   1oc1o 6680   2oc2o 6681   0cc0 8950   1c1 8951    < clt 9080    - cmin 9251   NNcn 9960   2c2 10009   ZZ>=cuz 10448   ...cfz 11003  ..^cfzo 11094   #chash 11577  Word cword 11676   splice csplice 11680   <"cs2 11764   ~FG cefg 15297
This theorem is referenced by:  efgredlemf  15332  efgredlemg  15333  efgredlemd  15335  efgredlemc  15336  efgredlem  15338
This theorem was proved from axioms:  ax-1 5  ax-2 6  ax-3 7  ax-mp 8  ax-gen 1552  ax-5 1563  ax-17 1623  ax-9 1662  ax-8 1683  ax-13 1723  ax-14 1725  ax-6 1740  ax-7 1745  ax-11 1757  ax-12 1946  ax-ext 2389  ax-rep 4284  ax-sep 4294  ax-nul 4302  ax-pow 4341  ax-pr 4367  ax-un 4664  ax-cnex 9006  ax-resscn 9007  ax-1cn 9008  ax-icn 9009  ax-addcl 9010  ax-addrcl 9011  ax-mulcl 9012  ax-mulrcl 9013  ax-mulcom 9014  ax-addass 9015  ax-mulass 9016  ax-distr 9017  ax-i2m1 9018  ax-1ne0 9019  ax-1rid 9020  ax-rnegex 9021  ax-rrecex 9022  ax-cnre 9023  ax-pre-lttri 9024  ax-pre-lttrn 9025  ax-pre-ltadd 9026  ax-pre-mulgt0 9027
This theorem depends on definitions:  df-bi 178  df-or 360  df-an 361  df-3or 937  df-3an 938  df-tru 1325  df-ex 1548  df-nf 1551  df-sb 1656  df-eu 2262  df-mo 2263  df-clab 2395  df-cleq 2401  df-clel 2404  df-nfc 2533  df-ne 2573  df-nel 2574  df-ral 2675  df-rex 2676  df-reu 2677  df-rab 2679  df-v 2922  df-sbc 3126  df-csb 3216  df-dif 3287  df-un 3289  df-in 3291  df-ss 3298  df-pss 3300  df-nul 3593  df-if 3704  df-pw 3765  df-sn 3784  df-pr 3785  df-tp 3786  df-op 3787  df-uni 3980  df-int 4015  df-iun 4059  df-br 4177  df-opab 4231  df-mpt 4232  df-tr 4267  df-eprel 4458  df-id 4462  df-po 4467  df-so 4468  df-fr 4505  df-we 4507  df-ord 4548  df-on 4549  df-lim 4550  df-suc 4551  df-om 4809  df-xp 4847  df-rel 4848  df-cnv 4849  df-co 4850  df-dm 4851  df-rn 4852  df-res 4853  df-ima 4854  df-iota 5381  df-fun 5419  df-fn 5420  df-f 5421  df-f1 5422  df-fo 5423  df-f1o 5424  df-fv 5425  df-ov 6047  df-oprab 6048  df-mpt2 6049  df-1st 6312  df-2nd 6313  df-riota 6512  df-recs 6596  df-rdg 6631  df-1o 6687  df-oadd 6691  df-er 6868  df-en 7073  df-dom 7074  df-sdom 7075  df-fin 7076  df-card 7786  df-pnf 9082  df-mnf 9083  df-xr 9084  df-ltxr 9085  df-le 9086  df-sub 9253  df-neg 9254  df-nn 9961  df-2 10018  df-n0 10182  df-z 10243  df-uz 10449  df-fz 11004  df-fzo 11095  df-hash 11578  df-word 11682
  Copyright terms: Public domain W3C validator