z = 1 2 x 3 4 y + 3 y dt


 Evan Stanley Shields
 9 months ago
 Views:
Transcription
1 Exact First Order Differential Equations This Lecture covers material in Section 2.6. A first order differential equations is exact if it can be written in the form M(x, ) + N(x, ) d dx = 0, where M = N x. Before showing how to solve these we need to review some multivariable calculus, especiall the twovariable chain rule. This will also help to motivate wh equations of this form are important in phsics. Let ψ(x, ) be a function of two variables. Then we can think of z = ψ(x, ) as a surface in threedimensional space where z is the height above the xplane. Now suppose the x and are functions of t (time) so that (x(t), (t)) gives a curve in the xplane. Then z(t) = ψ(x(t), (t)) gives a curve in threedimensional space. Suppose we desire to know the rate of change of z with respect to t. According to the twovariable chain rule the answer is dz dt = ψ x dx dt + ψ d dt. This formula is derived in Calculus III. Here I will give an intuitive motivation for wh it works. Suppose ψ(x, ) is just a plane. Then we have z = ψ(x, ) = Ax + B + C for some constants A, B and C. Here A is the slope of the plane with respect to the x direction, B is the slope of the plane with respect to the direction and C is the intercept with the zaxis. 1 ( )
2 2 z 3 P 4 6 x z = 1 2 x We want to compute the change in z as t changes from t 0 to t 0 + t. Let x = x(t 0 + t) x(t 0 ) and = (t 0 + t) (t 0 ) be the changes in x and, respectivel. For convenience let x 0 = x(t 0 ) and 0 = (t 0 ). Then the change in z is z = ψ(x 0 + x, 0 + ) ψ(x 0, 0 ) = A x + B. We divide both sides b t to obtain z t = A x t + B t. Now we can find the derivative of z with respect to t b taking limits as t 0. This gives dz dt = Adx dt + Bd dt. But notice that A = x ψ and B = ψ. Thus, we have dz dt = ψ dx x dt + ψ d dt which is ( ). This shows that the twovariable chain rule works for planes. In general if ψ(x, ) is reasonabl smooth it can be approximated near each point b a tangent plane. It can be shown that this gives the twovariable chain rule for an function of two variables that
3 is smooth enough that its graph has a tangent plane at each point in an open set containing the point of interest. Now, let z = ψ(x, ) be a surface. But suppose z is some quantit that is conserved, like energ. That is we now have ψ(x, ) = C. The slice of the surface through z = C is called level curve. Example. Let z = ψ(x, ) = x Then the level curve for z = 1 is a circle of radius 1 that floats one unit above the xplane. Example. Let z = ψ(x, ) = 3x + 3. The level curve for z = 2 is the line 3x + 3 = 2, or = 3x + 5, that is it floating two units above the xplane. For now suppose is a function of x (at least implicitl). As we change x we cause to change so that z = ψ(x, ) stas on the same level curve. Since z is not changing we have dz/dx = 0. The twovariable chain rule, using x for t, gives 0 = dz dx = dψ(x, (x)) dx = ψ dx x dx + ψ d dx. Therefore, ψ x + ψ = 0. If ψ x and ψ are known functions what we have is a differential equation in. We will be doing the inverse of this process. differential equation in the form 3 That is, given at M(x, ) + N(x, ) d dx = 0 we will solve it for (x) (or at least a relation between x and ) b finding a surface ψ(x, ) such that M = ψ x and N = ψ, and
4 4 then using an initial condition to find the desired level curve. In man applications M, N is given as a force field and then ψ is a potential energ function. If energ is conserved, the dnamics are restricted to a level curve of z = ψ(x, ). Enough talk, let s do some examples. Example 1. Solve (2x + ) + (x + 2) = 0, with (3) = 1. Solution. We want to find a function ψ(x, ) such that So, we integrate. ψ = ψ x dx = ψ x = 2x + & ψ = x x + dx = x 2 + x + C 1 (), where C 1 () an arbitrar function of. The idea is we are finding the class of all functions whose partial derivative with respect to x gives 2x +. But we also need for ψ = x + 2. So, we integrate. ψ = ψ d = x + 2 d = x C 2 (x), where C 2 (x) can be an function of x. We now have two classes of functions, each satisfing one of the two conditions. If we could find a function that is in both classes that would do the trick. The answer is obvious. Let ψ(x, ) = x 2 + x + 2. This function is in both classes and thus satisfies both the needed conditions. Now we consider the initial condition, (3) = 1, that is, x = 3 = = 1. Then ψ(3, 1) = = 13.
5 Thus, the level curve we want is 5 x 2 + x + 2 = 13. We will leave as a relation. Below are plots of the surface z = x 2 + x + 2 with the level 13 curve and a projection of this curve into the xplane. Extra Credit. Prove that this curve x 2 + x + 2 = 13 is an ellipse and find its focal points. You can do this b reviewing how to rotate graphs with rotation matrices and the properties of ellipses. Then rotate the graph 45 o so that its major axis lies along the xaxis.
6 6 Example 2 (Not!). Solve (2x + 2) + (x + 2) = 0, with (3) = 1. We integrate. ψ = 2x + 2 dx = x 2 + 2x + C 1 (). ψ = x + 2 d = x C 2 (x). Now look closel. Since 2x x there is no function that meets both conditions. The method fails! What this means in phsical terms is that the force field 2x + 2, x + 2 does not arise from a potential function; in such a sstem energ is not conserved. Note: This example can be converted to a separable equation because it is homogeneous. We work through this in the Appendix at the end of these notes. What we need is a quick test to see if ψ exists for a given equation so that we don t waste a lot of time barking up the wrong tree. Theorem! Given two functions M(x, ) and N(x, ), there exists a function ψ(x, ) such that ψ x = M(x, ) & ψ = N(x, ), if and onl if M = N x, in an open rectangle containing the point of interest. Check this for the two examples above. This is Theorem in our textbook. Your textbook gives a proof, but another proof is covered in Calculus III that uses Green s Theorem. If ou are a Math major read both and compare them. However, one direction is eas: if ψ exists, then ψ x = ψ x = M = N x. This theorem is the motivation for the definition we gave at the beginning of an exact first order differential equation.
7 Example 3. Find the general solution to cos x + e x + (sin x + xe x ) = 0. Solution. Let M = cos x + e x and N = sin x + xe x. Then M = cos x + e x + xe x = N x. Thus, it is exact. We integrate. ψ = M dx = sin x + e x + C 1 () and ψ = N d = sin x + e x + C 2 (x). We let ψ(x, ) = sin x + e x. The general solution is then sin x + e x = C. Example 4. Solve 4x = 0, with (1) = 1. Solution. It is exact since (4x 3 ) = 0 and (4 3 ) x = 0. Then ψ = 4x 3 dx = x 4 + C 1 () and ψ = 4 3 d = 4 + C 2 (x). We let ψ = x Since (1,1) is our initial condition we see that our solution is x = 2. Below is a graph of this curve projected into the xplane.
8 8 Note. The equation in Example 4 is separable and can be solved easil b that method. In fact all separable first order differential equations are also exact. See if ou can prove this. Example 5. Solve 4x 4 + 4x 3 = 0, with (1) = 1. Solution. We check for exactness. (4x 4 ) = 0 while (4x 3 ) x = 4 3. Thus, it is not exact. But wait! Notice that this example is exactl the same as Example 4, but that we have multiplied through b x. So, if we now multiple through b 1 x we get 4x = 0. Thus, the solution is same as in Example 4!
9 Integrating factors. 9 This last example motivates the following idea. Suppose we have a differential equation of the form M + N = 0 which is not exact. Can we find a function µ(x, ) such that µm + µn = 0 is exact? The answer is, not alwas, but sometimes ou can. When this works we call µ an integrating factor. Finding such as µ can be trick. Here we show three special cases where an integrating factor µ can be found. Each relies on an assumption about µ that can be tested for. Case 1. Suppose a suitable µ exists and that it is a function of x onl. Case 2. Suppose a suitable µ exists and that it is a function of onl. Case 3. Suppose a suitable µ exists and that it can be written as a function dependent onl on the product x. In all cases we need to find µ such that (µm) = (µn) x so that we have exactness. B the product rule this is equivalent to requiring µ M + µm = µ x N + µn x. ( )
10 10 Case 1. If Case 1 holds then µ = 0 and we can think of µ x as µ. Then ( ) becomes or µm = µ N + µn x µ µ = M N x. N If our assumption is correct then, since µ /µ depends onl on x, we know that (M N x )/N depends onl on x. Then the integrals below are well defined. 1 µ dµ = M N x dx N Thus, µ = e M Nx N dx. In fact, this gives us a test to determine when this method will work. If M N x N depends onl on x it follows that µ depends onl on x. Example 6. Find the general solution to 2 + x 3 + x = 0. Solution. Since ( 2 + x 3 ) = 2 and (x) x = are not equal, this equation is not exact. But 2 x depends onl on x. Thus, we let = 1 x µ = e 1 x dx = x. So, we multipl through b x to get x 2 + x 4 + x 2 = 0.
11 Let M = x 2 + x 4 and N = x 2. Then M = 2x = N x, so we have exactness. Now we find ψ as before. ψ = M dx = 1 2 x x5 + C 1 () ψ = N d = 1 2 x2 2 + C 2 (x) 11 Thus, we let ψ = 1 2 x x5, so the general solution is or if ou prefer Solving for gives 1 2 x x5 = C, 5x x 5 = C. C 2x 5 = ±. 5x 2 Case 2. This is so similar to Case 1 that we leave it to ou to develop the method and find the formula for µ(). Case 3. Recall equation ( ): µ M + µm = µ x N + µn x. Let v = x and remember we are assuming µ can be rewritten as a function of v. Thus, µ = µ(v) = dµ v dv = dµ dv x = xµ, and µ x = µ(v) x = dµ v dv = dµ dv = µ, where µ means the derivative with respect to v. Now ( ) becomes xµ M + µm = µ N + µn x,
12 12 which gives µ µ = N x M xm N. If the right hand side depends onl on v = x then the assumption we are making is valid, and thus µ = e Perhaps an example would help. Example. Solve with (1) = π. N x M xm N dv. 5x x cos x + x4 + cos x d dx = 0, Solution. Let M = 5x x cos x and N = x4 +cos x. Then M = sin x & N x = 4x3 sin x Thus, the given equation is not exact. We now search for an integration factor. Case 1. Case 2. M N x N = 4x3 x 4 +cos x N x M 4x3 M = 5x 4 +cos x x = = 4x 3 x 4 + cos x 4x 4 5x 4 + cos x No good! Rats!! Case 3. N x M xm N = Let v = x. Now, 4x3 5x 4 + cos x (x 4 + cos x) = 1 x! Eureka!!! µ(v) = e 1 v dv = e ln v +C = C v = C x ;
13 we will use µ = x On ward! We multipl the original equation b x to get 5x 4 + cos x + (x 5 + x cos x) = 0. Let M = 5x 4 + cos x and N = x 5 + x cos x. We double check that it is in fact exact. M = 5x 4 + cos x x sin x = N x. Now the hunt is on for ψ! ψ = M dx = x 5 + sin x + C 1 () 13 and ψ = N d = x 5 + sin x + C 2 (x). Thus, ψ = x 5 +sin x and the general solution is x 5 +sin x = C. Since (1) = π ou can check that C = π. Thus, the solution is x 5 + sin x = π. Appendix A. Example 2. Recall that Example 2 was not exact, but that it was noted that it is homogeneous. Here we will solve it. 2x 2 = = 2 2 ( ) x x ( 2 2v ) = 1 + 2v, x where v = /x. It follows that = v + xv. Now we have x dv dx Thus, = 2 2v 1 + 2v v = 2 2v 1 + 2v v1 + 2v 1 + 2v = 2 3v 2v v
14 v 2 + 3v + v dv = 2 We rewrite the left integrand as Now and 1 4v v 2 + 3v + 2 = x dx ( 4v + 3 2v 2 + 3v v 2 + 3v + 2 4v + 3 2v 2 + 3v + 2 dv = ln 2v2 + 3v C 1 2v 2 + 3v + 2 dv = dv ( 2v ) /8 Let u = 2v Then du = 2dv. The integral becomes du u 2 + /8 = 4 du 8u 2 / + 1. Let w = 2 2u. Then dw = 2 2du. Now the integral becomes, 2 dw w = 2 arctan(w) + C. Putting all this together gives ln x + C = 1 2 ln 2v2 + 3v arctan ) ( ) 4v + 3. Now we find C. We had (1) = 1 and since v = /x we get v = 1. Thus, ( ) C = ln + 1 ( ) arctan. Thus, our solution is given b the relation ln x = 1 2 ln(2v2 + 3v + 2) + 1 arctan ( ) 4v + 3
15 ln ( ) 1 1 ( ) arctan, 15 where v = /x. I tried to graph this using an implicitplot commend. I got no where. I kept getting an error message: Error, (in implicitplot) could not evaluate expression. So, even though I was able to solve the differential equation, the solution is so convoluted it was not of much use to me. So, I used a numerical method on a computer. > DEplot(diff((x),x)=(2*x2*(x))/(x+2*(x)),(x), x= ,[[(1)=1]],= ,arrows=line); But, notice something odd is happening just after x = 1.9. The graph of the solution curve suddenl shoots off straight. Look at the slope field. Notice the slopes are tending toward negative infinit just after x = 1.9. After that point the computer s solution curve is no longer valid. That computer will not tell ou this. You have to understand what is going on with the math in order to use solution properl.