Skip to Content.
Sympa Menu

coq-club - [Coq-Club] Partial functions in Coq

coq-club AT inria.fr

Subject: The Coq mailing list

List archive

[Coq-Club] Partial functions in Coq


Chronological Thread 
  • From: Iain Whiteside <Iain.Whiteside AT newcastle.ac.uk>
  • To: "coq-club AT inria.fr" <coq-club AT inria.fr>
  • Subject: [Coq-Club] Partial functions in Coq
  • Date: Thu, 25 Sep 2014 15:31:23 +0000
  • Accept-language: en-GB, en-US

Dear all,

I am investigating the ways in which different theorem provers handle
undefinedness. In Isabelle, for example, 5/0 is represented as some number,
but we cannot reason about it; alternatively, partial functions can be
encoded in a monad (None | Some x).

I’d be interested to hear what is the (if any) canonical way of representing
partiality in Coq and pCiC? For example, how could a recursive difference
function like below (deliberately partial) be represented?

diff (i,j) = if i = y then 0 else diff(i+1,j) + 1

additionally, could a theorem such as

forall i j. diff(i,j) = i - j \/ diff(j,i) = j - i

Many thanks in advance,

Iain


Archive powered by MHonArc 2.6.18.

Top of Page