If you declare a to be positive, it simplifies with me.

 

From: sympy@googlegroups.com <sympy@googlegroups.com> On Behalf Of Pierre H
Sent: Saturday, July 27, 2024 2:38 PM
To: sympy <sympy@googlegroups.com>
Subject: [sympy] Simplification of a^x * (1/a)^x: not equal to 1?

 

Hello,

 

This is perhaps a classical question, but since I'm only using SymPy every now 
and then...

 

I wonder why the expression a^x * (1/a)^x doesn't simplify to 1. See code (with 
SymPy 1.12)

 

a,x = symbols('a x')
simplify(a**x * (1/a)**x)

 

(then of course the variant a**x * (1/(a**x)) does simplify to 1).

 

So is a SymPy issue that the power of x isn't propagated inside the 1/(a) 
expression. Or I'm just missing a mathematical subtlety which requires adding 
some assertions about x and a?

 

Pierre

 

-- 
You received this message because you are subscribed to the Google Groups 
"sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sympy+unsubscr...@googlegroups.com 
<mailto:sympy+unsubscr...@googlegroups.com> .
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sympy/1b37bc0c-aa69-4e89-99d0-fb5700920dccn%40googlegroups.com
 
<https://groups.google.com/d/msgid/sympy/1b37bc0c-aa69-4e89-99d0-fb5700920dccn%40googlegroups.com?utm_medium=email&utm_source=footer>
 .

-- 
You received this message because you are subscribed to the Google Groups 
"sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sympy+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sympy/003401dae023%246da70330%2448f50990%24%40gmail.com.

Reply via email to