Bengt Richter wrote:
> you can do what you like, pretty much. I.e.,
>
>     cas = CAS()
>     cas.a        # like your plain a, where you said "that's it"
>
>
>     cas.a, cas.b = cas.Expr(), cas.Expr()
>     (cas.a + cas.b)/cas.c
>
> Etc.

Hmmm... feels like a good idea if extended to use properties as special
constructors:

>>> expr = CAS(Expr)
>>> expr.a
a
>>> type(expr.a)
<type 'Expr'>

>>> expr.a+expr.b
a+b

or a bit shorter if Expr becomes the "master algebra":

>>> _ = CAS(Expr)
>>> _.a + _.b
a+b

Regarding that an object oriented CAS will mix an arbitray number of
algebras/namespaces that use algebraic operators homogenously
referencing namespaces is a reasonable for providing clarity.

A helpfull suggestion. Thanks Bengt!

Regards,
Kay


Regards,
Kay

-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to