EasyManua.ls Logo

HP HP-16C - Doubledivide

HP HP-16C
140 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...
Section
4:
Arithmetic
and
Bit
Manipulation
Functions
53
Example:
To
illustrate
double
multiplication,
the
calculation
of
(7
X
6)
in
binary with
word
size
5
and
2’s
Complement
is
shown
below.
7
00111
FivebitsinY.
Xoe
X
00110
Five
bitsin
X.
42,0
00001
01010,
Ten-bit
representation
of
42,
———
———
gplit
between
X-
and
Y-registers.
X Y
Keystrokes
Display
([STATUS]:
2-05-1000)
(BIN]111
00111
b
Binary
mode.
110(g][DBLX]
00001
b
Most
significant
bits
are
put
in
X.
(xxy]
01010
b
Least
significant
bits
are
putin
Y.
Result
is
therefore
00001
01010,.
Double
Divide
The
function
computes
the quotient
of
a
dividend
of
double
word
size
in
the
Y-
and
Z-registers—the
most
significant
bits
of
which
are
in
the
Y-register—divided
by
a
single-word
divisor
in
the
X-register.
The
stack
drops
twice,
placing
the
single-word
result
in
the
X-register.
Error
O
occurs
if
the
answer
cannot
be
represented
in
a
single
word
size.
Flag
4
(carry)
is
set
if
the
remainder
is
not
equal
to
zero.
The
stack
contents
during
this
operation
are:
T
t
Z
dividend
!
Y
(high
order
bits
in
Y)
t
X
divisor
(y...z)/x|
quotient
Keys
(¢](oBL:]

Table of Contents

Related product manuals