Skip to content

Instantly share code, notes, and snippets.

Require Import Arith.
Fixpoint sum_odd(n:nat) : nat :=
match n with
| O => O
| S m => 1 + m + m + sum_odd m
end.
Goal forall n, sum_odd n = n * n.
Proof.
Require Import Arith.
Goal forall x y, x < y -> x + 10 < y + 10.
Proof.
intros.
apply plus_lt_compat_r.
apply H.
Qed.
Theorem Modus_ponens : forall P Q : Prop, P -> (P -> Q) -> Q.
Proof.
intros.
apply H0.
apply H.
Qed.
Theorem Modus_tollens : forall P Q : Prop, ~Q /\ (P -> Q) -> ~P.
Proof.
intros.