Hello. I’ve spent some time reading about the reasons behind why Julia deals with negative exponents the way it does and I’m not interested in resurrecting that debate. I’m working on a script and I’ve run into a problem that boils down to the following:
-1.5 ^ -1.5 # Works! b = -1.5 b ^ b # Doesn't work! :( # Why? Because: (-1.5) ^ (-1.5) # also doesn't work while - (1.5) ^ (-1.5) # works, and is what the above is evaluated as.
How can I get Julia to accept taking a variable with a negative base to a negative exponent?