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, 23 Aug 2013 09:35:59 +0200How to simplify x^a/x into x^(a-1) OR how to solve...?https://ask.sagemath.org/question/10197/how-to-simplify-xax-into-xa-1-or-how-to-solve/Can any body show me which function simplifies x^a/x into x^(a-1)?
A related question is how to solve x^a == 2*x to have x = 2^(1/(a-1))?
Mathematica works out these questions well, but I'm a huge fan of Sage/Maxima, and eager to get an answer using Sage. Thanks!Wed, 17 Jul 2013 11:05:49 +0200https://ask.sagemath.org/question/10197/how-to-simplify-xax-into-xa-1-or-how-to-solve/Answer by tmonteil for <p>Can any body show me which function simplifies x^a/x into x^(a-1)?
A related question is how to solve x^a == 2*x to have x = 2^(1/(a-1))?
Mathematica works out these questions well, but I'm a huge fan of Sage/Maxima, and eager to get an answer using Sage. Thanks!</p>
https://ask.sagemath.org/question/10197/how-to-simplify-xax-into-xa-1-or-how-to-solve/?answer=15248#post-id-15248Concerning your first question, you can try this:
sage: x, a = var('x a')
sage: expr = x^a/x
sage: expr.full_simplify()
x^(a - 1)
Wed, 17 Jul 2013 12:28:20 +0200https://ask.sagemath.org/question/10197/how-to-simplify-xax-into-xa-1-or-how-to-solve/?answer=15248#post-id-15248Comment by Gustav Delius for <p>Concerning your first question, you can try this: </p>
<pre><code>sage: x, a = var('x a')
sage: expr = x^a/x
sage: expr.full_simplify()
x^(a - 1)
</code></pre>
https://ask.sagemath.org/question/10197/how-to-simplify-xax-into-xa-1-or-how-to-solve/?comment=17131#post-id-17131While full_simplify works on x^a/x, it already fails as soon as x is replaced by something slightly more complicated, like (1-x). Fri, 23 Aug 2013 09:35:59 +0200https://ask.sagemath.org/question/10197/how-to-simplify-xax-into-xa-1-or-how-to-solve/?comment=17131#post-id-17131Comment by tmonteil for <p>Concerning your first question, you can try this: </p>
<pre><code>sage: x, a = var('x a')
sage: expr = x^a/x
sage: expr.full_simplify()
x^(a - 1)
</code></pre>
https://ask.sagemath.org/question/10197/how-to-simplify-xax-into-xa-1-or-how-to-solve/?comment=17257#post-id-17257Yes, i agree that
sage: sage: x, a = var('x a')
sage: solve(x^a == 2*x, x)
[x == 1/2*x^a]
is not very satisfactory.Sat, 20 Jul 2013 19:12:37 +0200https://ask.sagemath.org/question/10197/how-to-simplify-xax-into-xa-1-or-how-to-solve/?comment=17257#post-id-17257Comment by Qiang for <p>Concerning your first question, you can try this: </p>
<pre><code>sage: x, a = var('x a')
sage: expr = x^a/x
sage: expr.full_simplify()
x^(a - 1)
</code></pre>
https://ask.sagemath.org/question/10197/how-to-simplify-xax-into-xa-1-or-how-to-solve/?comment=17264#post-id-17264Thanks! This works. But how Sage or Maxima solve the above equation still troubles me a lot.Thu, 18 Jul 2013 05:53:12 +0200https://ask.sagemath.org/question/10197/how-to-simplify-xax-into-xa-1-or-how-to-solve/?comment=17264#post-id-17264