Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

why doesn't rootscontract work with conjugate?

x=var('x')
assume(x,'real')
(sqrt(-x+1)*sqrt(x+1)).conjugate()._maxima_().rootscontract()._sage_()

It works without conjugate, but with conjugate it does not contract roots. Is there a workaround? I know I can do it by hand but, what I have above is a part of a much larger expression.

click to hide/show revision 2
retagged

why doesn't rootscontract work with conjugate?

x=var('x')
assume(x,'real')
(sqrt(-x+1)*sqrt(x+1)).conjugate()._maxima_().rootscontract()._sage_()

It works without conjugate, but with conjugate it does not contract roots. Is there a workaround? I know I can do it by hand but, what I have above is a part of a much larger expression.