matlab求导函数
求n阶导函数
syms x
y=atan(x)
dy=diff(y,x)
figure(1)
ezplot(dy)
d2y=diff(y,x,2)
figure(2)
ezplot(d2y)
二阶图像:
一阶图像: matlab 求积分
1.定积分:
syms x
fun=x*sin(x)
int(fun,x,0,2*pi)
2.不定积分:
syms x,y,z
fun=sin(x*y+z)
int(fun,x)
matlab解决积分问题:
y=dsolve('D2y+2*x=2*y','x')
y=dsolve('Dy=1/(1+x^2)-2*y^2','y(0)=0','x')
ezplot(y)