필터 지우기
필터 지우기

How to plot 2d filled contour

조회 수: 2 (최근 30일)
Aiden James
Aiden James 2021년 5월 28일
댓글: Aiden James 2021년 5월 29일
I have function y= (0.32/(0.32+0.38*x))^2
k=m*(dy/dx)
It means 'k' depends on 'm' and 'x'
x= 0:1 ( 0 to1)
m=0:1 ( 0 to1)
I want see variation of k with 'm' and 'x' using 2d contour in range of (0 ,1)
How to do it?

채택된 답변

KSSV
KSSV 2021년 5월 28일
x = linspace(0,1) ;
m = linspace(0,1) ;
[X,M] = meshgrid(x,m) ;
Y = (0.32./(0.32+0.38*X)).^2 ;
dX = gradient(X) ;
dY = gradient(Y) ;
K = M.*(dY./dX) ;
contourf(X,M,K)

추가 답변 (0개)

카테고리

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

태그

제품


릴리스

R2018b

Community Treasure Hunt

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

Start Hunting!

Translated by