EasyManua.ls Logo

Commodore Plus 4 - Page 185

Commodore Plus 4
464 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Redefining
the
Function
Keys
173
square
a
number
by
multiplying
it
by
itself,
get
a
square
root
by
using
the
SQR
function,
and
calculate
a
reciprocal
by
dividing
1
by
the
number.
It
is
somewhat
faster
to
add
a
number
to
itself
than
to
multiply
by
2.
It
is
somewhat
faster
to
divide
by
2
than
to
multiply
by
0.5.
Subtraction
and
addition
take
virtually
the
same
amount
of
time.
Logarithms
and
Exponentials
LOG(X)
returns
the
logarithm
base
e
(the
natu
ral
logarithm)
of
X.
The
logarithm
with
respect
to
a
different
base,
B,
can
be
found
by
dividing
LOG(X)
by
LOG(B).
The
inverse
of
the
logarithm
base
e
(e
raised to
a
power)
can
be
calculated
with
EXP.
The
inverse
of
the
logarithm
base
B
can
be
calculated
by
using
the
up
arrow
to
raise
B
to
the
power.
Trigonometric
Calculations
An
approximation
of
pi
is
available
by
using
the
pi
key
(the
Q
and
equal
keys
pressed
together).
This
is
particularly
useful
when
the
values
of
trigonometric
ratios
are
desired
and
the
angle
is
measured
in
degrees.
The
SIN,
COS,
and
TAN
functions
are
available,
but
each
requires
the
specified
angle
to
be
measured
in
radians.
To
translate
from
degrees
to
radians,
multiply
the
angle
by
pi,
and
divide
by
180.
To
calculate
the
values
of
the
remaining
trigonometric
ratios,
recall
that
csc(X)
=
1/SIN(X)
sec(X)
=
1/COS(X)
cot(X)
=
1/TABT(X)
The
only
inverse
trigonometric
ratio
available
is
the
arctangent
(ATN).
The
value
is
returned
in
radians.
To
change
to
degrees,
multiply
by
180,
and
divide
by
pi.
To
calculate
the
values
of
the
remaining
inverse
functions,
recall
that
arcsin(A)
=
ATN(A/SQR(
1-A*A))
arccos(A)
=
ATW(SQR(
1-A*A)/A)
arccsc(A)
=
ATN(l/(A*SQR(l-l/(A*A))))
arcsec(A)
=
ATN(A*SQR(1-1/(A*A)))
arccot(A)
=
ATN(1/A)
Rounding
Off
Numbers
When
asked
to
display
a
number,
the
PRINT
(or
PRINT#)
command
prints
nine
digits
of
precision.
If
this
is
not
desired,
the
PRINT
USING
command
may
be
used.
Or,
recall
that
the
number
X
rounded
to
N
decimal
places
is
given
by
IET(10tW*X+.5)/10t]!ir

Other manuals for Commodore Plus 4

Related product manuals