Section PACO2.
Variable T0 : Type.
Variable T1 : forall (x0: @T0), Type.
(** ** Signatures *)
Record sig2T  :=
exist2T {
proj2T0: @T0;
proj2T1: @T1 proj2T0;
}.
Definition uncurry2  (R: rel2 T0 T1): rel1 sig2T :=
fun x => R (proj2T0 x) (proj2T1 x).
Definition curry2  (R: rel1 sig2T): rel2 T0 T1 :=
fun x0 x1 => R (@exist2T x0 x1).
(** ** Predicates of Arity 2 *)
Definition paco2(gf : rel2 T0 T1 -> rel2 T0 T1)(r: rel2 T0 T1) : rel2 T0 T1 :=
curry2 (paco (fun R0 => uncurry2 (gf (curry2 R0))) (uncurry2 r)).
Definition upaco2(gf : rel2 T0 T1 -> rel2 T0 T1)(r: rel2 T0 T1) := paco2 gf r \2/ r.
Arguments paco2 : clear implicits.
Arguments upaco2 : clear implicits.
Hint Unfold upaco2 : core.
Definition monotone2 (gf: rel2 T0 T1 -> rel2 T0 T1) :=
forall x0 x1 r r' (IN: gf r x0 x1) (LE: r <2= r'), gf r' x0 x1.
Definition _monotone2 (gf: rel2 T0 T1 -> rel2 T0 T1) :=
forall r r'(LE: r <2= r'), gf r <2== gf r'.

Lemma monotone2_compose (gf gf': rel2 T0 T1 -> rel2 T0 T1)
(MON1: monotone2 gf)
(MON2: monotone2 gf'):
monotone2 (compose gf gf').