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

Theorem hof2fval 16895
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 16892 . . 3  |-  ( ph  ->  M  =  <. ( Hom f  `  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 6201 . . . 4  |-  ( Hom f  `  C )  e.  _V
8 fvex 6201 . . . . . . 7  |-  ( Base `  C )  e.  _V
93, 8eqeltri 2697 . . . . . 6  |-  B  e. 
_V
109, 9xpex 6962 . . . . 5  |-  ( B  X.  B )  e. 
_V
1110, 10mpt2ex 7247 . . . 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 7179 . . 3  |-  ( M  =  <. ( Hom f  `  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 17 . 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 796 . . . . . 6  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  y  =  <. Z ,  W >. )
1514fveq2d 6195 . . . . 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 7180 . . . . . . 7  |-  ( ( Z  e.  B  /\  W  e.  B )  ->  ( 1st `  <. Z ,  W >. )  =  Z )
1916, 17, 18syl2anc 693 . . . . . 6  |-  ( ph  ->  ( 1st `  <. Z ,  W >. )  =  Z )
2019adantr 481 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 1st ` 
<. Z ,  W >. )  =  Z )
2115, 20eqtrd 2656 . . . 4  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 1st `  y )  =  Z )
22 simprl 794 . . . . . 6  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  x  =  <. X ,  Y >. )
2322fveq2d 6195 . . . . 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 7180 . . . . . . 7  |-  ( ( X  e.  B  /\  Y  e.  B )  ->  ( 1st `  <. X ,  Y >. )  =  X )
2724, 25, 26syl2anc 693 . . . . . 6  |-  ( ph  ->  ( 1st `  <. X ,  Y >. )  =  X )
2827adantr 481 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 1st ` 
<. X ,  Y >. )  =  X )
2923, 28eqtrd 2656 . . . 4  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 1st `  x )  =  X )
3021, 29oveq12d 6668 . . 3  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( ( 1st `  y ) H ( 1st `  x
) )  =  ( Z H X ) )
3122fveq2d 6195 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 2nd `  x )  =  ( 2nd `  <. X ,  Y >. ) )
32 op2ndg 7181 . . . . . . 7  |-  ( ( X  e.  B  /\  Y  e.  B )  ->  ( 2nd `  <. X ,  Y >. )  =  Y )
3324, 25, 32syl2anc 693 . . . . . 6  |-  ( ph  ->  ( 2nd `  <. X ,  Y >. )  =  Y )
3433adantr 481 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 2nd ` 
<. X ,  Y >. )  =  Y )
3531, 34eqtrd 2656 . . . 4  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 2nd `  x )  =  Y )
3614fveq2d 6195 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 2nd `  y )  =  ( 2nd `  <. Z ,  W >. ) )
37 op2ndg 7181 . . . . . . 7  |-  ( ( Z  e.  B  /\  W  e.  B )  ->  ( 2nd `  <. Z ,  W >. )  =  W )
3816, 17, 37syl2anc 693 . . . . . 6  |-  ( ph  ->  ( 2nd `  <. Z ,  W >. )  =  W )
3938adantr 481 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 2nd ` 
<. Z ,  W >. )  =  W )
4036, 39eqtrd 2656 . . . 4  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( 2nd `  y )  =  W )
4135, 40oveq12d 6668 . . 3  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( ( 2nd `  x ) H ( 2nd `  y
) )  =  ( Y H W ) )
4222fveq2d 6195 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( H `  x )  =  ( H `  <. X ,  Y >. ) )
43 df-ov 6653 . . . . 5  |-  ( X H Y )  =  ( H `  <. X ,  Y >. )
4442, 43syl6eqr 2674 . . . 4  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( H `  x )  =  ( X H Y ) )
4521, 29opeq12d 4410 . . . . . 6  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  <. ( 1st `  y ) ,  ( 1st `  x )
>.  =  <. Z ,  X >. )
4645, 40oveq12d 6668 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( <. ( 1st `  y ) ,  ( 1st `  x
) >.  .x.  ( 2nd `  y ) )  =  ( <. Z ,  X >.  .x.  W ) )
4722, 40oveq12d 6668 . . . . . 6  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( x  .x.  ( 2nd `  y
) )  =  (
<. X ,  Y >.  .x. 
W ) )
4847oveqd 6667 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  ( g
( x  .x.  ( 2nd `  y ) ) h )  =  ( g ( <. X ,  Y >.  .x.  W )
h ) )
49 eqidd 2623 . . . . 5  |-  ( (
ph  /\  ( x  =  <. X ,  Y >.  /\  y  =  <. Z ,  W >. )
)  ->  f  =  f )
5046, 48, 49oveq123d 6671 . . . 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 4733 . . 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 6717 . 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 5148 . . 3  |-  ( ( X  e.  B  /\  Y  e.  B )  -> 
<. X ,  Y >.  e.  ( B  X.  B
) )
5424, 25, 53syl2anc 693 . 2  |-  ( ph  -> 
<. X ,  Y >.  e.  ( B  X.  B
) )
55 opelxpi 5148 . . 3  |-  ( ( Z  e.  B  /\  W  e.  B )  -> 
<. Z ,  W >.  e.  ( B  X.  B
) )
5616, 17, 55syl2anc 693 . 2  |-  ( ph  -> 
<. Z ,  W >.  e.  ( B  X.  B
) )
57 ovex 6678 . . . 4  |-  ( Z H X )  e. 
_V
58 ovex 6678 . . . 4  |-  ( Y H W )  e. 
_V
5957, 58mpt2ex 7247 . . 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 6788 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 setvar class
Syntax hints:    -> wi 4    /\ wa 384    = wceq 1483    e. wcel 1990   _Vcvv 3200   <.cop 4183    |-> cmpt 4729    X. cxp 5112   ` cfv 5888  (class class class)co 6650    |-> cmpt2 6652   1stc1st 7166   2ndc2nd 7167   Basecbs 15857   Hom chom 15952  compcco 15953   Catccat 16325   Hom f chomf 16327  HomFchof 16888
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1722  ax-4 1737  ax-5 1839  ax-6 1888  ax-7 1935  ax-8 1992  ax-9 1999  ax-10 2019  ax-11 2034  ax-12 2047  ax-13 2246  ax-ext 2602  ax-rep 4771  ax-sep 4781  ax-nul 4789  ax-pow 4843  ax-pr 4906  ax-un 6949
This theorem depends on definitions:  df-bi 197  df-or 385  df-an 386  df-3an 1039  df-tru 1486  df-ex 1705  df-nf 1710  df-sb 1881  df-eu 2474  df-mo 2475  df-clab 2609  df-cleq 2615  df-clel 2618  df-nfc 2753  df-ne 2795  df-ral 2917  df-rex 2918  df-reu 2919  df-rab 2921  df-v 3202  df-sbc 3436  df-csb 3534  df-dif 3577  df-un 3579  df-in 3581  df-ss 3588  df-nul 3916  df-if 4087  df-pw 4160  df-sn 4178  df-pr 4180  df-op 4184  df-uni 4437  df-iun 4522  df-br 4654  df-opab 4713  df-mpt 4730  df-id 5024  df-xp 5120  df-rel 5121  df-cnv 5122  df-co 5123  df-dm 5124  df-rn 5125  df-res 5126  df-ima 5127  df-iota 5851  df-fun 5890  df-fn 5891  df-f 5892  df-f1 5893  df-fo 5894  df-f1o 5895  df-fv 5896  df-ov 6653  df-oprab 6654  df-mpt2 6655  df-1st 7168  df-2nd 7169  df-hof 16890
This theorem is referenced by:  hof2val  16896
  Copyright terms: Public domain W3C validator