资源描述:
《《符号计算》word版》由会员上传分享,免费在线阅读,更多相关内容在应用文档-天天文库。
1、1.微分diff(sym('cos(x)+sin(x)-e^x'))ans=cos(x)-sin(x)-e^x*log(e)diffcos(x)Warning:Themethodchar/diffwillberemovedinafuturerelease.Usesym/diffinstead.Forexamplediff(sym('x^2')).Afterremovaldiff('x^2')willreturndiff(double('x^2')).>Inchar.diffat10ans=-sin(x)2.积分symsxyz;F2
2、=int(int(int(x^2+y^2+z^2,z,sqrt(x*y),x^2*y),y,sqrt(x),x^2),x,1,2)VF2=vpa(F2)Warning:Explicitintegralcouldnotbefound.???Errorusing==>mupadmexErrorinMuPADcommand:Recursivedefinition[See?MAXDEPTH];duringevaluationof'hastype'Errorin==>sym.intat56r=mupadmex('symobj::intdef
3、',f.s,x.s,a.s,b.s);3.用MUPADF2=int(int(int(x^2+y^2+z^2,z=sqrt(x*y)..x^2*y),y=sqrt(x)..x^2),x=1..2)4.矩阵M=sym('[ab;cd]')M=[a,b][c,d]det(M)ans=a*d-b*cdiff(sym('x^n'),sym('n'))ans=x^n*log(x)5.符号演示a1=[1/3,pi/7,sqrt(5),pi+sqrt(5)]a2=sym([1/3,pi/7,sqrt(5),pi+sqrt(5)])a3=sym([
4、1/3,pi/7,sqrt(5),pi+sqrt(5)],'e')a4=sym('[1/3,pi/7,sqrt(5),pi+sqrt(5)]')a1=0.33330.44882.23615.3777a2=[1/3,pi/7,5^(1/2),189209612611719/35184372088832]a3=[1/3-eps/12,pi/7-(13*eps)/165,(137*eps)/280+5^(1/2),189209612611719/35184372088832]a4=[1/3,pi/7,5^(1/2),pi+5^(1/2)
5、]1.化减表达式y=sym('2*sin(x)*cos(x)')y=simple(y)y=2*cos(x)*sin(x)y=sin(2*x)symsAttaow;yf=int(A*exp(-i/w*t),t,-tao/2,tao/2);Yf=simple(yf)Yf=(A*w*sinh((6*tao)/w))/62.分离分母与分子f=sym('(a*x^2)/(b-x)')[n,d]=numden(f)f=(a*x^2)/(b-x)n=a*x^2d=b-x3.函数复合symsxyztu;f=1/(1+x^2);g=sin(y);h
6、=x^t;p=exp(-y/u);a=compose(f,g)jia=f+gjian=f/ga=1/(sin(y)^2+1)jia=sin(y)+1/(x^2+1)jian=1/(sin(y)*(x^2+1))1.求反函数symsfxg;f=x^2;g=1/tan(x);finverse(f)finverse(g)Warning:Functionalinverseisnotunique.结果不唯一>InD:ProgramFilesMATLABR2011atoolboxsymbolicsymbolicsymengine
7、.p>symengineat52Insym.finverseat41ans=x^(1/2)ans=atan(1/x)2.替换symsax;f=a*sin(x)+5;fi=subs(f,'sin(x)','y')fi=a*y+5