how to find nearest node in random wireless sensor network for 100 nodes 100*100 area...plz help
조회 수: 1 (최근 30일)
이전 댓글 표시
in a random sensor network 100 nodes are there.. how to find nearest node for n1, nearest node for n2....provided if n10 is the nearest node of n1 then it never bea again nearest of any other...plz help me
댓글 수: 0
답변 (1개)
Walter Roberson
2014년 1월 31일
Find the distance from each node to every other node, and sort() the result recording the indices (the two-output version of sort). Be careful about the distance of nodes to themselves.
Yes, there are probably more efficient methods. Or at least methods that use less memory. In particular... http://www.mathworks.com/help/matlab/ref/voronoi.html -- though at the moment I do not see any convenient routine to determine which voronoi cell a particular point is in.
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Voronoi Diagram에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!