Definition lex_pair {A B} (Ra: A -> A -> Prop) (Rb: B -> B -> Prop)
(x: A*B) (y: A*B) : Prop :=
Ra (fst x) (fst y) \/ (fst x = fst y /\ Rb (snd x) (snd y)).
(* Lemma lex_pair_eqv: forall A B Ra Rb, lex_pair Ra Rb = (fun x y => lexprod A (fun _ => B) Ra (fun _ => Rb) (existT (fun _:A => B) (fst x) (snd x)) (existT (fun _:A => B) (fst y) (snd y))). *)

(* Specifications: *)
Lemma well_founded_incl:
forall A (Rs Rt: A -> A -> Prop),
inclusion _ Rt Rs -> well_founded Rs -> well_founded Rt.
Lemma well_founded_image:
forall A B (f: A -> B) (Rb: B -> B -> Prop),
well_founded Rb ->
well_founded (fun x y => Rb (f x) (f y)).
Lemma well_founded_lex_pair:
forall A B (Ra: A -> A -> Prop) (Rb: B -> B -> Prop),
well_founded Ra -> well_founded Rb -> well_founded (lex_pair Ra Rb).
Lemma well_founded_trans:
forall A (Ra: A -> A -> Prop),
well_founded Ra <-> well_founded (clos_trans _ Ra).