[README] [FEATURES] [INPUT] [UNITS] [OPERATORS] [FUNCTIONS] [VARIABLES] [DISCLAIMER]

README:

  1. PURPOSE
    This program is an in-depth expression evaluator. It can take any valid mathematical expression, including operands with units, and return the numerical result with the evaluated unit. The input style closely matches that of a TI-85 ( Texas Instruments) hand held calculator (i.e. type in an expression string (input box) and hit enter, and the result appears in a results list (output box) above the entry section). The program is very easy to use with an "intelligent" input box.
  2. INSTALLATION
    Expressionator.exe runs out of the folder you copied it to. It stores expressionator.ini in the same folder. The expcustomunits.ini file is also there by default. A small registry entry (/HKEY_CURRENT_USER/SOFTWARE/ENSOFT/CALCULATOR/) is made for backward compatibility with WinUnits but can be used by any program to find the last ran location of Expressionator.
  3. STATUS
    This program is shareware. It is fully functional and will never time-out, but if you like it and use it, you are asked to contribute unless you received it bundled with another (registered) program from Redscull Interactive. Versions prior to 2.0 may be received bundled with software from Ensoft, Inc.
  4. DISTRIBUTION
    This program may be freely distributed so long as it is not modified in any way. Expressionator may not be sold by any parties other than Redscull Interactive. This program may not be included on any form of Shareware bundle unless the retail cost of this package is no more than the cost of the media. Simply put, this program may not be included in any bundle which is sold for profit.
  5. CONTACT
    This program is made by Jonathan Kirkland. Any questions may be directed to Lordred@Redscull.com. Also, see my web page at www.redscull.com.

FEATURES:

Expressionator accepts simple mathematical expressions as input and returns an evaluated numeric answer for that expression. Expressionator supports input/output accuracy of 18 significant digits (80-bit values). Simple functions such as SIN, COS, INT, FLOOR, and ! (factoral) are supported in expressions, as well as the variables pi and e. Parentheses ( ) are supported in addition to common operators. Furthermore, Expressionator will convert units (also known as measurements) during its calculations.

In addition to the above mentioned mathematical features, Expressionator has many user-friendly interface features (all accessable by right-clicking the form or pressing the popup menu button on the keyboard). Most have shortcuts assigned as well.

The UP and DOWN arrow keys can be used to scroll through previous entries.

All entries and results are logged while the program is running for easy review.

The input window features full copy/paste support using the standard CTRL+C and CTRL+V. In addition, an extra 1000 clipboard entries are available for copying to (CTRL+SHIFT+0 - CTRL+SHIFT+999) and pasting from (CTRL+0 - CTRL+999).

Both input and results may be any of four number systems: Decimal, Hexidecimal, Roman Numeral, and Scientific Notation. Input can even be mixed (13+$A9+xviii+5.039E+02 = 703.9). Normally, roman numerals are drawn with an overline to indicate x1000. Expressionator performs x1000 on UPPERCASE and treats lowercase as traditional roman numerals (vi = 6, VI = 6000, I = m). Results displayed in Scientific Notation can be changed from the default display by editing the format string ScientificNotation in the Options section of expressionator.ini.

If you assign Expressionator a hotkey via its hotkey dialog (F3), when you press that key while Expressionator is running (but not necessarily your active program), it will attempt to calculate the string currently on the operating system clipboard and place the result back on the clipboard. Use this feature while in other programs to quickly get a result without even switching to Expressionator!

INPUT:

Expressionator accepts expressions built with numeric operands and its known operators as well as functions. The order of operations in this program are (x and y represent operands; x is evaluated before y):
  1. (x)
  2. -x (negative operand)
  3. x!
  4. x^y, x`y, x_y
  5. x*y, x/y, x\y, x%y
  6. x+y, x-y
  7. x=y, x>y, x<y
  8. function x
All white space in the entered expression is ignored.

Decimals don't require leading zeros. A lone decimal point will evaluate to zero (not an error).

Implicit multiplication is supported for parentheses ie 2(5+3) = 16 same as 2*(5+3) = 16 but not for variables. ie 3pi must be written as 3*pi or (3)pi.

You may store custom variables/formulas (F2) using alpha names of your choosing (not case sensitive). In the case of conflicting names, functions have highest priority (ie you cannot make a custom var using the name of a built-in function), then custom variables, and finally built-in variables (custom vars can replace built-in vars).

All functions (not case sensitive) except factoral are calculated using the evaluated operand immediately following the function name. So, FRAC 2.2*3 would first evaluate 2.2*3 to 6.6 then do FRAC 6.6, returning 0.6 as the result. The factoral uses the operand immediately preceding the !.

In the options section of expressionator.ini, you can set the "eaches" size by changing the value of EachesSize to any positive integer. This is used to allow input of "wholes:eaches" values. Using the default of 60, 5:30 would evaluate to 5.5 (5 + 30/60 = 5.5). Operands entered this way must use standard digits and will always return a decimal.

Most operands may take a unit type (unit symbols are case-sensitive). To enter three meters, type 3'm' which is the normal operand followed by the symbol of the unit enclosed in apostrophes. Unit symbols may be combined ('m*m' or 'm/s' or 'kg/m*hr' etc.) and may also take positive/negative exponents ('m^3' or 'm*s^-1' or 'm/s^2' etc.). Expressionator will combine units into the most logical representation before displaying the result (9'm^3' would be displayed rather than 9'm*m*m'). Also, different units in the same category (category refers to "Length" or "Time") will be converted to the same unit type (selected in the Expressionator Categories panel). So, an entry of 3'm'+1'km' would return 1003'm' (where 'm' was selected as the Length result type).

Expressionator will attempt to load custom categories and units if it finds a file named ExpCustomUnits.ini in the same directory as Expressionator.exe (you can change the location of this file by modifying its entry in the options section of expressionator.ini). The format of the file is...
[Category]
SymbolA:DescriptionA=1
SymbolB:DescriptionB=5


The conversion will show that 1'SymbolB' evaluates to 5'SymbolA'. If a symbol exists in more than one category, it will be treated as if it belongs to the last category it was added to (this way you can override the built-in units). Only the first instance of a symbol in a category is used in calculations.

Certain operands must be constants. (A constant, as defined for Expressionator, is an operand without a specified unit type.) All exponents must be constants; in addition, exponents being applied to an operand with a unit must evaluate to integer constants (e.g. 9'm'^0.5 tries to return 3'm^0.5' which will be an error; 9'm^2'^0.5 will return 3'm' which is ok). Factoral only works on constants.

The evaluated result is always a single number (with or without a unit) and not an expression. So, an entry of 5'm' + 10's' (which should return 5'm' + 10's' because Length and Time are not summable categories) will not be accepted by the program.

OPERATORS:

$ hex entry$F2 = 242
^ exponent2^3 = 8
` root, x`y is equivalent to x^(1/y)16`4 = 2
_ log n, x_y is equivalent to y^?=x9_3 = 2
* multiplication4*5 = 20
/ division9/2 = 4.5
\ integer division9/2 = 4
% mod (remainder)7%3 = 1
+ addition2+2 = 4
- subtraction3-2 = 1
- negative-5 = -5 (detects when a - is minus and when it's negative)
= tests equalityx=y will return 1 if x equals y and 0 otherwise
~ tests inequalityx~y will return 1 if x and y are not equal and 0 if they are equal
> greater thanx>y will return 1 if x is larger than y, 0 otherwise
< less thanx<y will return 1 if x is smaller than y, 0 otherwise
: wholes:eaches5:30 = 5.5 (using EachesSize default of 60)

FUNCTIONS:

arctanh hyperbolic arc-tangent
arctan arc-tangent
cotan cotangent
tanh hyperbolic tangent
tan tangent
arccosh hyperbolic arc-cosine
arccos arc-cosine
cosh hyperbolic cosine
cos cosine
sec secant
arcsinh hyperbolic arc-sine
arcsin arc-sine
sinh hyperbolic sine
sin sine
cosec cosecant
csc (same as cosec)
abs absolute valueABS -5 = 5
frac operand's fractionFRAC 1.8 = 0.8
int operand's integerINT 1.8 = 1
trunc (same as int)
round round to nearest integerROUND 2.6 = 3 (".5 rounds up")
ceil round to highest integerCEIL 2.1 = 3
floor round to lowest integerFLOOR 2.9 = 2
ln natural log (log base e)
log log base 10
log2 log base 2
exp inverse logEXP 1 = e
! factoral5! = 120

VARIABLES:

pi3.14159265358979323846
e2.71828182845904523539
ralways equals your last evaluated result
c#corresponding custom clipboard value (c000-c999)

DISCLAIMER:

You are at your own risk. Jonathan Kirkland can not be held liable for an inaccurate result. It is difficult to test every possible type of input that might be entered, but the latest version of Expressionator should be quite accurate. Unit conversion data was thouroughly researched and appears accurate (to 18 digits).

BUGS?
Let me know, please, at Lordred@Redscull.com.

SUGGESTIONS?
No promises that they'll be implemented (or even considered if time is scarce), but you're welcome to send them.