Docsity

HP 50g Solving differential equations, Lecture notes of Differential Equations

Partial preview of the text

Download HP 50g Solving differential equations and more Lecture notes Differential Equations in PDF only on Docsity!

HP 50g Solving differential equations The menu SYMBOLIC SOLVE How differential equations can be displayed The commands for symbolic solutions The built-in form for numeric solutions Practice solving differential equations

HP 50g Solving differential equations The menu SYMBOLIC SOLVE The menu SYMBOLIC SOLVE menu is t he WHITE shifted function of the 7 key. This menu contains commands for symbolically solving a great variety of problems. Two of these commands, DESOLVE and LDEC are for symbolically solving differential equations. To access the menu you press !Î. Figure 1 How differential equations can be displayed On the HP50g differential equations can be denoted in two different ways. The first is to use some of the built-in differentiation commands. For example the differential equation: can be denoted as: or or (if the current variable VX is X) The second way to denote differential equations is to use the formal derivatives of the HP50g. Formal derivatives are written starting with the letter "d", then a number that indicates the position of the independent variable in the unknown formal function, then the unknown formal function followed by its arguments in parentheses. For example the above differential equation could be also written as: where d1Y(X) means the derivative for the first variable (i.e. X) of Y(X). According to this rule of syntax the differential equation: can be written as: or

HP 50g Solving differential equations Figure 3 The input field f: is where we enter the right hand side of the differential equation of the form Y'(t)=F(T,Y). The input field Indep: is for specifying the independent variable of the differential equation. In the same row, Init: takes the initial value and Final: the final value of the independent variable of differential equation. The field Soln: is for entering the dependent variable. Init: takes the initial value of the dependent variable. Final: is the field where the numeric solution is put when the HP50g solves the problem. The field Tol: is for specifying the maximum tolerance for the answer, Step: is for the maximum step size of the calculation. (The solution is calculated stepwise according to the Runge-Kutta-Fehlberg method.) The option _Stiff is for specifying that the problem is "stiff", which causes the HP50g to use a special method suitable for such problems. The menu key %EDIT% is for editing the data of an input field. CHOOS allows selecting between several alternatives. INIT+ replaces the current initial values by the current final values. And finally SOLVE returns the solution for the differential equation. The next few examples barely begin to explore differential equations on the 50g. Practice solving differential equations Example 1: The differential equation of the concentration c(t) of a chemical substance that undergoes decay in a first order reaction is given by: Find c(t) if the initial concentration is c(0). Solution: Assume algebraic mode and CHOOSE boxes. Press !Î Figure 4 Choose DESOLVE and enter the differential equation. %%OK%% @¿~~!t!Üc!Ü!t™™@Å-!k*c! Ü!t™@íc!Ü!tFigure 5 Notice that the variable VX was changed to t (upper edge of the screen). Extract the solution from the list. !°6``7!î`

HP 50g Solving differential equations Figure 6 Substitute t=0 in the above solution. !î@¦!Ü~!t@Å0Figure 7 Solve for the integration constant cC0. !Î6!î@í~~!cc0Figure 8 …×2!î(expand) Figure 9 Substitute the constant cC0 in the general solution. The general solution of the differential equation is the fourth most recent answer of the HP50g. Use ANS(4) to refer to it. …×8!4™@í!î` Figure 10

HP 50g Solving differential equations Figure 14 Enter the independent variable. ™³~!tFigure 15 Enter the final value of the independent variable. ™1 Figure 16 Enter the dependent variable. ³~!v` Figure 17 Solve for the final value of the dependent variable. ™SOLVE Figure 18

HP 50g Solving differential equations View the solution %EDIT% Figure 19 CANCL to finish viewing. Use the final values as new initial values. INIT+ Figure 20 Enter the new final value for t and solve again. —2™™ SOLVE Figure 21 Repeat the process for t=3s. INIT+ —3™™ SOLVE: Figure 22 Repeat the process for t=5s. INIT+ —5`™™SOLVE