Aplet view configuration ..............1-17 Mathematical calculations ..............1-18 Using fractions..................1-24 Complex numbers.................1-27 Catalogs and editors ................1-28 Differences between the HP 38G and the HP 39G/40G.......1-29 2 Aplets and their views Aplet views.....................2-1 About the Symbolic view ..............2-1 Defining an expression (Symbolic view)..........2-1 Evaluating expressions ..............2-3...
Page 4
3 Function aplet About the Function aplet ................3-1 Getting started with the Function aplet..........3-1 Function aplet interactive analysis ............3-8 Plotting a piecewise defined function example ......3-11 4 Parametric aplet About the Parametric aplet ..............4-1 Getting started with the Parametric aplet..........4-1 5 Polar aplet Getting started with the polar aplet...........5-1 6 Sequence aplet...
Page 5
9 Inference aplet About the Inference aplet ...............9-1 Getting started with the Inference aplet..........9-2 Importing Sample Statistics from the Statistics aplet .......9-5 Hypothesis tests ..................9-9 One–Sample Z–Test .................9-9 Two–Sample Z–Test...............9-10 One–Proportion Z–Test ..............9-11 Two–Proportion Z–Test..............9-12 One–Sample T–Test ...............9-13 Two–Sample T–Test...............9-14 Confidence intervals................9-16 One–Sample Z–Interval..............9-16 Two–Sample Z–Interval ..............9-17...
Page 6
11 Variables and memory management Introduction ..................11-1 Storing and recalling variables .............11-2 The VARS menu ..................11-4 Memory Manager .................11-9 12 Matrices Introduction ..................12-1 Creating and storing matrices...............12-2 Working with matrices .................12-4 Matrix arithmetic ..................12-6 Solving systems of linear equations..........12-8 Matrix functions and commands ............12-9 Argument conventions..............12-10 Matrix functions................12-10 Examples ....................12-13...
Page 7
15 Programming Introduction ..................15-1 Program catalog ................15-2 Creating and editing programs .............15-4 Using programs ..................15-7 Working with programs................15-8 About customizing an aplet ..............15-9 Aplet naming convention..............15-10 Customizing an aplet example............15-10 Programming commands..............15-14 Aplet commands ................15-14 Branch commands.................15-17 Drawing commands ..............15-19 Graphic commands ...............15-20 Loop commands................15-22 Matrix commands .................15-23...
Page 8
Regulatory information .................R-1 USA ....................R-1 Canada .....................R-1 LED safety.....................R-2 Warranty ....................R-2 CAS .......................R-4 Resetting the HP 39G/40G ..............R-4 To erase all memory and reset defaults ...........R-5 If the calculator does not turn on ............R-5 Glossary ....................R-6 Operating details..................R-7 Batteries ...................R-7 Menu maps of the VARS menu.............R-8...
Preface The HP 39G/40G is a feature-rich graphing calculator. It is also a powerful mathematics learning tool. The HP 39G/40G is designed so that you can use it to explore mathematical functions and their properties. You can get more information on the HP 39G/40G from Hewlett-Packard’s Calculators web site.
Getting started On/off, cancel operations To turn on Press to turn on the calculator. To cancel When the calculator is on, the key cancels the current operation. To turn off Press to turn the calculator off. To save power, the calculator turns itself off after several minutes of inactivity.
HOME display. Press the to scroll in the HOME display. N O T E The HP 40G is packaged with a computerized algebra system (CAS). Press to access the computerized algebra system. 86T•...
Annunciators. Annunciators are symbols that appear above the title bar and give you important status information. Annunciator Description Shift in effect for next keystroke. To cancel, press again. α Alpha in effect for next keystroke. To cancel, press again. ((•)) Low battery power.
Page 14
• On the calculator keyboard, the top row of keys are called menu keys. Their meanings depend on the context—that’s why their tops are blank. The menu keys are sometimes called “soft keys”. • The bottom line of the display shows the labels for the menu keys’...
Page 15
Entry/Edit keys The entry and edit keys are: Meaning Cancels the current operation if the CANCEL calculator is on by pressing Pressing , then turns the calculator off. Accesses the function printed in blue above a key. Returns to the HOME view, for performing calculations.
Page 16
For a lower case letter, press For a string of letters, hold down while typing. HELPWITH The HP 39G built-in help is available in HOME only. It provides syntax help for built-in math functions. Access the HELPWITH command by pressing SYNTAX and then the math key for which you require syntax help.
Page 17
H I N T When using the MATH menu, or any menu on the HP 39G/ 40G, pressing an alpha key takes you straight to the first menu option beginning with that alpha character. With this method, you do not need to press first.
Menus A menu offers you a choice of items. Menus are displayed in one or two columns. • arrow in the display É• means more items below. • arrow in the display e•Ã means more items above. To search a menu •...
Input forms An input form shows several fields of information for you to examine and specify. After highlighting the field to edit, you can enter or edit a number (or expression). You can also select options from a list ( ).
Page 20
Setting Options (Continued) Number The number format mode you set is the Format number format used in both HOME and the current aplet. Standard. Full-precision display. Fixed. Displays results rounded to a number of decimal places. Example: 123.456789 becomes 123.46 in Fixed 2 format.
You select the aplet that you want to work with. Aplets come from a variety of sources: • Built-in the HP 39G/40G (initial purchase). • Aplets created by saving existing aplets, which have been modified, with specific configurations. See “Creating new aplets based on existing aplets”...
Page 22
Quad Explorer and Trig Explorer. You cannot modify configuration settings for these aplets. A great many more teaching aplets can be found at HP’s web site and other web sites created by educators, together with accompanying documentation, often with student work sheets.
Page 23
H I N T More detailed documentation, and an accompanying student work sheet can be found at HP’s web site. When first started, the aplet is mode, in which the BSQC——...
Page 24
Trig Explorer The Trig Explorer aplet is used to investigate the behaviour aplet of the graph of as the values of a, b, c and d change, both by manipulating the equation and seeing the change in the graph, or by manipulating the graph and seeing the change in the equation.
Aplet library Aplets are stored in the Aplet library. To open an aplet Press to display the Aplet library menu. Select the aplet and press TU6SU• From within an aplet, you can return to HOME any time by pressing Aplet views When you have configured an aplet to define the relation or data that you want to explore, you can display it in different views.
Page 26
Plot-Table The VIEWS menu contains the Plot-Table view. view Select Plot-Table PF— Splits the screen into the plot and the data table. See “Other views for scaling and splitting the graph” on page 2-13 for futher information. Plot-Detail The VIEWS menu contains the Plot-Detail view. view Select Plot-Detail PF—...
To save aplet You can save an aplet configuration that you have used, and configuration transfer the aplet to other HP 39G/40G calculators. See “Sending and receiving aplets” on page 16-5. Getting started 1-17 Downloaded from www.Manualslib.com...
). You can do all calculations here, and you can access all operations. Entering • Enter an expression into the HP 39G/40G in the same expressions left-to-right order that you would write the expression. This is called algebraic entry. •...
7 – × × Scientific A number like 5 10 3.21 10 is written in scientific notation, that is, in terms of powers of ten. This is simpler to notation work with than 50000 or 0.000000321. To enter numbers like (powers of 10) these, use .
Page 30
7. AND and NOT. 8. OR and XOR. 9. Left argument of | (where). 10. Equals, =. Largest and The smallest number the HP 39G/40G can represent is –499 smallest 1 × 10 (1E–499). A smaller result is displayed as zero. The –49...
Page 31
Clearing • clears the character under the cursor. When the numbers cursor is positioned after the last character, deletes the character to the left of the cursor, that is, it performs the same as a backspace key. • ) clears the edit line. CANCEL •...
Page 32
Example See how retrieves and reuses the last result (50), updates (from 50 to 75 to 100). You can use the last result as the first expression in the edit line without pressing . Pressing , or , (or other operators that require a preceding argument) automatically enters before the operator.
Storing a value You can save an answer in a variable and use the variable in later calculations. There are 27 variables available for storing in a variable real values. These are A to Z and θ. See Chapter 11, “Variables and memory management”...
Clearing the It’s a good habit to clear the display history ( CLEAR whenever you have finished working in HOME. It saves display history calculator memory to clear the display history. Remember that all your previous inputs and results are saved until you clear them.
Page 35
Setting The fraction precision setting determines the precision in which the HP 39G/40G converts a decimal value to a fraction. fraction The greater the precision value that is set, the closer the precision fraction is to the decimal value. By choosing a precision of 1 you are saying that the fraction only has to match 0.234 to at least 1 decimal place (3/13 is...
Page 36
Fraction When entering fractions: calculations • You use the key to separate the numerator part and the denominator part of the fraction. • To enter a mixed fraction, for example, 1 , you enter it in the format (1+ For example, to perform the following calculation: 1.
6. Complex numbers Complex results The HP 39G/40G can return a complex number as a result for some math functions. A complex number appears as an ordered pair (x, y), where x is the real part and y is the imaginary part.
TUP—c• Catalogs and editors The HP 39G/40G has several catalogs and editors. You use them to create and manipulate objects. They access features and stored values (numbers or text or other items) that are independent of aplets.
Differences between the HP 38G and the HP 39G/40G The HP 40G is packaged with a computer algebra system (CAS). Refer to the CAS Manual for further information. Memory The HP 39G/40G incorporates a memory manager that you manager can use to see how much memory the objects that you have created or loaded are occupying.
Page 40
Downloaded from www.Manualslib.com manuals search engine...
Aplets and their views Aplet views This section examines the options and functionality of the three main views for the Function, Polar, Parametric, and Sequence aplets: Symbolic, Plot, and Numeric views. About the Symbolic view The Symbolic view is the defining view for the Function, Parametric, Polar, and Sequence aplets.
Page 42
– For a Function definition, enter an expression to define F(X). The only independent variable in the expression is – For a Parametric definition, enter a pair of expressions to define X(T) and Y(T). The only independent variable in the expressions is –...
Evaluating expressions In aplets In the Symbolic view, a variable is a symbol only, and does not represent one specific value. To evaluate a function in Symbolic view, press . If a function calls another @W6G• function, then resolves all references to other functions @W6G•...
Page 44
SYMB view The following table details the menu keys that you use to work with the Symbolic view. keys Meaning Copies the highlighted expression to the @9DU• edit line for editing. Press when PF• done. •8CF• Checks/unchecks the current expression (or set of expressions).
About the Plot view After entering and selecting (check marking) the expression in the Symbolic view, press . To adjust the appearance of the graph or the interval that is displayed, you can change the Plot view settings. You can plot up to ten expressions at the same time. Select the expressions you want to be plotted together.
Page 46
Field Meaning (Continued) NRNG Sequence aplet: Specifies the index (N) values for the graph. For Parametric plots: the increment TSTEP for the independent variable. θSTEP For Polar plots: the increment value for the independent variable. For Sequence aplet: Stairstep SEQPLOT or Cobweb types.
Exploring the graph Plot view gives you a selection of keys and menu keys to explore a graph further. The options vary from aplet to aplet. PLOT view The following table details the keys that you use to work with keys the graph.
Page 48
Trace a graph You can trace along a function using the key which moves the cursor along the graph. The display also shows the current coordinate position (x, y) of the cursor. Trace mode and the coordinate display are automatically set when a plot is drawn.
Page 49
Option Meaning (Continued) Divides horizontal and vertical scales by the X-factor and Y-factor. For instance, if zoom factors are 4, then zooming in results in 1/4 as many units depicted per pixel. (see Set Factors) Multiplies horizontal and vertical scales by the X-factor and Y-factor (see Set Factors).
Page 50
Option Meaning (Continued) Integer Rescales horizontal axis only, making each pixel =1 unit. (Not available in Sequence or Statistics aplets.) Trig Rescales horizontal axis so 1 pixel = π/24 radian, 7.58, or grads; rescales vertical axis so 1 pixel = 0.1 unit. (Not in Sequence or Statistics aplets.) Un-zoom Returns the display to the previous...
Page 51
X-Zoom In: X-Zoom In aPPH• PF• Now un-zoom. X-Zoom Out: X-Zoom Out aPPH• PF• Now un-zoom. Y-Zoom In: Y-Zoom In aPPH• PF• Now un-zoom. Y-Zoom Out: Y-Zoom Out aPPH• PF• Zoom Square: Square aPPH• PF• Aplets and their views 2-11 Downloaded from www.Manualslib.com manuals search engine...
Page 52
To box zoom The Box Zoom option lets you draw a box around the area you want to zoom in on by selecting the endpoints of one diagonal of the zoom rectangle. 1. If necessary, press to turn on the menu-key labels. H@IV•...
Other views for scaling and splitting the graph The preset viewing options menu ( ) contains options for drawing the plot using certain pre-defined configurations. This is a shortcut for changing Plot view settings. For instance, if you have defined a trigonometric function, then you could select Trig to plot your function on a trigonometric scale.
Page 54
Split the screen The Plot-Detail view can give you two simultaneous views of the plot. 1. Press . Select Plot-Detail and press . The PF• graph is plotted twice. You can now zoom in on the right side. 2. Press , select the zoom method and press H@IV•ÃaPPH•...
Overlay plots If you want to plot over an existing plot without erasing that plot, then use Overlay Plot instead of Note that tracing follows only the current functions from the current aplet. Decimal scaling Decimal scaling is the default scaling. If you have changed the scaling to Trig or Integer, you can change it back with Decimal.
Setting up the table (numeric view setup) Press to define any of the table settings. Use the Numeric Setup input form to configure the table. 1. Highlight the field to edit. Use the arrow keys to move from field to field. –...
Exploring the table of numbers NUM view The following table details the menu keys that you use to work with the table of numbers. menu keys Meaning aPPH• Displays ZOOM menu list. 7DB• Toggles between two character sizes. 9@AI• Displays the defining function expression for the highlighted column.
The display on the right is a Zoom In of the display on the left. The ZOOM factor is 4. H I N T To jump to an independent variable value in the table, use the arrow keys to place the cursor in the independent variable column, then enter the value to jump to.
Clear data Press to erase the data from a table. CLEAR `@T• “Build Your Own” menu keys Meaning @9DU• Puts the highlighted independent value (X, T, θ, or N) into the edit line. Pressing replaces this variable with its current value. DIT•...
Example: plotting a circle Plot the circle, x = 9. First rearrange it to read ± – To plot both the positive and negative y values, you need to define two equations as follows: – – – 1. In the Function aplet, specify the functions. Select Function TU6SU•...
Function aplet About the Function aplet The Function aplet enables you to explore up to 10 real–valued, rectangular functions y in terms of x. For example Once you have defined a function you can: • create graphs to find roots, intercepts, slope, signed area, and extrema •...
Page 62
Define the 2. There are 10 function definition fields on the Function aplet’s Symbolic view screen. They are labeled F1(X) to expressions F0(X). Highlight the function definition field you want to use, and enter an expression. (You can press delete an existing line, or to clear all lines.) CLEAR Set up the plot...
Page 63
Change the 6. You can change the scale to see more or less of your graphs. In this example, choose Auto Scale. (See scale “VIEWS menu options” on page 2-13 for a description of Auto Scale). Select Auto Scale PF— Trace a graph 7.
Page 64
To find the 10. Find the greater of the two roots of the quadratic greater of the two function. roots of the Note: Move the cursor to the graph of the quadratic quadratic equation by pressing the key. Then move the function cursor so that it is near 1 –...
Page 65
To find the slope 13. Find the slope of the quadratic function at the intersection of the quadratic point. function H@IV— A8I— Select Slope PF— The slope value is displayed at the bottom of the screen. To find the signed 14.
Page 66
18. Display the numerical value of the integral. PF— Note: See “Shading area” on page 3-10 for another method of calculating area. To find the 19. Move the cursor to the quadratic equation and find the extremum of the extremum of the quadratic. quadratic H@IV—...
Page 67
22. Match the table settings to the pixel columns in the graph view. QGPU— PF— Explore the 23. Display a table of numeric values. table To navigate 24. Move to X = –5.9. around a table 6 times To go directly to a 25.
To change font 27. Display table numbers in large font. size 7DB— To display the 28. Display the symbolic definition for the F1 column. symbolic 9@AI— definition of a column The symbolic definition of F1 is displayed at the bottom of the screen.
Page 69
Access FCN The FCN variables are contained in the VARS menu. variables To access FCN variables in HOME: 6QG@U— Select Plot FCN to choose a variable PF— To access FCN variable in the Function aplet’s Symbolic view: Select Plot FCN to choose a variable PF—...
Page 70
Function Description (Continued) Signed area Select Signed area to find the numeric integral. (If there are two or more expressions checkmarked, then you will be asked to choose the second expression from a list that includes the x-axis.) Select a starting point, then move the cursor to selection ending point.
Plotting a piecewise defined function example Suppose you wanted to graph the following piecewise defined function. ≤ 1 – f x ( ) < ≤ 1 – x 1 ≥ – 1. Open the Function aplet. Select Function TU6SU—Ã...
Page 72
Downloaded from www.Manualslib.com manuals search engine...
Parametric aplet About the Parametric aplet The Parametric aplet allows you to explore parametric equations. These are equations in which both x and y are f t ( ) defined as functions of t. They take the forms g t ( ) Getting started with the Parametric aplet The following example uses the parametric equations x t ( )
Page 74
Set angle 3. Set the angle measure to degrees. measure MODES 8CPPT• Select Degrees PF• Set up the plot 4. Display the graphing options. PLOT You can see the Plot Setup input form has two fields not included in the Function aplet, TRNG and TSTEP. TRNG specifies the range of t values.
Overlay plot 8. Plot a triangle graph over the existing circle graph. PLOT PF• Select Overlay Plot PF• H@IV•ÃH@IV• A triangle is displayed rather than a circle (without changing the equation) because the changed value of TSTEP ensures that points being plotted are 120° apart instead of nearly continuous.
Page 76
Downloaded from www.Manualslib.com manuals search engine...
Polar aplet Getting started with the polar aplet Open the Polar 1. Open the Polar aplet. aplet Select Polar S@T@U—Ã`@T— TU6SU— Like the Function aplet, the Polar aplet opens in the Symbolic view. Define the θ 2 ⁄ θ ( ) 2.
Page 78
Explore the 5. Display the Plot view menu key labels. graph H@IV— The Plot view options available are the same as those found in the Function aplet. See “Exploring the graph” on page 2-7 for further information. 6. Display the table of values θ for and R1. Display the numbers The Numeric view...
Sequence aplet About the Sequence aplet The Sequence aplet allows you to explore sequences. You can define a sequence named, for example, U1: • in terms of n • in terms of U1(n-1) • in terms of U1(n-2) • in terms of another sequence, for example, U2(n) •...
Page 80
Define the 2. Define the Fibonacci sequence, in which each term (after the first two) is the sum of the preceding two terms: expression > – – In the Symbolic view of the Sequence aplet, highlight the (1) field and begin defining your sequence. V •ÃbI d•Ã...
Page 81
Plot the 4. Plot the Fibonacci sequence. sequence 5. In Plot Setup, set the SEQPLOT option to Cobweb. SETUP PLOT Select Cobweb 8CPPT•Ã PF• Display the 6. Display the table of numeric values for this example. table Sequence aplet Downloaded from www.Manualslib.com manuals search engine...
Page 82
Downloaded from www.Manualslib.com manuals search engine...
Solve aplet About the Solve aplet The Solve aplet solves an equation or an expression for its unknown variable. You define an equation or expression in the symbolic view, then supply values for all the variables except one in the numeric view. Solve works only with real numbers.
Getting started with the Solve aplet Suppose you want to find the acceleration needed to increase the speed of a car from 16.67 m/sec (60 kph) to 27.78 m/sec (100 kph) in a distance of 100 m. The equation to solve is: Open the 1.
Page 85
Solve the 5. Solve for the unknown variable (A). unknown TPGW@— variable Therefore, the acceleration needed to increase the speed of a car from 16.67 m/sec (60 kph) to 27.78 m/sec (100 kph) in a distance of 100 m is approximately 2.47 Because the variable A in the equation is linear, once values are substituted into V, U and D, we know that we need not look for any other solutions.
Page 86
7. Trace along the graph representing the left member of the equation until the cursor nears the intersection. ≈ 20 times Note the value of A displayed near the bottom left corner of the screen. The Plot view provides a convenient way to find an approximation to a solution before using the Numeric view Solve option.
Use an initial guess You can usually obtain a faster and more accurate solution if you supply an estimated value for the unknown variable before pressing . Solve starts looking for a solution at TPGW@— the initial guess. Before plotting, make sure the unknown variable is highlighted in the numeric view.
Interpreting results After Solve has returned a solution, press in the Numeric DIAP— view for more information. You will see one of the following three messages. Press to clear the message. PF— Message Condition Zero The Solve aplet found a point where the value of the equation (or the root of the expression) is zero within the calculator’s 12-digit accuracy.
Page 89
If Solve could not find a solution, you will see one of the following two messages. Message Condition Bad Guess(es) The initial guess lies outside the domain of the equation. Therefore, the solution was not a real number or it caused an error. Constant? The value of the equation is the same at every point sampled.
Plotting to find guesses The main reason for plotting in the Solve aplet is to help you find initial guesses and solutions for those equations that have difficult-to-find or multiple solutions. Consider the equation of motion for an accelerating body: ------ - where x is distance, v is initial velocity, t is time, and a is...
Page 91
3. Use the Plot view to find an initial guess for T. First set appropriate X and Y ranges in the Plot Setup. Since we × × 2 ⁄ have an equation, , the plot will produce two graphs: one for and one for ×...
8. Use this equation to solve for another variable, such as velocity. How fast must a body’s initial velocity be in order for it to travel 50 m within 3 seconds? Assume the same acceleration, 4 m/s . Leave the last value of V as an initial guess.
Statistics aplet About the Statistics aplet The Statistics aplet can store up to ten separate data sets at one time. It can do one-variable or two-variable statistical analysis of one or more sets of data. The Statistics aplet starts with the Numeric view which is used to enter data.
Page 94
Open the 1. Open the Statistics aplet and clear existing data by pressing Statistics aplet S@T@U• Select Statistics S@T@U•Ã`@T• TU6SU• The Statistics aplet starts in the Numerical 1VAR/2VAR view. menu key label At any time the Statistics aplet is configured for only one of two types of statistical explorations: one-variable ( ) or two- W6S•...
Page 95
Choose fit and 4. Select a fit in the Symbolic setup view. data columns SETUP SYMB 8CPPT• Select Linear PF• You can define up to five explorations of two-variable data, named S1 to S5. In this example, we will create just one: S1.
Page 96
Plot the graph 9. Plot the graph. Draw the 10. Draw the regression curve (a curve to fit the data points). regression H@IV• ADU• curve This draws the regression line for the best linear fit. Display the 11. Return to the Symbolic view. equation for best linear fit 12.
Predict values 13. To find the predicted sales figure if advertising were to go up to 6 minutes: PF•Ã S (to highlight Stat-Two) (to highlight PREDY) PF• 14. Return to the Plot view. Ã 15. Jump to the indicated point on the regression line. BPUP•...
Page 98
Statistics aplet’s NUM view keys The Statistics aplet’s Numeric view keys are: Meaning @9DU• Copies the highlighted item into the edit line. DIT• Inserts a zero value above the highlighted cell. TPSU• Sorts the specified independent data column in ascending or descending order, and rearranges a specified dependent (or frequency) data column accordingly.
Page 99
Example You are measuring the height of students in a classroom to find the mean height. The first five students have the following measurements 160cm, 165cm, 170cm, 175cm, 180cm. 1. Open the Statistics aplet. Select Statistics S@T@U•Ã`@T• TU6SU• 2. Enter the measurement data. 3.
Page 100
4. Press to close the PF• statistics window and press key to see the data set definitions. The first column indicates the associated column of data for each data set definition, and the second column indicates the constant frequency, or the column that holds the frequencies.
Page 101
Meaning (Continued) Resets default specifications for the CLEAR data sets or clears the edit line (if it was active). Note: If is used the data CLEAR sets will need to be selected again before re-use. To continue our example, suppose that the heights of the rest of the students in the class are measured, but each one is rounded to the nearest of the five values first recorded.
Page 102
8. Display the computed statistics. TU6UT• You can scroll down to the mean. The mean height is approximately 167.63cm. 9. Setup a histogram plot for the data. SETUP PLOT PF• Enter set up information appropriate to your data. 10. Plot a histogram of the data. Ã...
Insert data Highlight the entry following the point of insertion. Press DIT• then enter a number. It will write over the zero that was inserted. Sort data 1. In Numeric view, highlight the column you want to sort, and press values TPSU•...
Page 104
Fit models Eight fit models are available: Fit model Meaning (Default.) Fits the data to a straight Linear line, y = mx+b. Uses a least-squares fit. Logarithmic Fits to a logarithmic curve, y = m lnx + b. Exponential Fits to an exponential curve, y = be Fits to a power curve, y = bx Power Fits to a quadratic curve,...
Computed statistics One-variable Statistic Definition Σ Number of data points. Σ Sum of data values (with their frequencies). Σ Mean value of data set. MEAN Σ Population variance of data set. PVAR Σ Sample variance of data set. SVAR PSDEV Population standard deviation of data set.
Page 106
Two-variable Statistic Definition Mean of x- (independent) values. MEANX Σ Sum of x-values. Σ Sum of x -values. MEANY Mean of y- (dependent) values. Σ Sum of y-values. Σ Sum of y -values. Σ Sum of each xy. Sample covariance of independent SCOV and dependent data columns.
Plotting You can plot: • histograms ( W6S• • box-and-whisker plots ( W6S• • scatter plots of data ( !W6S• Once you have entered your data ( ), defined your data set ( ), and defined your Fit model for two-variable statistics ( ), you can plot your data.
Plot types Histogram One-variable statistics. The numbers below the plot mean that the current bar (where the cursor is) starts at 0 and ends at 2 (not including 2), and the frequency for this column, (that is, the number of data elements that fall between 0 and 2) is 1.
Fitting a curve to 2VAR data In the Plot view, press . This draws a curve to fit the ADU• checked two-variable data set(s). See “To choose the fit” on page 8-11. H@IV• ADU• TCPX• The expression in Fit2 shows that the slope=1.98082191781 and the y-intercept=2.2657.
Setting up the plot (Plot setup view) The Plot Setup view ( ) sets most of the SETUP PLOT same plotting parameters as it does for the other built-in aplets. See “Setting up the plot (Plot view setup)” on page 2-5. Settings unique to the Statistics aplet are as follows: Plot type (1VAR) STATPLOT enables you to specify either a histogram or a...
Trouble-shooting a plot If you have problems plotting, check that you have the following: • The correct menu label on (Numeric W6S• !W6S• view). • The correct fit (regression model), if the data set is two- variable. • Only the data sets to compute or plot are checkmarked (Symbolic view).
Exploring the graph The Plot view has menu keys for zooming, tracing, and coordinate display. There are also scaling options under . These options are described in“Exploring the graph” on page 2-7. Statistics aplet’s PLOT view keys Meaning Erases the plot. CLEAR Offers additional pre-defined views for splitting the screen, overlaying plots,...
Calculating predicted values The functions PREDX and PREDY estimate (predict) values for X or Y given a hypothetical value for the other. The estimation is made based on the curve that has been calculated to fit the data according to the specified fit. Find predicted 1.
Page 114
Downloaded from www.Manualslib.com manuals search engine...
Inference aplet About the Inference aplet The Inference capabilities include calculation of confidence intervals and hypothesis tests based on the Normal Z–distribution or Student’s t–distribution. Based on the statistics from one or two samples, you can test hypotheses and find confidence intervals for the following quantities: •...
Getting started with the Inference aplet This example describes the Inference aplet’s options and functionality by stepping you through an example using the example data for the Z–Test on 1 mean. Open the 1. Open the Inference aplet. Inference aplet Select Inferential TU6SU—...
Page 117
If you choose one of the hypothesis tests, you can choose the alternative hypothesis to test against the null hypothesis. For each test, there are three possible choices for an alternative hypothesis based on a quantitative comparison of two quantities. The null hypothesis is always that the two quantities are equal.Thus, the alternative hypotheses cover the various cases for the two quantities being unequal: <, >, and ≠.
Page 118
Enter data 4. Enter the sample statistics and population parameters that define the chosen test or interval. SETUP The table below lists the fields in this view for our current Z–Test: 1 µ example. Field name Definition µ0 Assumed population mean σ...
Plot test 8. Display a graphic view of the test results. results Horizontal axes are presented for both the distribution variable and the test statistic. A generic bell curve represents the probability distribution function. Vertical lines mark the critical value(s) of the test, as well as the value of the test statistic.
Page 120
Enter data 2. In the C1 column, enter the random numbers produced by the calculator. H I N T If the Decimal Mark setting in the Modes input form ) is set to Comma, use instead of MODES 3. If necessary, select 1–variable statistics. Do this by pressing the fifth menu key until is displayed as W6S——...
Page 121
Choose 7. Choose an inference method. inference 8CPPT— Select CONF INTERVAL method and PF— type 8. Choose a distribution statistic type. 8CPPT— Select T-Int: 1 µ PF— Set up the 9. Set up the interval calculation. Note: The default values interval are sample data from the on-line help example.
Page 122
11. Specify a 90% confidence interval in the C: field. to move to the C: field Display 12. Display the confidence interval in the Numeric view. Note: The interval setting is 0.5. Numeric view Display Plot 13. Display the confidence interval in the Plot view. view You can see, from the second text row, that the...
You use hypothesis tests to test the validity of hypotheses that relate to the statistical parameters of one or two populations. The tests are based on statistics of samples of the populations. The HP 39G/40G hypothesis tests use the Normal Z–distribution or Student’s t-distribution to calculate probabilities.
Results The results are: Result Description Test Z Z–test statistic. Prob Probability associated with the Z–Test statistic. Critical Z Boundary values of Z associated with the α level that you supplied. Boundary values of required by Critical the α value that you supplied. Two–Sample Z–Test Z–Test: µ1–µ2 Menu name...
Results The results are: Result Description Test Z Z–Test statistic Prob Probability associated with the Z–Test statistic. Critical Z Boundary value of Z associated with the α level that you supplied. One–Proportion Z–Test Z–Test: 1P Menu name On the basis of statistics from a single sample, this test measures the strength of the evidence for a selected hypothesis against the null hypothesis.
Results The results are: Result Description Test P Proportion of successes in the sample. Test Z Z–Test statistic. Prob Probability associated with the Z–Test statistic. Critical Z Boundary value of Z associated with the level you supplied. Two–Proportion Z–Test Menu name Z–Test: P1–P2 On the basis of statistics from two samples, each from a different population, the 2 proportion Z–Test measures the...
Results The results are: Result Description Test P1–P2 Difference between the proportions of successes in the two samples. Test Z Z–Test statistic. Prob Probability associated with the Z–Test statistic. Critical Z Boundary values of Z associated with the α level that you supplied. One–Sample T–Test T–Test: 1 µ...
Results The results are: Result Description Test T T–Test statistic. Prob Probability associated with the T–Test statistic. Critical T Boundary value of T associated with the α level that you supplied. Boundary value of required by Critical the α value that you supplied. Two–Sample T–Test T–Test: µ1 –...
Page 129
Inputs The inputs are: Field name Definition Sample 1 mean. Sample 2 mean. Sample 1 standard deviation. Sample 2 standard deviation. Sample 1 size. Sample 2 size. α Significance level. _Pooled? Check this option to pool samples based on their standard deviations. Results The results are: Result...
Confidence intervals The confidence interval calculations that the HP 39G/40G can perform are based on the Normal Z–distribution or Student’s t–distribution. One–Sample Z–Interval Z–INT: 1 µ Menu name This option uses the Normal Z–distribution to calculate a confidence interval for µ, the true mean of a population, when the true population standard deviation, σ, is known.
Two–Sample Z–Interval Z–INT: µ1– µ2 Menu name This option uses the Normal Z–distribution to calculate a confidence interval for the difference between the means of two populations, µ – µ , when the population standard deviations, σ and σ , are known. Inputs The inputs are: Field name...
One–Proportion Z–Interval Menu name Z–INT: 1 P This option uses the Normal Z–distribution to calculate a confidence interval for the proportion of successes in a population for the case in which a sample of size, n, has a number of successes, x. Inputs The inputs are: Field name...
Two–Proportion Z–Interval Menu name Z–INT: P1 – P2 This option uses the Normal Z–distribution to calculate a confidence interval for the difference between the proportions of successes in two populations. Inputs The inputs are: Field name Definition Sample 1 success count. Sample 2 success count.
One–Sample T–Interval T–INT: 1 µ Menu name This option uses the Student’s t–distribution to calculate a confidence interval for µ, the true mean of a population, for the case in which the true population standard deviation, σ, is unknown. Inputs The inputs are: Field name Definition...
Two–Sample T–Interval T–INT: µ1 – µ2 Menu name This option uses the Student’s t–distribution to calculate a confidence interval for the difference between the means of two populations, µ − µ , when the population standard deviations, σ and σ , are unknown.
Page 136
Downloaded from www.Manualslib.com manuals search engine...
Using mathematical functions Math functions The HP 39G/40G contains many math functions. The functions are grouped in categories. For example, the Matrix category contains functions for manipulating matrices. The Probability category (shown as Prob. on the MATH menu) contains functions for working with probability.
Page 138
To select a 1. Press to display the MATH menu. The categories function appear in alphabetical order. Press to scroll through the categories. To skip directly to a category, press the first letter of the category’s name. Note: You do not need to press first.
Math functions by category Following are definitions for all categories of functions except List, Matrix, and Statistics, each of which appears in its own chapter. Except for the keyboard operations, which do not appear in the MATH menu, all other functions are listed by their category in the MATH menu.
Keyboard functions The most frequently used functions are available directly from the keyboard. Many of the keyboard functions also accept complex numbers as arguments. Add, Subtract, Multiply, Divide. Also accepts complex numbers, lists and matrices. value1+ value2, etc. Natural exponential. Also accepts complex numbers. e^value Example e^5 returns 148.413159103...
Page 141
–1 Arc sine: sin x. Output range is from –90° to 90°, –π/2 to ASIN π/2, or –100 to 100 grads. Inputs and outputs depend on the current angle format. Also accepts complex numbers. ASIN(value) Example ASIN(1) returns 90 (Degrees mode). –1 x.
Page 142
Power (x raised to y). Also accepts complex numbers. value^power Example 2^8 returns 256 Absolute value. For a complex number, this is ABS(value) ABS((x , y)) Example ABS(–1) returns 1 ABS((1,2)) returns 2.2360679775 Takes the nth root of x. root NTHROOT value Example 3 NTHROOT 8 returns 2 10-6...
Calculus functions The symbols for differentiation and integration are available directly form the keyboard— and respectively—as well as from the MATH menu. Differentiates expression with respect to the variable of differentiation. From the command line, use a formal name (S1, etc.) for a non-numeric result. See “Finding derivatives” on page 10-23.
Complex number functions These functions are for complex numbers only. You can also use complex numbers with all trigonometric and hyperbolic functions, and with some real-number and keyboard functions. Enter complex numbers in the form (x,y), where x is the real part and y is the imaginary part. Argument.
Constants The HP 39G/40G has an internal numeric representation for these constants. Natural logarithm base. Internally represented as 2.71828182846. Imaginary value for √−1 , the complex number (0,1). MAXREAL Maximum real number. Internally represented as 9.99999999999 x 10 MAXREAL –...
ALOG Antilogarithm (exponential). This is more accurate than 10^x due to limitations of the power function. ALOG(value) Natural exponential. This is more accurate than due to limitations of the power function. EXP(value) EXPM1 Exponent minus 1 : e –1. This is more accurate than EXP when x is close to zero.
Loop functions The loop functions display a result after evaluating an expression a given number of times. ITERATE Repeatedly for #times evaluates an expression in terms of variable. The value for variable is updated each time, starting with initialvalue. ITERATE(expression,variable,initialvalue, #times) Example ,X,2,3) returns 256...
Polynomial functions Polynomials are products of constants (coefficients) and variables raised to powers (terms). POLYCOEF Polynomial coefficients. Returns the coefficients of the polynomial with the specified roots. POLYCOEF ([roots]) Example To find the polynomial with roots 2, –3, 4, –5: POLYCOEF([2,-3,4,-5]) returns[1,2,-25, -26,120], representing x –25x...
H I N T The results of POLYROOT will often not be easily seen in HOME due to the number of decimal places, especially if they are complex numbers. It is better to store the results of POLYROOT to a matrix. For example, POLYROOT([1,0,0,-8] M1 will store TUPc•Ã...
Page 150
H I N T The setting of Time will be different for each calculator, so using RANDSEED(Time) is guaranteed to produce a set of numbers which are as close to random as possible. You can set the seed using the command RANDSEED. UTPC Upper-Tail Chi-Squared Probability given degrees of freedom, evaluated at value.
Real-number functions Some real-number functions can also take complex arguments. CEILING Smallest integer greater than or equal to value. CEILING(value) Examples CEILING(3.2) returns 4 CEILING(-3.2) returns -3 → Degrees to radians. Converts value from Degrees angle format to Radians angle format. DEG→RAD(value) Example DEG→RAD(180) returns 3.14159265359, the...
Page 152
→ Hours-minutes-seconds to decimal. Converts a number or expression in H.MMSSs format (time or angle that can include fractions of a second) to x.x format (number of hours or degrees with a decimal fraction). HMS→(H.MMSSs) Example HMS→(8.30) returns 8.5 → Decimal to hours-minutes-seconds.
Page 153
Modulo. The remainder of value1/value2. value1 MOD value2 Example 9 MOD 4 returns 1 x percent of y; that is, x/100*y. %(x,y) Example %(20,50) returns 10 %CHANGE Percent change from x to y, that is, 100(y–x)/x. %CHANGE(x,y) Example %CHANGE(20,50) returns 150 %TOTAL Percent total : (100)y/x.
SIGN Sign of value. If positive, the result is 1. If negative, –1. If zero, result is zero. For a complex number, this is the unit vector in the direction of the number. SIGN(value) SIGN((x,y)) Examples SIGN (–2) returns –1 SIGN((3,4)) returns (.6,.8) TRUNCATE Truncates value to decimal places.
Symbolic functions The symbolic functions are used for symbolic manipulations of expressions. The variables can be formal or numeric, but the result is usually in symbolic form (not a number). You will find the symbols for the symbolic functions = and | (where) in the CHARS menu ( ) as well as the MATH menu.
QUOTE Encloses an expression that should not be evaluated numerically. QUOTE(expression) Examples F1(X) stores the expression QUOTE(SIN(45)) TUPc• SIN(45) rather than the value of SIN(45). Another method is to enclose the expression in single quotes. For example, X^3+2*X F1(X) puts the TUPc•...
Compares value1 and value2. Returns 1 if they are both non- zero, otherwise returns 0. value1 AND value2 IFTE If expression is true, do the trueclause; if not, do the falseclause. IFTE(expression , trueclause , falseclause ) Example IFTE(X>0,X Returns 1 if value is zero, otherwise returns 0. NOT value Returns 1 if either value1 or value2 is non-zero, otherwise returns 0.
To perform symbolic calculations, for example symbolic variables differentiations and integrations, you need to use formal names. The HP 39G/40G has six formal names available for use in symbolic calculations. These are S0 to S5. When you perform a calculation that contains a formal name, the HP 39G/40G does not carry out any substitutions.
Finding derivatives The HP 39G/40G can perform symbolic differentiation on some functions. There are two ways of using the HP 39G/40G to find derivatives. • You can perform differentiations in HOME by using the formal variables, S1 to S5. •...
Page 160
@W6G• 4. Press to display the result. (Use the arrow keys to TCPX• view the entire function.) TCPX• HP 39G HP 40G You could also just define F1 x ( ) x ( ) 10-24 Using mathematical functions Downloaded from www.Manualslib.com...
Page 161
2. Show the result format. TCPX• 3. Press to close the PF• show window. 4. Copy the result and evaluate. 8PQ`•Ã HP 39G HP 40G Thus, substituting X for S1, it can be seen that: ---- - ∫ ...
Page 162
The ‘extra’ constant of 6.4 results from the substitution into (x – 2) and should be disregarded if an indefinite integral is required. 10-26 Using mathematical functions Downloaded from www.Manualslib.com manuals search engine...
The calculator uses this memory to store variables, perform computation, and store history. A variable is an object that you create in memory to hold data. The HP 39G/40G has two types of variables, home variables and aplet variables. •...
Storing and recalling variables You can store numbers or expressions from a previous input or result into variables. Numeric A number stored in a variable is always stored as a 12-digit Precision mantissa with a 3-digit exponent. Numeric precision in the display, however, depends on the display mode (Standard, Fixed, Scientific, Engineering, or Fraction).
Page 165
To store the If the value you want to store is in the HOME view display results of a history, for example the results of a previous calculation, you need to copy it to the command line, then store it. calculation 1.
To use variables You can use variables in calculations. The calculator in calculations substitutes the variable’s value in the calculation: The VARS menu You use the VARS menu to access all variables in the calculator. The VARS menu is organised by category. For each variable category in the left column, there is a list of variables in the right column.
Page 167
5. Choose whether to place the variable name or the variable value on the command line. – Press to indicate that you want the variable’s W6GV@— contents to appear on the command line. – Press to indicate that you want the variable’s I6H@—Ã...
Page 168
4. Enter data for L2. PF— PF— PF— PF—Ã PF— 5. Press to access HOME. 6. Open the variable menu and select L1. 7. Copy it to the command line. Note: Because the I6H@— option is highlighted, the variable’s name, rather than its contents, is copied to the command line.
Home It is not possible to store data of one type in a variable of another type. For example, you use the Matrix catalog to variables create matrices. You can create up to ten matrices, and you can store these in variables M0 to M9. You cannot store matrices in variables other than M0 to M9.
Page 170
Aplet variables Aplet variables store values that are unique to a particular aplet. These include symbolic expressions and equations (see below), settings for the Plot and Numeric views, and the results of some calculations such as roots and intersections. See the Reference Information chapter for more information about aplet variables.
Memory Manager You can use the Memory Manager to determine the amount of available memory on the calculator. You can also use Memory Manager to organize memory. For example, if the available memory is low, you can use the Memory Manager to determine which aplets or variables consume large amounts of memory.
Page 172
Downloaded from www.Manualslib.com manuals search engine...
Matrices Introduction You can perform matrix calculations in HOME and in programs. The matrix and each row of a matrix appear in brackets, and the elements and rows are separated by commas. For example, the following matrix: 1 2 3 4 5 6 is displayed in the history as: [[1,2,3],[4,5,6]]...
Prompts for a matrix type, then opens an empty matrix with the highlighted name. T@I9• Transmits the highlighted matrix to another HP 39G/40G or a disk drive. See “Sending and receiving aplets” on page 16-5. S@8W• Receives a matrix from another HP 39G/40G or a disk drive.
Page 175
To create a matrix 1. Press to open the Matrix catalog. The MATRIX in the matrix Matrix catalog lists the 10 available matrix variables, M0 to M9. catalog 2. Highlight the matrix variable name you want to use and press I@X•...
You can send matrices between calculators just as you can matrix send aplets, programs, lists, and notes. 1. Align the HP 39G calculators’ infrared ports. 2. Open the Matrix catalogs on both calculators. 3. Highlight the matrix to send. 4. Press T@I9•...
Page 177
To display a • In the Matrix catalog ( ), highlight the MATRIX matrix matrix name and press @9DU• • In HOME, enter the name of the matrix variable and press To display one In HOME, enter matrixname(row,column). For example, if element M2 is [[3,4],[5,6]], then M2(1,2) returns 4.
Matrix arithmetic You can use the arithmetic functions (+, –, ×, / ) with matrix arguments. Division left–multiplies by the inverse of the divisor. You can enter the matrices themselves or enter the names of stored matrix variables. The matrices can be real or complex.
Page 179
To multiply two To multiply the two matrices M1 and M2 that you created for matrices the previous example, use the following keystrokes: To multiply a matrix by a vector, enter the matrix first, then the vector. The number of elements in the vector must equal the number of columns in the matrix.
Solving systems of linear equations Example Solve the following linear system: – 4x y – 1. Open the Matrix catalog and choose to create a vector in the M1 variable. MATRIX I@X• 2. Create the vector of the constants in the linear system. 3.
6. Return to HOME and enter the calculation to left multiply the constants vector by the inverse of the coefficients matrix. –1 7. Evaluate the calculation. The result is a vector of the solutions: • • • 2 – An alternative method, is to use the RREF function. See “RREF”...
About commands Matrix commands are listed in the CMDS menu ( ), in the matrix category. CMDS See “Matrix commands” on page 15-23 for details of the matrix commands available for use in programming. Functions differ from commands in that a function can be used in an expression.
Page 183
EIGENVAL Displays the eigenvalues in vector form for matrix. EIGENVAL(matrix) EIGENVV Eigenvectors and Eigenvalues for a square matrix. Displays a list of two arrays. The first contains the eigenvectors and the second contains the eigenvalues. EIGENVV(matrix) IDENMAT Identity matrix. Creates a square matrix of dimension size ×...
Page 184
QR Factorization. Factors an m×n matrix into three matrices: {[[m×m orthogonal]],[[m×n uppertrapezoidal]],[[n×n permutation]]}. QR(matrix) RANK Rank of a rectangular matrix. RANK(matrix) ROWNORM Row Norm. Finds the maximum value (over all rows) for the sums of the absolute values of all elements in a row. ROWNORM(matrix) RREF Reduced Row Echelon Form.
TRACE Finds the trace of a square matrix. The trace is equal to the sum of the diagonal elements. (It is also equal to the sum of the eigenvalues.) TRACE(matrix) Transposes matrix. For a complex matrix, TRN finds the conjugate transpose. TRN(matrix) Examples Identity Matrix...
Page 186
Reduced-Row The following set of equations x 2y – – – Echelon Form – 1 2 – 3 14 can be written as the augmented matrix 1 – 3 – 4 2 – 2 14 which can then stored as a ×...
Lists You can do list operations in HOME and in programs. A list consists of comma-separated real or complex numbers, expressions, or matrices, all enclosed in braces. A list may, for example, contain a sequence of real numbers such as {1,2,3}.
Page 188
Meaning @9DU— Opens the highlighted list for editing. Transmits the highlighted list to T@I9— another HP 39G/40G or a PC. See “Sending and receiving aplets” on page 16-5 for further information. Receives a list from another HP 39G/ S@8W— 40G or a PC. See “Sending and receiving aplets”...
Page 189
List edit keys When you press edit to create or change a list, the following keys are available to you: Meaning Copies the highlighted list item into @9DU— the edit line. Inserts a new value before the DIT— highlighted item. Deletes the highlighted item from the list.
Displaying and editing lists To display a list • In the List catalog, highlight the list name and press Ã@9DU— • In HOME, enter the name of the list and press To display one In HOME, enter listname(element#). For example, if L2 is element {3,4,5,6}, then L2(2) returns 4.
Page 191
To insert an 1. Open the List catalog. element in a list LIST 2. Press to highlight the name of the list you want to edit (L1, etc.) and press to display the list @9DU—Ã contents. @9DU— 3. Press to the insertion position.
Transmitting lists You can send lists to calculators or PCs just as you can aplets, programs, matrices, and notes. 1. Align the HP 39G calculators’ infrared ports. 2. Open the List catalogs on both calculators. 3. Highlight the list to send.
List functions Following are details of list functions. You can use them in HOME, as well as in programs. You can type in the name of the function, or you can copy the name of the function from the List category of the MATH menu.
Page 194
CONCAT Concatenates two lists into a new list. CONCAT(list1 , list2) Example CONCAT({1,2,3},{4}) returns {1,2,3,4}. ∆ LIST Creates a new list composed of the differences between the sequential elements in list1. The new list has one fewer elements than list1. The first differences for {x ...
Page 195
ΠLIST Calculates the product of all elements in list. ΠLIST(list) Example ΠLIST({2,3,4}) returns 24. Returns the position of an element within a list. The element can be a value, a variable, or an expression. If there is more than one instance of the element, the position of the first occurrence is returned.
Finding statistical values for list elements To find values such as the mean, median, maximum, and minimum values of the elements in a list, use the Statistics aplet. Example In this example, use the Statistics aplet to find the mean, median, maximum and minimum values of the elements in the list, L1.
Page 197
4. In the Symbolic view, define H1 (for example) as C1 (sample) and 1 (frequency). Make sure that H1 is checkmarked. 5. Go to the Numeric view to display calculated statistics. TU6UT— See “One-variable” on page 8-13 for the meaning of each computed statistic.
Page 198
Downloaded from www.Manualslib.com manuals search engine...
Notes and sketches Introduction The HP 39G/40G has text and picture editors for entering notes and sketches. • Each aplet has its own independent Note view and Sketch view. Notes and sketches that you create in these views are associated with the aplet. When you save the aplet, or send it to another calculator, the notes and sketches are saved or sent as well.
Page 200
Note edit keys Meaning TQ68@• Space key for text entry. Displays next page of a multi-page Q6B@É• note. Alpha-lock for letter entry. 6a• Lower-case Alpha-lock. 6a• 7FTQ• Backspaces cursor and deletes character. Deletes current character. Starts a new line. Erases the entire note. CLEAR Menu for entering variable names, and contents of variables.
Aplet sketch view You can attach pictures to an aplet in its Sketch view ). Your work is automatically saved with the SKETCH aplet. Press any other view key or to exit the Sketch view Sketch keys Meaning TUP• Stores the specified portion of the current sketch to a graphics variable (G1 through G0).
Page 202
To draw a box 1. In Sketch view, press and move the cursor to 9S6X• where you want any corner of the box to be. 2. Press . This turns on box-drawing. 7PY• 3. Move the cursor to mark the opposite corner for the box. You can adjust the size of the box by moving the cursor.
Page 203
To label parts of a 1. Press and type the text in the edit line. To lock the U@YU• sketch Alpha shift on, press (for uppercase) or 6a• 6a• (for lowercase). To make the label a smaller character size, turn off 7DB•...
To import a You can copy the contents of a graphics variable into the graphics variable Sketch view of an aplet. 1. Open the Sketch view of the aplet ( ). The SKETCH graphic will be copied here. 2. Press .
Page 205
I@X• Begins a new note, and asks for a name. T@I9• Transmits the selected note to another HP 39G/40G or PC. S@8W• Receives a note being transmitted from another HP 39G/40G or PC. Deletes the selected note. Deletes all notes in the catalog.
Page 206
To import a note You can import a note from the Notepad into an aplet’s Note view, and vice-versa. Suppose you want to copy a note named “Assignments” from the Notepad into the Function Note view: 1. In the Function aplet, display the Note view NOTE 2.
Programming Introduction This chapter describes how to program using the HP 39G/ 40G. In this chapter you’ll learn about: • using the Program catalog to create and edit programs • programming commands • storing and retrieving variables in programs •...
Editline contains the last expression that you entered from the edit line in HOME, or the last data you entered in an input form. (If you press from HOME without entering any data, the HP 39G/40G runs the contents of Editline.) Editline is a built-in function.
Page 209
Prompts for a new program name, I@X— then opens an empty program. T@I9— Transmits the highlighted program to another HP 39G/40G or to a disk drive. S@8W— Receives the highlighted program from another HP 39G/40G or from a disk drive.
PROGRM program 2. Press I@X— The HP 39G/40G prompts you for a name. A program name can contain special characters, such as a space. However, if you use special characters and then run the program by typing it in HOME, you must enclose the program name in double quotes ("...
Page 211
Enter Until you become familiar with the HP 39G/40G commands, the easiest way to enter commands is to use the Commands commands menu from the Program editor. You can always type in commands using alpha characters. 1. From the Program editor, press...
Page 212
Editing keys The editing keys are: Meaning Inserts the character at the editing TUPc— TUPc— point. TQ68@— Inserts space into text. Displays previous page of the program. eQ6B@— Displays next page of the program. Q6B@É— Moves up or down one line. Moves right or left one character.
HOME, the HP 39G/40G displays the contents of Ans (Home variable containing the last result), when the program has finished. If you start the program from the Program catalog, the HP 39G/40G returns you to the Program catalog when the program ends. Debug a...
Working with programs Copy a You can use the following procedure if you want to make a copy of your work before editing—or if you want to use one program program as a template for another. 1. Press to open the Program catalog. PROGRM 2.
Delete all You can delete all programs at once. programs 1. In the Program catalog, press CLEAR 2. Press `@T— Delete the You can clear the contents of a program without deleting the program name. contents of a program 1. Press to open the Program catalog.
Aplet naming convention To assist users in keeping track of aplets and associated programs, use the following naming convention when setting up an aplet’s programs: • Start all program names with an abbreviation of the aplet name. We will use APL in this example. •...
Page 217
3. Create a program called EXP.ME2 with contents as shown. This program sets the numeric view options for the aplet, and runs the program that you can use to configure the angle mode. 4. Create a program called EXP.ANG which the previous two programs call.
Page 218
SETVIEWS ’ ’ ’ ’ ; ;’ ’ ’ ’ ; 18; Sets the first menu option to be "Auto scale". This is the fourth standard Function aplet view menu option and the 18 "Auto scale", specifies that it is to be included in the new menu.
Page 219
You only need to run this program once to configure your aplet’s VIEWS menu. Once the aplet’s VIEWS menu is configured, it remains that way until you run SETVIEWS again. You do not need to include this program for your aplet to work, but it is useful to specify that the program is attached to the aplet, and transmitted when the aplet is transmitted.
Programming commands This section describes the commands for programming with HP 39G/40G. You can enter these commands in your program by typing them or by accessing them from the Commands menu. Aplet commands These commands control aplets. CHECK Checks (selects) the corresponding function in the current aplet.
Page 221
• All the programs that are called from the VIEWS menu are transferred when the aplet is transferred, for example to another calculator or to a PC. • As part of the VIEWS menu configuration, you can specify programs that you want transferred with the aplet, but are not called as menu options.
Page 222
Auto-run programs If the Prompt item is “Start”, then the ProgramName program runs whenever you start the aplet. This is useful for setting up a program to configure the aplet. Users can select the Start item from the Views menu to reset the aplet if they change configurations.
View numbers The views are numbered as follows: HOME List Catalog Plot Matrix Catalog Symbolic Notepad Catalog Numeric Programs Catalog Plot-Setup Plot-Detail Symbolic-Setup Plot-Table Numeric-Setup Overlay Plot Views Auto scale Note Decimal Sketch view Integer Aplet Catalog Trig UNCHECK Unchecks (unselects) the corresponding function in the current aplet.
Page 224
IFERR... Many conditions are automatically recognized by the HP THEN... 39G/40G as error conditions and are automatically treated as errors in programs. END... IFERR...THEN...END allows a program to intercept error conditions that otherwise would cause the program to abort.
Xmin, Xmax, Ymin, and Ymax values. The following examples assume the HP 39G/40G default settings with the Function aplet as the current aplet. Draws a circular arc, of given radians, whose centre is at (x,y) The arc is drawn from start_angle_measurement, and end_angle_measurement.
FREEZE Halts the program, freezing the current display. Execution resumes when any key is pressed. LINE Draws a line from (x1, y1) to (x2, y2). LINE x1;y1;x2;y2 PIXOFF Turns off the pixel at the specified coordinates (x,y). PIXOFF x;y PIXON Turns on the pixel at the specified coordinates (x,y).
Page 227
Creates a graphic from expression, using font_size, and stores the resulting graphic in graphicname. Font sizes are 1, 2, or 3. If the fontsize argument is 0, the HP 39G/40G creates a graphic display like that created by the SHOW operation.
ZEROGROB graphicname;width;height: Loop commands Loop structures allow a program to execute a routine repeatedly. The HP 39G/40G has three loop structures. The example programs below illustrate each of these structures incrementing the variable A from 1 to 12. DO…UNTIL Do ...
FOR…TO…STEP FOR name=start-expression TO end-expression ...END [STEP increment]; loop-clause END FOR A=1 TO 12 STEP 1; DISP 3;A: Note that the STEP parameter is optional. If it is omitted, a step value of 1 is assumed. BREAK Terminates loop. BREAK Matrix commands The matrix commands take variables M0–M9 as arguments.
Page 230
RANDMAT Creates random matrix with a specified number of rows and columns and stores the result in name (name must be M0...M9). The entries will be integers ranging from –9 to 9. RANDMAT name;rows;columns REDIM Redimensions the specified matrix or vector to size. For a matrix, size is a list of two integers {n1,n2}.
Print commands These commands print to an HP infrared printer, for example the HP 82240B printer. Note: The HP 40G does not have an infrared port and will not print to an infrared printer. PRDISPLAY Prints the contents of the display.
Page 232
Example A:CHOOSE A; "COMIC STRIPS"; "DILBERT"; "CALVIN&HOBBES"; "BLONDIE"; DISP Displays textitem in a row of the display at the line_number. A text item consists of any number of expressions and quoted strings of text. The expressions are evaluated and turned into strings.
Page 233
FREEZE This command prevents the display from being updated after the program runs. This allows you to view the graphics created by the program. Cancel FREEZE by pressing any key. FREEZE GETKEY Waits for a key, then stores the keycode rc.p in name, where r is row number, c is column number, and p is key-plane number.
Page 234
MSGBOX Displays a message box containing textitem. A text item consists of any number of expressions and quoted strings of text. The expressions are evaluated and turned into strings of text. For example, "AREA IS:" 2+2 becomes AREA IS: 4. Use CHARS to type the quote marks "...
Stat-One and Stat-Two commands The following commands are used for analysis of one- variable and two-variable statistical data. Stat-One commands DO1VSTATS Calculates STATS using datasetname and stores the results in the corresponding variables: NΣ, TotΣ, MeanΣ, PVarΣ, SVarΣ, PSDev, SSDev, MinΣ, Q1, Median, Q3, and MaxΣ. Datasetname can be H1, H2, ..., or H5.
Storing and retrieving variables in programs The HP 39G/40G has both Home variables and Aplet variables. Home variables are used for real numbers, complex numbers, graphics, lists, and matrices. Home variables keep the same values in HOME and in aplets.
Page 237
Coord Turns the coordinate-display mode in Plot view on or off. From Plot view, use the Menu mean key to toggle coordinate display on an off. In a program, type Coord—to turn coordinate display on (default). Coord—to turn coordinate display off. Extremum Contains the last value found by the Extremum operation in the Plot-FCN menu.
Page 238
Hwidth Sets the width of histogram bars. From Plot Setup in 1VAR stats set a value for Hwidth In a program, type Hwidth Indep Defines the value of the independent variable used in tracing mode. In a program, type Indep InvCross Toggles between solid crosshairs or inverted crosshairs.
Page 239
Nmin / Nmax Defines the minimum and maximum independent variable values. Appears as the NRNG fields in the Plot Setup input form. From Plot Setup, enter values for NRNG. In a program, type Nmin Nmax > where Recenter Recenters at the crosshairs locations when zooming. From Plot-Zoom-Set Factors, check (or uncheck) Recenter In a program, type...
Page 240
Simult Toggles between simultaneous and sequential graphing of all selected expressions. From Plot Setup, check (or uncheck) _SIMULT In a program, type Simult—for simultaneous graphing. Simult—for sequential graphing. Slope Contains the last value found by the Slope function in the Plot–FCN menu.
Page 241
Tmin / Tmax Defines the minimum and maximum independent variable values. Appears as the TRNG field in the Plot Setup input form. From Plot Setup, enter values for TRNG. In a program, type Tmin Tmax > where Tracing Turns tracing mode on or off in Plot view. In a program, type Tracing—to turn Tracing mode on (default).
Page 242
Xtick Defines the distance between tick marks for the horizontal axis. From the Plot Setup input form, enter a value for Xtick. In a program, type > Xtick where Ytick Defines the distance between tick marks for the vertical axis. From the Plot Setup input form, enter a value for Ytick.
Xzoom Sets the horizontal zoom factor. From Plot-ZOOM-Set Factors, enter the value for XZOOM. In a program, type XZOOM > where Yzoom Sets the vertical zoom factor. From Plot-ZOOM-Set Factors, enter the value for YZOOM. In a program, type YZOOM Symbolic-view variables The following aplet variables available in the Symbolic view.
Page 244
X1, Y1...X9,Y9 Can contain any expression. Independent variable is T. X0,Y0 Example ’SIN(4*T)’ Y1(T):’2*SIN(6*T)’ STO X1(T) Can contain any expression. Independent variable is θ. R1...R9, R0 Example ’2*SIN(2*θ)’ R1(θ) U1...U9, U0 Can contain any expression. Independent variable is N. Example RECURSE (U,U(N-1)*N,1,2) U1(N) E1...E9, E0...
Numeric-view variables The following aplet variables control the Numeric view. The value of the variable applies to the current aplet only. C1...C9, C0 C0 through C9, for columns of data. Can contain lists. Enter data in the Numeric view In a program, type LIST C n where n = 0, 1, 2, 3 ...
Page 246
Format Defines the number display format. From Solve’s Numeric Setup view, choose Standard, Fixed, Scientific, or Engineering in the Number Format field. In a program, store the constant name (or its number) into the variable Format. 1. Standard 2. Fixed 3.
Page 247
NumRow Defines the highlighted row in Numeric view. In a program, type NumRow > where NumStart Defines the starting value for a table in Numeric view. From Num Setup, enter a value for NUMSTART. In a program, type NumStart NumStep Defines the step size (increment value) for an independent variable in Numeric view.
StatMode Toggles between 1–variable and 2–variable statistics in the Statistics aplet. Does not appear in the Plot Setup input form. Corresponds to the menu keys in Numeric W6S— !W6S— View. In a program, store the constant name (or its number) into the variable StatMode.
Extending aplets Aplets are the application environments where you explore different classes of mathematical operations. You can extend the capability of the HP 39G/40G in the following ways: • Create new aplets, based on existing aplets, with specific configurations such as angle measure, graphical or tabular settings, and annotations.
Page 250
TPSU• Alphabetically or chronologically sorts the items in the Aplet Library menu list. T@I9• Transmits the highlighted aplet to another HP 39G/40G or a storage device. Receives the aplet sent from another S@8W• (receive) HP 39G/40G or storage device.
Page 251
3. Decide whether you want the aplet to operate in Degrees, Radians, or Grads. MODES 8CPPT• Select Degrees PF• 4. Ensure the TRIANGLES aplet is saved in the Aplet Library. The Solve aplet can now be reset and used for other problems.
For example, Hewlett-Packard’s Calculators web site contains aplets that demonstrate certain mathematical concepts. Note that you need the Graphing Calculator Connectivity Kit in order to load aplets from a PC. Hewlett-Packard’s Calculators web site can be found at: www.hp.com/calculators 16-4 Extending aplets Downloaded from www.Manualslib.com...
Sorting items in the aplet library menu list Once you have entered information into an aplet, you have defined a new version of an aplet. The information is automatically saved under the current aplet name, such as “Function.” To create additional aplets of the same type, you must give the current aplet a new name.
Any modifications to the calculator not expressly approved by Hewlett-Packard could void the authority to operate the HP 39G/40G in these regions. This calculator generates, uses, and can radiate radio frequency energy and may interfere with radio and television reception.
Replacement products may be either new or like-new. 2. HP warrants to you that HP software will not fail to execute its programming instructions after the date of purchase, for the period specified above, due to defects in material and workmanship when properly installed and used.
Page 257
3. HP does not warrant that the operation of HP products will be uninterrupted or error free. If HP is unable, within a reasonable time, to repair or replace any product to a condition as warranted, you will be entitled to a refund of the purchase price upon prompt return of the product.
EXCLUDE, RESTRICT OR MODIFY AND ARE IN ADDITION TO THE MANDATORY STATUTORY RIGHTS APPLICABLE TO THE SALE OF THIS PRODUCT TO YOU. The HP 40G is packaged with a computerized algebra system (CAS). Refer to the CAS User Manual for further information. Resetting the HP 39G/40G If the calculator “locks up”...
If the calculator does not turn on If the HP 39G/40G does not turn on follow the steps below until the calculator turns on. You may find that the calculator turns on before you have completed the procedure. If the calculator still does not turn on, please contact Customer Support for further information.
Glossary aplet A small application, limited to one topic. The built-in aplet types are Function, Parametric, Polar, Sequence, Solve, and Statistics. An aplet can be filled with the data and solutions for a specific problem. It is reusable (like a program, but easier to use) and it records all your settings and definitions.
menu A choice of options given in the display. It can appear as a list or as a set of menu- key labels across the bottom of the display. menu keys The top row of keys. Their operations depend on the current context. The labels along the bottom of the display show the current meanings.
Warning: Low Bat. The HP 39G/40G uses three AAA batteries. Be sure all three are of the same brand and type. Rechargeable batteries are not recommended because of their lower capacity and more sudden demise.
Category Available name (Continued) Graphic G1...G9, G0 Library Function Parametric Polar Sequence Solve Statistics User-named List L1...L9, L0 Matrix M1...M9, M0 Modes Date HAngle HDigits HFormat Ierr Time Notepad User-named Program Editline User-named A...Z, θ Real Function aplet variables The function aplet variables are: Category Available name Plot...
Menu maps of the MATH menu Math functions The math functions are: Category Available name Calculus TAYLOR Complex CONJ Constant MAXREAL MINREAL π Hyperb. ACOSH TANH ASINH ALOG ATANH COSH EXPM1 SINH LNP1 List CONCAT REVERSE ∆LIST SIZE ΣLIST MAKELIST πLIST SORT Loop...
Program constants The program constants are: Category Available name Angle Degrees Grads Radians Format Standard Fixed Fraction SeqPlot Cobweb Stairstep S1...5fit Linear QuadFit LogFit Cubic ExpFit Logist Power User StatMode Stat1Var Stat2Var StatPlot Hist BoxW Reference information R-17 Downloaded from www.Manualslib.com manuals search engine...
Selected status messages The status messages are: Message Meaning Bad Argument Type Incorrect input for this operation. Bad Argument The value is out of range for this Value operation. Infinite Result Math exception, such as 1/0. Insufficient You must recover some memory Memory to continue operation.
Page 274
Message Meaning (Continued) (OFF SCREEN) Function value, root, extremum, or intersection is not visible in the current screen. Receive Error Problem with data reception from another calculator. Re-send the data. Too Few The command requires more Arguments arguments than you supplied. Undefined Name The global variable named does not exist.
Page 276
connectivity kit 16-5 constant? error message 7-7 calculus constants 10-9 operations 10-8 e 10-9 catalogs 1-28 i 10-9 chronological sorting 16-6 maximum real number 10-9 circle drawing 14-4 minimum real number 10-9 clearing program R-17 aplet 16-4 contrast characters 1-21 decreasing display 1-2 display 1-21 increasing display 1-2...
Page 277
deleting aplet 16-6 e 10-9 lists 13-6 edit line 1-2 matrices 12-4 editing programs 15-9 matrices 12-4 statistical data 8-10 notes 14-2 delimiters, programming 15-1 programs 15-5 derivatives Editline definition of 10-7 Program catalog 15-2 in Function aplet 10-24 editors 1-28 in Home 10-23 eigenvalues 12-11 determinant...
Page 278
fixed number format 1-10 one-variable statistics 8-18 overlaying 2-16 font size scatter 8-15 8-16 change 3-8 14-5 split-screen view 2-15 forecasting 8-21 splitting into plot and close-up 2-14 fraction number format 1-10 splitting into plot and table 2-14 full-precision display 1-10 stairsteps 6-2 function statistical data 8-15...
Page 280
list low battery 1-1 arithmetic with 13-7 lowercase letters 1-6 calculate sequence of elements 13-8 calculating product of 13-9 composed from differences 13-8 mantissa 10-16 concatenating 13-8 math functions counting elements in 13-9 complex number 10-8 creating 13-1 13-3 13-4 13-5 hyperbolic 10-10 deleting 13-6...
Page 281
multiplying and dividing by scalar maximum real number 1-20 10-9 12-6 memory R-19 multiplying by vector 12-7 clearing all R-5 multiplying row by value and adding organizing 11-9 result to second row 15-24 out of R-20 multiplying row number by value saving 1-24 16-1 15-24...
Page 282
in Solve aplet 7-5 comparing 2-5 scientific 1-10 connected points 8-16 8-18 Standard 1-10 decimal scaling 2-14 numeric precision 11-9 defining the independent variable Numeric view 15-35 adding X values 2-19 drawing axes 2-6 automatic 2-17 expressions 3-3 build your own table 2-19 goto function 1-29 display defining function for column grid points 2-6...
Page 285
sketches define one-variable sample 15-29 define two-variable data set’s depen- creating 14-5 dent column 15-29 creating a blank graphic 15-22 define two-variable data set’s inde- creating a set of 14-5 pendent column 15-29 erasing a line 15-20 defining a fit 8-11 labeling 14-5 defining a regression model 8-11 opening view 14-3...
Comments to this Manuals
Latest comments: