資源描述:
《理工數(shù)學(xué)實(shí)驗(yàn)答案matlab》由會員上傳分享,免費(fèi)在線閱讀,更多相關(guān)內(nèi)容在教育資源-天天文庫。
1、第五章5.symsxyuvduxduydvxdvy>>f=x^2+y^2+u^2+v^2-R^2;>>g=x+y+u+v;>>fx=diff(f,'x');fy=diff(f,'y');fu=diff(f,'u');fv=diff(f,'v');>>gx=diff(g,'x');gy=diff(g,'y');gu=diff(g,'u');gv=diff(g,'v');>>ffx=fu*dux+fv*dvx+fx;>>ggx=gu*dux+gv*dvx+gx;>>[dux,dvx]=solve(ffx,ggx,'dux','dvx')d
2、ux=-(x-v)/(u-v)dvx=(-u+x)/(u-v)>>ffy=fu*duy+fv*dvy+fy;>>ggy=gu*duy+gv*dvy+gy;>>[duy,dvy]=solve(ffy,ggy,'duy','dvy')duy=-(y-v)/(u-v)dvy=(-u+y)/(u-v)6.symsxyz>>f=x+y+z-exp(-(x+y+z));>>fx=diff(f,'x');fz=diff(f,'z');>>dzx=-fx/fz;>>fxy=diff(dzx,'y')fxy=exp(-x-y-z)/(1+exp(-x-
3、y-z))+(-1-exp(-x-y-z))/(1+exp(-x-y-z))^2*exp(-x-y-z)7.symsxy>>z=x^2-x*y-2*y^2;>>zx=diff(z,'x');zy=diff(z,'y');>>fzx=inline(zx);>>fzy=inline(zy);>>a=pi/6;b=pi/3;>>f1=fzx(1,2)*cos(a)+fzy(1,2)*cos(b)f1=-4.50008.symst>>x=sin(t)>>y=cos(t)>>z=t;>>dx=diff(x,'t');dy=diff(y,'t')
4、;dz=diff(z,'t');>>x1=inline(dx);>>x2=inline(dy);>>x3=inline(dz);>>x10=x1(1)x10=x1(pi/4)x10=0.7071>>x20=x2(pi/4)x20=-0.7071>>x30=x3(pi/4)x30=19.symsxy>>f=x^2+y^2;>>fx=diff(f,'x');>>fy=diff(f,'y');>>x=1;>>y=2;>>fx0=subs(fx)fx0=2>>fy0=subs(fy)fy0=410.symsxy>>f=x^3-y^3+3*x^
5、2+3*y^2-9*x;>>fx=diff(f,'x');fy=diff(f,'y');>>[x0y0]=solve(fx,fy)x0=1-31-3y0=0022>>fxx=diff(diff(f,'x'),'x')fxx=6*x+6>>fxy=diff(diff(f,'x'),'y');>>fyy=diff(diff(f,'y'),'y');>>delta=inline(fxy^2-fxx*fyy);>>delta(x0,y0)ans=-727272-72>>x=1;y=0;>>fmin=subs(f)fmin=-5x=-3;y=2
6、;>>fmax=subs(f)fmax=3110.symsxyzlamdaa>>L=x*y*z+lamda*(x^2/2+y^2/2+z^2-a*a);>>Lx=diff(L,'x');>>Ly=diff(L,'y');>>Lz=diff(L,'z');>>Llamda=diff(L,'lamda');>>[lamdaxyz]=solve(Lx,Ly,Lz,Llamda)lamda=0000001/3*3^(1/2)*a-1/3*3^(1/2)*a1/3*3^(1/2)*a-1/3*3^(1/2)*a-1/3*3^(1/2)*a1/3
7、*3^(1/2)*a-1/3*3^(1/2)*a1/3*3^(1/2)*ax=002^(1/2)*a-2^(1/2)*a00-1/3*6^(1/2)*a-1/3*6^(1/2)*a1/3*6^(1/2)*a1/3*6^(1/2)*a1/3*6^(1/2)*a1/3*6^(1/2)*a-1/3*6^(1/2)*a-1/3*6^(1/2)*ay=2^(1/2)*a-2^(1/2)*a00001/3*6^(1/2)*a1/3*6^(1/2)*a-1/3*6^(1/2)*a-1/3*6^(1/2)*a1/3*6^(1/2)*a1/3*6^(1
8、/2)*a-1/3*6^(1/2)*a-1/3*6^(1/2)*az=0000a-a1/3*3^(1/2)*a-1/3*3^(1/2)*a1/3*3^(1/2)*a-1/3*3^(1/2)*a1/3*3^(1/2)*a-