All freeware available at this location is freely copyable and freely redistributable.
POWER.exe: Activates various power saving features.
Version B.13, Frank P. Westlake, Mar 3 2009.
MAPM Library Version 4.9.5 Copyright (C) 1999-2007, Michael C. Ring
C++ interface by Orion Sky Lawlor, maintained by Michael Ring.
Math, arbitrary precision, floating point and fractions.
MATH [options] expression[,expression[...]]
THIS IS AN EXPERIMENTAL VERSION. USE CAUTION!
OPTIONS:
/, Replace the default radix point of '.' with ','. See /RadixChar below for
more information.
/_ Check for and convert repeating digits during both input and output (i.e.
0.123123 => 123/999). Ex: '/I:_ 1.99'. If the value input is 0.123123 the
repeating pattern of '123' will be translated to the fraction 123/999. During
output the value 0.123123123123 will be converted to 0._123 or to [41/333]
depending on the selected output format. Conversion may be specified for only
input or only output with '/I:_' and /O:_'.
Example: MATH /_ 0.123123 Solution: 0._123
Example: MATH /_ /O:F 0.123123 Solution: [41/333]
/^^ Swap the XOR operator and the power operator so that '^' is the power
operator and '**' is the XOR operator. This switch is actually '/^' but in
the Windows console '^' is the escape character so it must be used to escape
itself, or the whole switch must be quoted ("/^"). Alternatively, '/**' is
available to accomplish the same function.
/A Print the solution in all number bases from -62 through 62 and in Roman
numerals. For this feature, the base 1 representation is only printed if it
is less than 100. The intent of this feature is to permit a visual comparison
of the value in all supported number bases.
/A= Print the solution in all balanced number bases from 2 through 26.
/BI=base Number base of input numbers is 'base'.
/BO=base Number base for output numbers is 'base'.
/B[=base] Optionally specify the number base for both input and output. If '/B' is
indicated without 'base', all values will be examined for a base indicator. A
base indicator is a two-character prefix beginning with the character '0' and
ending with the highest value in the base set. For example, the value 1 in
bases 2, 8, 10, 16, and 62 is: 011, 071, 091, 0F1, and 0z1 respectively; but
only if the '/B' switch is indicated. Without the '/B' switch, values
preceded by '0b', '0o', and '0x' are base 2, base 8, and base 16
respectively. Preceeding zeroes are otherwise ignored so the traditional
octal notation (i.e. 037) is ineffective. With or without the switch '/B',
the base suffix (i.e. 10[16] for base 16) is always recognized and takes
precedence over the base prefix. If both are used the prefix is discarded.
This parameter also causes the output to include the base indicator.
Example: MATH /bi=16 /bo=2 FF*3 Solution: 1011111101 (765 base ten)
Example: MATH /bi=16 FF*3 Solution: 765 (base ten)
Example: MATH /b 0FFF * 0111 Solution: 09765 (765 base ten)
/BaseSet=
/BaseSetIn=
/BaseSetOut=
Specify the set of characters for the number base. The default base set is:
0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
That is the characters 0-9, followed by A-Z, then followed by a-z. This base
set supports a maximum base of 62 and a minimum base of -62. In the default
set, if the base is -36 through 36 then the alphabetic characters are not
case sensitive and az[36] is equivalent to AZ[36]. If the base set is changed
with this parameter then all bases will be case sensitive.
Example: MATH /BaseSet="ABCDEFGHIJ" BAB*D Solution: DAD
Example: MATH /BaseSetIn="ABCDEFGHIJ" BAB*D Solution: 303
Example: MATH /BaseSetOut="ABCDEFGHIJ" 101*3 Solution: DAD
/C List the internal table of constants.
/F[=path] Store and read variables as disk files instead of as environment variables.
The current directory will be used unless 'path' is specified. These files
are normal ASCII text files. Variables with names prefixed with the character
'$' are temporary and will be deleted when the program exits, even if it is a
preexisting variable. The prefix need only be applied once. Some versions of
Windows will not permit the value of environment variables to be retained
after program exit; file variables must then be used.
Example: MATH /F price=25, quantity=6, cost=price*quantity
Example: MATH /F=%TEMP% price=25, quantity=6, cost=price*quantity
Example: MATH /F $price=25, $quantity=6, $cost=price*quantity
/I=[option]
Input format. 'option' may be one or more of the following:
_ Check for and convert repeating digits. See '/_' above for details.
Example: MATH /I:_ 0.123123 (0.123123 becomes [41/333] internally.)
B Examine values for a base indicator. See '/B' above for details.
Example: MATH /I:B 09123 (09123 becomes 123 base ten internally.)
R All input values are Roman numerals. To mix Roman numeral input with
other input types, see 'MATH /? roman()'.
Example: MATH /I:R V*X Solution: 50
/[ No brackets. Brackets will not be printed to delimit fractions. Fractions are
normally delimited by brackets so that if output is used later as input the
value will be read as a fraction instead of as a division operation.
Example: MATH /o:f 2*[1/3] Solution: [2/3]
Example: MATH /o:f /[ 2*[1/3] Solution: 2/3
/O[=option]
Output format. 'Option' may be one of the following (example value is
123456789000.987):
N Scientific (1.23456789000987\+11).
E Engineering (123.456789000987\+9).
F Fraction (123456789000987/1000]).
I Integer (123456789000).
R Roman numeral (MCCXXXIVS'DCLXXVIIIS'MMMMS.....).
Some of the above may be modified by one or more of the following (i.e.
/O:RFX)
B Base suffix (1.23456789000987\+11[10]). Modifies: All.
P SI prefix (123.456789000987 giga-). Modifies: E.
S Short class (123.456789000987 billion). Modifies: E.
L Long class (123.456789000987 milliard). Modifies: E.
F Fraction ([123456789000987/1000]). Modifies R.
M Mixed Fraction (123456789000+[987/1000]). Modifies: F, R.
X Exponential magnitude (123456789\+3). Modifies: I, F, R.
O Arithmetic round integers (123456789001). Modifies: I, R.
[ No brackets. (123456789000+987/1000). Modifies: F, FM, R,
RM.
Use '/O' without 'option' to sample the various formats.
/P Precision; the number of digits to retain.
Example: MATH 1/3 Solution: 0.333333333333333333333333333333
Example: MATH /p=10 1/3 Solution: 0.3333333333
/R All input and output values are Roman numerals. For mixing Roman numerals
with other types, see 'MATH /? roman()'.
Example: /R V*X Solution: L
/?[W|B] [/V]
Print this document. '/V' is for verbose output. Optionally select buffer
word wrap ('/?B') or window word wrap ('/?W') (default).
/?[W|B] [function]
Print descriptive information for 'function'. Wildcards * and ? are accepted.
Optionally select buffer word wrap ('/?B') or window word wrap ('/?W')
(default).
Example: MATH /? c*d Solution: crd(n) Chord of n.
/RomanSet='set'
'set' is a comma delimited list of glyphs to use in place of the default set
of ".,S,I,V,X,L,C,D,M". Not all glyphs must be replaced and trailing commas
may be ommitted. For example, to replace "I" with "j" and "D" with "I)":
/RomanSet=,,j,,,,,I) OR /RomanSet=,,j,,,,,I),
Example: MATH /RomanSet=,,j,,,,,I) /O:R 833*2 Solution: MI)CLXVj
Example: MATH /RomanSet=[1/12],[1/2],[1],[5],[10],[50],[100],[500],[1000]
/o:r 19999/12 Solution: [1000][500][100][50][10][5][1][1/2][1/12]
/MagnitudeStr=
Replace the default magnitude indicator of '\' with 'str' for both input and
output.
Replacing the default indicator can cause conflicts. If the replacement is
alphanumeric, such as the conventional indicator of 'E', then conflicts will
occur in number bases that use the character 'E'. If the replacement contains
operators, such as in " * 10^", then the algebraic engine will misinterpret
those operators. The default indicator '\' was chosen because it does not
conflict in any way and because it has a history of the same function in some
computer systems.
Example: MATH /MagnitudeStr=E 5E3/5 Solution: 1000
/RadixChar=
Replace the default radix point of '.' with 'char' for both input and output.
Since the comma is a very common replacement, the switch '/,' is available
for that replacement alone.
Example: MATH /RadixChar=' 123'4*2 Solution: 246'8
/illiard='str'
Replace the default number name suffix of 'illiard' with 'str' for both input
and output.
Example: MATH /O:L /illiard=iljard 10**15 Solution: 1 biljard
/illion='str'
Replace the default number name suffix of 'illion' with 'str' for both input
and output.
Example: MATH /O:L /illion=iljoen 10**18 Solution: 1 triljoen
INPUT
-Use standard algebraic notation; i.e 1+2*3**4*5+6 is equivalent to 1+(2*(3**4)*5)+6 and
3**4*2*5+1+6.
-The general format for number input is thee fraction: [n/d]\e[b] with n=numerator,
d=denominator, e=magnitude (*10**c, with '10' being in base d), b=the number base.
-All values 'n', 'd', and 'e' may be integeers, floating point numbers, internal
constants, or names of variables. 'd' must be an integer. The brackets permit assignment
to numerator and denominator without losing precision by performing the division.
VARIABLES
-Names of variables are not case sensitive.
-Variables may consist of a complete expresssion, not just a numerical value.
-A variable may also be defined as a functiion with a parameter list for input.
-Names of variables begin with an alphabetiic character and may thereafter consist of both
alphabetic and numeric characters. There is no limit on name length.
-Variables exist either in the environment (default) or in disk files. Both types of
variables may be used in the same expression if file-based variables are prefixed with
the character '@'.
-If the /F switch is used, variables will aall be in disk files in the current directory,
or in the directory specified following the /F switch, and the prefix character is not
needed.
-If a variable is defined in the environmennt it cannot be used when the '/F' switch is
specified.
-File-based variables may also include an aabsolute or relative path. For example, the
variable 'z' as the file 'C:\math\vars\z' may be expressed either as '@C:\math\vars\z'
or as 'z'; in the latter case either the current directory is 'C:\math\vars' or the
commandline parameter '/F=C:\math\vars' is used.
-If names of variables are prefixed with thhe character '$' they are temporary and will be
deleted before the program exits, even if it is a preexisting variable. The file-based
variable prefix ('@') may be placed either before or after the temporary-variable prefix
('$@' or '@$'). The prefix need only be applied once.
-Some versions of Windows will not permit tthe value of environment variables to be
retained after program exit; file variables must then be used.
-When in number bases greater than 10 use ccaution with variable name assigments; the
string of alphanumeric characters could be read as either a variable name or as a
number.