1 / 15

背 景 - PowerPoint PPT Presentation

I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.

PowerPoint Slideshow about '背 景' - peggy

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.

- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript

(1)均需使用命令“sym”或“syms”创建符号变量和

(2) 先创建符号变量，然后才能创建符号表达式；

limit (f,x,a)

limit (f,x,a,’left’)

• 二、极限运算

limit (f,x,a,’right’)

>>syms a b c x

>>f = sym ('a*x^2+b*x+c');

>>f1 = limit (f,x,2)

f1 = 4*a+2*b+c

>>f2 = limit (f,b,3)

f2 = a*x^2+3*x+c

>>syms t x

>>limit ( (cos (x+t)-cos (x) )/ t, t,0)

ans = - sin(x)

diff(f)

diff(f,2)

• 三、微分与导数运算

diff(f,n)

diff(S,'x')

diff(S,'x',n)

>>syms a b c x

>>f1=diff('a*x^2+b*x+c')

f1=2*a*x+b

>>f2=diff('a*x^2+b*x+c',2)

f2=2*a

>>f3=diff(f,a)

f3=x^2

>>f4=diff(f,a,2)

f4=0

int(f)

int(f,a,b)

• 四、积分计算

>>syms a b c x

>>f=sym('a*x^2+b*x+c');

>>f1=int(f)

f1 =1/3*a*x^3+1/2*b*x^2+c*x

>>f2=int(f,x,0,2)

f2 =8/3*a+2*b+2*c

>>f3=int(f,a)

f3=1/2*a^2*x^2+b*x*a+c*a

>>f4=int(int(f,a),x)

f4 =1/6*a^2*x^3+1/2*b*x^2*a+c*a*x

dsolve('Dy=f(x,y)','x')

dsolve('Dy=f(x,y)','y(0)=a','x')

，D2y表示

• 五、解常微分方程

dsolve('D2y=f(x,y,Dy)','y(0)=a','Dy(0)=b','x')

(1)求

(2)求

(3)求

(1)

>>syms x y

>>y=dsolve('Dy=x','x')

y =1/2*x^2+C1

(2)

>>dsolve (‘D2y= Dy+1’,’x’)

ans =-x+C1+C2*exp(x)

>>dsolve('D2y= Dy+1','y(0)=1','Dy(0)=0','x')

(3)

ans =-x+exp(x)

MATLAB典型函数

MATLAB典型函数

abs(x)

tan(x)

sqrt(x)

cot(x)

exp(x)

atan(x)

sin(x)

acot(x)

cos(x)

log(x)

asin(x)

Log10(x)

acos(x)