I am trying to force the routing to reuse as many path parts as possible as described in initial question. The submodel for it is as follows:
What it supposed to do is as follows:
- The path from the first iteration is precalculated with normal "Route" in network analyst and given to this model as initial value for "previously chosen route"
- Then the iterator goes through the rest of the points and calculates the shortest path under scaled cost (0.1) for the already chosen route segments
- The feedback is supposed to dynamically update the chosen route list
There I have also chosen the option to Append to existing to make the list of previously chosen routes.
The problem is that this dynamic update does not work and I do not know, why. The model starts showing that there is not enough input parameters and at the same time Copy features does not create any new layers, so practically only the initial input route stays and the rest of output is not created. The iteration and merging is working fine.
The model works, when I remove the feedback link, but this is not what I want.