Skip to Content.
Sympa Menu

coq-club - Re: [Coq-Club] Question about proving the domain of a real-valued function

coq-club AT inria.fr

Subject: The Coq mailing list

List archive

Re: [Coq-Club] Question about proving the domain of a real-valued function


Chronological Thread 
  • From: Guillaume Melquiond <guillaume.melquiond AT inria.fr>
  • To: coq-club AT inria.fr
  • Subject: Re: [Coq-Club] Question about proving the domain of a real-valued function
  • Date: Wed, 12 Nov 2014 08:31:33 +0100

On 12/11/2014 08:03,
ncyms8r3x2 AT snkmail.com
wrote:
Let's say I have a function:
Definition f (x:R) := (x + 1)/(x - 1).

Is there anyway to prove what that 1 isn't in its domain?

No, because 1 is in its domain. The logic of Coq (and of most other proof assistants) is a logic of total functions. Even if you can't prove anything interesting about f(1), it is nonetheless a real number.

If you want to forcibly remove 1 from the domain of f, you can define it as follows:

Definition f (x:R) (_: x <> 1) := (x + 1)/(x - 1).

Or as follows:

Definition f (x: {t:R | t <> 1}) := (projS1 x + 1)/(projS1 x - 1).

But I would strongly advise against it.

Best regards,

Guillaume



Archive powered by MHonArc 2.6.18.

Top of Page