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

Theorem hof2fval 14045
Description: The morphism part of the Hom functor, for morphisms  <. f ,  g >. : <. X ,  Y >. --> <. Z ,  W >. (which since the first argument is contravariant means morphisms  f : Z --> X and  g : Y --> W), yields a function (a morphism of  SetCat) mapping  h : X --> Y to  g  o.  h  o.  f : Z --> W. (Contributed by Mario Carneiro, 15-Jan-2017.)
Hypotheses
Ref Expression
hofval.m  |-  M  =  (HomF
`  C )
hofval.c  |-  ( ph  ->  C  e.  Cat )
hof1.b  |-  B  =  ( Base `  C
)
hof1.h  |-  H  =  (  Hom  `  C
)
hof1.x  |-  ( ph  ->  X  e.  B )
hof1.y  |-  ( ph  ->  Y  e.  B )
hof2.z  |-  ( ph  ->  Z  e.  B )
hof2.w  |-  ( ph  ->  W  e.  B )
hof2.o  |-  .x.  =  (comp `  C )
Assertion
Ref Expression
hof2fval  |-  ( ph  ->  ( <. X ,  Y >. ( 2nd `  M
) <. Z ,  W >. )  =  ( f  e.  ( Z H X ) ,  g  e.  ( Y H W )  |->  ( h  e.  ( X H Y )  |->  ( ( g ( <. X ,  Y >.  .x.  W )
h ) ( <. Z ,  X >.  .x. 
W ) f ) ) ) )
Distinct variable groups:    f, g, h, B    ph, f, g, h    C, f, g, h   
f, H, g, h   
f, W, g, h    .x. , f, g, h    f, X, g, h    f, Y, g, h    f, Z, g, h
Allowed substitution hints:    M( f, g, h)

Proof of Theorem hof2fval
Dummy variables  x  y are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 hofval.m . . . 4  |-  M  =  (HomF
`  C )
2 hofval.c . . . 4  |-  ( ph  ->  C  e.  Cat )
3 hof1.b . . . 4  |-  B  =  ( Base `  C
)
4 hof1.h . . . 4  |-  H  =  (  Hom  `  C
)
5 hof2.o . . . 4  |-  .x.  =  (comp `  C )
61, 2, 3, 4, 5hofval 14042 . . 3  |-  ( ph  ->  M  =  <. (  Homf  `  C ) ,  ( x  e.  ( B  X.  B ) ,  y  e.  ( B  X.  B )  |->  ( f  e.  ( ( 1st `  y ) H ( 1st `  x
) ) ,  g  e.  ( ( 2nd `  x ) H ( 2nd `  y ) )  |->  ( h  e.  ( H `  x
)  |->  ( ( g ( x  .x.  ( 2nd `  y ) ) h ) ( <.
( 1st `  y
) ,  ( 1st `  x ) >.  .x.  ( 2nd `  y ) ) f ) ) ) ) >. )
7 fvex 5555 . . . 4  |-  (  Homf  `  C )  e.  _V
8 fvex 5555 . . . . . . 7  |-  ( Base `  C )  e.  _V
93, 8eqeltri 2366 . . . . . 6  |-  B  e. 
_V
109, 9xpex 4817 . . . . 5  |-  ( B  X.  B )  e. 
_V
1110, 10mpt2ex 6214 . . . 4  |-  ( x  e.  ( B  X.  B ) ,  y  e.  ( B  X.  B )  |->  ( f  e.  ( ( 1st `  y ) H ( 1st `  x ) ) ,  g  e.  ( ( 2nd `  x
) H ( 2nd `  y ) )  |->  ( h  e.  ( H `
 x )  |->  ( ( g ( x 
.x.  ( 2nd `  y
) ) h ) ( <. ( 1st `  y
) ,  ( 1st `  x ) >.  .x.  ( 2nd `  y ) ) f ) ) ) )  e.  _V
127, 11op2ndd 6147 . . 3  |-  ( M  =  <. (  Homf  `  C ) ,  ( x  e.  ( B  X.  B
) ,  y  e.  ( B  X.  B
)  |->  ( f  e.  ( ( 1st `  y
) H ( 1st `  x ) ) ,  g  e.  ( ( 2nd `  x ) H ( 2nd `  y
) )  |->  ( h  e.  ( H `  x )  |->  ( ( g ( x  .x.  ( 2nd `  y ) ) h ) (
<. ( 1st `  y
) ,  ( 1st `  x ) >.  .x.  ( 2nd `  y ) ) f ) ) ) ) >.  ->  ( 2nd `  M )  =  ( x  e.  ( B  X.  B ) ,  y  e.  ( B  X.  B )  |->  ( f  e.  ( ( 1st `  y ) H ( 1st `  x
) ) ,  g  e.  ( ( 2nd `  x ) H ( 2nd `  y ) )  |->  ( h  e.  ( H `  x
)  |->  ( ( g ( x  .x.  ( 2nd `  y ) ) h ) ( <.
( 1st `  y
) ,  ( 1st `  x ) >.  .x.  ( 2nd `  y ) ) f ) ) ) ) )
136, 12syl 15 . 2  |-  ( ph  ->  ( 2nd `  M
)  =  ( x  e.  ( B  X.  B ) ,  y  e.  ( B  X.  B )  |->  ( f  e.  ( ( 1st `  y ) H ( 1st `  x ) ) ,  g  e.  ( ( 2nd `  x
) H ( 2nd `  y ) )  |->  ( h  e.  ( H `
 x )  |->  ( ( g ( x 
.x.  ( 2nd `  y
) ) h ) ( <. ( 1st `  y
) ,  ( 1st `  x ) >.  .x.  ( 2nd `  y ) ) f ) ) ) ) )
14 simprr 733 . . . . . 6  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  y  =  <. Z ,  W >. )
1514fveq2d 5545 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 1st `  y )  =  ( 1st `  <. Z ,  W >. ) )
16 hof2.z . . . . . . 7  |-  ( ph  ->  Z  e.  B )
17 hof2.w . . . . . . 7  |-  ( ph  ->  W  e.  B )
18 op1stg 6148 . . . . . . 7  |-  ( ( Z  e.  B  /\  W  e.  B )  ->  ( 1st `  <. Z ,  W >. )  =  Z )
1916, 17, 18syl2anc 642 . . . . . 6  |-  ( ph  ->  ( 1st `  <. Z ,  W >. )  =  Z )
2019adantr 451 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 1st ` 
<. Z ,  W >. )  =  Z )
2115, 20eqtrd 2328 . . . 4  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 1st `  y )  =  Z )
22 simprl 732 . . . . . 6  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  x  =  <. X ,  Y >. )
2322fveq2d 5545 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 1st `  x )  =  ( 1st `  <. X ,  Y >. ) )
24 hof1.x . . . . . . 7  |-  ( ph  ->  X  e.  B )
25 hof1.y . . . . . . 7  |-  ( ph  ->  Y  e.  B )
26 op1stg 6148 . . . . . . 7  |-  ( ( X  e.  B  /\  Y  e.  B )  ->  ( 1st `  <. X ,  Y >. )  =  X )
2724, 25, 26syl2anc 642 . . . . . 6  |-  ( ph  ->  ( 1st `  <. X ,  Y >. )  =  X )
2827adantr 451 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 1st ` 
<. X ,  Y >. )  =  X )
2923, 28eqtrd 2328 . . . 4  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 1st `  x )  =  X )
3021, 29oveq12d 5892 . . 3  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( ( 1st `  y ) H ( 1st `  x
) )  =  ( Z H X ) )
3122fveq2d 5545 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 2nd `  x )  =  ( 2nd `  <. X ,  Y >. ) )
32 op2ndg 6149 . . . . . . 7  |-  ( ( X  e.  B  /\  Y  e.  B )  ->  ( 2nd `  <. X ,  Y >. )  =  Y )
3324, 25, 32syl2anc 642 . . . . . 6  |-  ( ph  ->  ( 2nd `  <. X ,  Y >. )  =  Y )
3433adantr 451 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 2nd ` 
<. X ,  Y >. )  =  Y )
3531, 34eqtrd 2328 . . . 4  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 2nd `  x )  =  Y )
3614fveq2d 5545 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 2nd `  y )  =  ( 2nd `  <. Z ,  W >. ) )
37 op2ndg 6149 . . . . . . 7  |-  ( ( Z  e.  B  /\  W  e.  B )  ->  ( 2nd `  <. Z ,  W >. )  =  W )
3816, 17, 37syl2anc 642 . . . . . 6  |-  ( ph  ->  ( 2nd `  <. Z ,  W >. )  =  W )
3938adantr 451 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 2nd ` 
<. Z ,  W >. )  =  W )
4036, 39eqtrd 2328 . . . 4  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 2nd `  y )  =  W )
4135, 40oveq12d 5892 . . 3  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( ( 2nd `  x ) H ( 2nd `  y
) )  =  ( Y H W ) )
4222fveq2d 5545 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( H `  x )  =  ( H `  <. X ,  Y >. ) )
43 df-ov 5877 . . . . 5  |-  ( X H Y )  =  ( H `  <. X ,  Y >. )
4442, 43syl6eqr 2346 . . . 4  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( H `  x )  =  ( X H Y ) )
4521, 29opeq12d 3820 . . . . . 6  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  <. ( 1st `  y ) ,  ( 1st `  x )
>.  =  <. Z ,  X >. )
4645, 40oveq12d 5892 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( <. ( 1st `  y ) ,  ( 1st `  x
) >.  .x.  ( 2nd `  y ) )  =  ( <. Z ,  X >.  .x.  W ) )
4722, 40oveq12d 5892 . . . . . 6  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( x  .x.  ( 2nd `  y
) )  =  (
<. X ,  Y >.  .x. 
W ) )
4847oveqd 5891 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( g
( x  .x.  ( 2nd `  y ) ) h )  =  ( g ( <. X ,  Y >.  .x.  W )
h ) )
49 eqidd 2297 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  f  =  f )
5046, 48, 49oveq123d 5895 . . . 4  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( (
g ( x  .x.  ( 2nd `  y ) ) h ) (
<. ( 1st `  y
) ,  ( 1st `  x ) >.  .x.  ( 2nd `  y ) ) f )  =  ( ( g ( <. X ,  Y >.  .x. 
W ) h ) ( <. Z ,  X >.  .x.  W ) f ) )
5144, 50mpteq12dv 4114 . . 3  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( h  e.  ( H `  x
)  |->  ( ( g ( x  .x.  ( 2nd `  y ) ) h ) ( <.
( 1st `  y
) ,  ( 1st `  x ) >.  .x.  ( 2nd `  y ) ) f ) )  =  ( h  e.  ( X H Y ) 
|->  ( ( g (
<. X ,  Y >.  .x. 
W ) h ) ( <. Z ,  X >.  .x.  W ) f ) ) )
5230, 41, 51mpt2eq123dv 5926 . 2  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( f  e.  ( ( 1st `  y
) H ( 1st `  x ) ) ,  g  e.  ( ( 2nd `  x ) H ( 2nd `  y
) )  |->  ( h  e.  ( H `  x )  |->  ( ( g ( x  .x.  ( 2nd `  y ) ) h ) (
<. ( 1st `  y
) ,  ( 1st `  x ) >.  .x.  ( 2nd `  y ) ) f ) ) )  =  ( f  e.  ( Z H X ) ,  g  e.  ( Y H W )  |->  ( h  e.  ( X H Y )  |->  ( ( g ( <. X ,  Y >.  .x.  W ) h ) ( <. Z ,  X >.  .x.  W )
f ) ) ) )
53 opelxpi 4737 . . 3  |-  ( ( X  e.  B  /\  Y  e.  B )  -> 
<. X ,  Y >.  e.  ( B  X.  B
) )
5424, 25, 53syl2anc 642 . 2  |-  ( ph  -> 
<. X ,  Y >.  e.  ( B  X.  B
) )
55 opelxpi 4737 . . 3  |-  ( ( Z  e.  B  /\  W  e.  B )  -> 
<. Z ,  W >.  e.  ( B  X.  B
) )
5616, 17, 55syl2anc 642 . 2  |-  ( ph  -> 
<. Z ,  W >.  e.  ( B  X.  B
) )
57 ovex 5899 . . . 4  |-  ( Z H X )  e. 
_V
58 ovex 5899 . . . 4  |-  ( Y H W )  e. 
_V
5957, 58mpt2ex 6214 . . 3  |-  ( f  e.  ( Z H X ) ,  g  e.  ( Y H W )  |->  ( h  e.  ( X H Y )  |->  ( ( g ( <. X ,  Y >.  .x.  W )
h ) ( <. Z ,  X >.  .x. 
W ) f ) ) )  e.  _V
6059a1i 10 . 2  |-  ( ph  ->  ( f  e.  ( Z H X ) ,  g  e.  ( Y H W ) 
|->  ( h  e.  ( X H Y ) 
|->  ( ( g (
<. X ,  Y >.  .x. 
W ) h ) ( <. Z ,  X >.  .x.  W ) f ) ) )  e. 
_V )
6113, 52, 54, 56, 60ovmpt2d 5991 1  |-  ( ph  ->  ( <. X ,  Y >. ( 2nd `  M
) <. Z ,  W >. )  =  ( f  e.  ( Z H X ) ,  g  e.  ( Y H W )  |->  ( h  e.  ( X H Y )  |->  ( ( g ( <. X ,  Y >.  .x.  W )
h ) ( <. Z ,  X >.  .x. 
W ) f ) ) ) )
Colors of variables: wff set class
Syntax hints:    -> wi 4    /\ wa 358    = wceq 1632    e. wcel 1696   _Vcvv 2801   <.cop 3656    e. cmpt 4093    X. cxp 4703   ` cfv 5271  (class class class)co 5874    e. cmpt2 5876   1stc1st 6136   2ndc2nd 6137   Basecbs 13164    Hom chom 13235  compcco 13236   Catccat 13582    Homf chomf 13584  HomFchof 14038
This theorem is referenced by:  hof2val  14046
This theorem was proved from axioms:  ax-1 5  ax-2 6  ax-3 7  ax-mp 8  ax-gen 1536  ax-5 1547  ax-17 1606  ax-9 1644  ax-8 1661  ax-13 1698  ax-14 1700  ax-6 1715  ax-7 1720  ax-11 1727  ax-12 1878  ax-ext 2277  ax-rep 4147  ax-sep 4157  ax-nul 4165  ax-pow 4204  ax-pr 4230  ax-un 4528
This theorem depends on definitions:  df-bi 177  df-or 359  df-an 360  df-3an 936  df-tru 1310  df-ex 1532  df-nf 1535  df-sb 1639  df-eu 2160  df-mo 2161  df-clab 2283  df-cleq 2289  df-clel 2292  df-nfc 2421  df-ne 2461  df-ral 2561  df-rex 2562  df-reu 2563  df-rab 2565  df-v 2803  df-sbc 3005  df-csb 3095  df-dif 3168  df-un 3170  df-in 3172  df-ss 3179  df-nul 3469  df-if 3579  df-pw 3640  df-sn 3659  df-pr 3660  df-op 3662  df-uni 3844  df-iun 3923  df-br 4040  df-opab 4094  df-mpt 4095  df-id 4325  df-xp 4711  df-rel 4712  df-cnv 4713  df-co 4714  df-dm 4715  df-rn 4716  df-res 4717  df-ima 4718  df-iota 5235  df-fun 5273  df-fn 5274  df-f 5275  df-f1 5276  df-fo 5277  df-f1o 5278  df-fv 5279  df-ov 5877  df-oprab 5878  df-mpt2 5879  df-1st 6138  df-2nd 6139  df-hof 14040
  Copyright terms: Public domain W3C validator