proposition: Lemma spec_Qquadratic_Qpositive_to_Q_dL_dL_unfolded : forall (a b c d e f g h : Z) (p1 p2 : Qpositive), Qmult (Qplus (Qplus (Qplus (Qmult (Qmult a (Qpos (dL p1))) (Qpos (dL p2))) (Qmult b (Qpos (dL p1)))) (Qmult c (Qpos (dL p2)))) d) (Qinv (Qplus (Qplus (Qplus (Qmult (Qmult e (Qpos (dL p1))) (Qpos (dL p2))) (Qmult f (Qpos (dL p1)))) (Qmult g (Qpos (dL p2)))) h)) = Qmult (Qplus (Qplus (Qplus (Qmult (Qmult (a + b + c + d)%Z (Qpos p1)) (Qpos p2)) (Qmult (b + d)%Z (Qpos p1))) (Qmult (c + d)%Z (Qpos p2))) d) (Qinv (Qplus (Qplus (Qplus (Qmult (Qmult (e + f + g + h)%Z (Qpos p1)) (Qpos p2)) (Qmult (f + h)%Z (Qpos p1))) (Qmult (g + h)%Z (Qpos p2))) h)).
proof: Proof. Proof spec_Qquadratic_Qpositive_to_Q_dL_dL. Lemma spec_Qquadratic_Qpositive_to_Qpositive2_nR_nR : forall (a b c d e f g h : Z) (p1 p2 : Qpositive), spec_Qquadratic_Qpositive_to_Qpositive2 a b c d e f g h (nR p1) (nR p2) = spec_Qquadratic_Qpositive_to_Qpositive2 a (a + b) (a + c) (a + b + c + d) e (e + f) (e + g) (e + f + g + h) p1 p2. Proof. abstract (intros a b c d e f g h p1 p2; unfold spec_Qquadratic_Qpositive_to_Qpositive2 in |- *; do 6 rewrite Qmult_Z_nR; rewrite Qpos_nR; repeat rewrite Z_to_Qplus; apply f_equal2 with Qpositive Qpositive; try apply f_equal with Qpositive; apply f_equal with Q; abstract ring). Qed.
imports: Coq(FunInd) QArithSternBrocot(Field_Theory_Q)