Metamath Proof Explorer


Theorem fsuppcurry2

Description: Finite support of a curried function with a constant second argument. (Contributed by Thierry Arnoux, 7-Jul-2023)

Ref Expression
Hypotheses fsuppcurry2.g
|- G = ( x e. A |-> ( x F C ) )
fsuppcurry2.z
|- ( ph -> Z e. U )
fsuppcurry2.a
|- ( ph -> A e. V )
fsuppcurry2.b
|- ( ph -> B e. W )
fsuppcurry2.f
|- ( ph -> F Fn ( A X. B ) )
fsuppcurry2.c
|- ( ph -> C e. B )
fsuppcurry2.1
|- ( ph -> F finSupp Z )
Assertion fsuppcurry2
|- ( ph -> G finSupp Z )

Proof

Step Hyp Ref Expression
1 fsuppcurry2.g
 |-  G = ( x e. A |-> ( x F C ) )
2 fsuppcurry2.z
 |-  ( ph -> Z e. U )
3 fsuppcurry2.a
 |-  ( ph -> A e. V )
4 fsuppcurry2.b
 |-  ( ph -> B e. W )
5 fsuppcurry2.f
 |-  ( ph -> F Fn ( A X. B ) )
6 fsuppcurry2.c
 |-  ( ph -> C e. B )
7 fsuppcurry2.1
 |-  ( ph -> F finSupp Z )
8 oveq1
 |-  ( x = y -> ( x F C ) = ( y F C ) )
9 8 cbvmptv
 |-  ( x e. A |-> ( x F C ) ) = ( y e. A |-> ( y F C ) )
10 1 9 eqtri
 |-  G = ( y e. A |-> ( y F C ) )
11 3 mptexd
 |-  ( ph -> ( y e. A |-> ( y F C ) ) e. _V )
12 10 11 eqeltrid
 |-  ( ph -> G e. _V )
13 1 funmpt2
 |-  Fun G
14 13 a1i
 |-  ( ph -> Fun G )
15 fo1st
 |-  1st : _V -onto-> _V
16 fofun
 |-  ( 1st : _V -onto-> _V -> Fun 1st )
17 15 16 ax-mp
 |-  Fun 1st
18 funres
 |-  ( Fun 1st -> Fun ( 1st |` ( _V X. _V ) ) )
19 17 18 mp1i
 |-  ( ph -> Fun ( 1st |` ( _V X. _V ) ) )
20 7 fsuppimpd
 |-  ( ph -> ( F supp Z ) e. Fin )
21 imafi
 |-  ( ( Fun ( 1st |` ( _V X. _V ) ) /\ ( F supp Z ) e. Fin ) -> ( ( 1st |` ( _V X. _V ) ) " ( F supp Z ) ) e. Fin )
22 19 20 21 syl2anc
 |-  ( ph -> ( ( 1st |` ( _V X. _V ) ) " ( F supp Z ) ) e. Fin )
23 ovexd
 |-  ( ( ph /\ y e. A ) -> ( y F C ) e. _V )
24 23 10 fmptd
 |-  ( ph -> G : A --> _V )
25 eldif
 |-  ( y e. ( A \ ( ( 1st |` ( _V X. _V ) ) " ( F supp Z ) ) ) <-> ( y e. A /\ -. y e. ( ( 1st |` ( _V X. _V ) ) " ( F supp Z ) ) ) )
26 simplr
 |-  ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) -> y e. A )
27 6 ad2antrr
 |-  ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) -> C e. B )
28 26 27 opelxpd
 |-  ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) -> <. y , C >. e. ( A X. B ) )
29 df-ov
 |-  ( y F C ) = ( F ` <. y , C >. )
30 ovexd
 |-  ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) -> ( y F C ) e. _V )
31 1 8 26 30 fvmptd3
 |-  ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) -> ( G ` y ) = ( y F C ) )
32 simpr
 |-  ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) -> -. ( G ` y ) = Z )
33 32 neqned
 |-  ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) -> ( G ` y ) =/= Z )
34 31 33 eqnetrrd
 |-  ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) -> ( y F C ) =/= Z )
35 29 34 eqnetrrid
 |-  ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) -> ( F ` <. y , C >. ) =/= Z )
36 3 4 xpexd
 |-  ( ph -> ( A X. B ) e. _V )
37 elsuppfn
 |-  ( ( F Fn ( A X. B ) /\ ( A X. B ) e. _V /\ Z e. U ) -> ( <. y , C >. e. ( F supp Z ) <-> ( <. y , C >. e. ( A X. B ) /\ ( F ` <. y , C >. ) =/= Z ) ) )
38 5 36 2 37 syl3anc
 |-  ( ph -> ( <. y , C >. e. ( F supp Z ) <-> ( <. y , C >. e. ( A X. B ) /\ ( F ` <. y , C >. ) =/= Z ) ) )
39 38 ad2antrr
 |-  ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) -> ( <. y , C >. e. ( F supp Z ) <-> ( <. y , C >. e. ( A X. B ) /\ ( F ` <. y , C >. ) =/= Z ) ) )
40 28 35 39 mpbir2and
 |-  ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) -> <. y , C >. e. ( F supp Z ) )
41 simpr
 |-  ( ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) /\ z = <. y , C >. ) -> z = <. y , C >. )
42 41 fveq2d
 |-  ( ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) /\ z = <. y , C >. ) -> ( ( 1st |` ( _V X. _V ) ) ` z ) = ( ( 1st |` ( _V X. _V ) ) ` <. y , C >. ) )
43 xpss
 |-  ( A X. B ) C_ ( _V X. _V )
44 28 adantr
 |-  ( ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) /\ z = <. y , C >. ) -> <. y , C >. e. ( A X. B ) )
45 43 44 sselid
 |-  ( ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) /\ z = <. y , C >. ) -> <. y , C >. e. ( _V X. _V ) )
46 45 fvresd
 |-  ( ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) /\ z = <. y , C >. ) -> ( ( 1st |` ( _V X. _V ) ) ` <. y , C >. ) = ( 1st ` <. y , C >. ) )
47 26 adantr
 |-  ( ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) /\ z = <. y , C >. ) -> y e. A )
48 27 adantr
 |-  ( ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) /\ z = <. y , C >. ) -> C e. B )
49 op1stg
 |-  ( ( y e. A /\ C e. B ) -> ( 1st ` <. y , C >. ) = y )
50 47 48 49 syl2anc
 |-  ( ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) /\ z = <. y , C >. ) -> ( 1st ` <. y , C >. ) = y )
51 42 46 50 3eqtrd
 |-  ( ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) /\ z = <. y , C >. ) -> ( ( 1st |` ( _V X. _V ) ) ` z ) = y )
52 40 51 rspcedeq1vd
 |-  ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) -> E. z e. ( F supp Z ) ( ( 1st |` ( _V X. _V ) ) ` z ) = y )
53 fofn
 |-  ( 1st : _V -onto-> _V -> 1st Fn _V )
54 fnresin
 |-  ( 1st Fn _V -> ( 1st |` ( _V X. _V ) ) Fn ( _V i^i ( _V X. _V ) ) )
55 15 53 54 mp2b
 |-  ( 1st |` ( _V X. _V ) ) Fn ( _V i^i ( _V X. _V ) )
56 ssv
 |-  ( _V X. _V ) C_ _V
57 sseqin2
 |-  ( ( _V X. _V ) C_ _V <-> ( _V i^i ( _V X. _V ) ) = ( _V X. _V ) )
58 56 57 mpbi
 |-  ( _V i^i ( _V X. _V ) ) = ( _V X. _V )
59 58 fneq2i
 |-  ( ( 1st |` ( _V X. _V ) ) Fn ( _V i^i ( _V X. _V ) ) <-> ( 1st |` ( _V X. _V ) ) Fn ( _V X. _V ) )
60 55 59 mpbi
 |-  ( 1st |` ( _V X. _V ) ) Fn ( _V X. _V )
61 60 a1i
 |-  ( ph -> ( 1st |` ( _V X. _V ) ) Fn ( _V X. _V ) )
62 suppssdm
 |-  ( F supp Z ) C_ dom F
63 5 fndmd
 |-  ( ph -> dom F = ( A X. B ) )
64 62 63 sseqtrid
 |-  ( ph -> ( F supp Z ) C_ ( A X. B ) )
65 64 43 sstrdi
 |-  ( ph -> ( F supp Z ) C_ ( _V X. _V ) )
66 61 65 fvelimabd
 |-  ( ph -> ( y e. ( ( 1st |` ( _V X. _V ) ) " ( F supp Z ) ) <-> E. z e. ( F supp Z ) ( ( 1st |` ( _V X. _V ) ) ` z ) = y ) )
67 66 ad2antrr
 |-  ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) -> ( y e. ( ( 1st |` ( _V X. _V ) ) " ( F supp Z ) ) <-> E. z e. ( F supp Z ) ( ( 1st |` ( _V X. _V ) ) ` z ) = y ) )
68 52 67 mpbird
 |-  ( ( ( ph /\ y e. A ) /\ -. ( G ` y ) = Z ) -> y e. ( ( 1st |` ( _V X. _V ) ) " ( F supp Z ) ) )
69 68 ex
 |-  ( ( ph /\ y e. A ) -> ( -. ( G ` y ) = Z -> y e. ( ( 1st |` ( _V X. _V ) ) " ( F supp Z ) ) ) )
70 69 con1d
 |-  ( ( ph /\ y e. A ) -> ( -. y e. ( ( 1st |` ( _V X. _V ) ) " ( F supp Z ) ) -> ( G ` y ) = Z ) )
71 70 impr
 |-  ( ( ph /\ ( y e. A /\ -. y e. ( ( 1st |` ( _V X. _V ) ) " ( F supp Z ) ) ) ) -> ( G ` y ) = Z )
72 25 71 sylan2b
 |-  ( ( ph /\ y e. ( A \ ( ( 1st |` ( _V X. _V ) ) " ( F supp Z ) ) ) ) -> ( G ` y ) = Z )
73 24 72 suppss
 |-  ( ph -> ( G supp Z ) C_ ( ( 1st |` ( _V X. _V ) ) " ( F supp Z ) ) )
74 suppssfifsupp
 |-  ( ( ( G e. _V /\ Fun G /\ Z e. U ) /\ ( ( ( 1st |` ( _V X. _V ) ) " ( F supp Z ) ) e. Fin /\ ( G supp Z ) C_ ( ( 1st |` ( _V X. _V ) ) " ( F supp Z ) ) ) ) -> G finSupp Z )
75 12 14 2 22 73 74 syl32anc
 |-  ( ph -> G finSupp Z )