surface 3d plot

조회 수: 3 (최근 30일)
mallela ankamma rao
mallela ankamma rao 2022년 9월 20일
댓글: mallela ankamma rao 2022년 9월 20일
good afternoon sir
I got 3d plot like below form with my code
[gm,km] =meshgrid(0.1:0.01:0.5,0.1:0.01:0.5);
R2 = gm.*(7.5581+ (0.0813+km)./(0.1129+km));
surf(gm,km,R2)
colorbar
xlabel('β','fontweight','bold','fontsize',14);
ylabel('λ_u','fontweight','bold','fontsize',14);
zlabel('R_0','fontweight','bold','fontsize',14);
I requesting you sir please tell me how to get the 3d plot like below graph model.by using above code

답변 (1개)

Chunru
Chunru 2022년 9월 20일
편집: Chunru 2022년 9월 20일
[gm,km] =meshgrid(0.1:0.01:0.5, 0.1:0.01:0.5);
% 1st surface
R2 = gm.*(7.5581+ (0.0813+km)./(0.1129+km));
surf(gm,km,R2, 'EdgeColor', 'none')
hold on
% 2nd surface [you must prode the equation
R0 = ones(size(gm));
surf(gm,km,R0, 'EdgeColor', 'none')
surf(gm,km,2*R0, 'EdgeColor', 'none')
colorbar
xlabel('β','fontweight','bold','fontsize',14);
ylabel('λ_u','fontweight','bold','fontsize',14);
zlabel('R_0','fontweight','bold','fontsize',14);
  댓글 수: 1
mallela ankamma rao
mallela ankamma rao 2022년 9월 20일
Thank you somuch chunru sir.

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Surface and Mesh Plots에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by