How do I select specific points from the meshgrid function?
조회 수: 3 (최근 30일)
이전 댓글 표시
I have created a meshgrid and would like to select specific coordinates (rho, theta) on it in order to see their value relating to my Gauss-Laguerre beam I am inspecting.

rseed=[0*max(w):max(w)/30:3*max(w)];
thetaseed=[0:360]*pi/180;
[r,theta]=meshgrid(rseed,thetaseed)
댓글 수: 0
채택된 답변
Walter Roberson
2017년 11월 9일
The value at probe_r, probe_theta is approximately
interp2(r, theta, GaussLaguerreValues, probe_r, probe_theta)
댓글 수: 3
Walter Roberson
2017년 11월 10일
This disagrees with the r, theta meshgrid that you show you were creating. r and theta for this purpose should be those meshgrid results, and E should be the function evaluated at those locations. Then probe_r and probe_theta should be the places you want to ask about the value of.
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Surface and Mesh Plots에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!