How to find coordinate if only x is given?

1 回表示 (過去 30 日間)
Mathew Smith
Mathew Smith 2022 年 9 月 26 日
回答済み: KSSV 2022 年 9 月 26 日
Hello,
Let's assume that we have a surface given by triangular mesh with nodal coordinates [ID, x,y,z]. The surface is circular plate with diameter 200mm. I would like to ask you how to find coordinates x,y and their id which is as close to R = 75 mm as possible.
Best regards
Mathew

回答 (1 件)

KSSV
KSSV 2022 年 9 月 26 日
Rm = sqrt(x.^2+y.^2) ; % get radius from mexh (x,y)
R = 75 ;
tol = 10^-3 ;
idx = find(abs(Rm-R)<tol) ;
iwant = [idx x(idx) y(idx)]

カテゴリ

Help Center および File ExchangeSurface and Mesh Plots についてさらに検索

製品


リリース

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by