> Thinking loudly. In order to integrate trigonometric > functions we need imaginary unit. So, if not present we > need to add it, that is extend the original field. Currently > this is done by changing base ring from R to Complex(R). > OTOH if imaginary unit is present we should use it.
Hmmm... also thinking loudly... We cannot and should not have Complex Complex R, but what about a domain ComplexClosure(R: CommutativeRing): ComplexCategory(R) with ... == if R has with imaginary: () -> R then R else Complex R Would this be the wrapper that you want? To me that looks like an elegant solution. Of course there can be rings R that don't export "imaginary" and still have an element x that satisfies x^2+1=0. But I didn't want a condition that checks whether x^2+1 can be factored over R. As a first approximation, ComplexClosure would do what is needed, no? Adding conversion between R and ComplexClosure R shouldn't be difficult. 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 [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/fricas-devel. For more options, visit https://groups.google.com/d/optout.
