2

I'm trying out Coq, but I'm not completely sure what I'm doing. Is:

Theorem new_theorem : forall x, P:Prop /\ Q:Prop

Equivalent to:

∀x ( P(x) and Q(x) )

Edit: I think they are.

shouya
  • 2,863
  • 1
  • 24
  • 45
Peter
  • 435
  • 1
  • 4
  • 9
  • I don't see a question here? Are you asking if they are the same? – tvanfosson Apr 15 '09 at 18:14
  • Well, I'm trying to use the logic statement in Coq but I don't really understand the syntax. I suppose the question really is "How do I write Ax ( P(x) and Q(x) ) in Coq?". – Peter Apr 15 '09 at 18:17

2 Answers2

3

Are you having problems with the syntax?

$ coqtop
Welcome to Coq 8.1pl3 (Dec. 2007)

Coq < Section Test.

Coq < Variable X:Set.
X is assumed

Coq < Variables P Q:X -> Prop.
P is assumed
Q is assumed

Coq < Theorem forall_test: forall x:X, P(x) /\ Q(x).
1 subgoal

  X : Set
  P : X -> Prop
  Q : X -> Prop
  ============================
   forall x : X, P x /\ Q x

forall_test < 
starblue
  • 55,348
  • 14
  • 97
  • 151
2

Well, to answer your question:

Section test.

  Variable A : Type.           (* assume some universe A *)
  Variable P Q : A -> Prop.    (* and two predicates over A, P and Q *)

  Goal forall x, P x /\ Q x.   (* Ax, ( P(x) and Q(x) ) *)

End test.
akoprowski
  • 3,297
  • 1
  • 18
  • 26