# What is the conventional way to input n^x?

If I have a length or angle and type =, blender enters math mode where I can type equations to set the input of a transformation.

The only option I found is a very tedious $$exp((1/2) * log(2))$$ which there should be no reason to have to type. Can I not enter a simple radical instead?

• I usually type sqrt(144) on my calculator instead of 144^(1/2). Jan 13 '19 at 0:03

## 3 Answers

Blender uses Python as its script language, so you write the exponent like this:

2**(1/2)


Found another...

The only option I found is a very tedious "exp((1/2)*log(2))" which there should be no reason to have to type.

sqrt(2)


There is also the power method,

pow(2, 0.5)

• Isn't that what we type on calculators too? \s Jan 13 '19 at 0:01
• @10Replies also true. Jan 13 '19 at 0:01

Blender uses Python for scripts and is therefore subject to Python's syntax.

The ^ operator or caret operator in python (as well as many other languages) represents the bitwise XOR operation. You can find out more here:

https://stackoverflow.com/questions/2451386/what-does-the-caret-operator-in-python-do

If you want to know why programming languages feature ^ for XOR instead of exponents read here:

https://softwareengineering.stackexchange.com/questions/331388/why-was-the-caret-used-for-xor-instead-of-exponentiation

You want to use ** which is the exponent operator in Python