HP 40g hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf
HP 40g - Graphing Calculator Manual
View all HP 40g manuals
Add to My Manuals
Save this manual to your list of manuals |
HP 40g manual content summary:
- HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 1
hp 39g+ graphing calculator Mastering the hp 39g+ A guide for teachers, students and other users of the hp 39g+, hp 39g & hp 40g Edition 1.1 HP part number F2224-90010 Printed Date: 2005/10/11 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 2
12 How to use this Manual 13 Early High School...13 Downloaded aplets & memory 38 The GRAPHICS MANAGER 39 The LIBRARY MANAGER 39 Fractions on the hp 39g 40 Pitfalls to watch for ...42 The HOME History ...43 COPYing calculations 43 Clearing the History...44 SHOWing results...44 Storing - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 3
functions ...76 Retaining calculated values 77 The NUM view revisited 77 ZOOM ...78 ∫ Integration: The definite integral using the function 80 Integration: The algebraic indefinite integral 81 The hp 40g Computer Algebra System 82 Integration: The definite integral using PLOT variables - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 4
evaluating limits 88 Gradient at a point...90 Finding and accessing polynomial roots 91 The VIEWS menu 92 Plot-Detail ...93 Plot-Table ...94 Overlay Plot ...95 Auto Scale ...96 Decimal, Integer & Trig 97 Downloaded Aplets from the Internet 99 Curve Areas...99 Linear Programming...99 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 5
135 The User Defined model 135 Connected data ...136 Two Variable Statistics 137 Showing the line of best aplet 150 Using the Chi2 test on a frequency table 150 Hypothesis test: T-Test 1 151 Confidence interval: T-Int 1 153 Hypothesis test: T-Test µ1 -µ2 154 Hypothesis test: Z-Test - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 6
...164 Choosing the level...164 GRAPH mode...164 SYMB mode ...165 Self test mode ...166 The Trig Explorer teaching aplet 167 Objectives...167 SIN vs. COS ...167 SYMB vs. GRPH mode 167 Using Matrices on the hp 39g 170 The MATRIX Catalog 170 Matrix calculations in the HOME view 171 Solving - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 7
...200 Organizing your collection 201 Software for the hp 38g, hp 39g & hp 40g 202 Software for the hp 39g 203 The HPGComm Connectivity Program 204 Deleting downloaded aplets from the calculator 207 Saving notes, aplets and sketches via the Connectivity Kit 208 Capturing screens using the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 8
The Graphics commands 237 The Loop commands ...237 FOR = TO [STEP] END 237 DO UNTIL...237 WHILE REPEAT...237 BREAK ...238 The Matrix commands 238 EDITMAT...238 REDIM ...238 The Print commands ...239 PRDISPLAY ...239 PRHISTORY...239 PRVAR ...239 The Prompt commands - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 9
The 'Tests' group of functions 259 The 'Trigonometric' & 'Hyperbolic' groups of functions 259 268 The 'Loop' group of functions 269 ITERATE ...269 RECURSE ...270 Σ (SUMMATION) ...270 The 'Matrix' group of functions 271 COLNORM ...271 COND ...271 CROSS...271 DET ...272 DOT ...272 EIGENVAL...272 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 10
2 - Using POLYROOT 285 Finding critical points and graphing a polynomial 286 Solving simultaneous equations 288 Method 1 - Graphing the lines 288 Second method - using a matrix 288 Third method - using the 3x3 Solver aplet 289 Expanding polynomials 290 Exponential growth ...291 Solution of - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 11
the hp 39g, hp 40g & hp 39g 312 Using the CAS...313 Entering and editing an expression 313 In-line editing mode ...316 Erasing, copying, cutting and pasting 316 Cursor mode...317 The CAS HOME History 317 The PUSH and POP commands 318 Pasting to an aplet...319 Evaluating algebraic expressions - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 12
extensively with Hewlett Packard on the graphic calculator family of which the hp 39g+ is a member, and was part of the team which created the hp 39g & hp 40g in 2000. He maintains an extensive website of material for the hp 39g/40g/39g+ series called The HP Home view, at http://www.hphomeview - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 13
has been attempted to design this manual to cover the full use of the hp 39g+ calculator. This means explanations which will be useful to anyone from a student who is just beginning to use algebra seriously, to one who is coming to grips with advanced calculus, and also to a teacher who is already - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 14
graphs whose shape you don't know in advance. Learn how to use the Parametric aplet. Your teacher might best advise on which portions of the Statistics aplet will skills covered in this manual which will not be of use at some time. It is suggested that students skim the whole manual, and then re- - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 15
calculations once the important keys have set up the environment to do it in. The NUM key gives you a tabular view of your function, sequence or data. The PLOT key displays the graph do most of your calculations. It is shared by all the aplets and oversees them all. The APLET key is central. This - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 16
= x3 − x2 − 7x + 6 . The PLOT key - used to graph the function. The NUM key showing a tabular view of the function. The APLET key is used to choose which aplet is active. There are 10 aplets provided with the calculator and more can be downloaded from the internet. The MATH key gives access to more - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 17
KEYS & NOTATION CONVENTIONS There are a number of types of keys/buttons that are used on the hp 39g+. Some essential keys The basic keys are those that you see on any calculator including scientific ones, such as the numeric operators and the trig keys. Most of these keys have two or more functions. - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 18
keys A special type of key unique to the hp 39g+ and family is the row of blank keys way to see this is to press the APLET key. As you can see right, the say to press and choose Chronologically. The manual you are given with your calculator uses a different convention. As mentioned before, - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 19
alpha key can be used as a memory. You can also use these memories in calculations. Type in the following (not forgetting the ALPHA key before the D).... (3+D)/5 ENTER The calculator will use the value of 12 stored earlier in D to evaluate the expression (see right). In case you haven't worked it - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 20
You should now be back HOME, with the function ROUND( entered in the display as shown right. You can also achieve the same effect by using ALPHA to type in the word letter by letter. Some people prefer to do it that way. Now type in: 4+D/18,3) and press ENTER As you can see, the effect was to round - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 21
statistics via hypothesis testing and confidence intervals. This was not available on the hp 38g, the original calculator upon which the hp 39g+ was based. The Parametric aplet (see page 100) Handles x(t), y(t) style graphs. Can also be used to help with vector motion. The Finance aplet (see page - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 22
drawing scatter graphs, histograms and box & whisker graphs. The Trig Explorer aplet (see page 167) This is a teaching aplet, allowing aplet. Some typical aplet views The APLET key is used to list all the aplets and start, reset or save them. The SYMB view is used to enter equations.... It can store - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 23
Internet. See page 200. A cable and software were provided with your hp 39g+ which you can use to connect your PC or Mac to your calculator and then download aplets from the computer to the calculator or to save your work to the computer. If you have an hp 38g, hp 39g or hp 40g then you need to buy - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 24
(contains not only aplets and games, but also a huge amount of detailed information on the calculator.) Calculator Tip The aplets for an hp 39g, hp 40g and hp 39g+ are interchangeable but not those of an hp 38g. If you load an aplet from an hp 38g onto an older model then the download will appear to - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 25
in the following order: 1. Exploring the Keyboard 2. Angle and numeric settings 3. Memory management 4. Fractions on the hp 39g+ 5. The HOME History 6. Storing and retrieving memories 7. Referring to other aplets from the HOME view 8. An introduction to the MATH menu 9. Resetting the calculator 25 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 26
press this the row of screen keys labels appear or disappear. To see another view where all the keys are in use, change to the APLET view. Calculator Tip Develop the habit of checking the screen to see if any of those keys have been given meanings. In many views, the screen - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 27
various different aplets available. Everything in the calculator revolves around aplets, which you can think of either as miniature programs or as environments within which you can work. The hp 39g+ comes with ten standard aplets Finance, Function, Inference, Parametric, Polar, Quadratic Explorer - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 28
when using aplets which have been downloaded from the Internet. When a programmed aplet is created for the hp 39g+, a stored by the calculator. Shown right are two views of the VARS screen, the first from the HOME list showing the graphic variables (memories) G1, G2.... and the next from the APLET - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 29
have keys of their own, but there is a limit to the number of keys that one can put on a calculator before it takes too long to find the key hp 39g+ gets twice the action from each key by having this second function. The second function is accessed via the SHIFT key on the left side of the calculator - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 30
it, which are usually blank unless you have added to them. The main use for them comes with aplets downloaded from the Internet. Instructions for using the aplet are sometimes included with the aplet in note form, and sometimes as an accompanying sketch. The MODES view The MODES view (see right - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 31
of 1000. The screens right show the same two numbers displayed as in turn as; Fixed 4, Scientific 4 and Engineering 4. Calculator Tip If you have Labels turned on when you in (or out) on a graph then you may end up with axes whose numeric labels are horrible decimals (see below right). 31 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 32
key instead. The ANS key Above the ENTER key is the ANS key. This can be used to retrieve the final value of the last calculation done. An example of this is shown right. If you are not confident about using brackets, then the ANS key can be quite useful. For - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 33
facility and the function. This is discussed on page 43. The negative key Another important key is the (-) key (shown right). If you want to calculate the value of (say) −2 − (−9) then you must use the (-) key before the 2 and the 9 rather than the subtract key. If you press the subtract key - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 34
backspace key when typing in formulas or calculations, erasing the last character typed. If you have used the left/right arrow keys to move around within a line of typing, then the DEL key will . The remaining keys of LIST, MATRIX, MEMORY , NOTEPAD and PROGRAM have special chapters of their own. 34 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 35
numeric settings work. For those upgrading from the hp 38g this is particularly important, since the behavior is significantly different. On the hp 39g+, when you set the angle measure or the numeric format in the MODES view, it applies both to the aplet and to the HOME view. However, this setting - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 36
... On the hp 39g+, if we now change to the HOME view and perform the calculation shown right, we expect that the answer should be zero, as indeed it is. However, this is only the case because the angle measures of HOME and the Function aplet agree. The problem was that on the hp 38g the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 37
. This problem has been addressed on the hp 39g+ in two ways. Firstly, the hp 39g+ has over ten times the useable memory of the hp 38g. At 232 Kb (vs. only 23 Kb), there are very few users who will come close to filling the hp 39g+. Depending on size, there is enough room for at least fifty aplets - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 38
the internet. Downloaded aplets & memory If you use teaching aplets that you download from the internet via the Connectivity Kit, or which are supplied to you by your teacher via the infra-red link on your hp 39g+, then you need to bear in mind that most of them have 'helper' programs that aid them - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 39
These games, available on the internet, are listed in the APLET view along with the normal aplets and when you delete them the associated library is automatically deleted with them, unlike the case of the 'helper' programs. Calculator Tip Because of the amount of memory available on the hp 39g+, the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 40
Most calculators opt for the easy option of switching to a decimal answer in any mixture of fractions and decimals. The makers of the hp 39g+ took to enter mixed fractions as (1+2/3). Calculator Tip You need to be careful with brackets or "order of operations" problems may occur, such as 1 2 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 41
involves the method the hp 39g+ uses when converting decimals to fractions, which is basically to generate (internally and unseen by you) a series of continued fractions which are decimal to a fraction. As was said earlier, the calculator will use the first fraction it finds in its process of - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 42
calculators but can require that you understand what is happening. It should also be clear why a special fraction button was not provided: the 'fractions' are never actually stored by the hp 39g+ it is capable of producing results which are closer to what was probably intended by the user in entering - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 43
appeared so did two labels at the bottom of the screen. If you now press the screen key under you will find that the highlighted calculation will be copied on the edit line. This is shown in the screen shot on the right. 43 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 44
the history uses memory that may be needed for other things, even with the immense amount of user memory the hp 39g+ has. ! You can calculations and results from any number of different lines in building your new expression. SHOWing results Next to the key you will see another screen key - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 45
are ways of obtaining even more memories than these 26 alphabetic ones, such as storing values into a list (see page 176), but 26 is enough for most people. Once stored into memory, a value can be used in a calculation by typing the letter into the place where you would normally use the value - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 46
accessible not only from within the HOME view but also within any other aplet also. This is shown by the screen shots below. The results shown rather than just X-2, is that using X-2 would tell the calculator to use the value currently stored in memory X, while QUOTE(X-2) tells it to use the symbol - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 47
An introduction to the MATH Menu The MATH menu holds all the functions that are not used often enough to be worth a key of their own. There is a very large supply of functions available, many of them extremely powerful, listed in their own chapter later in the book. When you press the MATH key you - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 48
or is locking up then there are a number of ways to deal with this. Calculator Tip If you are a user of external aplets then you may find that one will stop working with the message "Invalid syntax. Edit program?". There is almost certainly nothing wrong. Press , try a soft reboot as below, then run - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 49
. This should never happen but it is important to know how to deal with it in case it happened during a test or an exam. Soft reboot (Hardware) On the back of the calculator is a small hole. Poke a paper clip or a pin into this hole and press gently on the switch inside. To - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 50
the APLET view. 8. Numbers are stored in memory using the key labeled . The stored values can then be used by simply putting the letter in the expression in place of the number. 9. You can reboot the calculator if it locks up. Make sure you know how to do this in case it happens during a test - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 51
! find derivatives algebraically ! find simple integrals algebraically ! evaluate functions at particular values ! graph and evaluate algebraically expressions such as f(g(x)) or f(x+2) Choose the aplet The first step for any aplet is to choose it in the APLET LIBRARY. Press the APLET key and - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 52
know where you are (if you didn't already). Calculator Tip Pressing ENTER here would have had the same aplet you are in. Let's use that key to produce a graph of the quadratic we dealt with in the earlier section on the HOME view. Using the up/down arrows, move the cursor (if necessary) to the line - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 53
(see page 77). The PLOT view Now try pressing the PLOT key. The graph you'll see will not be a terribly useful one (see right) because axes properly for a function whose shape is not known in advance is to let the calculator suggest a suitable scale. There are a number of ways of doing this. See - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 54
to Auto Scale and press ENTER. The calculator will adjust the y axis in an attempt to fit as much of the graph on to the screen as possible. Some points y axis of the graph you've just produced, you'll see that the axis tick marks are so close together that it looks like a solid line! To tidy this - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 55
highlight should be on the first value of 'XRng:'. Enter the value -4. Calculator Tip Don't use the subtract key to input a negative. You MUST use of every dot. This is quicker but may make some graphs appear less smooth, particularly graphs with steep gradients. There are two pages to this view - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 56
is obviously a bit slower. Connect The second option Connect: controls whether the separate dots that make up a graph are connected with lines or left as dots. vs... Y and numbers) are put on the axes. The only time this causes problems is if the scale is an odd one, causing the labels to have too - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 57
dot represents a 'jump' in the scale of 0.1 when tracing graphs. The y value is determined by the graph, of course, and has nothing to do with your choice the left/right arrows move along the currently selected function. Calculator Tip Pressing SHIFT right arrow or SHIFT left arrow will jump the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 58
6 times to see a similar display to that shown right. Pressing up or down arrow moves from function to function. The order used is not related graph but solely to the order that they are defined in the SYMB view. If it is turned off then the cursor is free to move - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 59
you to move directly to a point on the graph without having to trace along the graph. It is very powerful and useful. Suppose we screen, in this case at one pixel point back from x = 4. Calculator Tip The key will also accept calculated values. You could, for example, jump to a value such as e2 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 60
four extra options which follow these are covered as part of the detailed examination of the VIEWS menu on page 92. Center This redraws the graph with proportionally the same scale for each axis but re-centered around the current position of the cursor. If you already have a 'nice' scale, this - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 61
to move the cursor to one corner of a rectangle containing the part of the graph you want to zoom into and then press ENTER, the message will change to . menu to a new Calculator Tip Zoom is very handy for allowing you to examine small sections of a graph in detail, but remember Un-Zoom! 61 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 62
access to the view shown above right. You will also see a CHK mark next to an option called Recenter. If this is CHKed then the graph will be redrawn after zooming in or out with the current position of the cursor as its center. Changing the x factor is reflected in the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 63
cursor so that it is closer to the other root than to the present one. In general that means moving it past the turning point. Calculator Tip If you are working with a function which has asymptotes then make sure the cursor is positioned on the same side of the asymptote as - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 64
on, with either the X axis, or the other function F2(X). The results of choosing F2(X) are shown right. Calculator Tip When you find an intersection or a root the value of the x coordinate is stored in the memory X. If you immediately change to the HOME view and type X and hit ENTER then you - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 65
start and end points of the area to be calculated. Definite integrals 3 Suppose we want to find the definite integral: ∫ x2 − 5x − 4 dx −2 Choose the x axis, so position the highlight as shown and press ENTER. The graphs will then reappear, with a message requesting that you choose an end point. - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 66
, the hp 39g+ will calculate the signed area and display the result at the bottom of the screen. Calculator Tip It should be clearly understand that although the label at the bottom of the screen is Area it is a little misleading. What has actually been calculated is the definite integral (right - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 67
to move the cursor. As you do the area will be shaded by the calculator. The current position is shown at the bottom of the screen. When you to find true areas rather than the 'signed areas' given by a simple definite integral then we must take into account any roots of the function. This process is - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 68
right. Press and choose Extremum from the menu. You should find that the cursor will jump to the position of the maximum. Calculator Tip If your graph has asymptotes then make sure that the cursor is positioned on the side of the asymptote containing the extremum before initiating the process - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 69
of axes This is probably the most frustrating aspect of graphical calculators for many users and there is unfortunately no simple answer. Part of the those you can PLOT and then zoom in or out. 3. If the graph is part of a test or an examination then the wording of the question will often give a clue - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 70
VIEWS and choose Decimal, or press SHIFT CLEAR in the PLOT SETUP view. This will give you the default axes, probably not showing the graph very well. ! Place the cursor so that it is in the center of the area you are most interested in. ! Use the menu to adjust - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 71
The Function aplet is capable of shown right after pressing SHOW. ( )2 Notice that the calculator is smart enough to realize in F3(X) that x −1 for the domain that F3(X) should be defined only for nonnegative x. There is a limit to this however. If you define F1(x) = x2 − x −1 and then F - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 72
shown right (note the final ',X'), then highlight it and press , the hp 39g+ will expand the brackets and gather terms. Calculator Tip These functions can all be graphed but the speed of graphing is slowed if you don't press first. The 39G+ is fast enough that the result can be lived with but - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 73
already defined in the SYMB view of the Function aplet, or entered into the brackets as above. The . This can be seen more clearly if we store a specific value into the memory X beforehand. In −1 at the value of x = 2. But what of algebraic differentiation? It is possible but not very convenient to do - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 74
see the calculator's algebraic abilities do not extend to differentiating f ( x) = 2x as f ′( x) = ln (2).2x , but at least it is numerically correct. Calculator Tip Doing your differentiation in the Function aplet is much easier and offers the additional advantage of being able to graph the two - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 75
3 on the x axis and is undefined outside this domain. In order to graph it on the hp 39g+ you have to rearrange it into two equations of F1(X)= (9-X2) for the when the calculator draws the graph it does so by 'joining the dots'. For the default scale of -6.5 to 6.5 this is not a problem since the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 76
values are 2.953846 and 3.046154. This means that the calculator can't draw anything past 2.953846 because the next value graph. Ensure the angle measure is set to Radians in the MODES view if you intend to use this scale. Calculator Tip Make sure you set angle measure after you have ed the aplet - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 77
an intersection and then return to the menu and choose Slope, the slope calculated will be for the intersection just found rather than for the nearest pixel ways to access these values. The first and simplest is via the value stored in memory X. If you move from PLOT to the HOME view and type - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 78
own values for X. Typing in the values of (for example): 3 (ENTER) -2 (ENTER) 5 (ENTER) ... will give... In this situation the function values are being calculated as you input the X values. This can be quite useful if you are wanting to evaluate the behavior of a function at selected points. ZOOM - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 79
Pressing the key pops up the menu on the right. The first option of In causes the step size to decrease from 0.1 to 0.025. This is a factor of 4 and is changeable via the NUM SETUP view. I find a zoom factor setting of 2 or 5 to be more useful. The second option of Out causes the opposite - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 80
variable" S1. As with differentiation, the results are better in the Function aplet. The ∫ symbol is obtained via the keyboard. The syntax of the integration function is: ∫ (a,b, function, X ) where: a and b are the limits of integration and function is defined in terms of X. Let's look first at - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 81
Integration: The algebraic indefinite integral Algebraic integration is also possible (for simple functions), in the following fashions: i. If done in the SYMB view of the Function aplet, then the integration must be done using the symbolic variable S1 (or S2, S3, S4 or S5). If done in this manner - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 82
potential problem lies with the second line, where limits to what the hp 39g+ can integrate. ∫ For example, if you try to evaluate sin2 x.cos x dx using the calculator, it will not be able to do it. Essentially, beyond polynomials forget it. The hp 40g Computer Algebra System Owners of the hp 40g - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 83
definite integral using PLOT variables As was discussed earlier, when you find roots, intersections, extrema or signed areas in the PLOT view, the results are stored into variables for later use. For example, if we use Root to find the x intercept of f (x) = x2 − 2 then the result is stored into - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 84
first positive intersection of the two graphs. From the shaded screenshot shown storing the result into B. We can now calculate the area in the HOME view, using f1 − f2 for the first and f2 − f1 for the second. Use to duplicate the first integral and edit it to adjust the functions and limits - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 85
Piecewise defined functions It is possible to graph piecewise defined functions using the Function aplet, although it involves literally splitting the function into pieces. x +3 For example: f (x) = x 2 − 2 3 − x ; x < −2 ; −2≤ x ≤1 ; x ≥1 To graph this we need to enter it into - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 86
other scales, basically multiples of these numbers, that also give nice values if you want to along the graph. For example, halving each of -6.5 and 6.5 will place the dots 0.05 apart. To zoom out longer 'nice' because of the 3 dots consumed by the line down the middle of the screen. 86 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 87
adding or subtracting a constant from each end of the axes will produce a graph where the y axis is not centred. Use of brackets in functions One problem commonly encountered by new users is misinterpretation of brackets. The hp 39g+ will correctly interpret F1(X) = X2(X+1) as X2*(X+1) but will not - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 88
limits In evaluating limits to infinity using substitution, problems can be encountered if values are used which are too large. For example: ex lim x→∞ 2ex + 6 It is possible to gain a good idea of the value of this limit by entering the function F1(X)=e^X/(2*e^X+6) into the Function aplet - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 89
the graph becomes horizontal. Of course this is completely the wrong value! Although this explanation may be beyond the level of many students it is quite important that they have some understanding of these ideas if they use the calculator to evaluate limits. The solution to all problems of this - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 90
the Function aplet. In the Function aplet, enter the function being studied into F1(X). To examine the gradient at x=3, store 3 entering successively smaller values for X you can now investigate the limit as h tends towards zero. To investigate the gradient at aplet downloaded from the web. 90 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 91
roots. This can be dealt with easily by storing the results to a matrix. For example, suppose we want to find the roots Matrix Catalog. and pressing . See page 170 for more detailed information on matrices. In addition to this, you can access the roots in the HOME view as shown. Calculator - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 92
differ in only small ways. However, aplets downloaded from the Internet will usually have a radically different VIEWS menus created by the person who wrote the program for the aplet. See page 214 for more information on this process if you intend to program the calculator. The VIEWS key pops up the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 93
comparison of 'before' and 'after' views. The left hand graph is always the active one, with results of actions shown on the right. We can now , or alternatively, press the key under the label. This switches the right hand graph onto the left screen. Using or the FCN menu you can then find or - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 94
from one to another. In this case, with only one, it centers the table. Let us switch now to a graph of the two functions F1( X ) = X 2 −1 & F 2( X ) = X 3 + 2X 2 Tricks - Nice Scales" immediately following the chapter on the Function aplet. Looking at the table heading you will see that it currently - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 95
point. This means that the area will not be shaded but this should not be a problem. Overlay Plot Another possibility from the VIEWS menu is Overlay Plot. This option can be used to add another graph over the top of an existing one, without the screen being blanked first as it usually - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 96
don't fit the scale then they will not benefit. As you can see in the example shown right, the quadratic shows well but the second graph (a cubic) shows only an ascending section. Zooming out would be an option at this stage, as would un- ing the quadratic in the hopes that - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 97
≤ X ≤ 65 . The usual result of this is rather horrible. The final option of Trig is designed for graphing trig functions. It sets the scale so each pixel is π 24 . This means that if you were graphing F1( X ) = 2sin(X ) then 24 presses of the left or right arrows would move you through exactly - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 98
The example below uses zoom factors of 2x2 with Recenter: ed. Calculator Tip In the graphs above the cursor is at x = π. The coordinates at the bottom of the screen should show F1(X)=0 but doesn't due to the fact that the value of π stored - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 99
idea of integration to find areas. Linear Programming This aplet visually solves linear programming problems, finding the vertices of the feasible region and the max/min of an objective function. The final stage of finding the vertices is a bit slow on an hp 39g but more acceptable on an hp 39g+. 99 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 100
following then press the button before pressing . As with the Function aplet, this aplet begins in the SYMB view by allowing you to enter functions, the X and Y. Calculator Tip The default setting for TStep is 0.1. In my experience this is too large and can result in graphs that are not - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 101
value of the parameter TStep controls the jump between successive values of T when evaluating the function for graphing. Any graph is always a series of straight lines, and making TStep too large produces a graph which is not smooth. The example on the right shows TStep = 0.5 instead of 0.05. 101 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 102
a certain point will only slow down the graphing process but not smooth the graph further. ! Since trig functions are often used in parametric equations, one should always be careful that the angle measure chosen in MODES is correct. The default for all aplets is radian measure. As usual, the NUM - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 103
& TRICKS - PARAMETRIC EQUATIONS Fun and games Apart from the normal mathematical and engineering applications of parametric equations, some interesting graphs are available through this aplet. Three quick examples are given below. Example 1 Try exploring variants of the graph of: x(t ) = 3sin 3t - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 104
Vectors The Parametric aplet can be used to visually display vector motion in one and two dimensions. Example 1 A particle P is moving in a straight line. Its velocity v (in ms plots, the speed is slow enough to show its progress. The graph makes it plain that it doubles back twice in the first two - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 105
time t, you can enter the equation F1(X)= ( X1( X ) − X 2( X ))2 + (Y1( X ) − Y 2( X ))2 into the Function aplet. Note that the active variable must be an X in the Function aplet instead of the T of the Parametric aplet. Graphing this function will allow you to find its minimum value. In this case - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 106
THE POLAR APLET This aplet is used to graph functions of the type where the radius r is a function of the angle θ (theta). As with the parametric aplet, it is very similar to the Function aplet and so the space devoted to it here is limited mainly to the way it differs. Some examples of functions - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 107
THE SEQUENCE APLET This aplet is used to deal with sequences, and indirectly series, in both nonrecursive form ( -recursive then only the U1(N) entry need be filled in, with the other two entries calculated automatically from the definition. Let's start with a non-recursive sequence of Tn = 2n - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 108
provided at the bottom of the screen when entering sequences. Two of these - and - are available as soon as the cursor moves onto the U(N) line (see right). Pressing either will enter the appropriate text into the sequence definition. The rest become visible once you have begun to enter the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 109
the button. Due to the type of problems one is usually trying to solve with sequences, the NUM view rather than the PLOT view is often more useful in this aplet, but let's have a look at the change to the PLOT view and you should see a graph similar to the one shown below right. The second type of - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 110
values of A and R in the HOME view to change the sequence. Defining a series (sum to n terms of a sequence) is fairly straightforward using a similar method you can change both U1 & U2. by simply storing new values into A and R. Solving sequence problems Questions like "What term is the first to be - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 111
type problems are can enter my formula. The two values of 5600 and 6300 are automatically calculated. All we need do now is switch to the Numeric view to find, the Solve aplet. For example if we use the Sequence aplet to define U1(N)=2^(N-1) as before, then we can change to the Solve aplet and - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 112
Modeling loans I need to see the progress of a loan of $10,000 at a compound interest of 5.5% p.a., starting Jan. 1 1995, with a quarterly repayment rate of $175. Set up U1 and U2 as shown above. You can now follow the progress of the loan, with U1 containing time and U2 the amount owing at the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 113
THE SOLVE APLET This aplet will probably rival the Function aplet as your 'most used' tool. It solves equations, finds zeros of expressions involving multiple variables, and even involving derivatives and integrals. Equations vs. expressions To ensure that we are using the same terminology, let's - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 114
Suppose you had the problem: "What acceleration is needed to increase the speed of a car from 16⋅ 67 m/s you're trying to find) and press the button. You should find that you obtain the answer to our problem of 2⋅ 47 m/s2. The INFO report When the process has finished, you can obtain a report on - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 115
the estimates it needs, I'll assume that you would find it helpful to see a graph first. It is also possible to solve this in the Function aplet, which offers more powerful tools. The PLOT view in the Solve aplet, although powerful, can be deceptive if you don't understand it and I sometimes find it - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 116
Graphing in Solve In the SYMB view, enter the equation Y=X^3-2X2-5X+2 into E1. In the NUM view, enter the known value of Y=1, ensure that the highlight is on X, making it the active variable, and then press PLOT. The PLOT view shows two curves. The horizontal line Calculator Tip The Solve aplet is - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 117
(eventually) of 2.4495. The delay is caused by the repeated integrations as the calculator searches for better solutions. Example 4 "Let X be a random UTPN (see page 282) which gives the upper-tailed probability. In the Solve aplet, set E1 to UTPN(184.5,105,X)=0.05 Enter the NUM view, make an - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 118
of PLOT in Solve The PLOT view in the Solve aplet is a little more complex than most others, since line and the reason for this lies in how Solve interprets your equation. When you select B by highlighting it, the calculator substitutes the supplied values into all other variables except B and graphs - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 119
. When you do so, the approximate value you chose with the cursor is transferred as your first 'guess'. Now press and you will see the hp 39g+ find the nearest solution to your guess. Finish by pressing to verify that the solution is valid. See page 114 regarding this. Obviously the next - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 120
point, such as that of a reciprocal graph at x = 0, but is more likely problem is that unless you check you may not realize that this is not actually a valid solution. Calculator often better to work in the Function aplet, since it allows you to see tested (and wasn't the value you wanted). 120 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 121
way!" when confronted in a test with something like: ( x −1) −1 = 2 − (3 − x) 3 94 If you're sure there is only one answer to a problem, as there is in this will give solutions of 2.56 and 1.56. In this case the problem shown will graph easily on the default PLOT view but this will not always be - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 122
so, go to the APLET view, and then the Statistics aplet. Uni vs. Bi-variate data The hp 39g+ treats univariate and bivariate data of data and obtain all the usual statistics on it, and also plot a histogram and a box & whisker graph. { 2, 3, 1, 0, -2, 3, 4, 2, 2, 0, 6, 2, 3, 1, 0, 4, 1, 3, 3, - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 123
at the bottom of the screen you will see a series of tools provided for you. is not really worth you may have forgotten to the aplet. As you can see in the screens above right, the hp 39g+ gives not only the standard statistics that any scientific calculator would give, but also the minimum - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 124
the new column as a function of the old one. Although the 'virtual' column will not be displayed in the NUM view, it can now be graphed and analyzed normally. 124 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 125
only H3 is checked. The reason for the last instruction is that only one histogram can be drawn at a is always very effective in the Statistics aplet and is recommended. If you use the and ranges are listed. I found that I could tidy this graph up a little by going into PLOT SETUP and (on the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 126
at the bottom of the screen information on which columns make up each graph if you lose track. Looking again at the screen shot of the there are three ranges. As with the Parametric and Polar aplets, XRange and YRange control how much of the graph is seen. If your histogram has frequencies of (say - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 127
graph quite easily. However, eliminating them from your graph does not eliminate them from inclusion in the calculation - 39 37 40 - 49 23 The hp 39g+ provides some limited methods to deal 50 - 59 17 with allow calculation of exact values. Attempting a normal PLOT will produce a series of - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 128
However this can be fixed by using the setting HWidth. This variable controls the width of the columns, with the initial starting value and end value set by HRng. The PLOT SETUP views shown above will produce the graph shown below. 128 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 129
is that it takes much less memory if both columns need not be stored. Simulating Dice Many of the most common experiments in probability involve the rolling of dice. This can be simulated quite easily in the Statistics aplet using the MATH menu function MAKELIST. (Covered in more detail on page - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 130
normal die. We therefore need only store the resulting list into a Statistics aplet column to analyze and graph it. This is shown in the series of screen shots to the right. To both on the keyboard. This will be a relatively slow calculation because it involves evaluating 1000 random numbers. 130 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 131
,1) C2 As an illustration, the result of this particular simulation is shown graphically on the right. Its mean turned out to be 2.067 (3 decimal be different of course after all, that's the point of using random numbers! Calculator Tip The RANDOM function is not truly 'random' any more than it is - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 132
- BIVARIATE DATA As mentioned in the Univariate section, one of the major strengths of the hp 39g+ is the tools it provides for dealing with statistical data. Unlike the others, the Statistics aplet begins in the NUM view which offers easy input and editing of values, while the SYMB view is reserved - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 133
of the screen you will see a series of tools provided for you. As before, is not worth bothering with. Calculator Tip You can enter the xi and allowing you to choose different markings for different data sets if you are graphing multiple data sets. Set your PLOT SETUP screen so that it looks like - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 134
provided for your convenience. The screen above shows the default setup when you the aplet in the APLET view. It specifies that columns C1 and C2 are paired and that a linear fit (m*X + b) is to be used when calculating a line of best fit. This was all that was required for our previous example - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 135
On the hp 39g+ the Statistics aplet is the User Defined - discussed below. Calculator Tip 1. If you want L calculated automatically, pre-store a value of zero into it. If the value is known, you can store a positive real value into memory L prior to the curve fit. 2. If you calculate a line - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 136
us to find a valid model and test its fit. If we change into SYMB SETUP view and select User Defined and then change back to SYMB view of time series data. Unlike most bivariate data, time series values are usually plotted as a line graph - i.e. as connected points. This facilitated by Connect. For - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 137
Calculator Tip If you have trouble seeing the small dots that the hp 39g+ uses in its scatter-graphs by default then you will right to go through the analysis process a second time and this time examine the line of best fit. The data is also listed in the box below. xi yi 1 2 1 3 2 2 5 7 6 6 5 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 138
key and you will obtain the results listed in the two screens shown below. Calculator Tip Make sure that your data set is defined and ed in the SYMB and ed. Showing the line of best fit If you now press the PLOT key you will see the graph shown right. If there is no line of best fit on - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 139
right which gives the equation of the line of best fit as yˆ = 0.8199x calculator thinks that you are choosing to over-ride its choice of equation with your own by editing it. As long as you press there is no problem but if you press ENTER it changes the FitType from whatever you chose to 'User - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 140
make predictions from our line of best fit in two places - the HOME view and the PLOT view. The hp 38g was able to do PREDX and PREDY use whatever was the last line of best fit calculated. It is up to you to ensure that the one you want used was the one last graphed. If I want to predict a y value - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 141
the data (discussed below). The hp 39g+ provides an alternative measure of goodness drawback to RelErr is that there is no upper limit its value of as there is for the correlation data models, including the user defined model. xi yi As you can easily see from the graph left, a linear fit is not - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 142
equation comes out as Y = 1⋅ EXP(0.693147 X ) This "EXP(" is the calculator's notation for Y = 1⋅ e0.693147X which then changes to Y = 2X . Checking to using RelErr is to graph column C1 against ln(C2) which also straightens the data. 'Linearizing' will cause problems if some of the data points - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 143
for use on the hp 39g+ relatively easily. For example, the set of data below contains a suspected outlier (erroneous value). In this case one might suspect a missing comma. {2, 3, 5, 2, 1, 5, 3, 6, 7, -2, 3, 5, 5, 55} A common test for outliers is to calculate the mean and standard deviation - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 144
and then the screen key labeled then, assuming the Statistics aplet is active, you will see the view above right. Scroll and secondly press the key in order to force a calculation of the values you want. This ensures that the ones line of best fit, since they appear in the SYMB screen - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 145
Obtaining coefficients from the fit model Coefficients can be obtained from the chosen fit model algebraically. The function PREDY from MATH gives a predicted y value using the last line of best fit that was calculated. This means that you must use the SYMB view to ensure that your set of data - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 146
should not be felt that the hp 39g+ is unusual in this interpretation. Most calculators' equivalent of the PREDX function behave in the same manner. The reason for not using the second interpretation is that the results it gives would then be incorrect. The line of best fit (unlike the correlation - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 147
Assigning rank orders to sets of data It is occasionally handy to be able to assign rank orders to a set of data. You might be running a Quiz Competition Night, or recording times for the 100 meter sprint, but in either case it is handy to be able to sort the data into descending order and assign - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 148
passes through the points (1,5), (3,15) and (-5,71). In the Statistics aplet, choose mode and enter the data. Now change to the SYMB SETUP is not good because we don't care about the graph. It only needs to be drawn in order to calculate the fit equation. Finally, change back to the SYMB - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 149
best fit is what we need and it will be calculated even if the data doesn't show. Now change to the PLOT view and press . Wait while the line draws. Change to the SYMB view, move the highlight to the equation of the regression line and press . Rounded to 4 dec. places, this gives an - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 150
THE INFERENCE APLET This aplet is a very flexible tool for users investigating inference problems. It provides critical values for hypothesis testing and confidence intervals, and does this not only quickly but in a visually helpful format. Before we look at the Inference aplet in detail I am going - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 151
, particularly in cases where working is required to be shown. For more complex problems the Inference aplet provides more powerful tools. Hypothesis test: T-Test 1-µ A company makes boxes of matches which are supposed to contain an average of 50 matches. A student has counted the contents of - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 152
aplet. In this case we are working with a single sample and we do not know the standard deviation of the underlying population, so we will use the Student-t test and the alternate hypothesis for the t values, while the lower horizontal line shows the equivalent critical sample mean range. 152 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 153
shown by a vertical line in both the upper and lower diagrams. The regions for rejection of the null hypotheses are shown at the very top of the screen by the ' R' and 'R '. We assume, by statistical theory, that the distance ( x − µ ) is normally distributed. If the null hypothesis is true then the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 154
a confidence of 95%, that the true average number of matches is between 50.16 and 52.44. Hypothesis test: T-Test µ1 -µ2 A farmer compared the 15-day mean weight of two sets of chicks, one group receiving feed A is better (µ1 > µ2 ) Enter the data into columns C1 and C2 of the Statistics aplet. 154 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 155
and this is well below the permitted test level of 1%. The PLOT view also shows that the vertical line representing the value of x1 − x2 or ∆x is well into the region of rejection indicated by the R . From the evidence we should reject the null hypothesis and accept instead that the average weight - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 156
57, 52, 69, 50, 55, 59, 68, 62, 63, 53, 56} Enter the data into column C1 of the Statistics aplet. Changing to the Inference aplet, we choose a Hypothesis test using Z-test: 1 µ, since we know the population standard deviation. The hypotheses are: H0: The sample is drawn from a population whose mean - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 157
is larger than the required test value of 0.05. In the PLOT view, we can see visually that the vertical line representing the sample mean is not within the region of rejection marked by the R. From the evidence the teacher must reject the alternate hypothesis - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 158
. If you now change to the NUM SETUP view of the Inference aplet and try to use the import facility you will find that you can into a single column stored in column C0. The program uses columns 8, 9 & 10 because there is seldom data in them. To create it, go to the Program Catalog view and press - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 159
to save space. Bear in mind that if you use this program to create a column containing hundreds or even thousands of values then the program will take a long time to complete. It might be easier to use the Statistics aplet to calculate the required mean and standard deviation in the normal way and - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 160
THE FINANCE APLET This aplet is designed to allow users to solve time-value-of-money (TVM) and amortization style problems quickly and easily, as well as ordinary compound interest problems. Compound interest problems involve bank accounts, mortgages and similar situations where "money earns money". - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 161
payments means that N is 60. The view on the right shows the problem on the calculator. The button has been pressed to give a future value FV of $1816.70. Calculator Tip As can be seen above, the designers of this aplet chose to display money to 2 decimal places and using comma separators. This - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 162
for 20 years. What income can be withdrawn? The PV for this problem is negative because, from the point of view of the engineer, the money for 20 years. On this basis the monthly annuity can be $4289.71 Loan calculations You wish to purchase a car by taking out a loan. The current interest rate - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 163
Amortization The second page of this aplet allows amortization calculations in order to determine the amounts applied towards the principal and interest in a payment or series of payments. Suppose we borrow $20,000 at an interest rate of 6.5% and make monthly payments of $300. The initial situation - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 164
the effects of only one coefficient at a time if desired. GRAPH mode The default state for the aplet is to be in mode. In this mode the student uses screen. The original y=x2 graph is kept on the screen (dotted) for comparison and a grid is supplied to allow the user to see movement more clearly. - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 165
values for the increment are 0.5, 1 and 2. Pressing SYMB on the calculator, or the screen key labeled will change the emphasis from the graph to the equation in the right hand half of the screen. Pressing larger range of values to be explored. There is a limit to how far the graph can move. 165 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 166
test mode The final key is labeled . This key will present the student with a series of graphs for which they must supply the equation. The type of graph press either or for a new graph, or to return to the main screen. If you go to HP's website you can download a worksheet for use with your - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 167
SYMB and the PLOT keys. The NUM key has no effect in this aplet and the aplet has no SETUP views. The ranges for the x and y axes are preset and cannot be changed. In both modes the original shape of the sine or cosine graph is left visible as a dotted line for comparison. 167 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 168
seen by simply experimenting. SYMB mode The underlying concept in SYMB mode is that the equation controls the graph. The user has control of the coefficients and any changes are reflected in the graph. All four coefficients are shown at the top of the screen even when one or more is redundant - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 169
. The ranges of values available for the four coefficients are shown below: Coeff. a b c d Range -3 to 3 0.2 to 5 -4π to 4π -3 to 3 If you go to HP's website you can download a worksheet for use with your class. It takes the student through the process of deducing the effects of each of the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 170
they are 'real matrices' is that the hp 39g+ is capable of storing and manipulating not only matrices of real numbers but also matrices of real vectors, complex numbers and complex vectors. The key pops up the menu shown on the right, replacing the highlighted matrix with any empty one of the new - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 171
so that it looks like the one shown right. Now press MATRIX to switch back to the MATRIX Catalog and, with the highlight on M2, press and create the matrix 2 3 −1 4 shown right. −1 7 Matrix calculations in the HOME view Switch to the HOME view and multiply M1*M2. As you - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 172
store the result into a third matrix and then to view it through the Edit screen of the MATRIX Catalog. This is shown below. Matrix system can be algebraically rearranged to: x 2 3 −1−1 −6 y = 1 −3 1 12 z 3 −1 4 13 where the inverse matrix is... 2 3 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 173
coefficients in M1. Step 3. Enter the 3x1 matrix of into M2. Note the change to in order to make entering numbers easier. Step 4. Change to the HOME view, evaluate A−1 × b using any of the following three methods (all of which are acceptable to the hp 39g+), and store the result into M3. (a) M1 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 174
matrix 2 1 4 Eg. 2 Find the inverse matrix A−1 for the matrix A = 1 1 3 −2 4 −1 The first step is to store the matrix A into M1. If you now simply store answer as a fraction 1 det ( A) multiplied by a matrix of whole numbers. If we multiply the inverse by the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 175
, when fed with vectors. The hp 39g+ writes vectors as row matrices. For example a = (3, 4) would be written as [3,4]. The calculations are shown in the two screen shots on the right. Remember to change into degree mode first. The list of matrix functions available through the MATH menu - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 176
the hp 39g+ can contain more than simply numbers. For example, the return value for some matrix functions is a list where each element is a matrix. Elements of a list can be matrices, lists and other things.. Statistical columns as lists The column variables C1,C2..C9,C0 in the Statistics aplet - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 177
to the end of a list using the CONCAT function discussed on the next page. Lists can be sent from one hp 39g+ to another using the infra-red link with the aid of the two keys labeled and . The procedure is the same as that for sending aplets from one calculator to another. 177 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 178
been downloaded onto my calculator from the HP HOME view web site (http://www.hphomeview.com) on the internet and it is now found on the APLET key. If this aplet is run, the first thing visible is the VIEWS menu. This menu is set up by the programmer to control the aplet (see "Programming the hp 39g - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 179
lot to spare. On the hp 39g+, as programmers become used to having plenty of memory to use, aplets have become larger and more powerful. Aplets may also have an attached sketch which is transmitted with it when it is downloaded. This is empty by default but programmed aplets may use it. An example - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 180
. For the hp 38g and hp 39g it is necessary to purchase a special cable to connect to the serial port on a PC and the software will work only on Windows computers. For the hp 39g+ the cable is supplied with the calculator to allow you to connect to the USB port. The hp 39g+'s software should work on - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 181
Software For the hp 38g, hp 39g & hp 40g The HP Connectivity Kit, called HPGComm, is discussed in detail on page 204. It allows users to transfer aplets and all other HP objects such as notes from calculator to PC via the serial port. It does not let you edit them in any way. However there is also a - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 182
empty. The keys at the bottom of the screen allow you to an existing Note, create a one or to and Notes to or from another hp 39g+ (or a computer). A Note is deleted using the DEL key, while the SHIFT CLEAR key will delete all Notes in the catalog. Press the key to - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 183
calculator over the infra-red link using the and keys. Corrupting notes An occasional problem users has been stored by double calculator. If you find that you have unintentionally opened a file in this way then exit from the word processor without saving. Calculator Tip Only the proper software - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 184
not meant as a criticism of the calculator. It does an extremely good job at what it was designed for - working with numbers - but it was never designed to compete with a computer drawing package. Adding text to a sketch When you first enter the Sketch page on your hp 39g+ you will see the view at - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 185
leaves the cursor free to move with no effect on the Sketch. LINE Moving the cursor to one end of a proposed line, you can now press the key and move the cursor to the other end of the line. When the line is correctly positioned, press the key (or ). BOX A box is drawn in - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 186
view. Cut and paste (sort of...) Using the key you can capture part of the screen and store it into any of ten graphics memories G1,G2..G9,G0 (called 'GROBs', which is short for graphics objects). When you press the message you see on the right will appear, asking which GROB to - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 187
will move rapidly through the sketches, animating them. If you can program then you can even automate the animation quite simply. Capturing the be automatically stored into GROB G0. Now change into the sketch view, press the VAR key, select rather than , move the highlight to Graphic and then - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 188
the whole process worthwhile. If you're intending to do this to produce a set of 'cheat notes' for your next test or exam, you would do better to spend the time studying! Calculator Tip The screen capture facility demonstrated here can be used to capture any screen as a GROB, not just a PLOT - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 189
39g+ users, or from a PC or Mac onto which they have been copied. Once aplets have been copied from the Internet (onto a PC or Mac) the software and cable provided with your hp 39g+ can be used to download the aplets to the hp 39g+. Calculator Tip Aplets which were written for the hp 38g or stored - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 190
be asked to nominate a name for the newly created aplet. It is a good idea to name it something that will remind you of its purpose and contents later. After all, you may end up saving it permanently onto a PC or Mac using the Connectivity Kit and when you look at it six months from - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 191
Statistics aplet at the same time, ready for next use. This saved aplet can now be downloaded to all the students' calculators using aplet by adding a set of instructions to the Note which is associated with the aplet. This would allow an absent student to download a copy from a friend's hp 39g - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 192
Indeed, if the students have access to the Internet and a Connectivity Kit themselves, then there is no reason that the teacher could not post the aplet on the department's web page for downloading by any students who need access. In both of these cases, the procedure has been to save a copy of one - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 193
solve problems involving the probability distributions listed earlier. Details on use Equations E1 and E2 can be used for calculations As this formula involves the integration function, each use of the solve process will require the hp 39g+ to perform multiple integrations. Because of this the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 194
compact formula COMB(N,R). Doing it this way allows the user to solve for N, whereas the second option does not Matrix Catalog view and enter the matrices shown below into M1 and M2. M 1 = 1 0 0 − 1 M 2 = 1 1 2 1 1 3 1 1 Change to the HOME view and perform the calculation - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 195
, simply return to the HOME view, the previous calculation and press ENTER. The new image will be stored into matrix M3. If you now return to the PLOT view the image will not appear to have changed as the aplet does not realize the matrix has changed but pressing PLOT again will force a re - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 196
Calculator Tip Warning: Due to a bug which existed in the hp 38g and hp 39g, this aplet cannot be sent from one hp 39g to another using the infra-red link. The formulas in the SYMB view often become corrupted during the transfer and need to be re-entered. This is not a problem matrix and only X1 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 197
security in tests and exams, the distance over which they can talk is limited to about 8-10cm. If you look at the keyboard side of the calculator, near the "hp 39g+" label above the screen, you'll find a small white triangle. This marks the position of the infra-red port so you can line them up - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 198
original hp 38g but there was no demand for it and it is no longer manufactured. The overwhelming majority of users decided that if they wanted to save an aplet then they would send it to a computer using the Connectivity Kit. When both calculators are showing the / menu and are lined up correctly - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 199
you did not line the calculators up precisely enough programs which belong to an aplet called "Coin Tossing" which can be downloaded from the web site The HP HOME view (at http://www.hphomeview.com). Normally you do not need to worry about this, since the calculator knows they belong with the aplet - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 200
://www.hphomeview.com If you own an hp 39g+ then you already have the required cable with which to download from the internet. If you own one of the earlier models then you need to invest in a Connectivity Kit to get the required cable. Downloading an aplet from the Web is very simple. Accessing - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 201
download them from the Internet more quickly, and you should de-compress them as soon as you have them onto your PC or Mac. There are many programs going to download a few aplets then organization will not be as important. If you are a teacher or if you are intending to download lots of aplets then - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 202
supplied with the cable but not for the earlier model calculators. More recent versions of the software will probably exist though. Software for the hp 38g, hp 39g & hp 40g The HP Connectivity Kit, called HPGComm, is discussed in detail on pages 204. It allows users to transfer aplets and all other - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 203
. The hp 39g+ is sold with a cable included, unlike the earlier models. This cable lets it link to the USB port on a PC or a Mac. The intention is that the software being developed should run on any platform, including Unix, and will allow the transfer of objects such as aplets, programs or notes - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 204
Some school networks lock out ports for security reasons. Discuss your problem with the network administrator. You can test whether the program is working by performing a screen capture (more on this later). Connect up the cable to the calculator, being firm but careful when plugging it into the top - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 205
you've chosen a directory you should see "This directory contains hp 39g files" (if there are files there to be downloaded). Press the OK button to select the directory. Having connected the cable to the calculator, change into the APLET view and press . This time, choose Disk drive... from the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 206
Using downloaded aplets If you press the VIEWS key on your hp 39g+ you will see a list of options which vary according to which aplet is currently active. The VIEWS menu for Function is shown right. Any aplet that has been created by a programmer, such as the Curve Areas aplet shown right, will - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 207
to delete all programs at once. The Program Catalog view has no key. If you store a large number of aplets then you may find that you start to have trouble telling what program belongs and what should be deleted. For the average user this probably will not be a problem. The naming convention - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 208
sketches via the Connectivity Kit The following information applies to the HPGComm program for the hp 38g, hp 39g or hp 40g. If you have an hp 39g+ then the software will be similar in behavior although the appearance may be significantly different (page 203). Sending aplets, programs, notes etc - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 209
calculator to continue the process. You will then see a series of messages on the computer and on the calculator telling you that files are being transmitted. At the end of the process your aplet (or program each time you save to the directory. Calculator Tip DO NOT edit, rename, or otherwise - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 210
One of the most powerful abilities of the Connectivity Kit is its ability to capture images of the calculator screen. These images can be pasted into a document or into a Paint program for further processing. This allows teachers to create worksheets that include images of what the student should - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 211
. Editing Notes with the Aplet Development Kit Free software is available to let you edit Notes and aplets on a Windows computer from any of the hp 38g, hp 39g, hp 40g or hp 39g+. This software is called the Aplet Development Kit (ADK) and it is also used to create and program aplets. Here we will - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 212
Although you can choose to simply create programs which are self sufficient the whole point of working on the hp 39g+ is to use aplets. Hence this chapter will concentrate on the process of creating aplets with enhanced powers provided by attached 'helper' programs. The key to the entire process of - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 213
process far easier. To use the ADK you must have the Connectivity Kit and for models before the hp 39g+ this means buying a cable. We will begin by assuming that you have only the calculator and create our first two aplets entirely on the hp 39g+. We will then look at two more examples using the ADK - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 214
last option of 'Graphs...' runs a program which pops up another menu, shown right. The reason for this method is generally simply to avoid overcrowding the main menu. Another example of an aplet is shown right. It is called "Tangent Lines" and it draws a tangent line onto a graph and then lets you - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 215
where NAME is whatever name you chose at design stage. When you run this program it severs the aplet's link to the normal VIEWS menu inherited from its parent and replaces it with the new options. Calculator Tip If an aplet is created using the ADK then it may not have this .NAME.SV - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 216
it tells the calculator which programs are to be transmitted with the aplet when it is copied via cable or infra-red link. Only those programs named in the SETVIEWS command (or linked by the ADK) will be transmitted. Special entries in the SETVIEWS command In addition to the lines which form the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 217
VIEWS menu and include instructions in a separate file. Example aplet #1 This example will use the SETVIEWS command to design a very simple (and totally useless) aplet, which will illustrate a few of the concepts useful in programming the hp 39g+. We'll call it the 'Message' aplet and create it as - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 218
command asks the user for info, displaying a title, prompt and tip and having a default value of 20. .MSG.FN .MSG.S The command GROB in the program left, stands for "Graphic Object" and creates a GROB from the F1(X) expression stored in the SYMB view, storing it in the graphic memory G1, using - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 219
to run it. If you get an error message at any time then you may have to and the program. When you do this, the aplet will run the program .MSG.S which will display a MSGBOX. The line in the SETVIEWS command controlling this was: "Start";".MSG.S";7; Since the triple ends with a view number of - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 220
're told.";20: Examine the snapshot on the right and notice the connection between the various parts of the INPUT statement and their effect. Note .IN a line of ERASE: , which is a command to erase the display screen. Try editing the program, inserting this line before the MSGBOX line, and running - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 221
1: in order to it or it would not graph. You may wish to edit the .MSG.SV and.MSG.FN program to try this. The next lines display the expression using the four options available. The line: GROB G1;F1(QUOTE(X));0: converts the expression F1(X) into a Graphic Object (GROB). The number at the end - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 222
for use. Finally it loads the initial values into the matrices. This program changes the value of Xmin and then changes it back. In the original version the user had to press PLOT to force a re-draw. This technique fools the hp 39g+ into thinking that the PLOT view has changed and therefore forces - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 223
ensure it is 2x2, with the DO...UNTIL loop ensuring that the user cannot exit without a valid matrix entered. Assuming that you have the .TRANSF.SV program to create the new altered VIEWS menu then you can now test the aplet. Its operation should be familiar to you if you have already examined - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 224
the ADK - one for the hp 38g and one for the hp 39g, hp 40g and hp 39g+. Aplets created by one version are not compatible with the other version's calculators. Look for the ADK on The HP HOME view (at http://www.hphomeview.com). Example aplet #3 Run the Aplet Development Kit and use the File - New - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 225
prompt to "Change matrix", the Object name to ".TRANSF.MAT" and the Next View to "7: Views". In the main window, enter the code for this program (see Example PLOT SETUP view. Secondly, the program we used before to contain the SETVIEWS command is not required for aplets created by the ADK. When you - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 226
on the "Add - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 227
should have a Prompt of 'Plot axes', an Object Name of '.LINEXPL.AX' and a Next View of 1 (Plot view). The full code for each of the programs is given on the next page, and other settings are shown below and right. 227 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 228
- Aplet library facility to create the two special files for the directory which allow the calculator to download it. Finally, download it to the calculator and test it. Choose the first option on the VIEWS menu to plot the axes and then the 'Explore' option to explore the equation of a line. On - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 229
view. Users have a habit of changing things so try to allow for this in your programs. The next program below illustrates a very important technique where a copy of the PLOT view is stored in the aplet's sketch view and then retrieved and modified using the various graphics commands. The program is - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 230
you run the program and then later change to the SKETCH view you will be able to see this stored image. Finally, the user is presented with two messages which tell them what to do. The next section begins the code which performs the work in the aplet. The first line assigns initial values to - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 231
of the screen will be ignored. Finally the line itself is drawn. Even though part of the line extends off the screen there is no problem - the excess is clipped. The next section of code below waits until the user presses a key (GETKEY) and stores the key's code into the variable K. A CASE statement - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 232
telling them about this. Finally, add a line to display the current increment size at the top right of the screen using the DISPXY command. The explanation so far should help you in understanding the programming process on the hp 39g+. The aplet structure is well designed and, if you take advantage - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 233
so, consult the manual. The Aplet commands These control aspects of the aplet. CHECK n, UNCHECK program will normally be called by the active aplet anyway. I have only used it with 'stand-alone' programs not attached to an aplet so that they can temporarily 'borrow' abilities belonging to an aplet - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 234
going wrong which would normally crash the program, such as evaluating a function at a point for which it is undefined. By trapping the suspect code you can supply an alternative which will perform some other action. This will tend to make your programs more user friendly and is a very good idea - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 235
code in a separate program and calling it from different locations. See the SETVIEWS command for information on how to link a program to an aplet when it does not This command is VERY slow. BOX ;;; This draws a rectangular box on the screen using (x1,y1) and (x2,y2) as the corners. - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 236
FREEZE This command halts execution until the user presses any key. LINE ;;; This draws a line on the screen using (x1,y1) LINE except that the line drawn reverses the current set/unset value of all pixels. It can be used to erase previously drawn lines. One of the aplets on The HP - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 237
"Programming the hp 39g+" on page 226 for examples illustrating some of the graphics commands user friendly you could let the user know what they had done wrong by adding another few lines of code within the DO loop of.. IF INT(N) N OR N 0 THEN MSGBOX "Enter a positive integer only": END: WHILE - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 238
command in the language. The Matrix commands EDITMAT This command pops up a window in which the user can edit or input a matrix with an key at the bottom. When the user presses , execution resumes after the EDITMAT statement. REDIM ; This command is very - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 239
HP infra-red thermal printer that is designed for use with the hp 38g, hp 39g, hp 40g and hp 39g+. PRDISPLAY If you place this command in a program images of graphs without need for programming as follows: ! set up the graph or image as required ! press ON+PLOT to capture the image and store it in - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 240
accurate, varying by up to 5% from one calculator to the next and depending also on the /sec. We can use this to form a standard 'header' for any program we want to use to play music. The header shown right in the of the menu option highlighted when the user presses is returned in the variable. - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 241
the font specified. An extensive example can be found in the chapter "Programming the hp 39g+" on page 226. DISPTIME This command pops up a box displaying the calculator's internal time and date. These can be set by storing values to the variables Time and Date. Suppose the current time is 3:46 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 242
to be whatever the user last input then use INPUT N;........;N instead. If you do this then you will need to store and initial reasonable value This command pauses execution for the specified number of seconds. Calculator Tip This list does not cover anywhere near the full programming the hp 39g+. 242 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 243
Stat-Two Symbolic Tests Trig Calculus Complex Constants Hyperb. List Loop Matrix Polynom. Prob. - rounding, roots, conversions and % functions. - bivariate functions. - functions for manipulating equations and symbols. - used in programming more than normal work. - sec, cosec etc. - integration and - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 244
((X+2)^5-(3X-1)^2,X) (using Xy key to get ^) and then press the ENTER key. You will find that the expression (x + 2)5 − (3x −1)2 has been expanded on the following line to X^5+10*X^4+40*X^3+71*...etc There are two ways of seeing the complete result. You can move the highlight up to that - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 245
hp 39g+. If you need the higher level commands then consult the manual. a limit to how much this HELPWITH statement will aid a normal user of the calculator, the contents of memories. Suppose you have stored 10 in memory A and 15 in , which shows the 'Program Constants'. You can try it if - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 246
as the mathematical function 'greatest integer' which is studied in many mathematical courses. If you want to graph the greatest integer function then you will need to use the PLOT SETUP view to turn off CONNECT first, since the graph is supposed to be a discontinuous step function. The result with - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 247
you feed it an algebraic expression and an initial guess it will start from your guess and find the value which makes the expression zero. Don't bother. It's a lot easier to use the Solve aplet. This is a tool for programmers so that they can access the Solve abilities within programs. You need to - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 248
) This function works with time and angles. It converts degrees, minutes and seconds to degrees, and also hours, minutes and seconds to decimal time. The calculator can convert a value such as 45"23′17′′ if you put it into the form 45.2317 and then use the HMS function. Eg. sin - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 249
See also: XPON MAX(num1,num2) This function returns the larger of two values entered. This is not needed in your normal calculations, since you could just look at the numbers, but a programmer will be writing a program which deals with numbers not known in advance. Eg. MAX(3,5) = 5 See also: MIN 249 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 250
function gives you the remainder when one number is divided by another. It is considered to be an mathematical operator in the same way that a plus, minus, times or divide sign is. Because of this it does not need its arguments placed in brackets as most of the other functions in - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 251
from X to Y using the formula 100(Y-X)/X. It can be used to calculate (for example) percentage profit and loss. Eg. I buy a fridge TOTAL(Y,X). Note the reversed order. Eg. What percentage is a score of 53 out of 81 on a test? Use: %TOTAL(81,53) What percentage is 124 of 112? Use: % TOTAL(112,124) See - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 252
ROUND(num,dec.pts) This function rounds off a supplied number to the specified number of decimal places (d.p.). Eg. Round 66.65 to 1 d.p. Use: ROUND(66.65,1)=66.7 Round 34.56784 to 2 d.p. Use: ROUND(34.56784,2)=34.57 This function is also capable of rounding off to a specified number of significant - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 253
(0.0005087) = -4 This function could be of use to you if you are just learning scientific notation, but is of more use to people writing programs. A normal user would just look at the number and see the answer, but a programmer would not know in advance what number was going to be used and - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 254
in the Statistics aplet. This is discussed in more detail in the section covering the Statistics aplet, but a graphed in the PLOT view and that the FIT screen key has been used to plot the line value for the x (indep.) value of 3⋅5. Calculator Tip The line of best fit used in the function PREDY is - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 255
really. Except in programming, the = sign is simply used in exactly the way that you would expect it to be, mainly in the Solve aplet. It's easier to: X = −3 + A . B The ISOLATE function is very useful within its limitations, but it will not deal with a lot of formulae. See right: See also: The - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 256
aimed more at the programmer than at the normal user. It is designed to test whether a supplied expression is linear or non-linear is going to be when a programmer does not know in advance what function the user is going to type in. QUAD(expression,var.name) This function uses the quadratic - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 257
storing a function into an aplet in a program is to enclose it in single quotes. For example '(X)2-4' F1(X) would serve the same purpose as QUOTE(X)2-4 F1(X). On the other hand, entering F1('X') will not work but F1(QUOTE(X)) will. See Example 1 on page 217 in the chapter "Programming on the hp 39g - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 258
expression. Any not supplied will be evaluated using the value currently stored in that memory. This is again a function which is of more use to programmers since this is probably more flexibly handled in the Solve aplet. Eg. 1 Evaluate a = b + c where b = 6, c = -2 and d - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 259
not cover them here. An introduction to programming on the hp 39g+ is covered in an earlier chapter (see page 212) but those wanting more detail than is given there must consult the manual. If you want more information then download aplets from the internet and dismantle them. The 'Trigonometric - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 260
is paramount. These are: EXP(num) This function gives a more accurate answer than the key labeled e^ which appears above the LN key on the calculator. As you can see on the right, the difference is normally not detectable even to 12 significant figures. The difference is only apparent for some - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 261
function LNP1 ("ln plus 1"). By finding the natural log of x +1 rather than of x , the function becomes able to do its calculations in a domain detail in the chapter dealing with the Function aplet (see pages 65 to 83). The functions are the integrate, or function, the differentiate, or function, - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 262
hp 39g+ can be entered in either of two ways. Firstly, in the same way as they are commonly written in mathematical workings: a + bi. Secondly, as an ordered pair: (a,b). For example, 3 + 2i could be entered into the calculator numbers can be stored into the alphabetic memories A to Z, there are 10 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 263
a unit vector in the direction of (a, b). i.e. SIGN((A,B)) returns a , b a2 + b2 a2 + b2 This is very useful, not just in complex numbers, but also in vector problems. See also: SIGN (in the Real group),IM,RE,ARG,CONJ 263 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 264
( ) can be found on the keyboard as the SHIFT function for 'subtract'. If you enter a complex number in (r, ) form as shown right, then the calculator will display it in the form r cos(θ ) + r sin(θ ) from, and as an (a,b) ordered pair. Note the r cos(θ ) + r sin(θ ) form is used only when in - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 265
limits (see page 88). They consist, respectively, of the largest and smallest numbers with which the calculator is capable of dealing, and are there for use by programmers as a check to ensure that calculations within a program the end of list L1, storing the resulting longer list back into L1. 265 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 266
of your choice. It is very useful, not only in programming but in statistical simulations and modeling. The syntax is: MAKELIST( { 1, 9, 25, 49, 81 } as X goes from 1 to 3 to 5 to ... and also stores the result into L1. Eg. 2 MAKELIST(RANDOM,X,1,10,1) produces a set of 10 random numbers. The X in - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 267
, suppose we wish to simulate 10 Bernoulli trials with p = 0.75. We can use the fact that a test like (X0.2) returns a value of either 1 (if the test is true) or 0 (if the test is false). Thus: MAKELIST(RANDOM - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 268
returns the size of the list or matrix specified. Since normal users would probably know anyway, and could find out easily via the list catalog, this is clearly another of those functions which are of more use to programmers (who won't know when they write their program just how long the list you - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 269
The 'Loop' group of functions This is an interesting group of functions that may be of use for students studying discrete functions and sequences. ITERATE(expression,var.name,strt,num.iter.) This function evaluates an expression a specified number of times, starting with a supplied initial value - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 270
produce the result shown right in the SYMB view of the Sequence aplet. The resulting sequence is the factorial numbers. The syntax is: function, also available on the keyboard, offers a way of calculating the results of summation notation problems. The syntax of the function is ordered in the same - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 271
of examples for the more commonly used functions is given in the chapter titled "Using Matrices on the hp 39g+". See page 170. COLNORM See User's manual COND See User's manual CROSS([vector],[vector]) This function finds the cross product of two vectors. Vectors for this function are written - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 272
a = (3, 4) or 3 4 would be written as [3,4]. See page 175 for a worked example. EIGENVAL See User's manual EIGENVV See User's manual IDENTMAT(size) This function creates an n x n square matrix which is an identity matrix. For example, IDENTMAT(4) would produce a 4x4 identity - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 273
. An error message is given (see right) when the matrix is singular (det. zero). Note: Some people write the inverse matrix as a fraction (one over the determinant) multiplied by a matrix, so as to avoid decimals and fractions within the inverse matrix. The hp 39g+ does not do this. If you want the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 274
User's manual See User's manual MAKEMAT See User's manual QR See User's manual RANK See User's manual ROWNORM See User's manual RREF(matrix) This function takes an augmented matrix the augmented matrix 1 −2 3 14 2 1 −1 −3 4 −2 2 14 which is then stored as a 3x4 real matrix M1. We - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 275
solve this in the same way as before, the matrix which results is: The final line of 0 0 0 1 indicates no solution. See also: INVERSE, DET SCHUR See User's manual SIZE See User's manual SPECNORM See User's manual SPECRAD See User's manual SVD See User's manual SVL See User's manual 275 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 276
TRACE See User's manual TRN(matrix) This function returns the transpose of an n x m matrix. 2 3 For example, if M1 = 1 0 −2 4 then TRN(M1) would return 2 3 1 −2 0 4 . 276 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 277
12 at x = 3. Note: If evaluating more than one point it is probably more efficient to enter the function into the SYMB view of the Function aplet. Then either use the NUM view to find the function values required, or simply type F1(3), F1(-2) etc. in the HOME view. 277 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 278
This is a very powerful polynomial function. It allows algebraic manipulation and expansion of an expression into a polynomial evaluated expression that was the result of the previous POLYFORM. Copy it into the edit line and add a comma, a B and an end bracket. Pressing ENTER will now evaluate - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 279
POLYROOT([coeff1,coeff2,...]) This function returns the roots of the polynomial whose coefficients are specified. The coefficients must be input as a vector in square brackets. Eg. Using our earlier function of f (x) = (x − 2)(x + 3)(x −1) = x3 − 7x + 6 we can enter the coefficients as [1,0,-7,6]. - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 280
of 5 people from a pool of 6 men and 5 women. 65 p = 2 3 = 0.3247 11 5 Note: The reason for the single 'COMB(6,2)' above the main calculation is to save time. Rather than using the MATH menu for every entry of the COMB function, you can enter it once - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 281
supplies a random 12 digit number between zero and one. If you want a series of random numbers, just keep pressing ENTER after the first one. Eg. Produce hp 39g+'s will produce exactly the same sequence of "random" numbers! This can be a problem in that, for example, a class set of calculators - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 282
a standard deviation of 14%. What two scores will cut off the top and bottom 10% of students? i.e. Find x0 such that P(x > x0 ) = 0 ⋅1 Using the Solve aplet (right) we can reverse the normal direction of the UTPN function. Enter the expression to be solved for into the SYMB view as shown above - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 283
Calculator Tip The normal order for the arguments in the UTPN function is UTPN(mean,variance,value), giving the upper-tailed probability. However, many textbooks work - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 284
the calculator can be used to help solve some typical problems. In some cases more than one method is shown. Sometimes these problems are then copy just the decimal part and square it. Method 2 - Using the Function aplet. Shown right. Enter the function into the SYMB view, use the VIEWS key and - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 285
a method of copying the results to a matrix so as to gain easier access to them. store the results to a matrix. This offers the advantage of being able to examine the result more easily by ing the matrix, and also of being able to access each root by referring to the matrix elements in a calculation - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 286
the intercepts. (ii) find the turning points. (iii) draw a sketch graph showing this information. (iv) find the area under the curve between the two turning points. Step 1. Enter the function into the SYMB view of the Function aplet, so it is available for plotting. Step 2. Use the POLYROOT - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 287
menu again, retrieving this time from the VAR menu the variable called 'Root' and perhaps storing that into memory C. We will evaluate the integral in the HOME view where you can use the accurate values you stored in Step 4. It needs to be done in two parts and added (subtracted actually to - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 288
) 2x − y = 4 −3x + 2 y − z = −10.5 x − 3y + z = 10.5 Method 1 - Graphing the lines Because the first set of equations is a 2x2 system it can be graphed in the Function aplet. To do this it is necessary to re-arrange the functions into the form y = ...... and store them into F1(X) and F2(X) in - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 289
Change into the HOME view and enter the calculation M1-1*M2. The result is the (x,y) coordinate of the solution. A similar method can be used to solve the second 3x3 system of equations. Third method - using the 3x3 Solver aplet This method uses an aplet which is available from the internet called - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 290
Expanding polynomials Expand the expressions below. (i) (2x + 3)4 (ii) (3a − 2b)5 (i) Use POLYFORM((2X+3)^4,X) to expand the polynomial. Use the key to examine the result. Result: 16x4 + 96x3 + 216x2 + 216x + 81 (ii) Use POLYFORM((3A-2B)^5,B) to expand the polynomial as a function of B. Then use - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 291
and it will be calculated even if the data doesn't show.) YTick is set to 1000 incidentally. Now change to the PLOT view and press (if not already set). Wait while the line draws. Step 3. Change to the SYMB view, move the highlight to the equation of the regression line and press . Rounded - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 292
. Step 1. Find the values of N0 and k and store N0 into memory A and k into memory K, so that it is un-necessary to re-type them. See page 145 for instructions on finding the parameters from the exponential fit curve. Step 2. Switch to the Solve aplet and enter the equation to be solved. Changing - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 293
the values of A and B into M1 and M2 respectively. Finally use the HOME view to calculate the answer, using the function IDENMAT(2) to produce a 2x2 identity matrix, and making sure to store the result into M3. In this case the result is a horrible decimal. The fractional equivalent can be found - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 294
user to deal with matrices which are singular. (a) Entering the augmented matrix of coefficients into M1 (see above) we then use the RREF function, storing augmented matrix in M1 and then re-use the line in the HOME view. In this case the final line of zeros indicates that the original matrix is - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 295
second POLYROOT calculation in the screen shot right. In this case the results are unlikely to be integers so we store them into M1. The result is shown below and right. The edit line shows the highlighted element to a greater degree of accuracy. Unfortunately there is no way on the hp 39g+ to get - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 296
appear on the screen will show visibly that they do not collide. The graph is shown on the right just before closest approach. However we need + ( y1 − y2 )2 and this can now be entered into the Function aplet as shown right. With an equation this complex it is probably worth checking with the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 297
the first 6 seconds of movement. Show algebraically that its path is circular. The first step is to graph the particle's path. We go into the Parametric aplet and enter the rule into the first diagram onto our test paper as the required graph. Note the gap at the bottom because the TRng stops at 6 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 298
Function aplet and enter the formula for the required dot product as X2(X)*X3(X)+Y2(X)*Y3(X). If we now switch to the NUM view, we can see that this function is evaluating to zero for t = 0, 1, 2, 3.... Of course this is not the same as a proper algebraic proof but you wouldn't want the calculator - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 299
problem solving test is independent of the students' year at school. The teacher selected 120 students, 40 from each of Years 8, 9 & 10, and graded their performance in a test and C2 of the Statistics aplet. In the HOME view, perform the calculation shown right. This calculates the individual χ 2 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 300
Changing into the Solve aplet we can enter a formula which will allow us to calculate values from the Chi2 distribution using the UTPC function. With a 3 x 2 contingency table the the required critical value is 5.99 and so we would accept the null hypothesis and conclude no relationship. 300 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 301
hp 39g+ graphical calculator. Some of them are listed below: Investigating y = xn for n an integer This can be done most economically by setting an investigation, perhaps for homework. Save a copy of the Function aplet (iv) What do the graphs of y = xn look like for negative integer values of n? 301 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 302
algebraically but what then about the point X=2 in the NUM view (see right)? Use this in discussion to introduce the convention of graphing - a good way to introduce the idea of limits! However - there is a trick to this and so, since it is undefined, the calculator leaves it out. For this to work - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 303
is best introduced using an aplet called "Chords" downloaded from The HP HOME View web site (at http://www.hphomeview.com), but you can also use the Function aplet. In the Function aplet, enter the function being studied into F1(X). To examine the gradient at x=3, store 3 into A in the HOME view - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 304
step is to develop the idea of a gradient function. This can be done using an aplet downloaded from The HP HOME View web site called "Tangent Lines". This aplet will add a moveable tangent line to a graph, allowing the user to move it along the curve with the gradient displayed at the top left of - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 305
The Chain Rule If desirable, an aplet is available from The HP HOME View web site (at http://www.hphomeview.com , choosing for themselves what size square to cut out. They can then explore, using the Function aplet, what cut-out size will produce the maximum volume. As can be seen above right, the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 306
a family of curves. An aplet from The HP HOME View web site (at http://www.hphomeview.com), called "Slope Fields", will assist with this process. In this aplet the user enters the derivative function into F1 by a constant, which all fit the 'description' of the function stored in F1(X). 306 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 307
Parametric aplet can be used to produce motion graphs of the form shown right. The graph needs to be seen as it is being drawn to appreciate how the particle slows down and speeds up as it passes the turning points. Try it and see. Limits For information on evaluation of limits on the hp 39g+ and - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 308
the function to become undefined and consequently not be graphed. Inside the domain it has no effect. Note: The word 'AND' is available from the keyboard above the (-) sign. Sequences and Series Through the Sequence aplet the hp 39g+ provides very flexible tools for the investigation of sequences - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 309
problem is that students will misinterpret it as being N=10, when in fact it is simply that the calculator hp 39g+. Both of these aplets allow the student to explore the effect of changing parameters on the shape of the graph on the graph. In Quad Explorer there is even a "test yourself" facility - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 310
hp.com/calculators) or on the Help page of The HP HOME view (http://www.hphomeview.com). What is a CAS? Although you may not have thought about it consciously, you are probably aware that most calculators do not operate with algebra can watch the calculator work. In the Solve aplet, enter the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 311
obtain this exact answer because the calculator doesn't use algebra. However, the CAS or Computer Algebra System on the hp 40g does use algebra! As you can see in the screen shots to the right, the CAS on the hp 40g is perfectly capable of giving you the algebraically correct answer, and it does it - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 312
below the screen. The calculator's chip is able to detect which model it is in and activate or de-activate the CAS accordingly. The hp 39g+, released in 2004, is an upgraded model of the hp 39g, the differences being vastly greater speed and the extra Finance aplet. If you own an hp 39g and you are - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 313
Using the CAS The first step is to activate the CAS. This is done from the HOME view by pressing screen key 6 (SK6), labeled . When you do, you will see an empty screen with a cursor in the center and an extensive menu system at the bottom of the screen. From the HOME screen, pressing SHIFT - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 314
(iii) Press left arrow once then down arrow once. Press Xy 3, then press up arrow three times & finally press Xy 2. (DO NOT use the X2 button for this.) Notice that in each case the power was applied to the currently highlighted element of the expression. Brackets are automatically added as - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 315
't press the HOME button as the CAS has its own HOME view which behaves differently and is covered on page 317. Note: There can be a problem with the way that the X2 button is handled. Try going back through the same exercise but pressing the X2 button at step 3. You will - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 316
then you can highlight and edit an expression 'in-line' as if you were entering it in the calculator's normal HOME view. For example, highlight part of 5S node E, deleting first the node's contents then the operation (multiply) which connected it to the tree. Try it and see. P C ^ 81 This - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 317
HOME History. If you press HOME while in the CAS then you will see something similar to the view on the right, with all previous calculations and results recorded. As with the normal History it is worth deleting the contents regularly by pressing memory is not to be gradually used up - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 318
into the Function aplet. This can be done by using to retrieve the expression, enclosing it in single quotes from the CHARS view and then storing it ( ) into F1(X) or whichever is desired. The reverse process is also possible using PUSH but it is more limited in that - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 319
As mentioned above, one method of transferring CAS results to a normal aplet such as Function is to use the POP command. However, for graphing results, there is an even easier method - simply press PLOT. Suppose that we have a result in the CAS editor as shown right. Pressing the PLOT - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 320
cause it to be algebraically evaluated and any functions to integral (see page 81 and the page following). A better alternative is to use the INTVX function as shown below, even though it still does not add the '+c'. See the page after this for information on using functions in the CAS. Calculator - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 321
. These functions will only be available on the hp 40g, not on the hp 39g+. There are two ways that functions can be expression that has resulted from a previous calculation. E.g. 1 Using LIMIT Find lim x2 − 2x − 35 . x→7 x − 7 The sequence of keys for this is... scroll to LIMIT ENTER XTθ X2 - 2 XTθ - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 322
The sequence of keys for this is... (i) Expansion... 2 XTθ + 3 XTθ - 35 ▲ ▲ Xy 4 ▲ ▲ ENTER (ii) Examination... ON (iii) Retrieving... HOME Any recorded previous calculation or result can be retrieved in this way, just as it can in the normal HOME history. (iv) Factorization... While the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 323
(Y=-1) LINSOLVE can be used for any number of simultaneous variables. Step by step mode will show the solution process using row manipulation of an augmented matrix. 323 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 324
The LINSOLVE function can also be used to solve problems of the form below. Solve the system of equations: The command is LINSOLVE( 2.X+K.Y-1 AND (Q+3).X-Y-5, X AND Y) and it produces the results shown. 324 - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 325
in terms of a and b. As can be seen above, the initial integration gives an equation involving a fraction. This can be simplified by multiplying both . Notice that when the final simplification is equal to zero, the calculator does not bother to include the '=0'. The second probability tells us - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 326
We can now use the LINSOLVE function to find A and B. While the second linear equation is still highlighted, fetch the LINSOLVE command from the menu. Then press left arrow once and up arrow twice to highlight the linear expression again as shown right. Now, while the entire expression is - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 327
E.g. 6 Defining a user function The DEF function allows you to define your own functions, f ( K ) = 22K +1. You can now call this function by simply typing, for example, F(5). We can now test to see if this is a prime number by using the ISPRIME? function from the MATH menu. This is found in the - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 328
One of the most helpful features of the hp 40g CAS is the on-line help provided by the SYNTAX button (SHIFT 2). Pressing SYNTAX will display the menu shown to the right. You can use the up or down arrow - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 329
method is via the configuration line (CFG) at the top of each menu. The line shown right of CFG R= X S means that the calculator is set to exact-real mode Below the title bar you can see the first section of a series of alternatives which let you manipulate the configuration. Most alternatives are - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 330
it is suggested that you read carefully the relevant information in the manual and/or the information in Renée de Graeve's book mentioned in 1) In CAS, angles are always expressed in radians. When you are the calculator HOME screen, you can use the MODES view to change this default but this - HP 40g | hp 39g+ (39g & 40g)_mastering the hp 39g+_English_E_F2224-90010.pdf - Page 331
imaginary value - the root of x2+1=0. 5) Although you can use the integration symbol provided on the keyboard it has disadvantages outlined on page 82. Use twice will give +∞. These are often needed for use in the LIMITS function. For example, evaluating LIMIT( x + x + x − x ,+∞) will give ½ (
hp
39g+ graphing calculator
Mastering the hp 39g+
A guide for teachers, students and other
users of the hp 39g+, hp 39g & hp 40g
Edition 1.1
HP part number F2224-90010
Printed Date: 2005/10/11