auto with algebra.
Qed.
End ideals.
Hint Resolve ideal_prop2: algebra.
Section Ring_as_module.
Variable R : ring.
Definition ring_module : module R.
apply
(BUILD_MODULE_GROUP (R:=R) (module_util_G:=R)
(gen_module_op:=fun a x : R => ring_mult a x));
abstract auto with algebra.
Defined.
End Ring_as_module.
Coercion ring_module : ring >-> module.
Section Generated_ideal.
Variable R : RING.
Variable A : part_set R.
Definition generated_module_subgroup : subgroup R.
apply (BUILD_SUB_GROUP (G:=R) (H:=generated_module (R:=R) (Mod:=R) A));
simpl in |- *; auto with algebra.
intros x y H' H'0; try assumption.
elim H'0; intros x0 E; elim E; intros H'1 H'2; try exact H'2; clear E H'0.
elim H'; intros x1 E; elim E; intros H'0 H'3; try exact H'3; clear E H'.
exists (Law x1 x0); split; [ try assumption | idtac ].
simpl in |- *.
exact (SGROUP_comp (E:=R) H'3 H'2).
exists (Unit R A); split; [ idtac | try assumption ].
auto with algebra.
simpl in |- *.
auto with algebra.
intros x H'; try assumption.
elim H'; intros x0 E; elim E; intros H'0 H'1; try exact H'1; clear E H'.
exists (Inv x0); split; [ idtac | try assumption ].
auto with algebra.
simpl in |- *.
exact (GROUP_comp (G:=R) H'1).
Defined.
Definition generated_ideal : ideal R.
apply (Build_ideal (R:=R) (ideal_subgroup:=generated_module_subgroup)).
red in |- *.
simpl in |- *.
intros x H' a; try assumption.
elim H'; intros x0 E; elim E; intros H'0 H'1; try exact H'1; clear E H'.
exists (Op a x0); split; [ idtac | try assumption ].
auto with algebra.
simpl in |- *.
exact (MODULE_comp (R:=R) (Mod:=R:MODULE R) (Refl a) H'1).
Defined.

(* Specifications: *)
Lemma generated_ideal_included : included A generated_ideal.
red in |- *.