Users' Mathboxes Mathbox for Thierry Arnoux < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >   Mathboxes  >  smatrcl Structured version   Visualization version   Unicode version

Theorem smatrcl 28622
Description: Closure of the rectangular submatrix. (Contributed by Thierry Arnoux, 19-Aug-2020.)
Hypotheses
Ref Expression
smat.s  |-  S  =  ( K (subMat1 `  A
) L )
smat.m  |-  ( ph  ->  M  e.  NN )
smat.n  |-  ( ph  ->  N  e.  NN )
smat.k  |-  ( ph  ->  K  e.  ( 1 ... M ) )
smat.l  |-  ( ph  ->  L  e.  ( 1 ... N ) )
smat.a  |-  ( ph  ->  A  e.  ( B  ^m  ( ( 1 ... M )  X.  ( 1 ... N
) ) ) )
Assertion
Ref Expression
smatrcl  |-  ( ph  ->  S  e.  ( B  ^m  ( ( 1 ... ( M  - 
1 ) )  X.  ( 1 ... ( N  -  1 ) ) ) ) )

Proof of Theorem smatrcl
Dummy variables  i 
j  x are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 smat.a . . . . . . . 8  |-  ( ph  ->  A  e.  ( B  ^m  ( ( 1 ... M )  X.  ( 1 ... N
) ) ) )
2 elmapi 7493 . . . . . . . 8  |-  ( A  e.  ( B  ^m  ( ( 1 ... M )  X.  (
1 ... N ) ) )  ->  A :
( ( 1 ... M )  X.  (
1 ... N ) ) --> B )
3 ffun 5731 . . . . . . . 8  |-  ( A : ( ( 1 ... M )  X.  ( 1 ... N
) ) --> B  ->  Fun  A )
41, 2, 33syl 18 . . . . . . 7  |-  ( ph  ->  Fun  A )
5 eqid 2451 . . . . . . . . 9  |-  ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.
)  =  ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.
)
65mpt2fun 6398 . . . . . . . 8  |-  Fun  (
i  e.  NN , 
j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L , 
j ,  ( j  +  1 ) )
>. )
76a1i 11 . . . . . . 7  |-  ( ph  ->  Fun  ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  < 
L ,  j ,  ( j  +  1 ) ) >. )
)
8 funco 5620 . . . . . . 7  |-  ( ( Fun  A  /\  Fun  ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  < 
K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >. ) )  ->  Fun  ( A  o.  (
i  e.  NN , 
j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L , 
j ,  ( j  +  1 ) )
>. ) ) )
94, 7, 8syl2anc 667 . . . . . 6  |-  ( ph  ->  Fun  ( A  o.  ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  < 
K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >. ) ) )
10 smat.s . . . . . . . 8  |-  S  =  ( K (subMat1 `  A
) L )
11 fz1ssnn 11830 . . . . . . . . . 10  |-  ( 1 ... M )  C_  NN
12 smat.k . . . . . . . . . 10  |-  ( ph  ->  K  e.  ( 1 ... M ) )
1311, 12sseldi 3430 . . . . . . . . 9  |-  ( ph  ->  K  e.  NN )
14 fz1ssnn 11830 . . . . . . . . . 10  |-  ( 1 ... N )  C_  NN
15 smat.l . . . . . . . . . 10  |-  ( ph  ->  L  e.  ( 1 ... N ) )
1614, 15sseldi 3430 . . . . . . . . 9  |-  ( ph  ->  L  e.  NN )
17 smatfval 28621 . . . . . . . . 9  |-  ( ( K  e.  NN  /\  L  e.  NN  /\  A  e.  ( B  ^m  (
( 1 ... M
)  X.  ( 1 ... N ) ) ) )  ->  ( K (subMat1 `  A ) L )  =  ( A  o.  ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.
) ) )
1813, 16, 1, 17syl3anc 1268 . . . . . . . 8  |-  ( ph  ->  ( K (subMat1 `  A
) L )  =  ( A  o.  (
i  e.  NN , 
j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L , 
j ,  ( j  +  1 ) )
>. ) ) )
1910, 18syl5eq 2497 . . . . . . 7  |-  ( ph  ->  S  =  ( A  o.  ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  < 
L ,  j ,  ( j  +  1 ) ) >. )
) )
2019funeqd 5603 . . . . . 6  |-  ( ph  ->  ( Fun  S  <->  Fun  ( A  o.  ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  < 
L ,  j ,  ( j  +  1 ) ) >. )
) ) )
219, 20mpbird 236 . . . . 5  |-  ( ph  ->  Fun  S )
22 fdmrn 5744 . . . . 5  |-  ( Fun 
S  <->  S : dom  S --> ran  S )
2321, 22sylib 200 . . . 4  |-  ( ph  ->  S : dom  S --> ran  S )
2419dmeqd 5037 . . . . . 6  |-  ( ph  ->  dom  S  =  dom  ( A  o.  (
i  e.  NN , 
j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L , 
j ,  ( j  +  1 ) )
>. ) ) )
25 dmco 5343 . . . . . . 7  |-  dom  ( A  o.  ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  < 
L ,  j ,  ( j  +  1 ) ) >. )
)  =  ( `' ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  < 
K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >. ) " dom  A )
26 fdm 5733 . . . . . . . . . . . 12  |-  ( A : ( ( 1 ... M )  X.  ( 1 ... N
) ) --> B  ->  dom  A  =  ( ( 1 ... M )  X.  ( 1 ... N ) ) )
271, 2, 263syl 18 . . . . . . . . . . 11  |-  ( ph  ->  dom  A  =  ( ( 1 ... M
)  X.  ( 1 ... N ) ) )
2827imaeq2d 5168 . . . . . . . . . 10  |-  ( ph  ->  ( `' ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.
) " dom  A
)  =  ( `' ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  < 
K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >. ) " (
( 1 ... M
)  X.  ( 1 ... N ) ) ) )
2928eleq2d 2514 . . . . . . . . 9  |-  ( ph  ->  ( x  e.  ( `' ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  < 
L ,  j ,  ( j  +  1 ) ) >. ) " dom  A )  <->  x  e.  ( `' ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  < 
L ,  j ,  ( j  +  1 ) ) >. ) " ( ( 1 ... M )  X.  ( 1 ... N
) ) ) ) )
30 opex 4664 . . . . . . . . . . . 12  |-  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.  e.  _V
315, 30fnmpt2i 6862 . . . . . . . . . . 11  |-  ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.
)  Fn  ( NN 
X.  NN )
32 elpreima 6002 . . . . . . . . . . 11  |-  ( ( i  e.  NN , 
j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L , 
j ,  ( j  +  1 ) )
>. )  Fn  ( NN  X.  NN )  -> 
( x  e.  ( `' ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  < 
L ,  j ,  ( j  +  1 ) ) >. ) " ( ( 1 ... M )  X.  ( 1 ... N
) ) )  <->  ( x  e.  ( NN  X.  NN )  /\  ( ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.
) `  x )  e.  ( ( 1 ... M )  X.  (
1 ... N ) ) ) ) )
3331, 32ax-mp 5 . . . . . . . . . 10  |-  ( x  e.  ( `' ( i  e.  NN , 
j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L , 
j ,  ( j  +  1 ) )
>. ) " ( ( 1 ... M )  X.  ( 1 ... N ) ) )  <-> 
( x  e.  ( NN  X.  NN )  /\  ( ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.
) `  x )  e.  ( ( 1 ... M )  X.  (
1 ... N ) ) ) )
3433a1i 11 . . . . . . . . 9  |-  ( ph  ->  ( x  e.  ( `' ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  < 
L ,  j ,  ( j  +  1 ) ) >. ) " ( ( 1 ... M )  X.  ( 1 ... N
) ) )  <->  ( x  e.  ( NN  X.  NN )  /\  ( ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.
) `  x )  e.  ( ( 1 ... M )  X.  (
1 ... N ) ) ) ) )
35 simplr 762 . . . . . . . . . . . . . . . . . . 19  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  x  =  <. ( 1st `  x ) ,  ( 2nd `  x
) >. )
3635fveq2d 5869 . . . . . . . . . . . . . . . . . 18  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.
) `  x )  =  ( ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.
) `  <. ( 1st `  x ) ,  ( 2nd `  x )
>. ) )
37 df-ov 6293 . . . . . . . . . . . . . . . . . 18  |-  ( ( 1st `  x ) ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  < 
K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >. ) ( 2nd `  x ) )  =  ( ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  < 
L ,  j ,  ( j  +  1 ) ) >. ) `  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )
3836, 37syl6eqr 2503 . . . . . . . . . . . . . . . . 17  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.
) `  x )  =  ( ( 1st `  x ) ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.
) ( 2nd `  x
) ) )
39 breq1 4405 . . . . . . . . . . . . . . . . . . . . 21  |-  ( i  =  ( 1st `  x
)  ->  ( i  <  K  <->  ( 1st `  x
)  <  K )
)
40 id 22 . . . . . . . . . . . . . . . . . . . . 21  |-  ( i  =  ( 1st `  x
)  ->  i  =  ( 1st `  x ) )
41 oveq1 6297 . . . . . . . . . . . . . . . . . . . . 21  |-  ( i  =  ( 1st `  x
)  ->  ( i  +  1 )  =  ( ( 1st `  x
)  +  1 ) )
4239, 40, 41ifbieq12d 3908 . . . . . . . . . . . . . . . . . . . 20  |-  ( i  =  ( 1st `  x
)  ->  if (
i  <  K , 
i ,  ( i  +  1 ) )  =  if ( ( 1st `  x )  <  K ,  ( 1st `  x ) ,  ( ( 1st `  x )  +  1 ) ) )
4342opeq1d 4172 . . . . . . . . . . . . . . . . . . 19  |-  ( i  =  ( 1st `  x
)  ->  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.  =  <. if ( ( 1st `  x )  <  K ,  ( 1st `  x ) ,  ( ( 1st `  x )  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >. )
44 breq1 4405 . . . . . . . . . . . . . . . . . . . . 21  |-  ( j  =  ( 2nd `  x
)  ->  ( j  <  L  <->  ( 2nd `  x
)  <  L )
)
45 id 22 . . . . . . . . . . . . . . . . . . . . 21  |-  ( j  =  ( 2nd `  x
)  ->  j  =  ( 2nd `  x ) )
46 oveq1 6297 . . . . . . . . . . . . . . . . . . . . 21  |-  ( j  =  ( 2nd `  x
)  ->  ( j  +  1 )  =  ( ( 2nd `  x
)  +  1 ) )
4744, 45, 46ifbieq12d 3908 . . . . . . . . . . . . . . . . . . . 20  |-  ( j  =  ( 2nd `  x
)  ->  if (
j  <  L , 
j ,  ( j  +  1 ) )  =  if ( ( 2nd `  x )  <  L ,  ( 2nd `  x ) ,  ( ( 2nd `  x )  +  1 ) ) )
4847opeq2d 4173 . . . . . . . . . . . . . . . . . . 19  |-  ( j  =  ( 2nd `  x
)  ->  <. if ( ( 1st `  x
)  <  K , 
( 1st `  x
) ,  ( ( 1st `  x )  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.  =  <. if ( ( 1st `  x )  <  K ,  ( 1st `  x ) ,  ( ( 1st `  x )  +  1 ) ) ,  if ( ( 2nd `  x
)  <  L , 
( 2nd `  x
) ,  ( ( 2nd `  x )  +  1 ) )
>. )
49 opex 4664 . . . . . . . . . . . . . . . . . . 19  |-  <. if ( ( 1st `  x
)  <  K , 
( 1st `  x
) ,  ( ( 1st `  x )  +  1 ) ) ,  if ( ( 2nd `  x )  <  L ,  ( 2nd `  x ) ,  ( ( 2nd `  x )  +  1 ) ) >.  e.  _V
5043, 48, 5, 49ovmpt2 6432 . . . . . . . . . . . . . . . . . 18  |-  ( ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN )  -> 
( ( 1st `  x
) ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  < 
L ,  j ,  ( j  +  1 ) ) >. )
( 2nd `  x
) )  =  <. if ( ( 1st `  x
)  <  K , 
( 1st `  x
) ,  ( ( 1st `  x )  +  1 ) ) ,  if ( ( 2nd `  x )  <  L ,  ( 2nd `  x ) ,  ( ( 2nd `  x )  +  1 ) ) >. )
5150adantl 468 . . . . . . . . . . . . . . . . 17  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( 1st `  x ) ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.
) ( 2nd `  x
) )  =  <. if ( ( 1st `  x
)  <  K , 
( 1st `  x
) ,  ( ( 1st `  x )  +  1 ) ) ,  if ( ( 2nd `  x )  <  L ,  ( 2nd `  x ) ,  ( ( 2nd `  x )  +  1 ) ) >. )
5238, 51eqtrd 2485 . . . . . . . . . . . . . . . 16  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.
) `  x )  =  <. if ( ( 1st `  x )  <  K ,  ( 1st `  x ) ,  ( ( 1st `  x )  +  1 ) ) ,  if ( ( 2nd `  x
)  <  L , 
( 2nd `  x
) ,  ( ( 2nd `  x )  +  1 ) )
>. )
5352eleq1d 2513 . . . . . . . . . . . . . . 15  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( ( i  e.  NN , 
j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L , 
j ,  ( j  +  1 ) )
>. ) `  x )  e.  ( ( 1 ... M )  X.  ( 1 ... N
) )  <->  <. if ( ( 1st `  x
)  <  K , 
( 1st `  x
) ,  ( ( 1st `  x )  +  1 ) ) ,  if ( ( 2nd `  x )  <  L ,  ( 2nd `  x ) ,  ( ( 2nd `  x )  +  1 ) ) >.  e.  ( ( 1 ... M
)  X.  ( 1 ... N ) ) ) )
54 opelxp 4864 . . . . . . . . . . . . . . 15  |-  ( <. if ( ( 1st `  x
)  <  K , 
( 1st `  x
) ,  ( ( 1st `  x )  +  1 ) ) ,  if ( ( 2nd `  x )  <  L ,  ( 2nd `  x ) ,  ( ( 2nd `  x )  +  1 ) ) >.  e.  ( ( 1 ... M
)  X.  ( 1 ... N ) )  <-> 
( if ( ( 1st `  x )  <  K ,  ( 1st `  x ) ,  ( ( 1st `  x )  +  1 ) )  e.  ( 1 ... M )  /\  if ( ( 2nd `  x )  <  L ,  ( 2nd `  x ) ,  ( ( 2nd `  x )  +  1 ) )  e.  ( 1 ... N ) ) )
5553, 54syl6bb 265 . . . . . . . . . . . . . 14  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( ( i  e.  NN , 
j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L , 
j ,  ( j  +  1 ) )
>. ) `  x )  e.  ( ( 1 ... M )  X.  ( 1 ... N
) )  <->  ( if ( ( 1st `  x
)  <  K , 
( 1st `  x
) ,  ( ( 1st `  x )  +  1 ) )  e.  ( 1 ... M )  /\  if ( ( 2nd `  x
)  <  L , 
( 2nd `  x
) ,  ( ( 2nd `  x )  +  1 ) )  e.  ( 1 ... N ) ) ) )
56 ifel 3922 . . . . . . . . . . . . . . . 16  |-  ( if ( ( 1st `  x
)  <  K , 
( 1st `  x
) ,  ( ( 1st `  x )  +  1 ) )  e.  ( 1 ... M )  <->  ( (
( 1st `  x
)  <  K  /\  ( 1st `  x )  e.  ( 1 ... M ) )  \/  ( -.  ( 1st `  x )  <  K  /\  ( ( 1st `  x
)  +  1 )  e.  ( 1 ... M ) ) ) )
57 simplrl 770 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 1st `  x
)  <  K )  ->  ( 1st `  x
)  e.  NN )
5857nnred 10624 . . . . . . . . . . . . . . . . . . . . . . 23  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 1st `  x
)  <  K )  ->  ( 1st `  x
)  e.  RR )
5913nnred 10624 . . . . . . . . . . . . . . . . . . . . . . . 24  |-  ( ph  ->  K  e.  RR )
6059ad3antrrr 736 . . . . . . . . . . . . . . . . . . . . . . 23  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 1st `  x
)  <  K )  ->  K  e.  RR )
61 smat.m . . . . . . . . . . . . . . . . . . . . . . . . 25  |-  ( ph  ->  M  e.  NN )
6261nnred 10624 . . . . . . . . . . . . . . . . . . . . . . . 24  |-  ( ph  ->  M  e.  RR )
6362ad3antrrr 736 . . . . . . . . . . . . . . . . . . . . . . 23  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 1st `  x
)  <  K )  ->  M  e.  RR )
64 simpr 463 . . . . . . . . . . . . . . . . . . . . . . . 24  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 1st `  x
)  <  K )  ->  ( 1st `  x
)  <  K )
6558, 60, 64ltled 9783 . . . . . . . . . . . . . . . . . . . . . . 23  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 1st `  x
)  <  K )  ->  ( 1st `  x
)  <_  K )
66 elfzle2 11803 . . . . . . . . . . . . . . . . . . . . . . . . 25  |-  ( K  e.  ( 1 ... M )  ->  K  <_  M )
6712, 66syl 17 . . . . . . . . . . . . . . . . . . . . . . . 24  |-  ( ph  ->  K  <_  M )
6867ad3antrrr 736 . . . . . . . . . . . . . . . . . . . . . . 23  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 1st `  x
)  <  K )  ->  K  <_  M )
6958, 60, 63, 65, 68letrd 9792 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 1st `  x
)  <  K )  ->  ( 1st `  x
)  <_  M )
7057, 69jca 535 . . . . . . . . . . . . . . . . . . . . 21  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 1st `  x
)  <  K )  ->  ( ( 1st `  x
)  e.  NN  /\  ( 1st `  x )  <_  M ) )
7161nnzd 11039 . . . . . . . . . . . . . . . . . . . . . . 23  |-  ( ph  ->  M  e.  ZZ )
72 fznn 11863 . . . . . . . . . . . . . . . . . . . . . . 23  |-  ( M  e.  ZZ  ->  (
( 1st `  x
)  e.  ( 1 ... M )  <->  ( ( 1st `  x )  e.  NN  /\  ( 1st `  x )  <_  M
) ) )
7371, 72syl 17 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( ph  ->  ( ( 1st `  x
)  e.  ( 1 ... M )  <->  ( ( 1st `  x )  e.  NN  /\  ( 1st `  x )  <_  M
) ) )
7473ad3antrrr 736 . . . . . . . . . . . . . . . . . . . . 21  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 1st `  x
)  <  K )  ->  ( ( 1st `  x
)  e.  ( 1 ... M )  <->  ( ( 1st `  x )  e.  NN  /\  ( 1st `  x )  <_  M
) ) )
7570, 74mpbird 236 . . . . . . . . . . . . . . . . . . . 20  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 1st `  x
)  <  K )  ->  ( 1st `  x
)  e.  ( 1 ... M ) )
7658, 60, 63, 64, 68ltletrd 9795 . . . . . . . . . . . . . . . . . . . . 21  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 1st `  x
)  <  K )  ->  ( 1st `  x
)  <  M )
7761ad3antrrr 736 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 1st `  x
)  <  K )  ->  M  e.  NN )
78 nnltlem1 11003 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( ( ( 1st `  x
)  e.  NN  /\  M  e.  NN )  ->  ( ( 1st `  x
)  <  M  <->  ( 1st `  x )  <_  ( M  -  1 ) ) )
7957, 77, 78syl2anc 667 . . . . . . . . . . . . . . . . . . . . 21  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 1st `  x
)  <  K )  ->  ( ( 1st `  x
)  <  M  <->  ( 1st `  x )  <_  ( M  -  1 ) ) )
8076, 79mpbid 214 . . . . . . . . . . . . . . . . . . . 20  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 1st `  x
)  <  K )  ->  ( 1st `  x
)  <_  ( M  -  1 ) )
8175, 802thd 244 . . . . . . . . . . . . . . . . . . 19  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 1st `  x
)  <  K )  ->  ( ( 1st `  x
)  e.  ( 1 ... M )  <->  ( 1st `  x )  <_  ( M  -  1 ) ) )
8281pm5.32da 647 . . . . . . . . . . . . . . . . . 18  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( ( 1st `  x )  <  K  /\  ( 1st `  x )  e.  ( 1 ... M
) )  <->  ( ( 1st `  x )  < 
K  /\  ( 1st `  x )  <_  ( M  -  1 ) ) ) )
83 fznn 11863 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( M  e.  ZZ  ->  (
( ( 1st `  x
)  +  1 )  e.  ( 1 ... M )  <->  ( (
( 1st `  x
)  +  1 )  e.  NN  /\  (
( 1st `  x
)  +  1 )  <_  M ) ) )
8471, 83syl 17 . . . . . . . . . . . . . . . . . . . . 21  |-  ( ph  ->  ( ( ( 1st `  x )  +  1 )  e.  ( 1 ... M )  <->  ( (
( 1st `  x
)  +  1 )  e.  NN  /\  (
( 1st `  x
)  +  1 )  <_  M ) ) )
8584ad2antrr 732 . . . . . . . . . . . . . . . . . . . 20  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( ( 1st `  x )  +  1 )  e.  ( 1 ... M
)  <->  ( ( ( 1st `  x )  +  1 )  e.  NN  /\  ( ( 1st `  x )  +  1 )  <_  M ) ) )
86 simprl 764 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( 1st `  x
)  e.  NN )
8786peano2nnd 10626 . . . . . . . . . . . . . . . . . . . . 21  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( 1st `  x )  +  1 )  e.  NN )
8887biantrurd 511 . . . . . . . . . . . . . . . . . . . 20  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( ( 1st `  x )  +  1 )  <_  M 
<->  ( ( ( 1st `  x )  +  1 )  e.  NN  /\  ( ( 1st `  x
)  +  1 )  <_  M ) ) )
8986nnzd 11039 . . . . . . . . . . . . . . . . . . . . 21  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( 1st `  x
)  e.  ZZ )
9071ad2antrr 732 . . . . . . . . . . . . . . . . . . . . 21  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  M  e.  ZZ )
91 zltp1le 10986 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( ( ( 1st `  x
)  e.  ZZ  /\  M  e.  ZZ )  ->  ( ( 1st `  x
)  <  M  <->  ( ( 1st `  x )  +  1 )  <_  M
) )
92 zltlem1 10989 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( ( ( 1st `  x
)  e.  ZZ  /\  M  e.  ZZ )  ->  ( ( 1st `  x
)  <  M  <->  ( 1st `  x )  <_  ( M  -  1 ) ) )
9391, 92bitr3d 259 . . . . . . . . . . . . . . . . . . . . 21  |-  ( ( ( 1st `  x
)  e.  ZZ  /\  M  e.  ZZ )  ->  ( ( ( 1st `  x )  +  1 )  <_  M  <->  ( 1st `  x )  <_  ( M  -  1 ) ) )
9489, 90, 93syl2anc 667 . . . . . . . . . . . . . . . . . . . 20  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( ( 1st `  x )  +  1 )  <_  M 
<->  ( 1st `  x
)  <_  ( M  -  1 ) ) )
9585, 88, 943bitr2d 285 . . . . . . . . . . . . . . . . . . 19  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( ( 1st `  x )  +  1 )  e.  ( 1 ... M
)  <->  ( 1st `  x
)  <_  ( M  -  1 ) ) )
9695anbi2d 710 . . . . . . . . . . . . . . . . . 18  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( -.  ( 1st `  x
)  <  K  /\  ( ( 1st `  x
)  +  1 )  e.  ( 1 ... M ) )  <->  ( -.  ( 1st `  x )  <  K  /\  ( 1st `  x )  <_ 
( M  -  1 ) ) ) )
9782, 96orbi12d 716 . . . . . . . . . . . . . . . . 17  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( ( ( 1st `  x
)  <  K  /\  ( 1st `  x )  e.  ( 1 ... M ) )  \/  ( -.  ( 1st `  x )  <  K  /\  ( ( 1st `  x
)  +  1 )  e.  ( 1 ... M ) ) )  <-> 
( ( ( 1st `  x )  <  K  /\  ( 1st `  x
)  <_  ( M  -  1 ) )  \/  ( -.  ( 1st `  x )  < 
K  /\  ( 1st `  x )  <_  ( M  -  1 ) ) ) ) )
98 pm4.42 971 . . . . . . . . . . . . . . . . . 18  |-  ( ( 1st `  x )  <_  ( M  - 
1 )  <->  ( (
( 1st `  x
)  <_  ( M  -  1 )  /\  ( 1st `  x )  <  K )  \/  ( ( 1st `  x
)  <_  ( M  -  1 )  /\  -.  ( 1st `  x
)  <  K )
) )
99 ancom 452 . . . . . . . . . . . . . . . . . . 19  |-  ( ( ( 1st `  x
)  <_  ( M  -  1 )  /\  ( 1st `  x )  <  K )  <->  ( ( 1st `  x )  < 
K  /\  ( 1st `  x )  <_  ( M  -  1 ) ) )
100 ancom 452 . . . . . . . . . . . . . . . . . . 19  |-  ( ( ( 1st `  x
)  <_  ( M  -  1 )  /\  -.  ( 1st `  x
)  <  K )  <->  ( -.  ( 1st `  x
)  <  K  /\  ( 1st `  x )  <_  ( M  - 
1 ) ) )
10199, 100orbi12i 524 . . . . . . . . . . . . . . . . . 18  |-  ( ( ( ( 1st `  x
)  <_  ( M  -  1 )  /\  ( 1st `  x )  <  K )  \/  ( ( 1st `  x
)  <_  ( M  -  1 )  /\  -.  ( 1st `  x
)  <  K )
)  <->  ( ( ( 1st `  x )  <  K  /\  ( 1st `  x )  <_ 
( M  -  1 ) )  \/  ( -.  ( 1st `  x
)  <  K  /\  ( 1st `  x )  <_  ( M  - 
1 ) ) ) )
10298, 101bitri 253 . . . . . . . . . . . . . . . . 17  |-  ( ( 1st `  x )  <_  ( M  - 
1 )  <->  ( (
( 1st `  x
)  <  K  /\  ( 1st `  x )  <_  ( M  - 
1 ) )  \/  ( -.  ( 1st `  x )  <  K  /\  ( 1st `  x
)  <_  ( M  -  1 ) ) ) )
10397, 102syl6bbr 267 . . . . . . . . . . . . . . . 16  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( ( ( 1st `  x
)  <  K  /\  ( 1st `  x )  e.  ( 1 ... M ) )  \/  ( -.  ( 1st `  x )  <  K  /\  ( ( 1st `  x
)  +  1 )  e.  ( 1 ... M ) ) )  <-> 
( 1st `  x
)  <_  ( M  -  1 ) ) )
10456, 103syl5bb 261 . . . . . . . . . . . . . . 15  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( if ( ( 1st `  x
)  <  K , 
( 1st `  x
) ,  ( ( 1st `  x )  +  1 ) )  e.  ( 1 ... M )  <->  ( 1st `  x )  <_  ( M  -  1 ) ) )
105 ifel 3922 . . . . . . . . . . . . . . . 16  |-  ( if ( ( 2nd `  x
)  <  L , 
( 2nd `  x
) ,  ( ( 2nd `  x )  +  1 ) )  e.  ( 1 ... N )  <->  ( (
( 2nd `  x
)  <  L  /\  ( 2nd `  x )  e.  ( 1 ... N ) )  \/  ( -.  ( 2nd `  x )  <  L  /\  ( ( 2nd `  x
)  +  1 )  e.  ( 1 ... N ) ) ) )
106 simplrr 771 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 2nd `  x
)  <  L )  ->  ( 2nd `  x
)  e.  NN )
107106nnred 10624 . . . . . . . . . . . . . . . . . . . . . . 23  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 2nd `  x
)  <  L )  ->  ( 2nd `  x
)  e.  RR )
10816nnred 10624 . . . . . . . . . . . . . . . . . . . . . . . 24  |-  ( ph  ->  L  e.  RR )
109108ad3antrrr 736 . . . . . . . . . . . . . . . . . . . . . . 23  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 2nd `  x
)  <  L )  ->  L  e.  RR )
110 smat.n . . . . . . . . . . . . . . . . . . . . . . . . 25  |-  ( ph  ->  N  e.  NN )
111110nnred 10624 . . . . . . . . . . . . . . . . . . . . . . . 24  |-  ( ph  ->  N  e.  RR )
112111ad3antrrr 736 . . . . . . . . . . . . . . . . . . . . . . 23  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 2nd `  x
)  <  L )  ->  N  e.  RR )
113 simpr 463 . . . . . . . . . . . . . . . . . . . . . . . 24  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 2nd `  x
)  <  L )  ->  ( 2nd `  x
)  <  L )
114107, 109, 113ltled 9783 . . . . . . . . . . . . . . . . . . . . . . 23  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 2nd `  x
)  <  L )  ->  ( 2nd `  x
)  <_  L )
115 elfzle2 11803 . . . . . . . . . . . . . . . . . . . . . . . . 25  |-  ( L  e.  ( 1 ... N )  ->  L  <_  N )
11615, 115syl 17 . . . . . . . . . . . . . . . . . . . . . . . 24  |-  ( ph  ->  L  <_  N )
117116ad3antrrr 736 . . . . . . . . . . . . . . . . . . . . . . 23  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 2nd `  x
)  <  L )  ->  L  <_  N )
118107, 109, 112, 114, 117letrd 9792 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 2nd `  x
)  <  L )  ->  ( 2nd `  x
)  <_  N )
119106, 118jca 535 . . . . . . . . . . . . . . . . . . . . 21  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 2nd `  x
)  <  L )  ->  ( ( 2nd `  x
)  e.  NN  /\  ( 2nd `  x )  <_  N ) )
120110nnzd 11039 . . . . . . . . . . . . . . . . . . . . . . 23  |-  ( ph  ->  N  e.  ZZ )
121 fznn 11863 . . . . . . . . . . . . . . . . . . . . . . 23  |-  ( N  e.  ZZ  ->  (
( 2nd `  x
)  e.  ( 1 ... N )  <->  ( ( 2nd `  x )  e.  NN  /\  ( 2nd `  x )  <_  N
) ) )
122120, 121syl 17 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( ph  ->  ( ( 2nd `  x
)  e.  ( 1 ... N )  <->  ( ( 2nd `  x )  e.  NN  /\  ( 2nd `  x )  <_  N
) ) )
123122ad3antrrr 736 . . . . . . . . . . . . . . . . . . . . 21  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 2nd `  x
)  <  L )  ->  ( ( 2nd `  x
)  e.  ( 1 ... N )  <->  ( ( 2nd `  x )  e.  NN  /\  ( 2nd `  x )  <_  N
) ) )
124119, 123mpbird 236 . . . . . . . . . . . . . . . . . . . 20  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 2nd `  x
)  <  L )  ->  ( 2nd `  x
)  e.  ( 1 ... N ) )
125107, 109, 112, 113, 117ltletrd 9795 . . . . . . . . . . . . . . . . . . . . 21  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 2nd `  x
)  <  L )  ->  ( 2nd `  x
)  <  N )
126110ad3antrrr 736 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 2nd `  x
)  <  L )  ->  N  e.  NN )
127 nnltlem1 11003 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( ( ( 2nd `  x
)  e.  NN  /\  N  e.  NN )  ->  ( ( 2nd `  x
)  <  N  <->  ( 2nd `  x )  <_  ( N  -  1 ) ) )
128106, 126, 127syl2anc 667 . . . . . . . . . . . . . . . . . . . . 21  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 2nd `  x
)  <  L )  ->  ( ( 2nd `  x
)  <  N  <->  ( 2nd `  x )  <_  ( N  -  1 ) ) )
129125, 128mpbid 214 . . . . . . . . . . . . . . . . . . . 20  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 2nd `  x
)  <  L )  ->  ( 2nd `  x
)  <_  ( N  -  1 ) )
130124, 1292thd 244 . . . . . . . . . . . . . . . . . . 19  |-  ( ( ( ( ph  /\  x  =  <. ( 1st `  x ) ,  ( 2nd `  x )
>. )  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( 2nd `  x
)  <  L )  ->  ( ( 2nd `  x
)  e.  ( 1 ... N )  <->  ( 2nd `  x )  <_  ( N  -  1 ) ) )
131130pm5.32da 647 . . . . . . . . . . . . . . . . . 18  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( ( 2nd `  x )  <  L  /\  ( 2nd `  x )  e.  ( 1 ... N
) )  <->  ( ( 2nd `  x )  < 
L  /\  ( 2nd `  x )  <_  ( N  -  1 ) ) ) )
132 fznn 11863 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( N  e.  ZZ  ->  (
( ( 2nd `  x
)  +  1 )  e.  ( 1 ... N )  <->  ( (
( 2nd `  x
)  +  1 )  e.  NN  /\  (
( 2nd `  x
)  +  1 )  <_  N ) ) )
133120, 132syl 17 . . . . . . . . . . . . . . . . . . . . 21  |-  ( ph  ->  ( ( ( 2nd `  x )  +  1 )  e.  ( 1 ... N )  <->  ( (
( 2nd `  x
)  +  1 )  e.  NN  /\  (
( 2nd `  x
)  +  1 )  <_  N ) ) )
134133ad2antrr 732 . . . . . . . . . . . . . . . . . . . 20  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( ( 2nd `  x )  +  1 )  e.  ( 1 ... N
)  <->  ( ( ( 2nd `  x )  +  1 )  e.  NN  /\  ( ( 2nd `  x )  +  1 )  <_  N ) ) )
135 simprr 766 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( 2nd `  x
)  e.  NN )
136135peano2nnd 10626 . . . . . . . . . . . . . . . . . . . . 21  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( 2nd `  x )  +  1 )  e.  NN )
137136biantrurd 511 . . . . . . . . . . . . . . . . . . . 20  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( ( 2nd `  x )  +  1 )  <_  N 
<->  ( ( ( 2nd `  x )  +  1 )  e.  NN  /\  ( ( 2nd `  x
)  +  1 )  <_  N ) ) )
138135nnzd 11039 . . . . . . . . . . . . . . . . . . . . 21  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( 2nd `  x
)  e.  ZZ )
139120ad2antrr 732 . . . . . . . . . . . . . . . . . . . . 21  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  N  e.  ZZ )
140 zltp1le 10986 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( ( ( 2nd `  x
)  e.  ZZ  /\  N  e.  ZZ )  ->  ( ( 2nd `  x
)  <  N  <->  ( ( 2nd `  x )  +  1 )  <_  N
) )
141 zltlem1 10989 . . . . . . . . . . . . . . . . . . . . . 22  |-  ( ( ( 2nd `  x
)  e.  ZZ  /\  N  e.  ZZ )  ->  ( ( 2nd `  x
)  <  N  <->  ( 2nd `  x )  <_  ( N  -  1 ) ) )
142140, 141bitr3d 259 . . . . . . . . . . . . . . . . . . . . 21  |-  ( ( ( 2nd `  x
)  e.  ZZ  /\  N  e.  ZZ )  ->  ( ( ( 2nd `  x )  +  1 )  <_  N  <->  ( 2nd `  x )  <_  ( N  -  1 ) ) )
143138, 139, 142syl2anc 667 . . . . . . . . . . . . . . . . . . . 20  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( ( 2nd `  x )  +  1 )  <_  N 
<->  ( 2nd `  x
)  <_  ( N  -  1 ) ) )
144134, 137, 1433bitr2d 285 . . . . . . . . . . . . . . . . . . 19  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( ( 2nd `  x )  +  1 )  e.  ( 1 ... N
)  <->  ( 2nd `  x
)  <_  ( N  -  1 ) ) )
145144anbi2d 710 . . . . . . . . . . . . . . . . . 18  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( -.  ( 2nd `  x
)  <  L  /\  ( ( 2nd `  x
)  +  1 )  e.  ( 1 ... N ) )  <->  ( -.  ( 2nd `  x )  <  L  /\  ( 2nd `  x )  <_ 
( N  -  1 ) ) ) )
146131, 145orbi12d 716 . . . . . . . . . . . . . . . . 17  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( ( ( 2nd `  x
)  <  L  /\  ( 2nd `  x )  e.  ( 1 ... N ) )  \/  ( -.  ( 2nd `  x )  <  L  /\  ( ( 2nd `  x
)  +  1 )  e.  ( 1 ... N ) ) )  <-> 
( ( ( 2nd `  x )  <  L  /\  ( 2nd `  x
)  <_  ( N  -  1 ) )  \/  ( -.  ( 2nd `  x )  < 
L  /\  ( 2nd `  x )  <_  ( N  -  1 ) ) ) ) )
147 pm4.42 971 . . . . . . . . . . . . . . . . . 18  |-  ( ( 2nd `  x )  <_  ( N  - 
1 )  <->  ( (
( 2nd `  x
)  <_  ( N  -  1 )  /\  ( 2nd `  x )  <  L )  \/  ( ( 2nd `  x
)  <_  ( N  -  1 )  /\  -.  ( 2nd `  x
)  <  L )
) )
148 ancom 452 . . . . . . . . . . . . . . . . . . 19  |-  ( ( ( 2nd `  x
)  <_  ( N  -  1 )  /\  ( 2nd `  x )  <  L )  <->  ( ( 2nd `  x )  < 
L  /\  ( 2nd `  x )  <_  ( N  -  1 ) ) )
149 ancom 452 . . . . . . . . . . . . . . . . . . 19  |-  ( ( ( 2nd `  x
)  <_  ( N  -  1 )  /\  -.  ( 2nd `  x
)  <  L )  <->  ( -.  ( 2nd `  x
)  <  L  /\  ( 2nd `  x )  <_  ( N  - 
1 ) ) )
150148, 149orbi12i 524 . . . . . . . . . . . . . . . . . 18  |-  ( ( ( ( 2nd `  x
)  <_  ( N  -  1 )  /\  ( 2nd `  x )  <  L )  \/  ( ( 2nd `  x
)  <_  ( N  -  1 )  /\  -.  ( 2nd `  x
)  <  L )
)  <->  ( ( ( 2nd `  x )  <  L  /\  ( 2nd `  x )  <_ 
( N  -  1 ) )  \/  ( -.  ( 2nd `  x
)  <  L  /\  ( 2nd `  x )  <_  ( N  - 
1 ) ) ) )
151147, 150bitri 253 . . . . . . . . . . . . . . . . 17  |-  ( ( 2nd `  x )  <_  ( N  - 
1 )  <->  ( (
( 2nd `  x
)  <  L  /\  ( 2nd `  x )  <_  ( N  - 
1 ) )  \/  ( -.  ( 2nd `  x )  <  L  /\  ( 2nd `  x
)  <_  ( N  -  1 ) ) ) )
152146, 151syl6bbr 267 . . . . . . . . . . . . . . . 16  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( ( ( 2nd `  x
)  <  L  /\  ( 2nd `  x )  e.  ( 1 ... N ) )  \/  ( -.  ( 2nd `  x )  <  L  /\  ( ( 2nd `  x
)  +  1 )  e.  ( 1 ... N ) ) )  <-> 
( 2nd `  x
)  <_  ( N  -  1 ) ) )
153105, 152syl5bb 261 . . . . . . . . . . . . . . 15  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( if ( ( 2nd `  x
)  <  L , 
( 2nd `  x
) ,  ( ( 2nd `  x )  +  1 ) )  e.  ( 1 ... N )  <->  ( 2nd `  x )  <_  ( N  -  1 ) ) )
154104, 153anbi12d 717 . . . . . . . . . . . . . 14  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( if ( ( 1st `  x
)  <  K , 
( 1st `  x
) ,  ( ( 1st `  x )  +  1 ) )  e.  ( 1 ... M )  /\  if ( ( 2nd `  x
)  <  L , 
( 2nd `  x
) ,  ( ( 2nd `  x )  +  1 ) )  e.  ( 1 ... N ) )  <->  ( ( 1st `  x )  <_ 
( M  -  1 )  /\  ( 2nd `  x )  <_  ( N  -  1 ) ) ) )
15555, 154bitrd 257 . . . . . . . . . . . . 13  |-  ( ( ( ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  /\  ( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  ->  ( ( ( i  e.  NN , 
j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L , 
j ,  ( j  +  1 ) )
>. ) `  x )  e.  ( ( 1 ... M )  X.  ( 1 ... N
) )  <->  ( ( 1st `  x )  <_ 
( M  -  1 )  /\  ( 2nd `  x )  <_  ( N  -  1 ) ) ) )
156155pm5.32da 647 . . . . . . . . . . . 12  |-  ( (
ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  ->  ( ( ( ( 1st `  x )  e.  NN  /\  ( 2nd `  x )  e.  NN )  /\  (
( i  e.  NN ,  j  e.  NN  |->  <. if ( i  < 
K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >. ) `  x
)  e.  ( ( 1 ... M )  X.  ( 1 ... N ) ) )  <-> 
( ( ( 1st `  x )  e.  NN  /\  ( 2nd `  x
)  e.  NN )  /\  ( ( 1st `  x )  <_  ( M  -  1 )  /\  ( 2nd `  x
)  <_  ( N  -  1 ) ) ) ) )
157 1zzd 10968 . . . . . . . . . . . . . . . . 17  |-  ( ph  ->  1  e.  ZZ )
15871, 157zsubcld 11045 . . . . . . . . . . . . . . . 16  |-  ( ph  ->  ( M  -  1 )  e.  ZZ )
159 fznn 11863 . . . . . . . . . . . . . . . 16  |-  ( ( M  -  1 )  e.  ZZ  ->  (
( 1st `  x
)  e.  ( 1 ... ( M  - 
1 ) )  <->  ( ( 1st `  x )  e.  NN  /\  ( 1st `  x )  <_  ( M  -  1 ) ) ) )
160158, 159syl 17 . . . . . . . . . . . . . . 15  |-  ( ph  ->  ( ( 1st `  x
)  e.  ( 1 ... ( M  - 
1 ) )  <->  ( ( 1st `  x )  e.  NN  /\  ( 1st `  x )  <_  ( M  -  1 ) ) ) )
161120, 157zsubcld 11045 . . . . . . . . . . . . . . . 16  |-  ( ph  ->  ( N  -  1 )  e.  ZZ )
162 fznn 11863 . . . . . . . . . . . . . . . 16  |-  ( ( N  -  1 )  e.  ZZ  ->  (
( 2nd `  x
)  e.  ( 1 ... ( N  - 
1 ) )  <->  ( ( 2nd `  x )  e.  NN  /\  ( 2nd `  x )  <_  ( N  -  1 ) ) ) )
163161, 162syl 17 . . . . . . . . . . . . . . 15  |-  ( ph  ->  ( ( 2nd `  x
)  e.  ( 1 ... ( N  - 
1 ) )  <->  ( ( 2nd `  x )  e.  NN  /\  ( 2nd `  x )  <_  ( N  -  1 ) ) ) )
164160, 163anbi12d 717 . . . . . . . . . . . . . 14  |-  ( ph  ->  ( ( ( 1st `  x )  e.  ( 1 ... ( M  -  1 ) )  /\  ( 2nd `  x
)  e.  ( 1 ... ( N  - 
1 ) ) )  <-> 
( ( ( 1st `  x )  e.  NN  /\  ( 1st `  x
)  <_  ( M  -  1 ) )  /\  ( ( 2nd `  x )  e.  NN  /\  ( 2nd `  x
)  <_  ( N  -  1 ) ) ) ) )
165 an4 833 . . . . . . . . . . . . . 14  |-  ( ( ( ( 1st `  x
)  e.  NN  /\  ( 1st `  x )  <_  ( M  - 
1 ) )  /\  ( ( 2nd `  x
)  e.  NN  /\  ( 2nd `  x )  <_  ( N  - 
1 ) ) )  <-> 
( ( ( 1st `  x )  e.  NN  /\  ( 2nd `  x
)  e.  NN )  /\  ( ( 1st `  x )  <_  ( M  -  1 )  /\  ( 2nd `  x
)  <_  ( N  -  1 ) ) ) )
166164, 165syl6bb 265 . . . . . . . . . . . . 13  |-  ( ph  ->  ( ( ( 1st `  x )  e.  ( 1 ... ( M  -  1 ) )  /\  ( 2nd `  x
)  e.  ( 1 ... ( N  - 
1 ) ) )  <-> 
( ( ( 1st `  x )  e.  NN  /\  ( 2nd `  x
)  e.  NN )  /\  ( ( 1st `  x )  <_  ( M  -  1 )  /\  ( 2nd `  x
)  <_  ( N  -  1 ) ) ) ) )
167166adantr 467 . . . . . . . . . . . 12  |-  ( (
ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  ->  ( ( ( 1st `  x )  e.  ( 1 ... ( M  -  1 ) )  /\  ( 2nd `  x
)  e.  ( 1 ... ( N  - 
1 ) ) )  <-> 
( ( ( 1st `  x )  e.  NN  /\  ( 2nd `  x
)  e.  NN )  /\  ( ( 1st `  x )  <_  ( M  -  1 )  /\  ( 2nd `  x
)  <_  ( N  -  1 ) ) ) ) )
168156, 167bitr4d 260 . . . . . . . . . . 11  |-  ( (
ph  /\  x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >. )  ->  ( ( ( ( 1st `  x )  e.  NN  /\  ( 2nd `  x )  e.  NN )  /\  (
( i  e.  NN ,  j  e.  NN  |->  <. if ( i  < 
K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >. ) `  x
)  e.  ( ( 1 ... M )  X.  ( 1 ... N ) ) )  <-> 
( ( 1st `  x
)  e.  ( 1 ... ( M  - 
1 ) )  /\  ( 2nd `  x )  e.  ( 1 ... ( N  -  1 ) ) ) ) )
169168pm5.32da 647 . . . . . . . . . 10  |-  ( ph  ->  ( ( x  = 
<. ( 1st `  x
) ,  ( 2nd `  x ) >.  /\  (
( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN )  /\  ( ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  < 
L ,  j ,  ( j  +  1 ) ) >. ) `  x )  e.  ( ( 1 ... M
)  X.  ( 1 ... N ) ) ) )  <->  ( x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >.  /\  (
( 1st `  x
)  e.  ( 1 ... ( M  - 
1 ) )  /\  ( 2nd `  x )  e.  ( 1 ... ( N  -  1 ) ) ) ) ) )
170 elxp6 6825 . . . . . . . . . . . 12  |-  ( x  e.  ( NN  X.  NN )  <->  ( x  = 
<. ( 1st `  x
) ,  ( 2nd `  x ) >.  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) ) )
171170anbi1i 701 . . . . . . . . . . 11  |-  ( ( x  e.  ( NN 
X.  NN )  /\  ( ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  < 
L ,  j ,  ( j  +  1 ) ) >. ) `  x )  e.  ( ( 1 ... M
)  X.  ( 1 ... N ) ) )  <->  ( ( x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >.  /\  (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  ( ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.
) `  x )  e.  ( ( 1 ... M )  X.  (
1 ... N ) ) ) )
172 anass 655 . . . . . . . . . . 11  |-  ( ( ( x  =  <. ( 1st `  x ) ,  ( 2nd `  x
) >.  /\  ( ( 1st `  x )  e.  NN  /\  ( 2nd `  x )  e.  NN ) )  /\  (
( i  e.  NN ,  j  e.  NN  |->  <. if ( i  < 
K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >. ) `  x
)  e.  ( ( 1 ... M )  X.  ( 1 ... N ) ) )  <-> 
( x  =  <. ( 1st `  x ) ,  ( 2nd `  x
) >.  /\  ( (
( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN )  /\  ( ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  < 
L ,  j ,  ( j  +  1 ) ) >. ) `  x )  e.  ( ( 1 ... M
)  X.  ( 1 ... N ) ) ) ) )
173171, 172bitri 253 . . . . . . . . . 10  |-  ( ( x  e.  ( NN 
X.  NN )  /\  ( ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  < 
L ,  j ,  ( j  +  1 ) ) >. ) `  x )  e.  ( ( 1 ... M
)  X.  ( 1 ... N ) ) )  <->  ( x  = 
<. ( 1st `  x
) ,  ( 2nd `  x ) >.  /\  (
( ( 1st `  x
)  e.  NN  /\  ( 2nd `  x )  e.  NN )  /\  ( ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  < 
L ,  j ,  ( j  +  1 ) ) >. ) `  x )  e.  ( ( 1 ... M
)  X.  ( 1 ... N ) ) ) ) )
174 elxp6 6825 . . . . . . . . . 10  |-  ( x  e.  ( ( 1 ... ( M  - 
1 ) )  X.  ( 1 ... ( N  -  1 ) ) )  <->  ( x  =  <. ( 1st `  x
) ,  ( 2nd `  x ) >.  /\  (
( 1st `  x
)  e.  ( 1 ... ( M  - 
1 ) )  /\  ( 2nd `  x )  e.  ( 1 ... ( N  -  1 ) ) ) ) )
175169, 173, 1743bitr4g 292 . . . . . . . . 9  |-  ( ph  ->  ( ( x  e.  ( NN  X.  NN )  /\  ( ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.
) `  x )  e.  ( ( 1 ... M )  X.  (
1 ... N ) ) )  <->  x  e.  (
( 1 ... ( M  -  1 ) )  X.  ( 1 ... ( N  - 
1 ) ) ) ) )
17629, 34, 1753bitrd 283 . . . . . . . 8  |-  ( ph  ->  ( x  e.  ( `' ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  < 
L ,  j ,  ( j  +  1 ) ) >. ) " dom  A )  <->  x  e.  ( ( 1 ... ( M  -  1 ) )  X.  (
1 ... ( N  - 
1 ) ) ) ) )
177176eqrdv 2449 . . . . . . 7  |-  ( ph  ->  ( `' ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K , 
i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >.
) " dom  A
)  =  ( ( 1 ... ( M  -  1 ) )  X.  ( 1 ... ( N  -  1 ) ) ) )
17825, 177syl5eq 2497 . . . . . 6  |-  ( ph  ->  dom  ( A  o.  ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  < 
K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L ,  j ,  ( j  +  1 ) ) >. ) )  =  ( ( 1 ... ( M  -  1 ) )  X.  (
1 ... ( N  - 
1 ) ) ) )
17924, 178eqtrd 2485 . . . . 5  |-  ( ph  ->  dom  S  =  ( ( 1 ... ( M  -  1 ) )  X.  ( 1 ... ( N  - 
1 ) ) ) )
180179feq2d 5715 . . . 4  |-  ( ph  ->  ( S : dom  S --> ran  S  <->  S :
( ( 1 ... ( M  -  1 ) )  X.  (
1 ... ( N  - 
1 ) ) ) --> ran  S ) )
18123, 180mpbid 214 . . 3  |-  ( ph  ->  S : ( ( 1 ... ( M  -  1 ) )  X.  ( 1 ... ( N  -  1 ) ) ) --> ran 
S )
18219rneqd 5062 . . . . 5  |-  ( ph  ->  ran  S  =  ran  ( A  o.  (
i  e.  NN , 
j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  <  L , 
j ,  ( j  +  1 ) )
>. ) ) )
183 rncoss 5095 . . . . 5  |-  ran  ( A  o.  ( i  e.  NN ,  j  e.  NN  |->  <. if ( i  <  K ,  i ,  ( i  +  1 ) ) ,  if ( j  < 
L ,  j ,  ( j  +  1 ) ) >. )
)  C_  ran  A
184182, 183syl6eqss 3482 . . . 4  |-  ( ph  ->  ran  S  C_  ran  A )
185 frn 5735 . . . . 5  |-  ( A : ( ( 1 ... M )  X.  ( 1 ... N
) ) --> B  ->  ran  A  C_  B )
1861, 2, 1853syl 18 . . . 4  |-  ( ph  ->  ran  A  C_  B
)
187184, 186sstrd 3442 . . 3  |-  ( ph  ->  ran  S  C_  B
)
188 fss 5737 . . 3  |-  ( ( S : ( ( 1 ... ( M  -  1 ) )  X.  ( 1 ... ( N  -  1 ) ) ) --> ran 
S  /\  ran  S  C_  B )  ->  S : ( ( 1 ... ( M  - 
1 ) )  X.  ( 1 ... ( N  -  1 ) ) ) --> B )
189181, 187, 188syl2anc 667 . 2  |-  ( ph  ->  S : ( ( 1 ... ( M  -  1 ) )  X.  ( 1 ... ( N  -  1 ) ) ) --> B )
190 reldmmap 7481 . . . . . 6  |-  Rel  dom  ^m
191190ovrcl 6323 . . . . 5  |-  ( A  e.  ( B  ^m  ( ( 1 ... M )  X.  (
1 ... N ) ) )  ->  ( B  e.  _V  /\  ( ( 1 ... M )  X.  ( 1 ... N ) )  e. 
_V ) )
1921, 191syl 17 . . . 4  |-  ( ph  ->  ( B  e.  _V  /\  ( ( 1 ... M )  X.  (
1 ... N ) )  e.  _V ) )
193192simpld 461 . . 3  |-  ( ph  ->  B  e.  _V )
194 ovex 6318 . . . 4  |-  ( 1 ... ( M  - 
1 ) )  e. 
_V
195 ovex 6318 . . . 4  |-  ( 1 ... ( N  - 
1 ) )  e. 
_V
196194, 195xpex 6595 . . 3  |-  ( ( 1 ... ( M  -  1 ) )  X.  ( 1 ... ( N  -  1 ) ) )  e. 
_V
197 elmapg 7485 . . 3  |-  ( ( B  e.  _V  /\  ( ( 1 ... ( M  -  1 ) )  X.  (
1 ... ( N  - 
1 ) ) )  e.  _V )  -> 
( S  e.  ( B  ^m  ( ( 1 ... ( M  -  1 ) )  X.  ( 1 ... ( N  -  1 ) ) ) )  <-> 
S : ( ( 1 ... ( M  -  1 ) )  X.  ( 1 ... ( N  -  1 ) ) ) --> B ) )
198193, 196, 197sylancl 668 . 2  |-  ( ph  ->  ( S  e.  ( B  ^m  ( ( 1 ... ( M  -  1 ) )  X.  ( 1 ... ( N  -  1 ) ) ) )  <-> 
S : ( ( 1 ... ( M  -  1 ) )  X.  ( 1 ... ( N  -  1 ) ) ) --> B ) )
199189, 198mpbird 236 1  |-  ( ph  ->  S  e.  ( B  ^m  ( ( 1 ... ( M  - 
1 ) )  X.  ( 1 ... ( N  -  1 ) ) ) ) )
Colors of variables: wff setvar class
Syntax hints:   -. wn 3    -> wi 4    <-> wb 188    \/ wo 370    /\ wa 371    = wceq 1444    e. wcel 1887   _Vcvv 3045    C_ wss 3404   ifcif 3881   <.cop 3974   class class class wbr 4402    X. cxp 4832   `'ccnv 4833   dom cdm 4834   ran crn 4835   "cima 4837    o. ccom 4838   Fun wfun 5576    Fn wfn 5577   -->wf 5578   ` cfv 5582  (class class class)co 6290    |-> cmpt2 6292   1stc1st 6791   2ndc2nd 6792    ^m cmap 7472   RRcr 9538   1c1 9540    + caddc 9542    < clt 9675    <_ cle 9676    - cmin 9860   NNcn 10609   ZZcz 10937   ...cfz 11784  subMat1csmat 28619
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1669  ax-4 1682  ax-5 1758  ax-6 1805  ax-7 1851  ax-8 1889  ax-9 1896  ax-10 1915  ax-11 1920  ax-12 1933  ax-13 2091  ax-ext 2431  ax-rep 4515  ax-sep 4525  ax-nul 4534  ax-pow 4581  ax-pr 4639  ax-un 6583  ax-cnex 9595  ax-resscn 9596  ax-1cn 9597  ax-icn 9598  ax-addcl 9599  ax-addrcl 9600  ax-mulcl 9601  ax-mulrcl 9602  ax-mulcom 9603  ax-addass 9604  ax-mulass 9605  ax-distr 9606  ax-i2m1 9607  ax-1ne0 9608  ax-1rid 9609  ax-rnegex 9610  ax-rrecex 9611  ax-cnre 9612  ax-pre-lttri 9613  ax-pre-lttrn 9614  ax-pre-ltadd 9615  ax-pre-mulgt0 9616
This theorem depends on definitions:  df-bi 189  df-or 372  df-an 373  df-3or 986  df-3an 987  df-tru 1447  df-ex 1664  df-nf 1668  df-sb 1798  df-eu 2303  df-mo 2304  df-clab 2438  df-cleq 2444  df-clel 2447  df-nfc 2581  df-ne 2624  df-nel 2625  df-ral 2742  df-rex 2743  df-reu 2744  df-rab 2746  df-v 3047  df-sbc 3268  df-csb 3364  df-dif 3407  df-un 3409  df-in 3411  df-ss 3418  df-pss 3420  df-nul 3732  df-if 3882  df-pw 3953  df-sn 3969  df-pr 3971  df-tp 3973  df-op 3975  df-uni 4199  df-iun 4280  df-br 4403  df-opab 4462  df-mpt 4463  df-tr 4498  df-eprel 4745  df-id 4749  df-po 4755  df-so 4756  df-fr 4793  df-we 4795  df-xp 4840  df-rel 4841  df-cnv 4842  df-co 4843  df-dm 4844  df-rn 4845  df-res 4846  df-ima 4847  df-pred 5380  df-ord 5426  df-on 5427  df-lim 5428  df-suc 5429  df-iota 5546  df-fun 5584  df-fn 5585  df-f 5586  df-f1 5587  df-fo 5588  df-f1o 5589  df-fv 5590  df-riota 6252  df-ov 6293  df-oprab 6294  df-mpt2 6295  df-om 6693  df-1st 6793  df-2nd 6794  df-wrecs 7028  df-recs 7090  df-rdg 7128  df-er 7363  df-map 7474  df-en 7570  df-dom 7571  df-sdom 7572  df-pnf 9677  df-mnf 9678  df-xr 9679  df-ltxr 9680  df-le 9681  df-sub 9862  df-neg 9863  df-nn 10610  df-n0 10870  df-z 10938  df-uz 11160  df-fz 11785  df-smat 28620
This theorem is referenced by:  smatcl  28628  1smat1  28630
  Copyright terms: Public domain W3C validator