ASKSAGE: Sage Q&A Forum - RSS feedhttps://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Fri, 24 Jul 2020 19:12:44 +0200Reduction to a rational expressionhttps://ask.sagemath.org/question/52656/reduction-to-a-rational-expression/I have the the following expression:
$ tan(m \cdot actan(x) + n \cdot arctan(y))$
For what values of $n,m \in \mathbb{N}$ is this expression reducible to a rational expression in $R[x,y]$, where $R$ is a generic ring?
Is there some rule $lhs => rhs $ that is needed in order to get a rational expression form the expression above?salFri, 24 Jul 2020 19:12:44 +0200https://ask.sagemath.org/question/52656/another factoring polynomials questionhttps://ask.sagemath.org/question/49709/another-factoring-polynomials-question/I have the following expression:
f = u^2*v*x + 3*u*v^2*x + 2*v^3*x + u^2*x^2 + 5*u*v*x^2 + 5*v^2*x^2 + 2*u*x^3 + 4*v*x^3 + x^4 + 2*u^2*v*y + 6*u*v^2*y + 4*v^3*y + 2*u^2*x*y + 12*u*v*x*y + 12*v^2*x*y + 6*u*x^2*y + 12*v*x^2*y + 4*x^3*y + u^2*y^2 + 6*u*v*y^2 + 6*v^2*y^2 + 6*u*x*y^2 + 12*v*x*y^2 + 5*x^2*y^2 + 2*u*y^3 + 4*v*y^3 + 2*x*y^3 + u^2*v*z + 3*u*v^2*z + 2*v^3*z + u^2*x*z + 6*u*v*x*z + 6*v^2*x*z + 3*u*x^2*z + 6*v*x^2*z + 2*x^3*z + u^2*y*z + 6*u*v*y*z + 6*v^2*y*z + 6*u*x*y*z + 12*v*x*y*z + 5*x^2*y*z + 3*u*y^2*z + 6*v*y^2*z + 3*x*y^2*z + u*v*z^2 + v^2*z^2 + u*x*z^2 + 2*v*x*z^2 + x^2*z^2 + u*y*z^2 + 2*v*y*z^2 + x*y*z^2
and I would like to simplify it by gathering and factoring partial sums
u, u+v,...,u+v+x+y+z
v, v+x,...,v+x+y+z
x, x+y,x+y+z,
y,y+z
z
(I have reason to expect that the expression will look quite a bit nicer if I do this, introducing notation for the sums of course, like h_{ij} = the sum of variables i up to j)
My first lame try at this was to ask sage to rational_simplify() quotients f/(u+v+x+y+z),...,f/(u+v), and so on, hoping to see more than just one big fraction. It didn't work.
Any insights/suggestions/corrections would be much appreciated!
Thanks,
anneWed, 29 Jan 2020 18:27:50 +0100https://ask.sagemath.org/question/49709/