axiom-math
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: FW: [Axiom-math] if-then-else: what is wrong?


From: Bill Page
Subject: RE: FW: [Axiom-math] if-then-else: what is wrong?
Date: Thu, 19 Jan 2006 14:56:49 -0500

On January 19, 2006 1:30 PM Fabio Stumbo wrote:
> 
> >> So: what is happening? Is the book wrong?!?!
> >
> Bill Page wrote:
> >
> > Worse than that: **both** :(
> >
> > You have found bugs in both the documentation and in the
> > implementation!
> 
> WOW! What a luck ;-)

Seriously, I think you have made a good contribution. Axiom
is now open source software and depends on reports of errors
such as yours. Sooner or later someone else will also help to
correct the problem.

> 
> > On the other hand the last example given in the book:
> >
> >  if i > 0
> >    then output("positive")
> >    else output("nonpositive")
> >
> > **is wrong** and it is also (correctly) reported as a syntax
> > error
> 
> Well, from a naif point of view, I can't see clearly, after the 
> documentation, why this is wrong. It doesn't look that bad...

That syntax in "pile" format would be equivalent to

  if i > 0 ( then output("positive"); else output("nonpositive") )

which would correspond to misplaced brackets { } in some other
languages.

> 
> >
> > The problem is that you are mixing the two methods of 
> > writing blocks. The use of the ';' separator in pile
> > syntax might be confusing since it is expected to be
> > used with ( ) to form a block.
> 
> I suspected that the problem was in the ";"  ...
> I didn't realize, reading the manual, that the two methods are
> incompatible: I just thought that ";" could be used like a
> separator for different commands on the same line, like it
> happens in other languages.

I agree but I would not say that they are "incompatible" -
only that the combination produces some unexpected results.
I think the Axiom implementation should probably be changed
to correspond to modern usages such as in Python and other
languages that use indentation.

> ...
> > 
> > I think you should try Axiom's hyperdoc browser. (Unfortunately
> > it is only currently available in the linux version of Axiom.)
> > Hyperdoc provides a lot of useful information of this kind for
> > the new Axiom user.
> >
> 
> Fortunately, I use only linux!
> Anyway, I must say that I never liked the Hyperdoc (moreover, 
> it crashes quite often).

Again, I agree. I also do not use Hyperdoc very much. My experience
is also that it often crashes, although I am not yet able to
document a specific sequence which causes a crash. If we could
report and reproduce such bugs, then it should not be difficult
to correct the problems. But even then, I do not much care for the
"look" of the user interface. There have been much discussion and
some programming work to replace Hyperdoc with a modern web
browser interface, but so far we do not have a good replacement
for Hyperdoc.

> My preferred type of documentation is of more "synthetic" 
> type. From this point of view, I like very much Mathematica 
> help system.

Could you explain more what you mean by "synthetic". Could you
give some examples?

> But this is only personal taste.

I am glad that you mentioned it.

> 
> I say that "I never liked" because I didn't start this month 
> using axiom: I used it extensively in my PhD thesis to compute
> cohomology of Artin groups 10 years ago. It is true, anyway,
> that since then I stopped to use it because I couldn't afford
> its price (where I got my PhD the university had a license, after
> I should have paid myself!)
> 
> Now that it is free, I am converting back to it and this year 
> I am going to use it in my lectures. So, my question about the 
> documentation was from the point of view of my students... ;-))
> 

Excellent! This is exactly the kind of use of Axiom that I think
we need to encourage. I am sure you can expect to receive a lot of
help from the Axiom user group with any problems that you report
here.

Are you aware that there is new tutorial book by Tim Daly about
Axiom that can be purchased through the university book store
(ISBN 141166597X)

http://www.bookfinder4u.com/IsbnSearch.aspx?isbn=141166597X&mode=direct

or direct from the publisher:

http://www.lulu.com/content/190827

I hope that this will encourage the use of Axiom in teaching.

Regards,
Bill Page.






reply via email to

[Prev in Thread] Current Thread [Next in Thread]