On Wed, Jul 9, 2008 at 6:32 PM, Gabriel Dos Reis wrote: > On Wed, Jul 9, 2008 at 3:31 PM, Bill Page wrote: >> ... >> If you expect to be able to write: >> >> x:Float >> x+1.0 >> >> what is the possible type of the result? > > Symbolic Float -- as explained in the `computing with unknowns' paper. >
Ah, I wish I could be at the meeting in Bristol to discuss this in detail. Maybe at ISSAC? >> What operation is represented >> by '+'? > > The `+' there is the modemap for the + that operates on Floats. Note that > x + 1.0 is not a Float, therefore, the code that implements the `+' operation > is not called, until x is actually substituted with a Float value. > > The value x + 1.0 -- which is of type Symbolc Float, is internally > a typed AST, with the node trhe modemap for `+', and leaves, the > Float value 1.0 and the symbol x. > >> What are the types of it's arguments? > > See above. > So this involves both a new mode for evaluating expressions in the Interpreter as well as a new domain constructor? Sounds like a lot of work! What is the role of the argument to the domain constructor? When is it used? What is the result of evaluating something like this? x:Integer y:Float x+y >> >> In the Axiom interpreter, not specifying any type for x is equivalent >> to declaring >> >> x:Variable(x) > > No, that is absolutely false. Not declaring `x' results in the > interpreter evaluating the *expression* `x' to a value of type > Variable x with internal representation the symbol x. > > The key is to distinguish declaration from the evaluation of an > identifier as an expression. > In what sense is it not "equivalent"? > > In the augmented OpenAxiom interpreter, not giving a > value to x in > > x:Float > > results in the evaluation of the *expression* `x' to evaluate to > a value of type Symbolic Float with internal representation > the symbol x. So where the interpreter used to say: x is declared as being in Float but has not been given a value. it now inserts a value of this type. Does it apply to all types? What happens if I write: x:Polynomial Integer without providing any value. Is 'x' evaluated as Symbolic Polynomial Integer? If not, how is that prevented? ----- I know these questions might lead to a lot of technical details, so if you would prefer to delay further discussion until we next meet, or at a later time please feel free. I think this is an exciting development for OpenAxiom users and could have a big impact on it's acceptance in the community. Thanks! Regards, Bill Page. ------------------------------------------------------------------------- Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW! Studies have shown that voting for your favorite open source project, along with a healthy diet, reduces your potential for chronic lameness and boredom. Vote Now at http://www.sourceforge.net/community/cca08 _______________________________________________ open-axiom-devel mailing list open-axiom-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/open-axiom-devel