您好,欢迎访问三七文档
当前位置:首页 > 电子/通信 > 综合/其它 > maple数学软件5
第四章微积分本章考虑用Maple系统求解极限、导数、微分、积分、级数展开、级数求和等问题。4.5导数的应用1、Rolle定理f:=x-x^5-2*x^2+x;diff(f(x),x);iscont(f(x),x=0..1,closed);evalb(f(0)=f(1));fsolve(f(x)=0,x=0..1);plot(f(x),x=0..1);例1.证明方程在(0,1)内至少有一个根.01454xx2、函数的单调性例2.确定在(-∞,+∞)内的单调性.1)(xexfxf:=x-exp(x)-x-1;f1:=diff(f(x),x);fsolve(f1=0,x);assume(x0);is(f10);assume(x0);is(f10);plot(f(x),x=-10..5);3、函数的极值例3.求函数的极值.7186223xxxyrestart:f:=x-2*x^3-6*x^2-18*x+7;f1:=diff(f(x),x);sols:=fsolve(f1=0,x);assume(x-1);is(f10);assume(x-1,x3);is(f10);assume(x3);is(f10);plot(f(x),x=-5..10);例4.利用高阶导数求函数的极值.7186223xxxyrestart:f:=x-2*x^3-6*x^2-18*x+7;f1:=diff(f(x),x);f2:=diff(f1,x);sols:=[fsolve(f1=0,x)];subs(x=sols[1],f2);subs(x=sols[2],f2);例5.求函数在区间[-5,1]上的最大值和最小值.xxxf1)(restart:f:=x+sqrt(1-x);eq:=diff(f,x);sols:=[solve(eq,x)];evalf(subs(x=sols[1],f));evalf(subs(x=-5,f));evalf(subs(x=1,f));例6.判断下列曲线的凹凸性.)()2(;1)()1(3xxfxxxfrestart:f:=x+sqrt(1-x);diff(f,x$2);g:=x^3;g1:=diff(g,x$2);assume(x0);is(g10);assume(x0);is(g10);restart:f:=3*x^4-4*x^3+1;f1:=diff(f,x$2);eq:=f1=0;solve(eq,x);例7.求函数的拐点.143)(34xxxfassume(x0);is(f10);assume(x0,x2/3);is(f10);assume(x2/3);is(f10);subs(x=0,f);subs(x=2/3,f);plot(f,x=-1/2..1);4.6不定积分调用形式:int(表达式,积分变量);1、不定积分的计算例:int(x^2-2*x+3,x);int(exp(x+1),x);不定积分表Int(k,x)=int(k,x);Int(x^mu,x)=int(x^mu,x);Int(1/x,x)=int(1/x,x);Int(1/sqrt(1-x^2),x)=int(1/sqrt(1-x^2),x);Int(cos(x),x)=int(cos(x),x);Int(sin(x),x)=int(sin(x),x);Int(1/cos(x)^2,x)=int(1/cos(x)^2,x);Int(1/sin(x)^2,x)=int(1/sin(x)^2,x);Int(sec(x)*tan(x),x)=int(sec(x)*tan(x),x);Int(csc(x)*cot(x),x)=int(csc(x)*cot(x),x);Int(a^x,x)=int(a^x,x);例1.计算下列不定积分.sin31)4(;2cos2sin1)3(;)1(1)2(;1)1(222223dxxdxxxdxxxxxdxxxInt(1/(x*x^(1/3)),x)=int(1/(x*x^(1/3)),x);Int((1+x+x^2)/(x*(1+x^2)),x)=int((1+x+x^2)/(x*(1+x^2)),x);Int(1/(sin(x/2)^2*cos(x/2)^2),x)=int(1/(sin(x/2)^2*cos(x/2)^2),x);Int(1/(3+sin(x)^2),x)=int(1/(3+sin(x)^2),x);可利用combine对表达式进行化简Int(1/(sin(x/2)^2*cos(x/2)^2),x)=int(combine(1/(sin(x/2)^2*cos(x/2)^2)),x);(1)换元积分法2、积分方法.sin)1(cos.13dxxx求积分例with(student):ut:=Int((cos(x)+1)^3*sin(x),x);changevar((cos(x)+1)=u,ut);ut1:=value(%);subs(u=(cos(x)+1),ut1);..222dxxa求积分例restart:with(student):assume(a0);assume(t-Pi/2,tPi/2);f:=sqrt(a^2-x^2);f1:=subs(x=a*sin(t),f);f1:=simplify(f1);f2:=int(f1*a*cos(t),t);changevar(cos(t)=sqrt(a^2-x^2)/a,f2);changevar(sin(t)=x/a,%);subs(t=arcsin(x/2),%);(2)分部积分法..12dxexx求积分例restart:with(student):intparts(Int(x^2*exp(x),x),x^2);intparts(%,x);value(%);.arctan.2xdxx求积分例restart:with(student):intparts(Int(x*arctan(x),x),arctan(x));value(%);.sin.3dxxex求积分例restart:with(student):ut:=Int(exp(x)*sin(x),x);intparts(ut,exp(x));ut1:=intparts(%,exp(x));op(3,ut1);left:=combine(ut-op(3,ut1));right:=ut1-op(3,ut1);ut:=1/2*right;4.7定积分调用形式:int(f,x=a..b);1、定积分的计算例:int(x^2-2*x+3,x=0..1);int(exp(x+1),x=1..2);例1.计算下列定积分20210053022.cos11)4(;)3(;sinsin)2(;)1(dxxdxedxxxdxxaxaInt(sqrt(a^2-x^2),x=0..a)=int(sqrt(a^2-x^2),x=0..a);Int(sqrt(sin(x)^3-sin(x)^5),x=0..Pi)=int(sqrt(sin(x)^3-sin(x)^5),x=0..Pi);Int(exp(sqrt(x)),x=0..1)=int(exp(sqrt(x)),x=0..1);Int(1/(1+cos(x)^2),x=0..Pi/2)=int(1/(1+cos(x)^2),x=0..Pi/2);(1)矩形法通过加载程序包student,调用函数leftsum求和.2、定积分的近似计算..102dxex计算积分例restart:with(student):f:=x-exp(-x^2);s:=leftsum(f(x),x=0..1,100);evalf(%);evalf(int(exp(-x^2),x=0..1);图示:with(plots):a:=array(1..2,1..2):a[1,1]:=leftbox(f(x),x=0..1,5):a[1,2]:=leftbox(f(x),x=0..1,10):a[2,1]:=leftbox(f(x),x=0..1,20):a[2,2]:=leftbox(f(x),x=0..1,100):s:=leftsum(f(x),x=0..1,100);display(a);(2)梯形法.)())()((21)(:11nkkbaxfbfafnabdxxf梯形法公式restart:n:=100;f:=x-exp(-x^2);a:=0:b:=1:s:=0:s1:=1/2*(f(a)+f(b)):forkfrom1to99dox:=k/n:s:=s+f(x):od;s:=evalf((b-a)/n*(s+s1));(3)抛物线法.)(4)(2))()((3)(:22121122nknkkkbaxfxfbfafnabdxxf抛物线法公式restart:n:=100;f:=x-exp(-x^2);a:=0:b:=1:s:=0:s1:=1/2*(f(a)+f(b)):forkfrom1ton/2dox1:=(2*k-1)/n:x2:=2*k/n;s:=s+2*f(x2)+4*f(x1);od:s:=s-2*f(b):s:=evalf(1/(3*n)*(s+s1));(1)积分区间为无穷区间的广义积分3、广义积分).0()2(;11)1(.102pdxxedxxpx计算积分例Int(1/(1+x^2),x=-infinity..infinity)=int(1/(1+x^2),x=-infinity..infinity);Int(x*exp(-p*x),x=0..infinity)=int(x*exp(-p*x),x=0..infinity);(2)无界函数的广义积分.)0(1)1(.2022aadxxa计算积分例restart;assume(a0);f:=x-1/sqrt(a^2-x^2);Int(1/sqrt('a'^2-x^2),x=0..'a')=int(f(x),x=0..a);4.8定积分的应用1、平面图形的面积.42.12的图形面积围成与直线计算抛物线例xyxywith(plots):implicitplot({y^2=2*x,y=x-4},x=0..10,y=-2..10);solve({y^2=2*x,y=x-4},{x,y});int(y+4-y^2/2,y=-2..4);.)0,3()3,0(34.22积处的切线围成的图形面和及其在点计算抛物线例xxyf:=-x^2+4*x-3;x1:=0:y1:=-3:x2:=3:y2:=0:k1:=subs(x=x1,diff(f,x));k2:=subs(x=x2,diff(f,x));f1:=k1*(x-x1)+y1;f2:=k2*(x-x2)+y2;plot({f1,f2,f},x=-2..4);solve({y=-2*x+6,y=4*x-3},{x,y});int(4*x-3-(-x^2+4*x-3),x=0..3/2)+int(-2*x+6-(-x^2+4*x-3),x=3/2..3);2、旋转体的体积.,2.3323232计算所得旋转体的体积轴旋转所围成图形绕把星形线例xyxwith(plots):implicitplot((x^2)^(1/3)+(y^2)^(1/3)=2^(2/3),x=-2..2,y=-2..2);assume(x=-2,x=2);sols:=[solve(x^(2/3)+y^(2/3)=2^(2/3),y)];2*int(Pi*(sols[1])^2,x=0..2);3、平面曲线的弧长.)(32.423的弧长计算曲线例bxaxyf:=x-2/3*x^(3/2);int(sqrt(1+diff(f(x),x)
本文标题:maple数学软件5
链接地址:https://www.777doc.com/doc-3385368 .html