contour plot problem Z must be at least a 2x2 matrix
조회 수: 2 (최근 30일)
이전 댓글 표시
Hallo everyone,
i have a problem to make the contour plot, it always shows Z must be at least a 2x2 matrix. i have try my best to solve, but it still not work, could you please to help me? The code is as follows.
x=[80;100;90;90;90]
y=[4;4;2;6;4]
[X,Y] = meshgrid(x,y)
% Polly 11 f(x,y)=p00+p10*x+p01*y
f1=1.7419-0.0006*x+0.0132*y
contour(X,Y,f1)
Thanks and best regards
JL
댓글 수: 0
채택된 답변
Star Strider
2024년 7월 25일
x=[80;100;90;90;90]
y=[4;4;2;6;4]
[X,Y] = meshgrid(x,y);
% Polly 11 f(x,y)=p00+p10*x+p01*y
f1=1.7419-0.0006*x+0.0132*y
Fz = scatteredInterpolant(x, y, f1)
F1 = Fz(X,Y)
contour(X,Y,F1)
.
댓글 수: 4
Star Strider
2024년 7월 25일
As always, my pleasure!
I will gladly help you with any further questions.
추가 답변 (1개)
Walter Roberson
2024년 7월 25일
x=[80;100;90;90;90];
y=[4;4;2;6;4];
[X,Y] = meshgrid(x,y);
% Polly 11 f(x,y)=p00+p10*x+p01*y
f1=1.7419-0.0006*X+0.0132*Y;
contour(X,Y,f1)
댓글 수: 4
참고 항목
카테고리
Help Center 및 File Exchange에서 Contour Plots에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!