how can I get y which correspond to x and then plot (x,y)??

조회 수: 1 (최근 30일)
jameslk
jameslk 2021년 6월 16일
답변: Rafael Hernandez-Walls 2021년 6월 16일
syms x y
x=[-4:1:4]
f = y^3+0.2*exp(-1*x^2)*y^2-2.2039*y^2+0.8155 == 0;

답변 (1개)

Rafael Hernandez-Walls
Rafael Hernandez-Walls 2021년 6월 16일
Try this:
x=linspace(-4,4);
for r=1:length(x)
y(r)=fzero(@(y)y.^3+0.2*exp(-1*x(r).^2)*y.^2-2.2039*y.^2+0.8155,1);
end
plot(x,y)

카테고리

Help CenterFile Exchange에서 Calculus에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by