# Exponentiation with parentheses

Why doesn't the following always simplify to 0?

Simplify[a^(b c) - (a^b)^c]


If we Assume a,b and c are integers it works...

Simplify[a^(b c) - (a^b)^c,
Assumptions -> {a \[Element] Integers, b \[Element] Integers,
c \[Element] Integers}]

• take a=-1, b=2, c=1/2. – kglr Sep 14 at 10:13
• @kglr No constraints on $a$ is needed: Simplify[a^(b c) - (a^b)^c, Assumptions -> b ∈ Integers && c ∈ Integers]yields zero. – yarchik Sep 14 at 11:11

For questions like these, FindInstance is your friend:

FindInstance[a^(b c) - (a^b)^c != 0, {a, b, c}]
(* {{a -> 99/5 + (12 I)/5, b -> -(28/5) + (79 I)/5, c -> 61/10 + (143 I)/10}} *)


So at least for complex numbers, there are issues. We can try to ask for solutions with real values as well:

FindInstance[{
a^(b c) - (a^b)^c != 0,
(a | b | c) ∈ Reals
}, {a, b, c}]
(* {{a -> -(69/5), b -> -(231/10), c -> -(8/5)}} *)


Through experimentation, we find that a and b can even be integers:

FindInstance[{
a^(b c) - (a^b)^c != 0,
c ∈ Reals,
(a | b) ∈ Integers
}, {a, b, c}]
(* {{a -> -1, b -> 18, c -> 8/5}} *)


We can guess some specific small values for a and b, which brings us essentially to the example given by @kglr in the comments:

FindInstance[{
a^(b c) - (a^b)^c != 0,
c ∈ Reals,
(a | b) ∈ Integers,
a == -1,
b == 2
}, {a, b, c}]
(* {{a -> -1, b -> 2, c -> 99/5}} *)

• $a$ need not be integer for the identity to hold. See my answer. – yarchik Sep 14 at 11:15
• @yarchik I know - I just wanted to find an example that's as simple as possible – Lukas Lang Sep 14 at 11:16

The identity works in a more broad case of $$a\in\mathbb{C}$$. Verification

Simplify[a^(b c) - (a^b)^c, Assumptions -> b ∈ Integers && c ∈ Integers]
(* 0 *)

• The only assumption needed is c ∈ Integers. – Carl Woll Sep 14 at 16:06
• @CarlWoll Right, because Power[x,y] takes the principal value of $e^{y\log(x)}$. Then the question is, why MA does not see this? – yarchik Sep 14 at 17:51