Metamath Proof Explorer


Theorem dfod2

Description: An alternative definition of the order of a group element is as the cardinality of the cyclic subgroup generated by the element. (Contributed by Mario Carneiro, 14-Jan-2015) (Revised by Mario Carneiro, 2-Oct-2015)

Ref Expression
Hypotheses odf1.1 X = Base G
odf1.2 O = od G
odf1.3 · ˙ = G
odf1.4 F = x x · ˙ A
Assertion dfod2 G Grp A X O A = if ran F Fin ran F 0

Proof

Step Hyp Ref Expression
1 odf1.1 X = Base G
2 odf1.2 O = od G
3 odf1.3 · ˙ = G
4 odf1.4 F = x x · ˙ A
5 fzfid G Grp A X O A 0 O A 1 Fin
6 1 3 mulgcl G Grp x A X x · ˙ A X
7 6 3expa G Grp x A X x · ˙ A X
8 7 an32s G Grp A X x x · ˙ A X
9 8 adantlr G Grp A X O A x x · ˙ A X
10 9 4 fmptd G Grp A X O A F : X
11 frn F : X ran F X
12 1 fvexi X V
13 12 ssex ran F X ran F V
14 10 11 13 3syl G Grp A X O A ran F V
15 elfzelz y 0 O A 1 y
16 15 adantl G Grp A X O A y 0 O A 1 y
17 ovex y · ˙ A V
18 oveq1 x = y x · ˙ A = y · ˙ A
19 4 18 elrnmpt1s y y · ˙ A V y · ˙ A ran F
20 16 17 19 sylancl G Grp A X O A y 0 O A 1 y · ˙ A ran F
21 20 ralrimiva G Grp A X O A y 0 O A 1 y · ˙ A ran F
22 zmodfz x O A x mod O A 0 O A 1
23 22 ancoms O A x x mod O A 0 O A 1
24 23 adantll G Grp A X O A x x mod O A 0 O A 1
25 simpllr G Grp A X O A x y 0 O A 1 O A
26 simplr G Grp A X O A x y 0 O A 1 x
27 15 adantl G Grp A X O A x y 0 O A 1 y
28 moddvds O A x y x mod O A = y mod O A O A x y
29 25 26 27 28 syl3anc G Grp A X O A x y 0 O A 1 x mod O A = y mod O A O A x y
30 27 zred G Grp A X O A x y 0 O A 1 y
31 25 nnrpd G Grp A X O A x y 0 O A 1 O A +
32 0z 0
33 nnz O A O A
34 33 adantl G Grp A X O A O A
35 34 adantr G Grp A X O A x O A
36 elfzm11 0 O A y 0 O A 1 y 0 y y < O A
37 32 35 36 sylancr G Grp A X O A x y 0 O A 1 y 0 y y < O A
38 37 biimpa G Grp A X O A x y 0 O A 1 y 0 y y < O A
39 38 simp2d G Grp A X O A x y 0 O A 1 0 y
40 38 simp3d G Grp A X O A x y 0 O A 1 y < O A
41 modid y O A + 0 y y < O A y mod O A = y
42 30 31 39 40 41 syl22anc G Grp A X O A x y 0 O A 1 y mod O A = y
43 42 eqeq2d G Grp A X O A x y 0 O A 1 x mod O A = y mod O A x mod O A = y
44 eqcom x mod O A = y y = x mod O A
45 43 44 bitrdi G Grp A X O A x y 0 O A 1 x mod O A = y mod O A y = x mod O A
46 simp-4l G Grp A X O A x y 0 O A 1 G Grp
47 simp-4r G Grp A X O A x y 0 O A 1 A X
48 eqid 0 G = 0 G
49 1 2 3 48 odcong G Grp A X x y O A x y x · ˙ A = y · ˙ A
50 46 47 26 27 49 syl112anc G Grp A X O A x y 0 O A 1 O A x y x · ˙ A = y · ˙ A
51 29 45 50 3bitr3rd G Grp A X O A x y 0 O A 1 x · ˙ A = y · ˙ A y = x mod O A
52 51 ralrimiva G Grp A X O A x y 0 O A 1 x · ˙ A = y · ˙ A y = x mod O A
53 reu6i x mod O A 0 O A 1 y 0 O A 1 x · ˙ A = y · ˙ A y = x mod O A ∃! y 0 O A 1 x · ˙ A = y · ˙ A
54 24 52 53 syl2anc G Grp A X O A x ∃! y 0 O A 1 x · ˙ A = y · ˙ A
55 54 ralrimiva G Grp A X O A x ∃! y 0 O A 1 x · ˙ A = y · ˙ A
56 ovex x · ˙ A V
57 56 rgenw x x · ˙ A V
58 eqeq1 z = x · ˙ A z = y · ˙ A x · ˙ A = y · ˙ A
59 58 reubidv z = x · ˙ A ∃! y 0 O A 1 z = y · ˙ A ∃! y 0 O A 1 x · ˙ A = y · ˙ A
60 4 59 ralrnmptw x x · ˙ A V z ran F ∃! y 0 O A 1 z = y · ˙ A x ∃! y 0 O A 1 x · ˙ A = y · ˙ A
61 57 60 ax-mp z ran F ∃! y 0 O A 1 z = y · ˙ A x ∃! y 0 O A 1 x · ˙ A = y · ˙ A
62 55 61 sylibr G Grp A X O A z ran F ∃! y 0 O A 1 z = y · ˙ A
63 eqid y 0 O A 1 y · ˙ A = y 0 O A 1 y · ˙ A
64 63 f1ompt y 0 O A 1 y · ˙ A : 0 O A 1 1-1 onto ran F y 0 O A 1 y · ˙ A ran F z ran F ∃! y 0 O A 1 z = y · ˙ A
65 21 62 64 sylanbrc G Grp A X O A y 0 O A 1 y · ˙ A : 0 O A 1 1-1 onto ran F
66 f1oen2g 0 O A 1 Fin ran F V y 0 O A 1 y · ˙ A : 0 O A 1 1-1 onto ran F 0 O A 1 ran F
67 5 14 65 66 syl3anc G Grp A X O A 0 O A 1 ran F
68 enfi 0 O A 1 ran F 0 O A 1 Fin ran F Fin
69 67 68 syl G Grp A X O A 0 O A 1 Fin ran F Fin
70 5 69 mpbid G Grp A X O A ran F Fin
71 70 iftrued G Grp A X O A if ran F Fin ran F 0 = ran F
72 fz01en O A 0 O A 1 1 O A
73 ensym 0 O A 1 1 O A 1 O A 0 O A 1
74 34 72 73 3syl G Grp A X O A 1 O A 0 O A 1
75 entr 1 O A 0 O A 1 0 O A 1 ran F 1 O A ran F
76 74 67 75 syl2anc G Grp A X O A 1 O A ran F
77 fzfid G Grp A X O A 1 O A Fin
78 hashen 1 O A Fin ran F Fin 1 O A = ran F 1 O A ran F
79 77 70 78 syl2anc G Grp A X O A 1 O A = ran F 1 O A ran F
80 76 79 mpbird G Grp A X O A 1 O A = ran F
81 nnnn0 O A O A 0
82 81 adantl G Grp A X O A O A 0
83 hashfz1 O A 0 1 O A = O A
84 82 83 syl G Grp A X O A 1 O A = O A
85 71 80 84 3eqtr2rd G Grp A X O A O A = if ran F Fin ran F 0
86 simp3 G Grp A X O A = 0 O A = 0
87 1 2 3 4 odinf G Grp A X O A = 0 ¬ ran F Fin
88 87 iffalsed G Grp A X O A = 0 if ran F Fin ran F 0 = 0
89 86 88 eqtr4d G Grp A X O A = 0 O A = if ran F Fin ran F 0
90 89 3expa G Grp A X O A = 0 O A = if ran F Fin ran F 0
91 1 2 odcl A X O A 0
92 91 adantl G Grp A X O A 0
93 elnn0 O A 0 O A O A = 0
94 92 93 sylib G Grp A X O A O A = 0
95 85 90 94 mpjaodan G Grp A X O A = if ran F Fin ran F 0