On Mon, Sep 15, 2008 at 10:25 PM, Waldek Hebisch wrote:
>
> Bill Page wrote:
>> Supoose I say: please consider the domain RomainNumeral.
>> You can use
>>
>> )show RomanNumeral
>>
>> and discover what it exports. Maybe I would like to "extend" this
>> list of exports to include new functions such as 'five', 'ten', 'fifty',
>> 'hundred' etc. It seems to me that I should be able to do this
>> without looking at the source code for RomanNumeral. This is
>> exactly what you *can* do with Aldor's extend. The only reason
>> you cannot do it some other way is because you cannot determine
>> exactly the category to which RomanNumeral belongs.
>>
>
> I think you misunderstood how Aldor extend works: when you extend
> D you effectively change category to which D belong.

I think I do understand how Aldor extend works. 'extend' is an
operation with some input and some result. When I *extend* D I
specifically intend to change D. There is an "old D" before the extend
operation, and a "new D" after the extend. Yes, "new D" belongs to
some new category.

> In Aldor you _can_ not change category after it is defined (extend
> is limited to ordinary domains).

I am not sure what you mean by "change category". Certainly I can
change which domains belong to a given category. Perhaps you mean that
I cannot change which operations a category exports? That is true but
it is not something that I am discussing here.

> So in Aldor you can extend D only because you _can not_ determine
> exactly the category to which D belong --

??? Every domain belongs to at least one category - even if it is
anonymous (not given a name).

> if you have Cat(D) in hand and you extend D than
> either Cat(D) will be out of date

The old value of Cat(D) will be out of date. If I use Cat(D) after
using extend then Cat(D) will evaluate to some new category.

> or you need to also extend Cat(D).

I do not understand what you mean by "extend Cat(D)". All that is
necessary is to evaluate it again in the new context.

> IMHO either will break a lot in Aldor design.
>

Actually I was not proposing this for Aldor since Aldor already has
extend, although I do not see any problem with doing so. My intention
was to propose a mechanism by which something equivalent to Aldor's
extend could be added to Spad.

Regards,
Bill Page.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"FriCAS - computer algebra system" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/fricas-devel?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to