How to obtain possible combinations of adjacent points with coordinates?
3 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Hi all,
I am trying to obtain all possible combinations of adjacent points in combinations of 2, 3, 4, 5,...n number.
Example, I have 9 points, and I would like to get all the possible combinations shown below:
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1459342/image.png)
If I do it with the combination function, I will get combinations that will not work for me, therefore a lot of noise will be introduced into my analysis. Also, the points are not always aligned and most of the time they look something like this:
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1459347/image.png)
I do have all the x and y coordinates of each point. Anyone can give me a hand on this please??
Thank you in advance!
3 Commenti
Walter Roberson
il 25 Ago 2023
It is not obvious why 1 2 6 10 would be excluded? In the case of purely rectangular boundaries would could guess about that... but especially as soon as you introduce diagonal connections as being permitted sometimes, then the rules become very unclear.
Risposte (0)
Vedere anche
Categorie
Scopri di più su Operating on Diagonal Matrices in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!