Metamath Proof Explorer


Theorem fodomr

Description: There exists a mapping from a set onto any (nonempty) set that it dominates. (Contributed by NM, 23-Mar-2006)

Ref Expression
Assertion fodomr B B A f f : A onto B

Proof

Step Hyp Ref Expression
1 reldom Rel
2 1 brrelex2i B A A V
3 2 adantl B B A A V
4 1 brrelex1i B A B V
5 0sdomg B V B B
6 n0 B z z B
7 5 6 bitrdi B V B z z B
8 4 7 syl B A B z z B
9 8 biimpac B B A z z B
10 brdomi B A g g : B 1-1 A
11 10 adantl B B A g g : B 1-1 A
12 difexg A V A ran g V
13 snex z V
14 xpexg A ran g V z V A ran g × z V
15 12 13 14 sylancl A V A ran g × z V
16 vex g V
17 16 cnvex g -1 V
18 15 17 jctil A V g -1 V A ran g × z V
19 unexb g -1 V A ran g × z V g -1 A ran g × z V
20 18 19 sylib A V g -1 A ran g × z V
21 df-f1 g : B 1-1 A g : B A Fun g -1
22 21 simprbi g : B 1-1 A Fun g -1
23 vex z V
24 23 fconst A ran g × z : A ran g z
25 ffun A ran g × z : A ran g z Fun A ran g × z
26 24 25 ax-mp Fun A ran g × z
27 22 26 jctir g : B 1-1 A Fun g -1 Fun A ran g × z
28 df-rn ran g = dom g -1
29 28 eqcomi dom g -1 = ran g
30 23 snnz z
31 dmxp z dom A ran g × z = A ran g
32 30 31 ax-mp dom A ran g × z = A ran g
33 29 32 ineq12i dom g -1 dom A ran g × z = ran g A ran g
34 disjdif ran g A ran g =
35 33 34 eqtri dom g -1 dom A ran g × z =
36 funun Fun g -1 Fun A ran g × z dom g -1 dom A ran g × z = Fun g -1 A ran g × z
37 27 35 36 sylancl g : B 1-1 A Fun g -1 A ran g × z
38 37 adantl z B g : B 1-1 A Fun g -1 A ran g × z
39 dmun dom g -1 A ran g × z = dom g -1 dom A ran g × z
40 28 uneq1i ran g dom A ran g × z = dom g -1 dom A ran g × z
41 32 uneq2i ran g dom A ran g × z = ran g A ran g
42 39 40 41 3eqtr2i dom g -1 A ran g × z = ran g A ran g
43 f1f g : B 1-1 A g : B A
44 43 frnd g : B 1-1 A ran g A
45 undif ran g A ran g A ran g = A
46 44 45 sylib g : B 1-1 A ran g A ran g = A
47 42 46 eqtrid g : B 1-1 A dom g -1 A ran g × z = A
48 47 adantl z B g : B 1-1 A dom g -1 A ran g × z = A
49 df-fn g -1 A ran g × z Fn A Fun g -1 A ran g × z dom g -1 A ran g × z = A
50 38 48 49 sylanbrc z B g : B 1-1 A g -1 A ran g × z Fn A
51 rnun ran g -1 A ran g × z = ran g -1 ran A ran g × z
52 dfdm4 dom g = ran g -1
53 f1dm g : B 1-1 A dom g = B
54 52 53 eqtr3id g : B 1-1 A ran g -1 = B
55 54 uneq1d g : B 1-1 A ran g -1 ran A ran g × z = B ran A ran g × z
56 xpeq1 A ran g = A ran g × z = × z
57 0xp × z =
58 56 57 eqtrdi A ran g = A ran g × z =
59 58 rneqd A ran g = ran A ran g × z = ran
60 rn0 ran =
61 59 60 eqtrdi A ran g = ran A ran g × z =
62 0ss B
63 61 62 eqsstrdi A ran g = ran A ran g × z B
64 63 a1d A ran g = z B ran A ran g × z B
65 rnxp A ran g ran A ran g × z = z
66 65 adantr A ran g z B ran A ran g × z = z
67 snssi z B z B
68 67 adantl A ran g z B z B
69 66 68 eqsstrd A ran g z B ran A ran g × z B
70 69 ex A ran g z B ran A ran g × z B
71 64 70 pm2.61ine z B ran A ran g × z B
72 ssequn2 ran A ran g × z B B ran A ran g × z = B
73 71 72 sylib z B B ran A ran g × z = B
74 55 73 sylan9eqr z B g : B 1-1 A ran g -1 ran A ran g × z = B
75 51 74 eqtrid z B g : B 1-1 A ran g -1 A ran g × z = B
76 df-fo g -1 A ran g × z : A onto B g -1 A ran g × z Fn A ran g -1 A ran g × z = B
77 50 75 76 sylanbrc z B g : B 1-1 A g -1 A ran g × z : A onto B
78 foeq1 f = g -1 A ran g × z f : A onto B g -1 A ran g × z : A onto B
79 78 spcegv g -1 A ran g × z V g -1 A ran g × z : A onto B f f : A onto B
80 20 77 79 syl2im A V z B g : B 1-1 A f f : A onto B
81 80 expdimp A V z B g : B 1-1 A f f : A onto B
82 81 exlimdv A V z B g g : B 1-1 A f f : A onto B
83 82 ex A V z B g g : B 1-1 A f f : A onto B
84 83 exlimdv A V z z B g g : B 1-1 A f f : A onto B
85 3 9 11 84 syl3c B B A f f : A onto B