问答文章1 问答文章501 问答文章1001 问答文章1501 问答文章2001 问答文章2501 问答文章3001 问答文章3501 问答文章4001 问答文章4501 问答文章5001 问答文章5501 问答文章6001 问答文章6501 问答文章7001 问答文章7501 问答文章8001 问答文章8501 问答文章9001 问答文章9501

怎么用MATLAB求解如Dy = y+1/y 的微分方程

发布网友 发布时间:2022-04-29 19:47

我来回答

2个回答

热心网友 时间:2022-06-22 01:58

这个方程可以直接分离变量吧

热心网友 时间:2022-06-22 01:59

>> syms x y0
>> y=dsolve('Dy=y+1/y','y(0)=y0','x')

y =

(-1+exp(2*x)*(1+y0^2))^(1/2)
-(-1+exp(2*x)*(1+y0^2))^(1/2)

>> help dsolve
DSOLVE Symbolic solution of ordinary differential equations.
DSOLVE('eqn1','eqn2', ...) accepts symbolic equations representing
ordinary differential equations and initial conditions. Several
equations or initial conditions may be grouped together, separated
by commas, in a single input argument.

By default, the independent variable is 't'. The independent variable
may be changed from 't' to some other symbolic variable by including
that variable as the last input argument.

The letter 'D' denotes differentiation with respect to the independent
variable, i.e. usually d/dt. A "D" followed by a digit denotes
repeated differentiation; e.g., D2 is d^2/dt^2. Any characters
immediately following these differentiation operators are taken to be
the dependent variables; e.g., D3y denotes the third derivative
of y(t). Note that the names of symbolic variables should not contain
the letter "D".

Initial conditions are specified by equations like 'y(a)=b' or
'Dy(a) = b' where y is one of the dependent variables and a and b are
constants. If the number of initial conditions given is less than the
number of dependent variables, the resulting solutions will obtain
arbitrary constants, C1, C2, etc.

Three different types of output are possible. For one equation and one
output, the resulting solution is returned, with multiple solutions to
a nonlinear equation in a symbolic vector. For several equations and
an equal number of outputs, the results are sorted in lexicographic
order and assigned to the outputs. For several equations and a single
output, a structure containing the solutions is returned.

If no closed-form (explicit) solution is found, an implicit solution is
attempted. When an implicit solution is returned, a warning is given.
If neither an explicit nor implicit solution can be computed, then a
warning is given and the empty sym is returned. In some cases involving
nonlinear equations, the output will be an equivalent lower order
differential equation or an integral.

Examples:

dsolve('Dx = -a*x') returns

ans = C1*exp(-a*t)

x = dsolve('Dx = -a*x','x(0) = 1','s') returns

x = exp(-a*s)

y = dsolve('(Dy)^2 + y^2 = 1','y(0) = 0') returns

y =
[ sin(t)]
[ -sin(t)]

S = dsolve('Df = f + g','Dg = -f + g','f(0) = 1','g(0) = 2')
returns a structure S with fields

S.f = exp(t)*cos(t)+2*exp(t)*sin(t)
S.g = -exp(t)*sin(t)+2*exp(t)*cos(t)

dsolve('Dy = y^2*(1-y^2)') returns

Warning:Explicit solution could not be found; implicit solution returned.

ans =
t+1/2*log(y-1)-1/2*log(y+1)+1/y+C1=0

dsolve('Df = f + sin(t)', 'f(pi/2) = 0')
dsolve('D2y = -a^2*y', 'y(0) = 1, Dy(pi/a) = 0')
S = dsolve('Dx = y', 'Dy = -x', 'x(0)=0', 'y(0)=1')
S = dsolve('Du=v, Dv=w, Dw=-u','u(0)=0, v(0)=0, w(0)=1')
w = dsolve('D3w = -w','w(0)=1, Dw(0)=0, D2w(0)=0')
y = dsolve('D2y = sin(y)'); pretty(y)

See also solve, subs.

Reference page in Help browser
doc dsolve
声明声明:本网页内容为用户发布,旨在传播知识,不代表本网认同其观点,若有侵权等问题请及时与本网联系,我们将在第一时间删除处理。E-MAIL:11247931@qq.com
体育运动员谁最有钱? 曲轴箱通风管漏气 有什么现象 曲轴箱强制通风管漏气? 曲轴箱(曲轴箱通风管坏了有什么影响) 100分求CS PING的问题 枇杷有什么作用与功效与作用 枇杷的功效和作用 三星手机大全5660三星手机大全所有型号图片 三星s5660能用动感地带152号段的卡上wlan吗? 我的三星S5660插移动卡就会显示只能进行紧急呼叫,用联通卡没问题,把卡... 为什么第一步还有一个y' 行列式加减消元法 求大一高数期末试卷或练习题? 微分方程d4y/dx=c如何解呢,请各位老师帮忙。其中c为常数,d4y为dy的4次幂。谢了! 去商丘旅游,有什么特产可以方便携带回去的吗? 其实我还不懂。。。是不是说D2Y/dx2是已经规定要这么写?无法推出这个式子? 请问:d/dx 与 d 这两种运算有什么区别?比如 d3y/dx^2 表示什么意思? 求微分方程的通解(d3y/dx3)^2-d2y/dx2*d4y/dx4=0 微分题目。请问d²y/dx²=? d3y/dx3怎么算 如何用视频录像? 百度可以上传自己录制的视频吗? 尤克里里和吉他 弹奏上面有什么区别 吉他尤克里里,古典,民族有什么区别 为什么百度小视频显示的视频都是每个人自己拍摄的,却没有是在播放器里录制的 吉他,吉他丽丽,尤克里里三者有什么区别 为什么百度里的小视频几乎没有屏幕录制录播放器里上传的视频 尤克里里属于古典吉他吗 吉他和尤克里里有什么区别?哪个比较好学? 百度录制视频为什么很短,是什么原因? 行列式a1b1c1d1e1 D是由y=x^3, y=1, x=-1围成的区域,计算∫∫xdxdy 先积x怎么算还有如果把D分成四个区域,根据性质 用克莱姆法则解线性方程组这道题怎么做 判断积分∫∫开三次根下的(1-x^2-y^2)dxdy的正负号 平面点集最接近点对问题怎么做 excel计算方程 三字经感想:,感悟 《三字经》读书心得 请谈谈读完《三字经》后有何感想 乐易购网络商城 乐易购n8卖1380跟诺基亚官网相差甚远。有知道情况的帮忙回答谢谢 现在什么手机比较好啊,我想买个女士手机哦 读三字经、弟子规写心得体会 校园安全教育三字经的心得体会 500字 诸天邪武白青青是谁 诵读《三字经》,《论语》,《弟子规》心得 三字经心得,不要泛泛而谈,精辟一些,最好配上感触最深的一段原文! 谢啦... 三字经或论语的学习体会400字 三字经 曰喜怒,曰哀惧.爱恶欲,七情具.这句的心得体会 找一片写弟子规三字经的体会600字 急用