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

Theorem hof2fval 14344
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 14341 . . 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 5734 . . . 4  |-  (  Homf  `  C )  e.  _V
8 fvex 5734 . . . . . . 7  |-  ( Base `  C )  e.  _V
93, 8eqeltri 2505 . . . . . 6  |-  B  e. 
_V
109, 9xpex 4982 . . . . 5  |-  ( B  X.  B )  e. 
_V
1110, 10mpt2ex 6417 . . . 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 6350 . . 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 16 . 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 734 . . . . . 6  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  y  =  <. Z ,  W >. )
1514fveq2d 5724 . . . . 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 6351 . . . . . . 7  |-  ( ( Z  e.  B  /\  W  e.  B )  ->  ( 1st `  <. Z ,  W >. )  =  Z )
1916, 17, 18syl2anc 643 . . . . . 6  |-  ( ph  ->  ( 1st `  <. Z ,  W >. )  =  Z )
2019adantr 452 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 1st ` 
<. Z ,  W >. )  =  Z )
2115, 20eqtrd 2467 . . . 4  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 1st `  y )  =  Z )
22 simprl 733 . . . . . 6  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  x  =  <. X ,  Y >. )
2322fveq2d 5724 . . . . 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 6351 . . . . . . 7  |-  ( ( X  e.  B  /\  Y  e.  B )  ->  ( 1st `  <. X ,  Y >. )  =  X )
2724, 25, 26syl2anc 643 . . . . . 6  |-  ( ph  ->  ( 1st `  <. X ,  Y >. )  =  X )
2827adantr 452 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 1st ` 
<. X ,  Y >. )  =  X )
2923, 28eqtrd 2467 . . . 4  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 1st `  x )  =  X )
3021, 29oveq12d 6091 . . 3  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( ( 1st `  y ) H ( 1st `  x
) )  =  ( Z H X ) )
3122fveq2d 5724 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 2nd `  x )  =  ( 2nd `  <. X ,  Y >. ) )
32 op2ndg 6352 . . . . . . 7  |-  ( ( X  e.  B  /\  Y  e.  B )  ->  ( 2nd `  <. X ,  Y >. )  =  Y )
3324, 25, 32syl2anc 643 . . . . . 6  |-  ( ph  ->  ( 2nd `  <. X ,  Y >. )  =  Y )
3433adantr 452 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 2nd ` 
<. X ,  Y >. )  =  Y )
3531, 34eqtrd 2467 . . . 4  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 2nd `  x )  =  Y )
3614fveq2d 5724 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 2nd `  y )  =  ( 2nd `  <. Z ,  W >. ) )
37 op2ndg 6352 . . . . . . 7  |-  ( ( Z  e.  B  /\  W  e.  B )  ->  ( 2nd `  <. Z ,  W >. )  =  W )
3816, 17, 37syl2anc 643 . . . . . 6  |-  ( ph  ->  ( 2nd `  <. Z ,  W >. )  =  W )
3938adantr 452 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 2nd ` 
<. Z ,  W >. )  =  W )
4036, 39eqtrd 2467 . . . 4  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 2nd `  y )  =  W )
4135, 40oveq12d 6091 . . 3  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( ( 2nd `  x ) H ( 2nd `  y
) )  =  ( Y H W ) )
4222fveq2d 5724 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( H `  x )  =  ( H `  <. X ,  Y >. ) )
43 df-ov 6076 . . . . 5  |-  ( X H Y )  =  ( H `  <. X ,  Y >. )
4442, 43syl6eqr 2485 . . . 4  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( H `  x )  =  ( X H Y ) )
4521, 29opeq12d 3984 . . . . . 6  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  <. ( 1st `  y ) ,  ( 1st `  x )
>.  =  <. Z ,  X >. )
4645, 40oveq12d 6091 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( <. ( 1st `  y ) ,  ( 1st `  x
) >.  .x.  ( 2nd `  y ) )  =  ( <. Z ,  X >.  .x.  W ) )
4722, 40oveq12d 6091 . . . . . 6  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( x  .x.  ( 2nd `  y
) )  =  (
<. X ,  Y >.  .x. 
W ) )
4847oveqd 6090 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( g
( x  .x.  ( 2nd `  y ) ) h )  =  ( g ( <. X ,  Y >.  .x.  W )
h ) )
49 eqidd 2436 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  f  =  f )
5046, 48, 49oveq123d 6094 . . . 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 4279 . . 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 6128 . 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 4902 . . 3  |-  ( ( X  e.  B  /\  Y  e.  B )  -> 
<. X ,  Y >.  e.  ( B  X.  B
) )
5424, 25, 53syl2anc 643 . 2  |-  ( ph  -> 
<. X ,  Y >.  e.  ( B  X.  B
) )
55 opelxpi 4902 . . 3  |-  ( ( Z  e.  B  /\  W  e.  B )  -> 
<. Z ,  W >.  e.  ( B  X.  B
) )
5616, 17, 55syl2anc 643 . 2  |-  ( ph  -> 
<. Z ,  W >.  e.  ( B  X.  B
) )
57 ovex 6098 . . . 4  |-  ( Z H X )  e. 
_V
58 ovex 6098 . . . 4  |-  ( Y H W )  e. 
_V
5957, 58mpt2ex 6417 . . 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 11 . 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 6193 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 359    = wceq 1652    e. wcel 1725   _Vcvv 2948   <.cop 3809    e. cmpt 4258    X. cxp 4868   ` cfv 5446  (class class class)co 6073    e. cmpt2 6075   1stc1st 6339   2ndc2nd 6340   Basecbs 13461    Hom chom 13532  compcco 13533   Catccat 13881    Homf chomf 13883  HomFchof 14337
This theorem is referenced by:  hof2val  14345
This theorem was proved from axioms:  ax-1 5  ax-2 6  ax-3 7  ax-mp 8  ax-gen 1555  ax-5 1566  ax-17 1626  ax-9 1666  ax-8 1687  ax-13 1727  ax-14 1729  ax-6 1744  ax-7 1749  ax-11 1761  ax-12 1950  ax-ext 2416  ax-rep 4312  ax-sep 4322  ax-nul 4330  ax-pow 4369  ax-pr 4395  ax-un 4693
This theorem depends on definitions:  df-bi 178  df-or 360  df-an 361  df-3an 938  df-tru 1328  df-ex 1551  df-nf 1554  df-sb 1659  df-eu 2284  df-mo 2285  df-clab 2422  df-cleq 2428  df-clel 2431  df-nfc 2560  df-ne 2600  df-ral 2702  df-rex 2703  df-reu 2704  df-rab 2706  df-v 2950  df-sbc 3154  df-csb 3244  df-dif 3315  df-un 3317  df-in 3319  df-ss 3326  df-nul 3621  df-if 3732  df-pw 3793  df-sn 3812  df-pr 3813  df-op 3815  df-uni 4008  df-iun 4087  df-br 4205  df-opab 4259  df-mpt 4260  df-id 4490  df-xp 4876  df-rel 4877  df-cnv 4878  df-co 4879  df-dm 4880  df-rn 4881  df-res 4882  df-ima 4883  df-iota 5410  df-fun 5448  df-fn 5449  df-f 5450  df-f1 5451  df-fo 5452  df-f1o 5453  df-fv 5454  df-ov 6076  df-oprab 6077  df-mpt2 6078  df-1st 6341  df-2nd 6342  df-hof 14339
  Copyright terms: Public domain W3C validator