^ (Raise to Power)
VALUE1
^
VALUE2

The ^ operator raises a number to a power.

Parameters

This operator has two parameters:

value1 – The first numeric value.

value2 – The second numeric value.

Description

The ^ operator raises a number to a power. Here are some examples:

    2 ^ 3 ☞ 8
    10 ^ 3 ☞ 1000
    2.5 ^ 7.1 ☞ 668.919816
    2 ^ -3 ☞ 0.125
    -2.5 ^ 4.2 ☞ nan

The result of the final example above is nan, which stands for not a number, which in this case really means not a real number. Panorama doesn’t support complex numbers, so any result that would include an imaginary component yields nan.

Error Messages

Cannot raise a text value to a power. – Both parameters of the ^ operator must be numbers.

Cannot raise a number to a text power. – Both parameters of the ^ operator must be numbers.

See Also

- - -- subtracts the numeric value on the right from the numeric value on the left.
- * -- multiplies the numeric value on the left by the numeric value on the right.
- / -- divides one numeric value by another.
- \ -- performs integer division.
- + -- works differently depending on the type of operands used with it. If both operands are numeric, it does numerical addition. If either operand is text the + operator concatenates (joins together) the two operands.
- abs( -- calculates the absolute value of a number.
- ceil( -- converts a number to an integer, truncating toward positive infinity.
- divzero( -- divides two numbers, returns zero if denominator is zero.
- divzeroerror( -- divides two numbers, returns an error if the denominator is zero.
- fix( -- converts a number to an integer, truncating toward zero.
- fixed -- converts a floating point number to fixed point.
- float( -- converts a fixed point number to a floating point number.
- infinity( -- returns infinity.
- int( -- converts a number to an integer, truncating toward negative infinity.
- mod -- computes the remainder (modulo) after integer division.
- nan( -- checks to see if a numeric value is invalid.
- nanerror( -- converts invalid numeric values into an error.
- nanzero( -- converts invalid numeric values into zero.
- randominteger( -- generates a random integer between the starting and ending values.
- rnd( -- generates a random number between 0 and 1.
- round( -- rounds a number to a specified increment.
- validnumber( -- checks to see if a numeric value is valid.

History

Version | Status | Notes
10.0 | No Change | Carried over from Panorama 6.0