From rl47 at hw.ac.uk  Mon Oct  8 18:39:40 2007
From: rl47 at hw.ac.uk (Robert Lamar)
Date: Mon Oct  8 21:25:55 2007
Subject: [Logiweb] Curious Logiwiki behavior
Message-ID: <470A5D4C.5090407@hw.ac.uk>

Good day,

I am a PhD student in Edinburgh, Scotland who was first introduced to 
Logiweb at MKM '07 [1].  Just this month, I have finally found time to 
start investigating it.  To that end, I have begun to proceed through 
the tutorials at logiweb.eu [2], and have encountered some strange 
behavior which I am unable to duplicate predictably.

The same problem has appeared twice:  After completing the Logiweb 
Submission form [3], I submit the page (with the strings org="hwu" and 
name="rlamar", if it helps) and receive the following error:

--------begin Logiwiki response--------
Frontend
Reverse lookup of 
http://logiweb.eu/logiweb/wiki/hwu/rlamar/../../../page/check/latest/vector/page.lgw
Reverse lookup of 
http://logiweb.eu/logiweb/wiki/hwu/rlamar/../../../page/Peano/latest/vector/page.lgw
Reverse lookup of 
http://logiweb.eu/logiweb/wiki/hwu/rlamar/../../../page/base/latest/vector/page.lgw
Frontend: parsing associativity sections
Frontend: parsing body
---

\section{Theorem}
We now state Lemma 3.2l of \cite{Mendelson87}:
"[ PA lemma 3.2|
---
l : all x : 0 * x = 0 end lemma ]"
\section{Proof}
"[ PA proof of 3.2l :
---
File Form input around line 153 char 16:
No interpretations
Goodbye
--------end Logiwiki response--------

This was the verbatim response of the second of the failed attempts. 
The astute reader will note that this happened while completing Tutorial 
T03.  It was to be my first attempt at this tutorial.  I had similar 
problems with my first attempt at Tutorial T02.

The common thread seems to be that on the occasions that the submission 
failed, I either typed the exercise by hand or copied it in pieces to 
the submission page.

I am sorry that my query is verbose.  Is what I describe here a known 
problem?  The "No Interpretations" error is rather meaningless to me, at 
this stage.

Thank you,
Robert

[1] Mathematical Knowledge Management, 
http://www.cs.bham.ac.uk/~mmk/events/MKM07/
[2] http://logiweb.eu/logiweb/tutorial/
[3] http://logiweb.eu/logiweb/tutorial/create.html

-- 
Robert Lamar
PhD Student
http://www.macs.hw.ac.uk/~rob/
From grue at diku.dk  Mon Oct  8 22:05:01 2007
From: grue at diku.dk (Klaus Ebbe Grue)
Date: Mon Oct  8 22:05:02 2007
Subject: [Logiweb] Curious Logiwiki behavior
In-Reply-To: <470A5D4C.5090407@hw.ac.uk>
References: <470A5D4C.5090407@hw.ac.uk>
Message-ID: <Pine.LNX.4.64.0710082128370.6141@tyr.diku.dk>

Hi Robert,

> I am a PhD student in Edinburgh, Scotland who was first introduced to Logiweb 
> at MKM '07 [1].  Just this month, I have finally found time to start 
> investigating it.

Welcome to the list

> To that end, I have begun to proceed through the tutorials 
> at logiweb.eu [2], and have encountered some strange behavior which I am 
> unable to duplicate predictably.
> The same problem has appeared twice:  After completing the Logiweb Submission 
> form [3], I submit the page (with the strings org="hwu" and name="rlamar", if 
> it helps) and receive the following error:
>
> --------begin Logiwiki response--------
> Frontend
> Reverse lookup of 
> http://logiweb.eu/logiweb/wiki/hwu/rlamar/../../../page/check/latest/vector/page.lgw
> Reverse lookup of 
> http://logiweb.eu/logiweb/wiki/hwu/rlamar/../../../page/Peano/latest/vector/page.lgw
> Reverse lookup of 
> http://logiweb.eu/logiweb/wiki/hwu/rlamar/../../../page/base/latest/vector/page.lgw
> Frontend:  parsing associativity sections
> Frontend:  parsing body

Everything until this point looks fine

> ---
>
> \section{Theorem}
> We now state Lemma 3.2l of \cite{Mendelson87}:
> "[ PA lemma 3.2|
> ---
> l : all x : 0 * x = 0 end lemma ]"
> \section{Proof}
> "[ PA proof of 3.2l :
> ---
> File Form input around line 153 char 16:
> No interpretations
> Goodbye

The "No interpretations, Goodbye" error message is one of the most common 
error messages from the system, and it can be quite frustrating. Usually, 
however, it is easy to locate the problem. The message means that the pyk 
compiler (which is the one which generates the Logiwiki response) has 
been able to parse everything up to line 153, character 15, but was 
unable to parse character 16.

The error message consists of "---" followed by the last characters up to 
line 153, character 15, followed by a vertical bar (so possible blanks at 
the end of the line become visible) followed by "---" followed by some 
line from line 153, character 16 and on, followed by "---" followed by the 
error message.

So the compiler could parse
   PA proof of 3.2
but could not parse
   PA proof of 3.2l
In other words, the compiler knows something whose name starts with 3.2 
but does not know something called 3.2l.

Your page references the Peano page which proves lemmas named 3.2a, 3.2b, 
and so on, so that explains why the compiler can parse up to "3.2".

But the compiler does not know a construct named "3.2l".

The 3.2l construct is one you are supposed to introduce. To do so, add a 
line saying
   "" 3.2l
in the first PREASSOCIATIVE section in the upper window on the submission 
form. The upper window should contain something like the following:

...
PREASSOCIATIVE
"check" check
"Peano" Peano
"base" base
"" 3.2l
PREASSOCIATIVE
"base" +"
...

where the 3.2l line is one you must type.

The 3.2l line comprises an empty string followed by the 3.2l construct. 
The empty string indicates that the 3.2l construct is not imported from 
any referenced page but, rather, is a construct you define. Tutorial 
T05 gives a systematic treatment of how to introduce constructs.

I think I will just give answers to two obvious questions right ahead:

Q: Why doesn't the compiler give a better error message?

A: It can't. Compilers for languages with a fixed syntax can typically 
give very precise error messages like "semicolon expected" or "3.2l 
unknown". But the present language has no fixed syntax and that makes it 
*extremely* difficult to give a better error message then the above when 
something is unparsable. Fortunately, the system can give better error 
messages in other situations. See Tutorial T05 for more on the syntax.

Q: Then, why doesn't the website or the tutorial give an explanation like 
the one above.

A: That is because of lack of time. Sorry.

> I am sorry that my query is verbose.

That was very helpful. In general, when asking questions, it is good to 
have the complete output from the system as well as the input (the 
contents of the upper and lower window of the submission form). Sometimes 
even indivial switches and the "org" and "name" fields are useful to have.

I hope the answer helps. Else ask again.

Cheers,
Klaus
From frederikeriksen at get2net.dk  Mon Oct  8 23:22:47 2007
From: frederikeriksen at get2net.dk (Frederik Eriksen)
Date: Mon Oct  8 23:25:42 2007
Subject: [Logiweb] Re: Curious Logiwiki behavior
In-Reply-To: <470A5D4C.5090407@hw.ac.uk>
References: <470A5D4C.5090407@hw.ac.uk>
Message-ID: <470A9FA7.4060108@get2net.dk>

Robert Lamar wrote:

> \section{Theorem}
> We now state Lemma 3.2l of \cite{Mendelson87}:
> "[ PA lemma 3.2|
> ---
> l : all x : 0 * x = 0 end lemma ]"
> \section{Proof}
> "[ PA proof of 3.2l :
> ---
> File Form input around line 153 char 16:
> No interpretations
> Goodbye
> --------end Logiwiki response--------
>
Hi Robert,

Are you sure you remembered to include the line

"" 3.21

in the header of your file? This line tells Logiweb that '3.21' is a 
valid syntactic construct. Without this line, Logiweb fails to parse 
'3.21'; it has "no interpretations" of '3.21', so to speak.

Best regards
Frederik Eriksen, Denmark.
(My M.Sc. thesis was about Logiweb).

From rl47 at hw.ac.uk  Tue Oct  9 15:57:35 2007
From: rl47 at hw.ac.uk (Robert Lamar)
Date: Tue Oct  9 16:02:31 2007
Subject: [Logiweb] Curious Logiwiki behavior
In-Reply-To: <Pine.LNX.4.64.0710082128370.6141@tyr.diku.dk>
References: <470A5D4C.5090407@hw.ac.uk>
	<Pine.LNX.4.64.0710082128370.6141@tyr.diku.dk>
Message-ID: <470B88CF.6010203@hw.ac.uk>

Klaus,

Klaus Ebbe Grue wrote:
 > Robert Lamar wrote:
>> I am a PhD student in Edinburgh, Scotland who was first introduced to 
>> Logiweb at MKM '07 [1].  Just this month, I have finally found time to 
>> start investigating it.
> 
> Welcome to the list

Thank you.  :c)  I appreciate the welcome and the prompt responses to my 
question.

>> [ ... description of my problem... ]
>> ---
>> File Form input around line 153 char 16:
>> No interpretations
>> Goodbye
> 
> The "No interpretations, Goodbye" error message is one of the most 
> common error messages from the system, and it can be quite frustrating. 

In fact, this was one of the main things I wanted to confirm: that it 
was "to be expected".  Even if it is unhelpful, it's good to know that 
all users cope with this at some point.

> [ ...analysis of the specific error... ]
> 
> The 3.2l construct is one you are supposed to introduce. To do so, add a 
> line saying
>   "" 3.2l
> in the first PREASSOCIATIVE section in the upper window on the 
> submission form. 

I recall this from the tutorial, and my future (successful) attempts 
included the line in question.  This may have been the primary reason 
for confusion:

   1. On one attempt, I would overlook that line, and it would fail.
   2. Because I was working on the crossbrowser submission form, I could
      not go back to my code to find errors.
   3. On the following attempt, I was more attentive, and did not make
      such mistakes.

I have learned my lesson, and now make my experiments in a text editor, 
copying them from there into the submission page.

> [ ...more problem analysis... ]
> 
> The 3.2l line comprises an empty string followed by the 3.2l construct. 
> The empty string indicates that the 3.2l construct is not imported from 
> any referenced page but, rather, is a construct you define. Tutorial T05 
> gives a systematic treatment of how to introduce constructs.

Thank you for the thorough explanation.  I will reach Tutorial T05 soon, 
and look forward to gaining further insights.

> I think I will just give answers to two obvious questions right ahead:
> 
> Q: Why doesn't the compiler give a better error message?
> 
> A: It can't. Compilers for languages with a fixed syntax can typically 
> give very precise error messages like "semicolon expected" or "3.2l 
> unknown". But the present language has no fixed syntax and that makes it 
> *extremely* difficult to give a better error message then the above when 
> something is unparsable. Fortunately, the system can give better error 
> messages in other situations. See Tutorial T05 for more on the syntax.

This is reasonable.  I can see that improving the error messages is a 
hard problem, and should be able to live with the situation.

> Q: Then, why doesn't the website or the tutorial give an explanation 
> like the one above.
> 
> A: That is because of lack of time. Sorry.

But of course.  Any documentation is appreciated, but it certainly takes 
time and energy to produce.

Thanks again for the prompt and thorough answer.  I may be dropping in 
again with other questions, but my previous query has been satisfied.

Cheers,
Robert
From rl47 at hw.ac.uk  Tue Oct  9 16:04:42 2007
From: rl47 at hw.ac.uk (Robert Lamar)
Date: Tue Oct  9 16:09:43 2007
Subject: [Logiweb] Re: Curious Logiwiki behavior
In-Reply-To: <470A9FA7.4060108@get2net.dk>
References: <470A5D4C.5090407@hw.ac.uk> <470A9FA7.4060108@get2net.dk>
Message-ID: <470B8A7A.8020409@hw.ac.uk>

Frederik,

Frederik Eriksen wrote:
> Robert Lamar wrote:
> 
>> \section{Theorem}
>> We now state Lemma 3.2l of \cite{Mendelson87}:
>> "[ PA lemma 3.2|
>> ---
>> l : all x : 0 * x = 0 end lemma ]"
>> \section{Proof}
>> "[ PA proof of 3.2l :
>> ---
>> File Form input around line 153 char 16:
>> No interpretations
>> Goodbye
>> --------end Logiwiki response--------
>>
> Hi Robert,
> 
> Are you sure you remembered to include the line
> 
> "" 3.21
> 
> in the header of your file? This line tells Logiweb that '3.21' is a 
> valid syntactic construct. Without this line, Logiweb fails to parse 
> '3.21'; it has "no interpretations" of '3.21', so to speak.

As I examine the situation, it becomes obvious that this was the 
problem.  My larger problem was that I submitted the code, which 
disappeared into the ether, and /then/ I received the unhelpful error 
message reflected above.  Thus, I couldn't go back and discover what was 
wrong with my submission.

More recently, I am storing these things in text files before pasting 
them into the Logiwiki submission form, so I can have a second look when 
things go awry.

Thank you for your efficient analysis of the situation.  It is good to 
understand the classes of problem that might elicit this "No 
interpretations, Goodbye" error.

Robert
From grue at diku.dk  Fri Oct 12 22:57:56 2007
From: grue at diku.dk (Klaus Ebbe Grue)
Date: Fri Oct 12 22:57:57 2007
Subject: [Logiweb] Re: Curious Logiwiki behavior
In-Reply-To: <470B8A7A.8020409@hw.ac.uk>
References: <470A5D4C.5090407@hw.ac.uk> <470A9FA7.4060108@get2net.dk>
	<470B8A7A.8020409@hw.ac.uk>
Message-ID: <Pine.LNX.4.64.0710122252070.14331@tyr.diku.dk>

Hi Robert,

> As I examine the situation, it becomes obvious that this was the problem.  My 
> larger problem was that I submitted the code, which disappeared into the 
> ether, and /then/ I received the unhelpful error message reflected above. 
> Thus, I couldn't go back and discover what was wrong with my submission.

Maybe that is related to something I have experienced in some browsers: 
When submitting something and then clicking "back" a number of times to 
get back and correct some errors, one just get some message about "this 
page contain POST code" or something. Then the trick is to go all the way 
back to the submission form in one step through the history of the 
browser.

I have experienced the same in some browsers. I think the trick is not to 
go back one page at a time (because then one gets

> More recently, I am storing these things in text files before pasting them 
> into the Logiwiki submission form, so I can have a second look when things go 
> awry.

That sounds reasonable. I suppose you have noticed that you don't need to 
split the text in upper and lower pane but just can paste the entire text 
into one of the panes (the two panes are just concattenated anyway).

It reminds me that I should place an alternative submission form which 
uploads the text file directly so that one does not need to copy-paste. 
That must be at next release.

Cheers,
Klaus
From rl47 at hw.ac.uk  Tue Oct 16 14:56:33 2007
From: rl47 at hw.ac.uk (Robert Lamar)
Date: Tue Oct 16 14:59:50 2007
Subject: [Logiweb] Larger examples?
Message-ID: <4714B501.3030600@hw.ac.uk>

Logiweb users,

Having worked through the tutorials (which are well-written, in my 
opinion), I am now looking for other sources of information, guidance, 
and inspiration as I attempt to improve my working knowledge of Logiweb. 
  I have found the Peano example, but it is very foundational.  Are 
there any examples from other parts of mathematics?  Perhaps pages which 
define things such as groups, polynomials, or graphs?

As an exercise for myself, I am attempting to define a bit of ring 
theory in the system, and would be grateful for pointers to models and 
other documentation which may exist.  While the tutorials were a good 
introduction to the flavor of the system, the examples there are quite 
small.

Thanks in advance for your help.

Robert

-- 
Robert Lamar
PhD Student
http://www.macs.hw.ac.uk/~rob/
From frederikeriksen at get2net.dk  Wed Oct 17 15:25:17 2007
From: frederikeriksen at get2net.dk (Frederik Eriksen)
Date: Wed Oct 17 15:28:16 2007
Subject: [Logiweb] Re: Larger examples?
In-Reply-To: <4714B501.3030600@hw.ac.uk>
References: <4714B501.3030600@hw.ac.uk>
Message-ID: <47160D3D.9010705@get2net.dk>

Robert Lamar wrote:

> Logiweb users,
>
> Having worked through the tutorials (which are well-written, in my 
> opinion), I am now looking for other sources of information, guidance, 
> and inspiration as I attempt to improve my working knowledge of 
> Logiweb.  I have found the Peano example, but it is very 
> foundational.  Are there any examples from other parts of 
> mathematics?  Perhaps pages which define things such as groups, 
> polynomials, or graphs?
>
> As an exercise for myself, I am attempting to define a bit of ring 
> theory in the system, and would be grateful for pointers to models and 
> other documentation which may exist.  While the tutorials were a good 
> introduction to the flavor of the system, the examples there are quite 
> small.
>
> Thanks in advance for your help.
>
> Robert
>
Hi Robert,

Well, there is my M.Sc. thesis "Constructing the real numbers in 
Logiweb" (URL: www.topps.diku.dk/eriksen/realNumbers). In the thesis, I 
develop some of Cantor's theory of the real numbers, using ZF set theory 
(and propositional logic and predicate logic). A word of caution: Most 
of the thesis is in Danish. However, since the formal theorems of the 
thesis are in English, it may still be of some use to you.

Best regards
Frederik.

From grue at diku.dk  Sun Oct 21 22:21:40 2007
From: grue at diku.dk (Klaus Ebbe Grue)
Date: Sun Oct 21 22:21:43 2007
Subject: [Logiweb] Larger examples?
In-Reply-To: <4714B501.3030600@hw.ac.uk>
References: <4714B501.3030600@hw.ac.uk>
Message-ID: <Pine.LNX.4.64.0710212057330.12516@tyr.diku.dk>

Hi Robert,

> Having worked through the tutorials (which are well-written, in my opinion),

Thanks

> I am now looking for other sources of information, guidance, and inspiration 
> as I attempt to improve my working knowledge of Logiweb.

Tutorial T05 covers syntax. I suppose a good next step would be to 
understand the semantics of Logiweb. Unfortunately, I have not yet written 
tutorials on semantics. (But I will give a talk on that in Edinburgh at 
the end of this month - there will probably also be a hands-on session).

At the end of Tutorial T05 it is explained how syntax is converted into a 
"vector" (i.e. "sequence of bytes"). The "semantics" of Logiweb defines 
what such vectors "mean".

I think the most compressed description of what Logiweb does with vectors 
is at http://logiweb.eu/logiweb/doc/browser/loading.html. So, at present,
http://logiweb.eu/logiweb/doc/browser/loading.html is the best available 
description of the semantics of Logiweb.

You probably need a bit of context to get started reading
http://logiweb.eu/logiweb/doc/browser/loading.html:

At the end of Tutorial T05 there is a section entitle "Amnesia" which 
states that once the frontend of the pyk compiler has converted the pyk 
source into a reference and a vector, the pyk compiler forgets the pyk 
source and continues working on the reference and vector.

The relation between reference and vector is as follows: given a vector, 
one can extract the reference from the vector. Once a vector is published 
on Logiweb, one can also convert the other way, i.e. from reference to 
vector. Converting a reference to a vector is called "fetching" in the 
terminology used in http://logiweb.eu/logiweb/doc/browser/loading.html.

http://logiweb.eu/logiweb/doc/browser/loading.html starts from the 
reference, describes how the reference is converted to a vector, and then 
describes what Logiweb does to that vector: it "loads" it, "renders" it, 
and "executes" it.

If you read http://logiweb.eu/logiweb/doc/browser/loading.html right after 
reading Tutorial T05 it may be puzzling that Tutorial T05 leaves you with
a vector but http://logiweb.eu/logiweb/doc/browser/loading.html starts 
with a reference. I hope the explanation above bridges that gap.

Once you are through http://logiweb.eu/logiweb/doc/browser/loading.html 
you will probably have noticed that there are many references to the 
"base" page. In Tutorial T05 you saw that you are the one who defines the 
syntax. It is not forced upon you as it is in e.g. C or Java. After 
reading http://logiweb.eu/logiweb/doc/browser/loading.html you will know 
that the same holds for the semantics: you define the semantics you want 
to use and then publishes it on Logiweb. If you want to use the semantics 
I have defined, fine. Just reference the "base", "check", or "Peano" page 
as first reference. If you want to attach a completely different semantics 
to Logiweb, fine. Just define it, publish it on Logiweb, and reference it 
as first reference in your future work. But before you decide to take 
complete control over Logiweb, I suggest you work with the semantics I 
have published on the "base" page.

The remark above also gives a hint on another source of information: You 
may simply read the "base" page (there are lots of references to it from 
http://logiweb.eu/logiweb/doc/browser/loading.html). The only problem is 
that it is 50 pages long and might give you more details than you want. 
And if the "base" page does not discourage you, you may continue with the 
"check" and "Peano" pages.

> I have found the 
> Peano example, but it is very foundational.  Are there any examples from 
> other parts of mathematics?  Perhaps pages which define things such as 
> groups, polynomials, or graphs?

I agree that Frederiks Ph.D. thesis (which was effectively handed in by 
publishing it on Logiweb) is the most impressive piece of work that has 
been published on Logiweb to date. Unfortunately, it is written in Danish.

And then there are two rather big examples which have *not* been put on 
Logiweb yet, but which were written explicitly with that in mind. They are 
at http://www.diku.dk/~grue/papers/classical/classical.html and
http://www.diku.dk/~grue/papers/mac0102/

> As an exercise for myself, I am attempting to define a bit of ring theory in 
> the system, and would be grateful for pointers to models and other 
> documentation which may exist.  While the tutorials were a good introduction 
> to the flavor of the system, the examples there are quite small.

It *should* be possible to jump directly to such applications. But it is 
probably still a good idea to know a little about the semantics: you will 
probably soon want to program your own side conditions or your own proof 
tactics. And you probably soon want to save yourself a lot of typing by 
defining your own macros. And last, not least, you will need a little 
knowledge of the semantics the moment you need to "debug" a proof.

I hope it helps. I on my part will try to write some more tutorials. And 
don't hesitate to ask again.

Cheers,
Klaus
From rl47 at hw.ac.uk  Mon Oct 29 18:00:03 2007
From: rl47 at hw.ac.uk (Robert Lamar)
Date: Mon Oct 29 18:09:54 2007
Subject: [Logiweb] Re: Larger examples?
In-Reply-To: <47160D3D.9010705@get2net.dk>
References: <4714B501.3030600@hw.ac.uk> <47160D3D.9010705@get2net.dk>
Message-ID: <47261193.6000108@hw.ac.uk>

Frederik,

Frederik Eriksen wrote:
> Robert Lamar wrote:
>> Having worked through the tutorials (which are well-written, in my 
>> opinion), I am now looking for other sources of information, guidance, 
>> and inspiration as I attempt to improve my working knowledge of 
>> Logiweb.  I have found the Peano example, but it is very 
>> foundational.  Are there any examples from other parts of 
>> mathematics?  Perhaps pages which define things such as groups, 
>> polynomials, or graphs?
>>
>>  [...]
> 
> Well, there is my M.Sc. thesis "Constructing the real numbers in 
> Logiweb" (URL: www.topps.diku.dk/eriksen/realNumbers). In the thesis, I 
> develop some of Cantor's theory of the real numbers, using ZF set theory 
> (and propositional logic and predicate logic). A word of caution: Most 
> of the thesis is in Danish. However, since the formal theorems of the 
> thesis are in English, it may still be of some use to you.

Thank you, belatedly, for pointing me towards this document.  I am still 
familiarizing myself with it, but it looks like it may be quite helpful. 
  From my initial observations, it seems like there are plenty of 
cognates between Danish and English, so I should do well enough on that 
score.

Thanks,
Robert

