Variant rat_spec (* (x : rat) *) : rat -> int -> int -> Type :=
Rat_spec (n : int) (d : nat)  & coprime `|n| d.+1
: rat_spec (* x  *) (n%:Q / d.+1%:Q) n d.+1.

Lemma ratP x : rat_spec x (numq x) (denq x).