Template:Powe

From The Scuba Wiki

(Difference between revisions)
Jump to: navigation, search
m (1 revision)
 

Latest revision as of 21:01, 28 December 2009

POWer as Expression.

Allows a number be raised to an integer power from -150 to 150. Powers of greater than 150 are treated as 150 and those less than -150 as -150. Unlike template:pow ( talk edit history links ), the result is here an expression, #expr or #ifexpr still has to be applied. This allows further computations with the result, even if by itself it would be represented in scientific notation.

Usage:
{{powe|<base>|<power>}}

Example:

"{{powe|2|10}}" gives "(2*2*2*2*2*2*2*2*2*2)" [1]

{{#expr:{{powe|2|10}}}} gives 1024.

The parentheses are needed for a case like this:

{{#expr:1/{{powe|2|10}}}} gives 0.0009765625.

Personal tools
support the site