OpenBI Docs Buy

POWER

Multiplies a number by itself a given number of times, or takes a root for a fractional power; the same as the ^ operator.

Group: Math. Compatible with DAX.

Syntax

POWER ( <number>, <power> )
ParameterTypeDescription
numberNumberThe base.
powerNumberThe exponent: a whole, fractional or negative number.

Returns

Number. The base raised to the exponent.

Remarks

  • POWER ( a, b ) and a ^ b are the same.
  • The ^ operator binds tighter than a leading minus: -2 ^ 2 is -4. Write ( -2 ) ^ 2 or POWER ( -2, 2 ) for 4.
  • A fractional power of a negative number is an error, such as POWER ( -4, 0.5 ); an odd root works: POWER ( -8, 1 / 3 ) is -2.
  • POWER ( 0, 0 ) is an error, and 0 to a negative power is a division by zero.
  • A blank base gives BLANK; a blank exponent counts as 0, so the result is 1.
  • Compound growth is a power: 100 growing by 5 % a year for ten years is 100 * POWER ( 1.05, 10 ).

Examples

Whole, fractional and negative powers

EVALUATE
ROW (
    "2 to the 10th", POWER ( 2, 10 ),
    "Root of 4", POWER ( 4, 0.5 ),
    "2 to the -1", POWER ( 2, -1 ),
    "Cube root of -8", POWER ( -8, 1 / 3 )
)
2 to the 10thRoot of 42 to the -1Cube root of -8
102420.5-2

The minus sign comes last

EVALUATE
ROW (
    "-2 ^ 2", -2 ^ 2,
    "( -2 ) ^ 2", ( -2 ) ^ 2,
    "POWER ( -2, 2 )", POWER ( -2, 2 )
)
-2 ^ 2( -2 ) ^ 2POWER ( -2, 2 )
-444

Ten years at 5 %

EVALUATE
ROW ( "100 grown", 100 * POWER ( 1.05, 10 ) )
100 grown
162.889462677744

SQRT, EXP, LN, LOG.

Last updated · OpenBI Studio 0.3.74