question about fplot function

4 ビュー (過去 30 日間)
kris Holm
kris Holm 2021 年 1 月 4 日
コメント済み: kris Holm 2021 年 1 月 4 日
hey! i have a question about fplot.
I am stuck with this problem since many hours. I solve a differential equation but i have to plot it but it dosent work. can someone please help me what im doing wrong?
my code looks like this.
syms f(x)
Dy = diff(y,x,1);
DDy = diff(y,x,2);
ysol = dsolve(DDy + 3*Dy == 12*x - 5, y(0) == 1,Dy(0) == 0)
fplot(f(x))
xlim([-2 10])

回答 (1 件)

Mischa Kim
Mischa Kim 2021 年 1 月 4 日
Hi Kris,
syms y(x)
Dy = diff(y,x,1);
DDy = diff(y,x,2);
ysol = dsolve(DDy + 3*Dy == 12*x - 5, y(0) == 1,Dy(0) == 0)
fplot(ysol)
xlim([-2 10])
  1 件のコメント
kris Holm
kris Holm 2021 年 1 月 4 日
Thank you verry much!

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeProgramming についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by