Higher Mathematics for Engineers and Scientists I
Higher Mathematics for Engineers and Scientists I MATH 3350
Popular in Course
Popular in Mathematics (M)
This 3 page Class Notes was uploaded by Ms. Ally Koelpin on Thursday October 22, 2015. The Class Notes belongs to MATH 3350 at Texas Tech University taught by Kevin Richard Long in Fall. Since its upload, it has received 23 views. For similar materials see /class/226463/math-3350-texas-tech-university in Mathematics (M) at Texas Tech University.
Reviews for Higher Mathematics for Engineers and Scientists I
Report this Material
What is Karma?
Karma is the currency of StudySoup.
Date Created: 10/22/15
How to define a function based on Mathematica s solution to an algebraic equation Notes for Math 3350 Fall 2008 Prof Kevin Long We ll set up an algebraic equation H01 Gx and solve it for y The equation in this example will have multiple solutions We ll choose the positivevalued solution and then use that positive solution to define aMathematica function yx Some of the syntax will seem a little strange at first so I ll walk you through this example step by step so you can get used to how to work with solutions to algebraic equations Start by defining H01 paying careful attention to the use of the underscore quot7quot after the variable name in the definition Hy f4 YAZ y y2 and then define Gx Gx x Sin4 x x sin4 x Create an expression representing the algebraic equation H01 Gx Note carefully the use of the double equals sign quot for the equality and the single equals sign quotquot for the assignment algEqn Hy Gx y4 yZ x sin4x To solve the equation use the Solve function The syntax quotSolvealgEqn y means to solve the equation algEqn for the variable y The equation will have multiple solutions it is a 4th degree polynomial equation in y and so will have 4 solutions The multiple solutions are returned as a list Only one of these solutions will be positive for x 2 0 allSolns SolvealgEq n Y V V4x4sm4x1 1 V 4x4sin4x1 1 1 MW gt V V 1 1 1 1 y gt EJ4X4SIH4X1 Ey gt Ex 4x4s1n4x1 Noticethatv 4x4sin4x 1 21 forallxz 0 Consequently for x 2 0 the contenm of the outer radical are negative for the first two solutions and positive for the last two solutions Therefore the rst two solutions are imaginary while the last two are real Of the real solutions the third is negative and the fourth is positive Therefore we select the fourth solution as the positive solution 2 AlgExampede nb posSoln allSolns 4 1 1 4x4sin4xl 2 2 This is where the syntax gets a bit odd The positive solution was returned as y gt V 4x 4 sin4x 1 which is a rule orsu st1tut1 4x4sin4xl or man ex ress1on oa esu stitution e ouuse esas ot f bquotng fy39yp39Tpplyth bquotruly thlhdquotquot operator For example to substitute the solution in for y in the expression y2 2y you would do the following YAZ 2y posSoln 1 Ex 4x4sin4x1 2 l l l 4x4sin4x1 2 2 2 To use the solution in the definition of a function yx you would write yx y and then substitute the solution for y on the RHS Here s how it works yx y posSoln l l 4x4sin4x1 2 2 This is now a function and you can do anything with it you d do with any other function such as plotting it Plotyx x 039 10 PlotRange gt All39 Frame gt True PlotLabel gt quotAlgebraic Solution Examplequot FrameLabel gt x y Algebraic Solution Example i i i i i l 5 i i l 0 i A 0 5 7 0 0 1 i i i i i 0 2 4 6 8 10 You can compute its exact value at a specified x such as 7r 3 yPi3 or compute a numerical value AlgExampede nb 3 NYPi 3 0395774 You can differentiate it D YX X 16 cos4 x 4 84x4sin4x14x4sin4x and do integrals involving it such as fyx2 16 cos 4 x 4 dx Integrateyx A2 16 Cos4 x 4 x l 2 2 x sin4x g4x 14x4sin4x1 gsin4x4x4sin4x 1 Question why didn tl do the integral fyx dx in this example