On Sat, Feb 04, 2012 at 12:42:03AM +0000, Mark Clements wrote:
> A brief comment on function composition:
> 
> One can look at the various MappingPackage(s). In particular, 
> MappingPackage3 provides function composition using '*', as well as other 
> functional operations such as curryLeft and curryRight. One can then do 
> the following in the interpreter:
> 
> p(x:Integer):Boolean == x>1
> q(x:Boolean):Boolean == not x
> map(q * p, [1,2]) -- or
> map(not$Boolean * p, [1,2])
> 
> which are reasonably elegant. In Spad, one would first use 
> "import MappingPackage3(Integer,Boolean,Boolean)" (for *), as alluded 
> to by Waldek, and "import ListFunctions2(Integer,Boolean)" (for map) - 
> which are less than elegant.
> 

Thank you.
But where to set "import", in what place of the Spad code for a package, 
or a category etc.? I do not see examples.
What is the meaning of import?
If  f  is not imported from a package Foo, is can be used by  f$Foo,
is this so?
If  f  is imported from Foo, can it be used as `f' ?

Regards,

------
Sergei
[email protected]

-- 
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