Word Size - HP -16C Owner's Handbook Manual

Table of Contents

Advertisement

32
Section 3: Number and Display Control
Word Size
To specify a word size, first place the desired word size (1, to 64,()
in the X-register, then press
[f][WSIZE]. The absolute value of the
number is used; a zero is interpreted as 64. After [WSIZE]is executed
the stack drops.
A current word size smaller than 8 will limit the size of the number
you can enter to stipulate a new word size; but you can always
enter O
to set a word size of 64. (You can then set any word
size.) Error 2 results if you attempt to specify a word size larger
than 64.*
Keystrokes
Display
16
(f)]SET COMPL(2s]
32767 [ENTER]
32767 d
8 [f](wsiZE]
-1.d
16 [fJ[WSIZE]
255 d
Base 10; word size 16.
Sets 2's Compl. mode.
Largest positive 2's
complement number
with a word size of 16.
Number changes from
01111111 1111111149(16
bits) to 11111111, (eight
bits).
Number changes from
11111111, to
00000000 111111115,
Note: A change in word size might not preserve numerically
equivalent values stored /in the memory stack. Going to a
smaller word size will truncate a word, leaving the least
significant bits. Going to a larger word size will not preserve
the sign bit of a negative number. If the original word size is
restored, the original stack contents are not restored. (The
effect on storage registers is different and is discussed on
page 67.)
*It is possible (in 1's or 2's Complement mode) to obtain a negative number if you try
entering a number larger than the largest positive number that can be represented
within the current word size. This occurs when the most significant bit (the sign bit)
becomes 1 (negative), as shown at the end of the keystroke sequence on page 36.
If the word size is 3 or less, attempting to initially enter a digit thatis legal in the current
number base mode but is too large for the given word size will result in the entry of a
zero.

Advertisement

Table of Contents
loading

Table of Contents