Short: RPN Scientific and Programmer Calculator
Author: Nathan Hesterman
Uploader: riversidepapa zoho com (Nathan Hesterman)
Type: misc/math
Version: 1.01
Requires: i386 AROS or 68020+ Amiga
Architecture: i386-aros; m68k-amigaos
RPN Scientific+ is a scientific, programmer, and statistics
calculator using Reverse Polish Notation. It allows entry in
and simultaneously displays values in decimal, hexadecimal,
binary, and time notation. The programmer functions allow
displaying values of Long, Short, and Byte signed or unsigned
numbers. Numbers and basic functions can be entered using the
number pad on your keyboard.
The calculator is stack-based with 4 registers. The stack can
be manipulated using the buttons in the upper right of the
calculator. They function as their Forth language counterparts.
Various options can be set by toggling the green keys. For
example, DEG when pressed toggles from angles in degrees to
angles in radians. The FP button alternates between floating
point scientific and programmer number sizes and functions.
Purple keys have alternate functions that can be accessed via
the purple Alt button. The alternate functions are closely
related to the normal functions. For example, the alternate
function for the SIN button is ArcSine.
RPNScientific+ was written on AROS 2 using Annotate and
Hollywood 5. Please contact me with any comments, criticisms,
or suggestions at NathanH13 on ArosExec or NathanH on AmigaWorld.
Hope you find this a useful program.
=================================================================
Reference:
X^2 squares the value in the x register
Sqrt takes the square root of the x register
Y^X raises the y register to the power in the x register
X^Y raises the x register to the power in the y register
1/X takes the reciprocal of the x register
SIN calculates the sine of the angle in the x register (see DEG|
RAD)
ASIN calculates the arc sine of the x register
COS calculates the cosine of the angle in the x register (see
DEG|RAD)
ACOS calculates the arc cosine of the x register
TAN calculates the tangent of the x register (see DEG|RAD)
ATAN calculates the arc tangent of the x register
/MOD returns the quotient (x reg) and remainder (y reg) from
dividing the y register by the x register using modulo division
REM returns only the remainder of the division in the x register
LN returns the natural logarithm of the x register
e^X raises e to the power of the x register
LOG returns the base 10 logarithm of the x register
10^X is the inverse, raising 10 to the xth power
PUT + 0-9 stores the x register in register 0-9
GET + 0-9 recalls the stored value back to the x register
SUM+ accumulates statistics for the values in x and y registers
SUM- can be used to remove data due to an entry mistake
MEAN displays xbar in x, ybar in y, sx in z, sy in t register
L.R. displays the regression intercept in x, slope in y, and
correlation coefficient (r) in the z register
The above statistics are accumulated as follows. Use GET to
view the desired register.
n in register 2 (also shown during accumulation in x
register)
SumX in register 3
SumX^2 in register 4
SumY in register 5
SumY^2 in register 6
SumXY in register 7
! (factorial) returns the factorial of x
GMMA returns the Gamma function of x (Lascosz approximation)
AND displays the bitwise AND of registers x and y
OR displays the bitwise OR of registers x and y
XOR displays the bitwise exclusive OR of registers x and y
INVERT inverts all bits in register x
<< performs a logical left shift of bits in x register
>> performs a logical right shift if unsigned or an arithmetic
right shift if signed
SIGN toggles between signed and unsigned bit interpretations
LONG displays hex and binary values for Longs (4 byte integers)
WORD displays hex and binary values for Shorts (2 byte integers)
BYTE displays hex and binary values for Bytes (1 byte integers)
FP toggles between scientific and programmer calculator function
<--- performs a backspace during number entry
LastX returns the previous value in the x register
DEG means angles are interpreted as degrees
RAD means angles are interpreted as radians
EEX enters an "e" indicating scientific notation
PI displays PI in the x register
e displays e in the x register
Clr clears all registers
DROP removes x from the stack ( a -- )
OVER copies y over x ( a b -- a b a)
SWAP swaps the x and y registers ( a b -- b a)
ROT rotates the z register to the top of stack ( a b c -- b c a)
TUCK copies the x register below the y register ( a b -- b a b)
NIP drops the y register ( a b -- b)
2DUP duplicates x & y into z & t ( a b -- a b a b)
ROLL circulates through each stack register
Uploaded using: archives.aros-exec.org