Path optimization algorithm for long segments search and small segments minimization

2 次查看(过去 30 天)
Hi all,
I am developing a code to find the best subpaths in a complex graph. My graph is just a representation of a physical structure, so my edges are actual segments. When I say "best" I want to obtain the longest segments possible that can also minimize the resulting "short" segments (only one edge). What I am doing now is an iterative approach.
Given a maximum length of the sub-path:,
  • each iteration starts from one of the n available nodes
  • the n subpaths are generated and the best one selected. Each subpath is generated based on available neighbors (not completed nodes and not visited edges)
  • I have a function to remove selected subpaths (and nodes with no available neighbors) from the next subpath generation search
I wanted to implement something metaheuristic like cuckoo nest, or bat algorithm, but my conditions here are slightly different. In my case the nodes must be visited more than once, because I need all the nodes to be included in the final count. This means that a node is excluded from the search when it's completed, not just visited.
My code is working fine, the problem is that I still have a high number of short segments (still 30% of the total number of edges, which is a lot), so perhaps I am missing another perspective or another approach that I have not thought about!
Thanks in advance for your help!

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Direct Search 的更多信息

产品


版本

R2024a

Community Treasure Hunt

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

Start Hunting!

Translated by