DM42 Quick Reference Guide

Version 2022-02-27
Check http://technical.swissmicros.com/dm42/fat/HELP for updates

Navigation

Numpad-like navigation keys

Symbols used in this guide


Contents


Menus

DM42 calculator has far too many functions to assign a key to each one, so most of them are available in menus rather than directly on keys.
Each menu displays a row of labels at the bottom of the screen, one above each key in the top row of the keyboard.
A function within the menu is activated by pressing the key directly below it. If there are more than six functions in the menu then the ▼▲ annunciator is displayed and the and keys allow you to scroll through the menu's pages. There are two kinds of menu:

Application Menu

There are five applications built into the DM42:
When you enter an application and its menu opens, any other menus are closed automatically. However, you can still open a function menu from within the application and when you've finished with it, it will close and reveal the application menu again.

Function Menu


Unlike application menus, a Function menu closes as soon as you have used one of the functions that it contains, with the exception of the CUSTOM menu, which remains open. Should you need to use more than one function from a Function menu, you can instruct the DM42 to keep the menu open by opening it twice in succession.

Storage


The Stack

The stack is the scratchpad that you use for performing calculations. It stores and shows you intermediate results as you work through a problem.
The four registers that make up the stack are known as X,Y,Z,T. Auxiliary register LASTx holds contents of X register used in most recent numeric function. Each of these registers can contain data of any type.

Storage Registers

Because of the ephemeral nature of the stack, data in its registers is likely to be lost when a new calculation is started.
More permanent storage can be achieved in the storage registers, of which there are 25 initially, numbered 00 to 24. This number can be altered with the SIZE function in the MODES menu.
STO nn STOres the contents of the X register into the storage register with the given number.
RCL nn ReCaLls the data from storage register nn into the stack.
If SIZE has been used to define more than 100 storage registers then registers numbered 100 and onwards can only be accessed using indirect addressing.
The STATistics application uses some of the storage registers for its internal housekeeping:
If ALLΣ mode is being used (as opposed to LINΣ mode) then the following additional storage registers are used: The storage registers can be all real numbers or all complex numbers. See Variables for how to switch between the two.

Variables

Rather than referring to stored data by a simple number (the number of the storage register containing it), it is possible to create named variables. Variables allow you to associate a meaningful name with the data. Also, named variables can contain any type of data, not just real or complex numbers.
E.g. suppose you have just calculated the volume of a shape. Store the value currently in the X register representing this volume in a variable named VOL:
STO ENTER VOL ENTER
Variables can have names up to seven characters long.
There is one system-reserved variable, REGS. REGS is a matrix containing the storage registers. REGS can be a real matrix, in which case all of the storage registers, i.e. the elements of REGS, are real numbers, or it can be a complex matrix, in which case all of the storage registers are complex numbers.
To convert REGS (or any other real matrix) to a complex matrix:
0 ENTER COMPLEX STO + REGS
To convert REGS from a complex matrix back into a real matrix:
RCL REGS COMPLEX x<>y STO REGS

The Alpha Register

The alpha Register can store up to 44 characters of text, which equate to two lines of text on the original HP-42S.

Available Memory

The DM42 has about 70KB of system memory that your programs and variables can use. The storage register matrix REGS uses some of this space.
To find out how much memory your DM42 has available, open the CATALOG menu and then press and hold MEM.
If you need more memory then use the CLP (CLear Program) and CLV (CLear Variable) functions from the CLEAR menu to remove unneccesary programs and variables and thus free up additional memory.
DO NOT DELETE THE REGS VARIABLE! Remember, it holds your storage registers! If necessary you can reduce its size with the SIZE command from the MODES menu.

Data Types


Real Numbers

Real numbers cover integer and decimal numbers, positive or negative. The range of numbers that the DM42 can handle is approximately 10-6143 to 106144 with a precision of 34 digits.

Complex Numbers

A complex number consists of two real numbers associated to form its real part and its imaginary part (rectangular coordinate mode).
Complex numbers are always stored internally in rectangular form but can be displayed directly:
0.2343 i1.4456
or in polar coordinate mode with a magnitude and an angle:
1.4645 ∡80.7937
Both of the examples here represent the same complex number.
To enter a complex number in rectangular mode:
real part ENTER imaginary part COMPLEX
To enter a complex number in polar mode:
Magnitude ENTER angle COMPLEX
The COMPLEX function either combines real numbers (or matrices) in the X and Y stack registers to form a complex number (or matrix) in X, or it performs the opposite operation by splitting the complex number (or matrix) in X into two real numbers (or matrices) in X and Y.
The role of the real number (or matrix) taken from X when combining X and Y or left in X when splitting the complex number (or matrix) in X depends on the display mode, rectangular or polar, in force when COMPLEX is executed. If rectangular then X is/was the imaginary part. If polar then X is/was the angle.
Complex numbers are displayed in polar mode normalised such that the magnitude is always positive and the absolute value of the angle does not exceed 180 degrees.

Alpha Strings

The alpha register contains strings of text up to 44 characters (2 lines on the HP-42S) in length.
Real variables and elements of real matrices (including REGS ) can also contain strings of up to 6 characters in length. Basically, you can store snippets of text anywhere you can store real numbers. However, you cannot store two such snippets in a complex variable.

Matrices

Matrices can be one-dimensional or two-dimensional. A matrix can have any number of rows and columns as long as there is enough memory in the DM42 to store all of its individual elements.
See Matrix Operations for more details.

Modes


Angles and Coordinates

Press MODES
The angle specifiers DEG, RAD and GRAD tell the DM42 to use degrees, radians, and gradians respectively when displaying and interpreting angles.
RECT and POLAR tell the DM42 to display and interpret complex numbers in rectangular and polar mode, respectively.

Other Modes

Press MODES
SIZE resizes the REGS matrix variable, thus defining the number of storage registers you can use.
QUIET switches off the internal buzzer and keeps the DM42 nice and.... quiet!
CPXRES allows the DM42 to return complex results when working on real numbers (e.g. square root of a negative number) while REALRES ensures that only real numbers are returned. In this case, operations that would otherwise return a complex result trigger an Invalid Data error. Operations given a complex number as an argument will return a complex number regardless of the CPXRES/REALRES setting.
KEYASN means that variables and programs assigned to the CUSTOM menu with the ASSIGN command will be shown in the CUSTOM menu. If LCLBL is selected then local alpha labels populate the CUSTOM menu.

Display Formats

Press DISP
FIX, SCI and ENG instruct the DM42 to display real numbers in fixed decimal, scientific and engineering notation, respectively, with a set number of decimals.
When ALL is selected, numbers are displayed with up to 12 digits precision, which was the native precision of the HP-42S.
Depending on where in the world you are, you will be used to using a dot as the decimal separator and a comma for grouping digits three by three before the decimal (e.g. 1,234.56 ) or, as in most of Europe, a comma as the decimal separator and a dot for grouping digits before the decimal (e.g. 1.234,56 ). RDX. selects the dot as the decimal separator and RDX, selects the comma.

Printing

Press PRINT
PRON and PROFF enable and disable printing by setting or clearing respectively flags 21 and 55.
MAN leads to items being printed manually. NORM leads to input and calculation results alone being printed automatically while TRACE sends a trace of all operations to the printer.
Additional modes are described under "Matrix Operations" and "Statistics."

Executing Functions & Programs


Any function or program can be executed by pressing XEQ and entering its name. If there is more than one program with the same name then when you attempt to XEQ that program, the one closest to the permanent .END. marker will be executed.
Only the current program will be searched if the name that you give is that of a local label.

Quick access to programs and functions

There are four ways to get at your programs and at the DM42's functions quickly:

Addressing modes

Some functions require a parameter that tells them on what specific item to operate. These functions accept one or more of the following addressing modes:

Programming


Program-Entry


* Use or if no menu is displayed.

Labels

A program label is simply a marker used to identify a program or a routine within a program.
Global labels can be accessed from anywhere in memory (and therefore should be unique). Global labels are distinguished from local labels by quotation marks (such as LBL "SAMPLE" ).
Local labels can be accessed only within the current program (and should be unique within the current program). There are two types of local labels:

The Do-lf-True Rule

The do-if-true rule determines how program lines are executed when a conditional function is encountered. If the condition is "true," the line immediately following the conditional is executed. If the condition is "false," the line following the conditional is skipped.

Looping

The ISG and DSE functions control looping. Each accesses a variable or register containing a control number in the form ccccccc.fffii; where ccccccc is the current counter value, and fff is the final counter value, and ii is the increment size (default is 1). Both ISG and DSE follow a variation of the do-if-true rule: if the count is not complete, the line following the instruction is executed (usually a branch to the top of the loop).
For example, this program segment counts from 1 to 52 by threes (executing the loop 18 times) and then beeps.
17 1.05203
18 STO "COUNT"
19 LBL 01

23 ISG "COUNT"
24 GTO 01
25 BEEP

Using a Variable Menu

A variable menu may be displayed by the Solver or Integration applications, or by the VARMENU function within a program. Each label in the menu represents a variable. While the menu is displayed, you can:
You can select and use any function menu without exiting from the variable menu.

The Solver

The Solver is a root finder that allows you to solve for an unknown variable in an expression, given values for all the other variables. Expressions are written as programs. There are three parts to a Solver program:

After entering the program, these are the steps for using the Solver:

A Simple Example: For the expression A + B = C, rewrite the expression as A + B - C = 0. The Solver program looks like this:

01 LBL "SIMPLE"
02 MVAR "A"
03 MVAR "B"
04 MVAR "C"
05 RCL "A"
06 RCL+ "B"
07 RCL- "C"
08 END

Hint: create the variables before entering the program. After entering the program, you can use it to solve for any variable, given a value for each of the others. For example, find A when B = 12 and C = log(B ).

Select the program: SOLVER SIMPL
Store B: 12 B
Store C: LOG C
Solve for A: A

Numerical Integration

The Numeric Integration application allows you to calculate an approximation of a definite integral. The integrand, f(x), is written as a program similar to a Solver program (see The Solver ). That is, the program must use a global label, declare the menu variables, and evaluate f(x).

After entering the integrand program, here are the steps for using the Integration application:
  1. Press ∫f(x)
  2. Select an integrand program from the menu.
  3. Use the variable menu to store a value into each of the variables that should remain constant.
  4. Select the variable of integration by pressing the corresponding menu key.
  5. Store the lower limit (LLIM ), the upper limit (ULIM ), and the accuracy factor (ACC ).
  6. Press to calculate the integral. The approximation for the integral is returned to the X-register and the uncertainty of computation is returned to the Y-register.

Matrix Operations

To create a new m × n matrix, enter the dimensions:
m ENTER n (for m rows and n columns) and then press:
MATRIX NEW for a matrix in the X-register.
Or MATRIX DIM ENTER name ENTER for a matrix in a variable. If the matrix already exists, the DIM function redimensions it.

Edit the matrix in the X-register:
MATRIX EDIT

Edit a named matrix:
MATRIX EDITN name

When a matrix is being edited it is said to be indexed. (To index a named matrix without editing it, use the INDEX function.) Whenever there’s an indexed matrix, two pointers are used to indicate the row and column of the current element: I and J, respectively.

Wrap and Grow Modes. If the index pointers are positioned to the last (lower-right) element in a matrix and you move to the right one position:
Wrap mode is automatically selected whenever you enter or exit the matrix editor. (The WRAP and GROW functions are in the second row of the editor menu.)

Matrix Arithmetic. Most arithmetic and other operations work for matrices just as for individual numbers. Anytime a matrix is used in a mathematical operation with a complex number, the result is a complex matrix. Therefore, you can make any matrix complex by adding 0 + i0 to it:
0 ENTER COMPLEX +
or 0 ENTER COMPLEX STOM + name

To solve a system of simultaneous linear equations represented by the matrix equation AX = B:
  1. Press MATRIX SIMQ.
  2. Key in the number of unknowns. The calculator automatically creates or redimensions the matrix variables MATA, MATB, and MATX.
  3. Optional: If your equations involve complex numbers, make MATA and/or MATB complex (as shown at the top of this page).
  4. Press MATA , fill the matrix and press EXIT
  5. Press MATB , fill the matrix and press EXIT
  6. Press MATX to calculate the solution matrix. Use the matrix editor keys to view the results.

Statistics

Statistical data is accumulated into 6 or 13 sequential storage registers. Initially, the first summation register is R11. Use the ΣREG function to change the location of the first summation register. ΣREG does not move the data in the registers.

Options to set the summation mode:
Clear the summation registers:
CLEAR CLΣ

Options to accumulate data:

To undo mistakes:
Put the incorrect data in the stack (try LASTx ).
Press Σ- and continue accumulating data.

To select a curve model for forecasting:
Press STAT CFIT MODL
and then one of the following:

Base Conversions

Real numbers are displayed according to the current base mode (Hexadecimal, Decimal, Octal, or Binary). You can change the base mode using the BASE menu or by manually executing HEXM, DECM, OCTM, or BINM. Decimal mode is automatically selected when you exit from the BASE menu.
Press and hold SHOW to display:

When the BASE menu is displayed, the following keys are temporarily redefined with these integer functions:
± BASE±36-bit 2’s complement.
÷ BASE÷36-bit integer divide.
× BASE×36-bit integer multiply.
- BASE- 36-bit integer subtract.
+ BASE+36-bit integer add.

Bits are numbered from right to left beginning with 0. Bit 35 (the most significant bit) is the sign bit. Negative numbers are represented in 2’s complement form. Nondecimal numbers longer than 36 bits are displayed as <Too Big>

DM42 Functions

ABSAbsolute value
ACOSArc cosine
ACOSHArc hyperbolic cosine
ADVAdvance paper
AGRAPHAlpha graphics
AIPAlpha integer part
ALENGAlpha length
ALLAll display format
ALLΣALLΣ mode (13 sum regs)
ANDLogical AND
AOFFAlpha off
AONAlpha on
ARCLAlpha recall
AROTAlpha rotate
ASHFAlpha shift
ASINArc sine
ASINHArc hyperbolic sine
ASSIGNAssign CUSTOM menu key
ASTOAlpha store
ATANArc tangent
ATANHArc hyperbolic tangent
ATOXAlpha to X
AVIEWAlpha view
BASE+Base add
BASE-Base subtract
BASE×Base multiply
BASE÷Base divide
BASE+/-Base change sign (2’s compl.)
BEEPBeep
BESTBest fit model
BINMBinary mode
BIT?Bit test (x-th bit of y)
BSTBack step
CFClear flag
CLAClear alpha register
CLALLClear all memory
CLDClear display
CLKEYSClear CUSTOM menu keys
CLLCDClear LCD
CLMENUClear programmable menu
CLPClear program
CLRGClear registers
CLSTClear stack
CLVClear variable
CLXClear X-register
CLΣClear summation registers
COMBCombinations
COMPLEXComplex
CORRCorrelation
COSCosine
COSHHyperbolic cosine
CPXRESComplex-result enable
CPX?Complex test
CROSSCross product
CUSTOMCUSTOM menu
DECMDecimal mode
DEGDegrees mode
DELDelete program lines
DELAYPrinter delay time
DELRDelete matrix row
DETDeterminant
DIMDimension matrix
DIM?Dimensions of matrix in X
DOTDot product
DSEDecrement, skip if ≤ zero
EDITEdit matrix in X-register
EDITNEdit named matrix
ENDEnd of a program
ENGEngineering display format
ENTEREnter
EXITALLExit all menus
EXPFCurve-fitting model: exp.
E↑XNatural exponential
E↑X-1Nat. exp values near zero
FCSTXForecast x given y (stat)
FCSTYForecast y given x (stat)
FIXFixed dec. display format
FRNMFrobenius norm of X matrix
FPReturn fractional part
GAMMAGamma function
GETKEYPut next key number to X-reg
GETMGet matrix
GRADGrads angular mode
GROWGrow mode (matrix edition)
GOTOGo to label
HEXMHexadecimal mode
HMS+Add x and y using H.MMSSss
HMS-Subtract x from y H.MMSSss
I+Inc. row pointer (matrix)
I-Dec. row pointer (matrix)
INDEXIndex matrix
INPUTUser input (prog. only)
INSRInsert row (matrix edition)
INTEGIntegrate
INVRTInvert matrix in X-register
IPReturn integer part
ISGIncrement, skip if greater
J+Inc. column pointer (matrix)
J-Dec. column pointer (matrix)
KEYASNKey-assignments mode
KEYGOn key, go to
KEYXOn key, execute
LASTXLast x
LBLLabel
LCLBLLocal label mode
LINFLinear fit model
LINELinear mode (six sum regs)
LISTList program lines
LNNatural logarithm
LN1+XNat log for values near zero
LOGCommon logarithm
LOGFLogarithmic fit
MANManual printing
MAT?Matrix test
MEANArithmetic mean (average)
MENUProgrammable MENU
MODModulo
MVARMenu variable
N!Factorial
NEWMATNew matrix
NORMNormal printing
NOTLogical NOT
OCTMOctal mode
OFFOff
OLDOld element value
ONContinuous on
ORLogical OR
PERMPermutations
PGMINTProgram to integrate
PGMSLVProgram to solve
PIpi
PIXELPixel on
POLARPolar mode
POSAPosition in alpha
PRAPrint alpha
PRLCDPrint LCD
PROFFPrinting off
PROMPTPrompt
PRONPrinting on
PR?Print program
PRSTKPrint stack
PRUSRPrint user vars and labels
PRVPrint variable
PRXPrint X-register
PR2Print summation registers
PSEPause
PUTMPut matrix
PWRFPower fit
QUIETQuiet mode
RADRadians mode
RANRandom number
RCLRecall
RCL+Recall add
RCL-Recall subtract
RCL×Recall multiply
RCL÷Recall divide
RCLELRecall element
RCLIJRecall IJ pointers
RDX,Radix comma
RDX.Radix period
REALRESReal-results only
REAL?Real test
RECTRectangular mode
RNDRound
RNRMRow norm
ROTXYRotate y by x bits
RSUMRow sum
RTNReturn
R<>RRow swap row
R↑Roll up
R↓Roll down
SCIScientific notation
SDEVStandard deviation
SEEDSeed (for RAN)
SFSet flag
SIGNSign
SINSine
SINHHyperbolic sine
SIZESize of REGS
SLOPESlope
SOLVESolve for variable
SQRTSquare root
SSTSingle step
STOStore
STO+Store add
STO-Store subtract
STO×Store multiply
STO÷Store divide
STOELStore element
STOIJStore IJ pointers
STOPStop program
STR?String test
SUMRecall Σx and Σy
TANTangent
TANHHyperbolic tangent
TONETone (0-9)
TRACETrace printing
TRANSTranspose matrix
UVECUnit vector
VARMENUVariable menu
VIEWView
WMEANWeighted mean
WRAPWrap mode
X<>x exchange
X<>Yx exchange y
XEQExecute
XORExclusive OR
XTOAX to alpha
X2Square, x2
YINTY-intercept
YXPower, yx
1/XReciprocal
10XCommon exponential, 10x
+Add
-Subtract
×Multiply
÷Divide
+/-Change sign
Σ+Summation plus
Σ-Summation minus
ΣREGSet loc. of 1. sum reg
ΣREG?Recall loc. of 1. sum reg
→DECTo decimal
→DEGTo degrees
→HMSTo hours-minutes-seconds
→HRTo decimal hours
→OCTTo octal
→POLTo polar
→RADTo radians
→RECTo rectangular
Index pointers left
Index pointers up
Index pointers down
Index pointers right
%Percent
%CHPercent change
ADATEAppend date from X to alpha
ATIMEAppend time from X to alpha
AT24Append 24h time from X to a.
CL12Set 12h time format AM/PM
CL24Set 24h time format
DATEPut date to X register
DATE+Add dates in X and Y regs
DDAYSDelta days of X and Y regs
DMYSet date format to DMY
DOWDay of Week of date in X reg
MDYSet date format to MDY
TIMEPut time to X register


Note: If you execute an HP-41 Function, it is automatically converted into the corresponding DM42 function.

Test Functions

If true, execute the next program line. If false, skip the next program line.
X<0?less than zero
X<Y?less than y
X≤0?less than or equal to zero
X≤Y?less than or equal to y
X=0?equal to zero
X=Y?equal to y
X≠0?not equal to zero
X≠Y?not equal to y
X>0?greater than zero
X>Y?greater than y
X≥0?greater than or equal to zero
X≥Y?greater than or equal to y


HP41 Functions

CHS+/-
DEG→DEG
D-R→RAD
ENTER↑ENTER
FACTN!
FRCFP
HMS→HMS
HR→HR
INTIP
OCT→OCT
P-R→REC
RDNR↓
R-D→DEG
R-P→POL
ST+STO+
ST-STO-
ST*STO×
ST/STO÷
X<=0?X≤0?
X<=Y?X≤Y?
*×
/÷

Using the ALPHA Menu

To type an alpha string into the alpha register:
  1. Press ALPHA to select the ALPHA menu.
  2. Optional: press ENTER to turn on the cursor (in Program-entry mode, inserts the I- symbol).
  3. Type the string using the characters shown below. Use shift to type lowercase letters.
  4. Press EXIT or ENTER


Flags

Flags 0-10 are indicated by annunciators at the top of the display.
Flags 36-80 are read-only and cannot be altered with SF, CF, FS?C, or FC?C.

Virtual variables

The concept of "Virtual Variables" is used to manage some of the new features specific to the DM42 calculator. These are variables that do not (and cannot, for that matter) exist in the DM42's variable table, but are used to read or change state variables specific to DM42.
DevID(read-only) Hardware device ID
GrMod(read-write) Graphic Modes
  • 0 = HP-42S resolution 131x16
  • 1 = reserved for future use
  • 2 = DM42 half resolution 200x120
  • 3 = DM42 full resolution 400x240
ResX(read-only) X-resolution for current graphics mode set in GrMod
ResY(read-only) Y-resolution for current graphics mode set in GrMod
Vbat(read-only) battery voltage


F-Buttons

The top row consists of six unprinted buttons referenced as F-Buttons (F1-F6) or soft-menu buttons.
Note that font changes using F5/F6 affect displaying of calculator stack and font in program mode and are stored independently for both stack and program mode.

Screenshot

Pressing SHIFT and DISP simultaneously makes a screenshot and saves a BMP graphics file in the folder /SCREENS.
The file name is made up by the current date and time.

Setup Menu



Setup Menu → File

Save and Load DM42 Programs to FAT Disk as *.raw files.

Setup Menu → Calculator State

The complete calculator state can be saved and loaded as one file (*.f42).

Setup Menu → Settings


Setup Menu → System

Warning: Certain actions in this menu can destroy all stored data of the calculator.
Please run 'Save Calculator State' in 'File' menu first to preserve data over potential RESET.


About


Top