Another service from Omega

Examples of Chain Rules Formulas with Maple


*****


In the following problems compute the derivative with respect to the parameter t at the given values.

Problem1:


> z1 := x^2*y + 3*x*y^3; x := exp(t); y := sin(t); t0 := 0;


                                     2          3
                              z1 := x  y + 3 x y

                                  x := exp(t)

                                  y := sin(t)

                                    t0 := 0




We can do this in several ways. First by just substituting back x and y as functions of t into the expression for z1. This is done automatically by maple,


> answer1 := diff(z1,t);


answer1 :=

         2                2                         3                  2
 2 exp(t)  sin(t) + exp(t)  cos(t) + 3 exp(t) sin(t)  + 9 exp(t) sin(t)  cos(t)


> answer1 := simplify(subs(t=0,answer1));

                                  answer1 := 1



An alternative form is to use the formula for the chain rule. We compute each part,


> x := 'x': y := 'y': z := x^2*y + 3*x*y^3; zx := diff(z,x); zy := diff(z,y);


                                     2          3
                               z := x  y + 3 x y

                                                3
                               zx := 2 x y + 3 y

                                      2        2
                               zy := x  + 9 x y


> xt := diff(exp(t),t); yt := diff(sin(t),t);

                                  xt := exp(t)

                                  yt := cos(t)



and the chain rule formula is,


> x := exp(t): y := sin(t): zt := 'zx'*'xt' + 'zy'*'yt';


                              zt := zx xt + zy yt



at t=0 this simplifies to,


> answer := simplify( subs(t=0,zt) );


                                  answer := 1



The same as the previous answer as it should. So the formula for the chain rule checks out with the plain substitution method in this case. It is often true that the plain substitution method is more desirable for computing derivatives with maple than the chain rule. The chain rule is however much easier to use if one has to compute the derivatives by hand.

Notice that we are computing a derivative along a line on the surface. Here is a picture of the curve and the surface:


> with(plots): C := spacecurve([x,y,z],t= -1..1,color=yellow):
> S := plot3d(x1^2*y1 + 3*x1*y1^3,x1=-1..1,y1=-1..1.5):
> display3d({S,C},axes=frame,orientation=[83,56]);

picture a picture here

Link to the commands in this file
Carlos Rodriguez <carlos@math.albany.edu>
Last modified: Tue Oct 15 16:24:29 EDT 1996