Variant rdvdp_spec p q : {poly R} -> bool -> Type :=
| Rdvdp k q1 & p * ((lead_coef q)^+ k)%:P = q1 * q : rdvdp_spec p q 0 true
| RdvdpN & rmodp p q != 0 : rdvdp_spec p q (rmodp p q) false.
(* Is that version useable ? *)

Lemma polyXsubCP p x : reflect (p.[x] = 0) (rdvdp ('X - x%:P) p).