On 02/28/2017 01:14 PM, oldk1331 wrote: > My point is, from typed Spad value to untyped SExpression, there'll > be loss of information.
Very true. > If you encode type into SExpression, you have to decode it later. So > the only way is to "from typed Spad value directly to target language > expression". In fact, only the domain that represents a value knows exactly how this value would have to be entered on the command line, in order to produce the same value. But even that is not completely true. In order to make sure that 1 is interpreted as Integer/NNI/PI or even some identity element of a monoid or the identity of %, it would be necessary to output "1$NNI" (or the like) every time a value is transformed into a string that when read back gives the same value. Looks like a pretty tough task. I don't yet see a good design that works for all cases (even if one restricts to "reading back spad expressions"). Although it would be nice to print something so that the output can be read by Mathematica or Maple or Sage or ..., I don't think that can ever work properly. Oh... once there was OpenMath... Ralf -- 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 fricas-devel+unsubscr...@googlegroups.com. To post to this group, send email to fricas-devel@googlegroups.com. Visit this group at https://groups.google.com/group/fricas-devel. For more options, visit https://groups.google.com/d/optout.