Set Warnings "-abstract-large-number".
Ltac invst H := inversion H; subst.
Ltac ctor := constructor.
Ltac ector := econstructor.
Ltac fext := apply functional_extensionality; intro.
Ltac gd x := generalize dependent x.
Ltac cg := try congruence.
Ltac clr_eqrefl:=
repeat match goal with
| H: ?A = ?A |- _ => clear H
end.
Ltac clr_dup:=
repeat match goal with
| H:?A, H':?A |- _ => clear H'
end.
Ltac clrs:=
clr_eqrefl; clr_dup.
Definition is_inj{T1 T2}(f:T1->T2):=
forall a b, f a = f b -> a = b.

Lemma ffx_eq_x_inj{A}:
forall f:A->A,
(forall x:A, f (f x) = x) ->
forall x y:A, f x = f y -> x = y.