Thanks. I was wondering why declaring the polynomial ring helped, but
this helps me understand.
Fernando
On 3/7/2020 3:00 PM, Simon King wrote:
On 2020-03-07, Eric Gourgoulhon wrote:
You should use simplify_full() instead of simplify():
Or you should rather use *polynomials* instead of gene
On 2020-03-07, Eric Gourgoulhon wrote:
> You should use simplify_full() instead of simplify():
Or you should rather use *polynomials* instead of general symbolic
variables, provided of course that all your expressions are multivariate
rational functions (which is the case here):
> sage: var('s t
You should use simplify_full() instead of simplify():
sage: var('s t')
(s, t)
sage: thirdroot = ((s^2 - 1)*t^2 - s^2 + 1)/(s^2 + 2*s*t + t^2)
sage: factor(thirdroot + 1)
(s*t + 1)^2/(s + t)^2
sage: a = thirdroot + 1 - (s*t + 1)^2/(s+t)^2
sage: a
((s^2 - 1)*t^2 - s^2 + 1)/(s^2 + 2*s*t + t^2) - (s*t