1 (**************************************************************************)
4 (* ||A|| A project by Andrea Asperti *)
6 (* ||I|| Developers: *)
7 (* ||T|| The HELM team. *)
8 (* ||A|| http://helm.cs.unibo.it *)
10 (* \ / This file is distributed under the terms of the *)
11 (* v GNU General Public License Version 2 *)
13 (**************************************************************************)
15 set "baseuri" "cic:/matita/algebra/groups/".
17 include "algebra/monoids.ma".
18 include "nat/le_arith.ma".
20 record isGroup (M:Monoid) (opp: M -> M) : Prop ≝
21 { opp_is_left_inverse: is_left_inverse M opp;
22 opp_is_right_inverse: is_right_inverse M opp
27 opp: monoid -> monoid;
28 group_properties: isGroup ? opp
31 coercion cic:/matita/algebra/groups/monoid.con.
33 notation "hvbox(x \sup (-1))" with precedence 89
36 interpretation "Group inverse" 'gopp x =
37 (cic:/matita/algebra/groups/opp.con _ x).
39 definition left_cancellable ≝
40 λT:Type. λop: T -> T -> T.
41 ∀x. injective ? ? (op x).
43 definition right_cancellable ≝
44 λT:Type. λop: T -> T -> T.
45 ∀x. injective ? ? (λz.op z x).
47 theorem eq_op_x_y_op_x_z_to_eq:
48 ∀G:Group. left_cancellable G (op G).
50 unfold left_cancellable;
53 rewrite < (e_is_left_unit ? ? (monoid_properties G));
54 rewrite < (e_is_left_unit ? ? (monoid_properties G) z);
55 rewrite < (opp_is_left_inverse ? ? (group_properties G) x);
56 rewrite > (semigroup_properties G);
57 rewrite > (semigroup_properties G);
63 theorem eq_op_x_y_op_z_y_to_eq:
64 ∀G:Group. right_cancellable G (op G).
66 unfold right_cancellable;
68 simplify;fold simplify (op G);
70 rewrite < (e_is_right_unit ? ? (monoid_properties G));
71 rewrite < (e_is_right_unit ? ? (monoid_properties G) z);
72 rewrite < (opp_is_right_inverse ? ? (group_properties G) x);
73 rewrite < (semigroup_properties G);
74 rewrite < (semigroup_properties G);
80 record enumerable (T:Type) : Type ≝
83 repr_inj: ∀n,n'. n≤order → n'≤order → repr n ≠ repr n';
84 repr_sur: ∀x.∃n.n≤order ∧ repr n = x
90 enumerable (carrier G) →
91 left_cancellable (carrier G) (op G) →
92 right_cancellable (carrier G) (op G) →
93 ∃e:G. is_left_unit ? e.
95 unfold left_cancellable in H1;
96 letin x ≝ (repr ? H O);
97 letin f ≝ (λy.x·(repr ? H y));
98 generalize in match (H1 x);