Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Hot stripping coqs

Name: Anonymous 2012-04-26 17:03

Hello proggers.

How do I discharge this goal in Coq?

Inductive type : nat -> Set := ctor : forall n, type n.
Goal forall n, type 0 <> type (S n).

Name: Anonymous 2012-05-19 15:09

>>10
Definition fb (x : bool) : Set := nat.
Definition fn (x : nat) : Set := nat.

(* New decision procedure because bool_dec is annoying. *)
Lemma bool_true_false (b : bool) : {b = true} + {b = false}.
destruct b.
  left. reflexivity.
  right. reflexivity.
Defined.
(* Print bool_true_false. *)

Definition bool_or_nat (b : bool) := if b then bool else nat.

(* Use eq_rect to convert "x : bool_or_nat b" to "x : bool_or_nat true" using "b = true" *)
Definition depx
  (b : bool)
  (x : bool_or_nat b)
  (y : match bool_true_false b with
         | left H => fb (eq_rect b bool_or_nat x true H)
         | right H => fn (eq_rect b bool_or_nat x false H)
       end)
  := 0.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List