This is the documentation page for Module:TemplateMath
| Alpha | This module is rated as alpha. It is ready for third-party input, and may be used on a few pages to see if problems arise, but should be watched. Suggestions for new features or changes in their input and output mechanisms are welcome. |
Usage
{{#invoke:TemplateMath|function_name}}
TemplateMath allows templates to calculate mathematical operations.
Usage
{{&35;invoke:TemplateMath|doOp|(first operand)|(operator)|(second operand)}}
As of now, the operator can be +, -, *, /, ^, r(This will return the first operand root of the second operand), and l(This will return the second operand base logarithm of the first operand). If an invalid operation is given, the module will return a question mark.
Example:
{{&35;invoke:TemplateMath|doOp|2|^|12}} returns 4096.
