(* This program is free software; you can redistribute it and/or      *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1   *)
(* of the License, or (at your option) any later version.             *)
(*                                                                    *)
(* This program is distributed in the hope that it will be useful,    *)
(* but WITHOUT ANY WARRANTY; without even the implied warranty of     *)
(* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the      *)
(* GNU General Public License for more details.                       *)
(*                                                                    *)
(* You should have received a copy of the GNU Lesser General Public   *)
(* License along with this program; if not, write to the Free         *)
(* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *)
(* 02110-1301 USA                                                     *)


Set Implicit Arguments.
Unset Strict Implicit.
Require Export Group_kernel.
Require Export Free_group.
Section Generated_group_def.
Variable G : GROUP.
Variable A : part_set G.

Definition generated_group : subgroup G := coKer (FG_lift (inj_part A)).
End Generated_group_def.

Lemma generated_group_minimal :
 forall (G : GROUP) (A : part_set G) (H : subgroup G),
 included A H -> included (generated_group A) H.
(* Goal: forall (G : Ob GROUP) (A : Carrier (part_set (sgroup_set (monoid_sgroup (group_monoid G))))), @included (sgroup_set (monoid_sgroup (group_monoid G))) A (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G (@generated_group G A)))) *)
unfold included in |- *.
(* Goal: @Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Var (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) (@Build_subtype (sgroup_set (monoid_sgroup (group_monoid G))) A x H'))) *)
simpl in |- *.
(* Goal: forall (G : group) (A : Predicate (sgroup_set (monoid_sgroup (group_monoid G)))) (H : subgroup G) (_ : forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x A), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H)))) (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : @ex (FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (fun x0 : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) => and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) x0)))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
intros G A H H' x H'0; try assumption.
(* Goal: @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
elim H'0; intros x0; clear H'0.
(* Goal: forall _ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) x0)), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
generalize x; clear x.
(* Goal: forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) x0))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
elim x0.
(* Goal: forall (c : Carrier (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Var (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) c)))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
(* Goal: forall (f : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (_ : forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) f))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H)))) (f0 : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (_ : forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) f0))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H)))) (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Law (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) f f0)))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
(* Goal: forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (Unit (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)))))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
(* Goal: forall (f : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (_ : forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) f))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H)))) (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Inv (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) f)))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
intros c; try assumption.
(* Goal: forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Var (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) c)))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
(* Goal: forall (f : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (_ : forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) f))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H)))) (f0 : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (_ : forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) f0))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H)))) (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Law (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) f f0)))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
(* Goal: forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (Unit (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)))))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
(* Goal: forall (f : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (_ : forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) f))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H)))) (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Inv (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) f)))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
elim c.
(* Goal: @Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Var (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) (@Build_subtype (sgroup_set (monoid_sgroup (group_monoid G))) A x H'))) *)
simpl in |- *.
intros y subtype_prf x H'0; elim H'0; intros H'1 H'2; try exact H'2;
 clear H'0.
(* Goal: @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
(* Goal: forall (f : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (_ : forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) f))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H)))) (f0 : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (_ : forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) f0))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H)))) (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Law (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) f f0)))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
(* Goal: forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (Unit (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)))))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
(* Goal: forall (f : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (_ : forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) f))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H)))) (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Inv (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) f)))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
apply in_part_comp_l with y; auto with algebra.
(* Goal: forall (f : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (_ : forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) f))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H)))) (f0 : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (_ : forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) f0))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H)))) (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Law (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) f f0)))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
(* Goal: forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (Unit (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)))))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
(* Goal: forall (f : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (_ : forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) f))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H)))) (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Inv (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) f)))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
intros f H'0 f0 H'1 x H'2; elim H'2; intros H'3 H'4; try exact H'4; clear H'2.
(* Goal: @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
(* Goal: forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (Unit (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)))))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
(* Goal: forall (f : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (_ : forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) f))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H)))) (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Inv (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) f)))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
simpl in H'4.
apply
 in_part_comp_l
  with
    (sgroup_law G (FG_lift_fun (inj_part A) f) (FG_lift_fun (inj_part A) f0));
(* Goal: True *)
 auto with algebra.
(* Goal: @Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Var (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) (@Build_subtype (sgroup_set (monoid_sgroup (group_monoid G))) A x H'))) *)
simpl in |- *.
(* Goal: forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@monoid_unit (monoid_sgroup (group_monoid G)) (monoid_on_def (group_monoid G))))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
(* Goal: forall (f : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (_ : forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) f))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H)))) (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Inv (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) f)))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
intros x H'0; elim H'0; intros H'1 H'2; try exact H'2; clear H'0.
(* Goal: @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
(* Goal: forall (f : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (_ : forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) f))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H)))) (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Inv (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) f)))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
apply in_part_comp_l with (monoid_unit G); auto with algebra.
(* Goal: forall (f : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (_ : forall (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) f))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H)))) (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Inv (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) f)))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
intros f H'0 x H'1; try assumption.
(* Goal: @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G H))) *)
elim H'1; intros H'2 H'3; simpl in H'3; clear H'1.
apply in_part_comp_l with (group_inverse G (FG_lift_fun (inj_part A) f));
(* Goal: True *)
 auto with algebra.
Qed.

Lemma generated_group_prop_included :
 forall (G : GROUP) (A : part_set G), included A (generated_group A).
(* Goal: forall (G : Ob GROUP) (A : Carrier (part_set (sgroup_set (monoid_sgroup (group_monoid G))))), @included (sgroup_set (monoid_sgroup (group_monoid G))) A (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G (@generated_group G A)))) *)
unfold included in |- *.
(* Goal: @Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Var (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) (@Build_subtype (sgroup_set (monoid_sgroup (group_monoid G))) A x H'))) *)
simpl in |- *.
(* Goal: forall (G : group) (A : Predicate (sgroup_set (monoid_sgroup (group_monoid G)))) (x : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : @in_part (sgroup_set (monoid_sgroup (group_monoid G))) x A), @ex (FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (fun x0 : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) => and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) x0))) *)
intros G A x H'; try assumption.
exists (Var (V:=A) (Build_subtype (E:=G) (P:=A) (subtype_elt:=x) H')); split;
 [ idtac | try assumption ].
(* Goal: True *)
auto with algebra.
(* Goal: @Equal (sgroup_set (monoid_sgroup (group_monoid G))) x (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) (@Var (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) (@Build_subtype (sgroup_set (monoid_sgroup (group_monoid G))) A x H'))) *)
simpl in |- *.
(* Goal: True *)
auto with algebra.
Qed.

Lemma generated_group_prop :
 forall (G : GROUP) (A : part_set G) (y : G),
 in_part y (generated_group A) ->
 exists x : FG A, Equal y (FG_lift (inj_part A) x).
(* Goal: True *)
simpl in |- *; auto with algebra.
(* Goal: forall (G : Ob GROUP) (A : Carrier (part_set (sgroup_set (monoid_sgroup (group_monoid G))))) (y : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : @ex (FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (fun x : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) => @Equal (sgroup_set (monoid_sgroup (group_monoid G))) y (@Ap (sgroup_set (monoid_sgroup (group_monoid (FreeGroup (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)))))) (sgroup_set (monoid_sgroup (group_monoid G))) (@sgroup_map (monoid_sgroup (group_monoid (FreeGroup (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))))) (monoid_sgroup (group_monoid G)) (@monoid_sgroup_hom (group_monoid (FreeGroup (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)))) (group_monoid G) (@FG_lift (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A)))) x))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) y (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G (@generated_group G A)))) *)
intros G A y H'; try assumption.
(* Goal: @ex (FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (fun x : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) => @Equal (sgroup_set (monoid_sgroup (group_monoid G))) y (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) x)) *)
elim H'; intros x E; elim E; intros H'0 H'1; try exact H'1; clear E H'.
(* Goal: @ex (FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (fun x : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) => @Equal (sgroup_set (monoid_sgroup (group_monoid G))) y (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) x)) *)
exists x; try assumption.
Qed.

Lemma generated_group_prop_rev :
 forall (G : GROUP) (A : part_set G) (y : G),
 (exists x : FG A, Equal y (FG_lift (inj_part A) x)) ->
 in_part y (generated_group A).
(* Goal: forall (G : Ob GROUP) (A : Carrier (part_set (sgroup_set (monoid_sgroup (group_monoid G))))) (y : Carrier (sgroup_set (monoid_sgroup (group_monoid G)))) (_ : @ex (FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (fun x : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) => @Equal (sgroup_set (monoid_sgroup (group_monoid G))) y (@Ap (sgroup_set (monoid_sgroup (group_monoid (FreeGroup (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)))))) (sgroup_set (monoid_sgroup (group_monoid G))) (@sgroup_map (monoid_sgroup (group_monoid (FreeGroup (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))))) (monoid_sgroup (group_monoid G)) (@monoid_sgroup_hom (group_monoid (FreeGroup (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)))) (group_monoid G) (@FG_lift (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A)))) x))), @in_part (sgroup_set (monoid_sgroup (group_monoid G))) y (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G (@generated_group G A)))) *)
intros G A y H'; try assumption.
(* Goal: @in_part (sgroup_set (monoid_sgroup (group_monoid G))) y (@subsgroup_part (monoid_sgroup (group_monoid G)) (@submonoid_subsgroup (group_monoid G) (@subgroup_submonoid G (@generated_group G A)))) *)
elim H'; intros x E; try exact E; clear H'.
(* Goal: True *)
simpl in |- *; auto with algebra.
(* Goal: @ex (FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A))) (fun x : FG (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) => and True (@Equal (sgroup_set (monoid_sgroup (group_monoid G))) y (@FG_lift_fun (@set_of_subtype_image (sgroup_set (monoid_sgroup (group_monoid G))) (@part (sgroup_set (monoid_sgroup (group_monoid G))) A)) G (@inj_part (sgroup_set (monoid_sgroup (group_monoid G))) A) x))) *)
exists x; split; [ idtac | try assumption ].
(* Goal: True *)
auto with algebra.
Qed.
Hint Resolve generated_group_minimal generated_group_prop_included
  generated_group_prop_rev: algebra.
