On 02/03/2015 01:07 AM, Ralf Hemmecke wrote:
Wouldn't List(L) or Union(L, Record(ltilde: L, r: L)) be better? Or
maybe  Record(ltilde: L, r: Union(L, failed))?
I don't know, actually. Union(L, List(L)) seemed to best fit the
description of the function as mentioned in the paper.
However, Union(L, Record(ltilde: L, r: L)) also seems good as it offers
extra information about what the 2 elements actually mean in the latter
case.
Now suppose you use this function and you are only interested in the
operator, i.e. you don't care whether or not there is a corresponding r.

You would then call

   z: Union(L, Record(ltilde: L, r: L)) := integrate_sols(...)
   l: L := if z case L then z::L else (z::Record(ltilde: L, r: L)).ltilde

That is why I suggested

   Record(ltilde: L, r: Union(L, failed)).

It also better says what actually fails if it does fail.
I've changed the return type to the above now.
Actually just having

   List L

would work similarly, but I somehow don't like to return a list if it
can only have on or two elements. That's somehow misuse.
Yes, even I feel that way. That's why I was initially using Union(L, List L) instead of List L.
Ralf

Thanks,
Abhinav.

--
You received this message because you are subscribed to the Google Groups "FriCAS - 
computer algebra system" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/fricas-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to