coq-club AT inria.fr
Subject: The Coq mailing list
List archive
- From: "Wan Hai" <wan.whyhigh AT gmail.com>
- To: "Coq Club" <coq-club AT pauillac.inria.fr>
- Subject: [Coq-Club] How to prove functions are equal?
- Date: Mon, 2 Jun 2008 14:15:07 +0200
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=wLEP0RaduSvecfly8vZr3jr+8Z+JKDM5ZsgoVpl9dzYNV9U+MytgRtu3uCJEr8u5lxw+2q4HqXStYAx836JGDocNYF9O1u7ixTDxBLfJzRjk2EmeHSZoJ/T706qFH4o2Tr7779QMAyb8tgrpUX/bYs0GsycE9vDRn8/QNsg3Qps=
- List-archive: <http://pauillac.inria.fr/pipermail/coq-club/>
Deal all,
Here I have a function fc:
------------------------------
fc =
fix fc (n : nat) (c : nat -> nat) {struct n} : nat :=
match n with
| 0 => c 1
| S n' => fc n' (fun v : nat => c (n * v))
end
------------------------------
which is of type: nat -> (nat -> nat) -> nat.
I want to prove that:
forall m1 m2 n, fc n (fun x=>m1*m2*x) = fc n (fun x=>m2*m1*x)
It is obviously right. I proved this in Coq by "cut ((fun x=>m1*m2*x)
= (fun x=>m2*m1*x))" and then prove "(fun x=>m1*m2*x) = (fun
x=>m2*m1*x)" by an extensionality axiom of function which says that:
forall f g, (forall n, f n = g n) -> f = g.
Is there another way to prove this not using the extensionality axiom?
Thanks in advance!
--
Best regards,
Hai Wan
- [Coq-Club] How to prove functions are equal?, Wan Hai
- Re: [Coq-Club] How to prove functions are equal?,
Adam Chlipala
- Re: [Coq-Club] How to prove functions are equal?, Bruno Barras
- Re: [Coq-Club] How to prove functions are equal?,
Florian Hatat
- Re: [Coq-Club] How to prove functions are equal?, Wan Hai
- Re: [Coq-Club] How to prove functions are equal?,
Conor McBride
- Re: [Coq-Club] How to prove functions are equal?,
Robin Green
- Re: [Coq-Club] How to prove functions are equal?, Conor McBride
- Re: [Coq-Club] How to prove functions are equal?, Thorsten Altenkirch
- Re: [Coq-Club] How to prove functions are equal?,
Robin Green
- Re: [Coq-Club] How to prove functions are equal?,
Adam Chlipala
Archive powered by MhonArc 2.6.16.