help find two closet node with their index ..distance = sqrt((xd-x(I))^2 + (yd-y(I))^2)

2 vues (au cours des 30 derniers jours)
maha ismail
maha ismail le 29 Jan 2015
Commenté : maha ismail le 29 Jan 2015
help find two closet node with their index ..distance = sqrt((xd-x(I))^2 + (yd-y(I))^2)

Réponses (1)

Jan
Jan le 29 Jan 2015
[value, index] = min(sqrt((xd-x(I))^2 + (yd-y(I))^2))

Catégories

En savoir plus sur Develop Apps Using App Designer dans Help Center et File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by