Metamath Proof Explorer


Theorem ssnnf1octb

Description: There exists a bijection between a subset of NN and a given nonempty countable set. (Contributed by Glauco Siliprandi, 11-Oct-2020)

Ref Expression
Assertion ssnnf1octb A ω A f dom f f : dom f 1-1 onto A

Proof

Step Hyp Ref Expression
1 nnfoctb A ω A g g : onto A
2 fofn g : onto A g Fn
3 nnex V
4 3 a1i g : onto A V
5 ltwenn < We
6 5 a1i g : onto A < We
7 2 4 6 wessf1orn g : onto A x 𝒫 g x : x 1-1 onto ran g
8 f1odm g x : x 1-1 onto ran g dom g x = x
9 8 adantl x 𝒫 g x : x 1-1 onto ran g dom g x = x
10 elpwi x 𝒫 x
11 10 adantr x 𝒫 g x : x 1-1 onto ran g x
12 9 11 eqsstrd x 𝒫 g x : x 1-1 onto ran g dom g x
13 12 3adant1 g : onto A x 𝒫 g x : x 1-1 onto ran g dom g x
14 simpr g : onto A g x : x 1-1 onto ran g g x : x 1-1 onto ran g
15 eqidd g : onto A g x : x 1-1 onto ran g g x = g x
16 8 eqcomd g x : x 1-1 onto ran g x = dom g x
17 16 adantl g : onto A g x : x 1-1 onto ran g x = dom g x
18 forn g : onto A ran g = A
19 18 adantr g : onto A g x : x 1-1 onto ran g ran g = A
20 15 17 19 f1oeq123d g : onto A g x : x 1-1 onto ran g g x : x 1-1 onto ran g g x : dom g x 1-1 onto A
21 14 20 mpbid g : onto A g x : x 1-1 onto ran g g x : dom g x 1-1 onto A
22 21 3adant2 g : onto A x 𝒫 g x : x 1-1 onto ran g g x : dom g x 1-1 onto A
23 vex g V
24 23 resex g x V
25 dmeq f = g x dom f = dom g x
26 25 sseq1d f = g x dom f dom g x
27 id f = g x f = g x
28 eqidd f = g x A = A
29 27 25 28 f1oeq123d f = g x f : dom f 1-1 onto A g x : dom g x 1-1 onto A
30 26 29 anbi12d f = g x dom f f : dom f 1-1 onto A dom g x g x : dom g x 1-1 onto A
31 24 30 spcev dom g x g x : dom g x 1-1 onto A f dom f f : dom f 1-1 onto A
32 13 22 31 syl2anc g : onto A x 𝒫 g x : x 1-1 onto ran g f dom f f : dom f 1-1 onto A
33 32 3exp g : onto A x 𝒫 g x : x 1-1 onto ran g f dom f f : dom f 1-1 onto A
34 33 rexlimdv g : onto A x 𝒫 g x : x 1-1 onto ran g f dom f f : dom f 1-1 onto A
35 7 34 mpd g : onto A f dom f f : dom f 1-1 onto A
36 35 a1i A ω A g : onto A f dom f f : dom f 1-1 onto A
37 36 exlimdv A ω A g g : onto A f dom f f : dom f 1-1 onto A
38 1 37 mpd A ω A f dom f f : dom f 1-1 onto A