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.Sun, 25 Apr 2021 22:03:53 +0200Get denominator with hold=Truehttps://ask.sagemath.org/question/56811/get-denominator-with-holdtrue/t2=x.mul(1/(x^2-x),hold=True)
t2.denominator()
results in x-1 instead of x*(x-1) or x^2-x. Is there any other way to obtain x^2-x?DammSun, 25 Apr 2021 22:03:53 +0200https://ask.sagemath.org/question/56811/numerator_denominator()https://ask.sagemath.org/question/10615/numerator_denominator/I have a very big rational function and i want to obtain the numerator and denominator.
with .numerator_denominator() it takes forever
with .numerator_denominator(False) not every term is expanded.
with .expand() and .combine() it takes forever and the result is not a single fraction.
I need a single fraction N(x)/D(x) where N and D are polynomials in x, it is not important how big !alessandroWed, 16 Oct 2013 18:58:48 +0200https://ask.sagemath.org/question/10615/divide numerator and denominator by certain valuehttps://ask.sagemath.org/question/8785/divide-numerator-and-denominator-by-certain-value/Hi,
is it somehow possible to divide the numerator and denominator of a fraction by the same value? For example, (a*b + c)/(b*d + a + c) gets (a + c/b)/(d + a/b + c/b) if I divide it by b. matthjesMon, 12 Mar 2012 05:55:24 +0100https://ask.sagemath.org/question/8785/How to Rationalize the Denominator of a Fraction ?https://ask.sagemath.org/question/8362/how-to-rationalize-the-denominator-of-a-fraction/Hi, experts.<br/>
<br/>
Is there any way to rationalize the denomintor of a fraction ?<br/>
<br/>
For example, I tried<br/>
a = 1 / (2 * sqrt(2) + 3)
b = a.simplify_full(); b;
c = a.simplify_factorial(); c;
d = a.simplify_radical(); d;
e = a.simplify_rational(); e;
expecting any of them to return "`3 - 2*sqrt(2)`" or "`-2*sqrt(2) + 3`". <br/>
However, all of the above commands return `1/(2*sqrt(2) + 3)`,<br/>
whose denominator is not rational.<br/>
<br/>
I know<br/>
(1) Sage uses Maxima.<br/>
(2) Standalone version of Maxima can rationalize the denominator by typing "`ratsimp(a), algebraic: true;`".<br/>
(3) Sage accepts "`maxima.ratsimp(a)`", but I don't know how to pass the Maxima option "`algebraic: true;`" to Sage.<br/>
Is there any way to rationalize the denominator with Sage ?<br/>
<br/>
Thanks in advance.<br/>
-Tatsuya
supertatSun, 09 Oct 2011 03:25:35 +0200https://ask.sagemath.org/question/8362/Radical in the denominator?https://ask.sagemath.org/question/7494/radical-in-the-denominator/Is there any way I can get a general complex number to display with the radical in the denominator, rather than having it rationalized? For example (1+i)/sqrt(2).Mike WittSun, 10 Oct 2010 13:00:07 +0200https://ask.sagemath.org/question/7494/