A solution finder for Language, Proof and Logic problems
I wrote it when I was taking the class even though it took much more time than actually doing the two or three problems (I was only taking the second half of the course, in which the sort of problems for which it can provide results have less prominence) for which it works took. I make it public now because I just remembered it? The textbook poses certain problems in terms of either finding a model for a bunch of statements or providing a counterexample to a claim, where the world in which one does this is of blocks of various sizes, shapes and positions; predicates are, eg, "is small" or "is to the right of" or "is the same shape as". Here's the script; a sample input module has a little explanation. If 15-32.py is in one's import path, then one can do this:
$ python /path/to/board.py 15-32
a: Cube(2,1,small)
b: Tetrahedron(0,1,small)
c: Cube(2,1,small)
$
The output being, of course, the names and natures of the blocks constituting a solution (in this case a counterexample to a claim about a relation's transitivity, with one object having two names). Since for any problem it's the case that either a model can be constructed to do the right thing (whatever that might be) or a proof can be constructed showing that the right thing can't be done, if one attempts to find a solution with this script and none is generated (assuming it's got no bugs, that is), that constitutes, at least pragmatically, a proof that none can be generated. Unfortunately, the program used to grade these things is an intuitionist and demands a postive proof.
Comments
on 2008-05-01 18:30:48.0, mwm433 commented:
hello there,
i'm kind of stuck on some problems of language proof and logic course( book by barwise and etchemendy). i'm basically having problems with proofs so anybody can help me out plz. i would sure appreciate it. my email address is mwaleed316@hotmail.com
and, further, on 2008-11-24 20:41:39.0, shawna commented:
im stuck with examples of chapter 10... 10.25 to 10.29, can anyone help me out??
and, further, on 2009-05-13 14:32:43.0, shona commented:
can anybody help me out with chapter 8???
and, further, on 2009-05-13 14:34:07.0, shona commented:
i need help with chapter 8 examples 8.20, 8.19,8.35, 8.36, 8.45, 8.46 plz send me on sonam_simmy@yahoo.co.in
and, further, on 2010-04-14 1:21:20.0, the dude commented:
Dear dummies from a few years ago: google 'language proof logic hints'
and, further, on 2010-04-27 21:48:18.0, daisy commented:
Hello would u please help me am stuck on 8.36 and 8.52 thanks
and, further, on 2017-02-01 9:56:19.0, gurpreet kaur commented:
I am having a problem in 6.4, 6.5 6.6 6.9 6.10 and 6.11 can anybody help me out