MIT 6006 Quiz 2: The shortest path task
Ok, I think here is how it should look like. You duplicate the graph G as many times as many v places you have to visit (e.g. v0, v1, v2). The order you must visit these vertices is the constraint which is expressed as zero weight edges (G1.v0 -&gt; G2.v0, G2.v1 -&gt; G3.v1).