Metamath Proof Explorer


Theorem rp-isfinite6

Description: A set is said to be finite if it is either empty or it can be put in one-to-one correspondence with all the natural numbers between 1 and some n e. NN . (Contributed by RP, 10-Mar-2020)

Ref Expression
Assertion rp-isfinite6 A Fin A = n 1 n A

Proof

Step Hyp Ref Expression
1 exmid A = ¬ A =
2 1 biantrur A Fin A = ¬ A = A Fin
3 andir A = ¬ A = A Fin A = A Fin ¬ A = A Fin
4 2 3 bitri A Fin A = A Fin ¬ A = A Fin
5 simpl A = A Fin A =
6 0fin Fin
7 eleq1a Fin A = A Fin
8 6 7 ax-mp A = A Fin
9 8 ancli A = A = A Fin
10 5 9 impbii A = A Fin A =
11 rp-isfinite5 A Fin n 0 1 n A
12 df-rex n 0 1 n A n n 0 1 n A
13 11 12 bitri A Fin n n 0 1 n A
14 13 anbi2i ¬ A = A Fin ¬ A = n n 0 1 n A
15 df-rex n 1 n A n n 1 n A
16 en0 A A =
17 ensymb A A
18 16 17 bitr3i A = A
19 18 notbii ¬ A = ¬ A
20 elnn0 n 0 n n = 0
21 20 anbi1i n 0 1 n A n n = 0 1 n A
22 andir n n = 0 1 n A n 1 n A n = 0 1 n A
23 21 22 bitri n 0 1 n A n 1 n A n = 0 1 n A
24 19 23 anbi12i ¬ A = n 0 1 n A ¬ A n 1 n A n = 0 1 n A
25 andi ¬ A n 1 n A n = 0 1 n A ¬ A n 1 n A ¬ A n = 0 1 n A
26 24 25 bitri ¬ A = n 0 1 n A ¬ A n 1 n A ¬ A n = 0 1 n A
27 3anass ¬ A n 1 n A ¬ A n 1 n A
28 3anass ¬ A n = 0 1 n A ¬ A n = 0 1 n A
29 27 28 orbi12i ¬ A n 1 n A ¬ A n = 0 1 n A ¬ A n 1 n A ¬ A n = 0 1 n A
30 26 29 sylbb2 ¬ A = n 0 1 n A ¬ A n 1 n A ¬ A n = 0 1 n A
31 simp2 ¬ A n 1 n A n
32 oveq2 n = 0 1 n = 1 0
33 fz10 1 0 =
34 32 33 eqtrdi n = 0 1 n =
35 simp2 ¬ A 1 n = 1 n A 1 n =
36 simp3 ¬ A 1 n = 1 n A 1 n A
37 35 36 eqbrtrrd ¬ A 1 n = 1 n A A
38 simp1 ¬ A 1 n = 1 n A ¬ A
39 37 38 pm2.21dd ¬ A 1 n = 1 n A n
40 34 39 syl3an2 ¬ A n = 0 1 n A n
41 31 40 jaoi ¬ A n 1 n A ¬ A n = 0 1 n A n
42 30 41 syl ¬ A = n 0 1 n A n
43 simprr ¬ A = n 0 1 n A 1 n A
44 42 43 jca ¬ A = n 0 1 n A n 1 n A
45 nngt0 n 0 < n
46 hash0 = 0
47 46 a1i n = 0
48 nnnn0 n n 0
49 hashfz1 n 0 1 n = n
50 48 49 syl n 1 n = n
51 45 47 50 3brtr4d n < 1 n
52 fzfi 1 n Fin
53 hashsdom Fin 1 n Fin < 1 n 1 n
54 6 52 53 mp2an < 1 n 1 n
55 51 54 sylib n 1 n
56 55 anim1i n 1 n A 1 n 1 n A
57 sdomentr 1 n 1 n A A
58 sdomnen A ¬ A
59 57 58 syl 1 n 1 n A ¬ A
60 ensymb A A
61 60 16 bitri A A =
62 61 notbii ¬ A ¬ A =
63 59 62 sylib 1 n 1 n A ¬ A =
64 56 63 syl n 1 n A ¬ A =
65 48 anim1i n 1 n A n 0 1 n A
66 64 65 jca n 1 n A ¬ A = n 0 1 n A
67 44 66 impbii ¬ A = n 0 1 n A n 1 n A
68 67 exbii n ¬ A = n 0 1 n A n n 1 n A
69 19.42v n ¬ A = n 0 1 n A ¬ A = n n 0 1 n A
70 15 68 69 3bitr2ri ¬ A = n n 0 1 n A n 1 n A
71 14 70 bitri ¬ A = A Fin n 1 n A
72 10 71 orbi12i A = A Fin ¬ A = A Fin A = n 1 n A
73 4 72 bitri A Fin A = n 1 n A