Borrar filtros
Borrar filtros

Finding neighbours of an element in a matrix

3 visualizaciones (últimos 30 días)
Bharathwaj
Bharathwaj el 13 de Feb. de 2012
Suppose that i have an element in a matrix and i need to find its neighbors and the distance of the neighbors...
i want to repeat this process for all elements in the matrix..
  2 comentarios
Michael
Michael el 13 de Feb. de 2012
can you define what you mean by "distance"? Each element would have four neighbours each with distance 1. Is the matrix sparse?
Bharathwaj
Bharathwaj el 13 de Feb. de 2012
actually..i have a surface containing paraboloids of different widths/sizes..i need to compute the distance between the centres of the paraboloids. A paraboloid might have 3 , 5 or 8 neighbours depending on where the paraboloid is located.

Iniciar sesión para comentar.

Respuestas (1)

Andrei Bobrov
Andrei Bobrov el 13 de Feb. de 2012
please try this is function
OR

Categorías

Más información sobre Statistics and Machine Learning Toolbox en Help Center y File Exchange.

Community Treasure Hunt

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

Start Hunting!

Translated by