Calculator

Calculator Plugin

The calculator plugin lets you calculate expressions quickly. It can evaluate expressions entered as text starting with "=". Entering = from command mode will start text mode directly with = prefixed for quick access.

Basic Usage

  1. Activate Kupfer and type =

  2. Type in a mathematical expression using +,-,/,* (and ** for exponentiation)

  3. Press Return to get the result.

Notes

The Calculator uses python's math and complex math modules, and parses expressions as Python expressions. You may use common mathematical functions, such as sqrt, sin, exp and log; the command =help will show a list of all defined functions and constants.

  • Notice that the power operator in Python is double stars, for example =3**3 will evaluate to 27.

  • To calculate trig functions for angles, convert to radians first:

    sin(radians(30)) -> 0.5
  • The last result is stored as the name _ (an underscore, just like in the Python console).