What algorithm can I use to find the shortest path between specified node types in a graph?

后端 未结 8 1828
自闭症患者
自闭症患者 2021-02-14 12:19

This is the problem:

I have n points (p1, p2, p3, .. pn), each of them can connect to any other with a determined cost x.

Each point belongs to one of a set of p

8条回答
  •  别跟我提以往
    2021-02-14 12:24

    alt text

    This is how I presently interpret your problem.

    Red arrows are me manually tracing the paths that conform to the given ordering constraint.

    Costs are not provided, but it is assumed all links incur a cost, and the link costs are different.

    If this accurately describes the scenario you are trying to solve, please say so, so that others can better answer the question.

提交回复
热议问题