(* Georges' trick for easy case analysis *)

Inductive eq_Spec (A: Type) (x y: A): bool -> Prop :=
 |eq_Spect:  x = y -> eq_Spec A x y true
 |eq_Specf: x <> y -> eq_Spec A x y false.(* Georges' trick for easy case analysis *)

Inductive eq_Spec (A: Type) (x y: A): bool -> Prop :=
 |eq_Spect:  x = y -> eq_Spec A x y true
 |eq_Specf: x <> y -> eq_Spec A x y false.(* Georges' trick for easy case analysis *)

Inductive eq_Spec (A: Type) (x y: A): bool -> Prop :=
 |eq_Spect:  x = y -> eq_Spec A x y true
 |eq_Specf: x <> y -> eq_Spec A x y false.(** Binomial Coefficient defined using Pascal's triangle *)
Fixpoint bin (a b : nat) {struct a} : nat :=
 match a, b with
   _, O => 1
  | O, S b' => 0
  | S a', S b' => bin a' (S b') + bin a' b'
 end.

(* Specifications: *)
Lemma bin_0: forall (n : nat), bin n 0 = 1.
Lemma bin_1: forall (n : nat), bin n 1 = n.
Lemma bin_more: forall (n m : nat), n < m -> bin n m = 0.
Lemma bin_nn: forall (n : nat), bin n n = 1.
Lemma bin_def: forall (n k : nat), bin (S n) (S k) = bin n (S k) + bin n k.