Hi David,


Op 24-02-12 16:26, davidglassborow schreef:
> Some more details on my problem:
>
>
> Here is an example of a vehicle routing solution, 2 crews and 4 Jobs A, B, C
> and D.
> The print out below is the solver and solutions found at each step (it
> prints out each chain of jobs)
> As you can see the initial solution is valid.
What do you mean by initial solution? The setPlanningProblem() aka "the 
uninitialed solution"
or the solution after the construction heuristic (aka "the initialized 
solution")
> The next and last solutions are invalid though, with the same job appearing
> more than once in a chain.
>
> At 109:
What's "109"?
> B =>  Crew1
> D =>  Crew2
> A =>  B =>  Crew1
> C =>  A =>  B =>  Crew1
>
> 2012-02-24 15:20:39,160 [main] DEBUG     Step index (3), time spend (110),
> score (0hard/-17soft), initialized planning entity (Job D ( linked to Crew
> Crew2)).
Ok, if it's invalid here, it's invalid during the construction heuristic 
already.
> 2012-02-24 15:20:39,160 [main] INFO  Phase construction heuristic ended:
> step total (4), time spend (110), best score (0hard/-17soft).
>
> At 127:
> D =>  Crew2
> A =>  B =>  Crew1
> B =>  A =>  B =>  Crew1
How is this possible? That means that B is pointing both to A and to Crew1 ?
It's only a single pointer? VrpCustomer.getPreviousAppereance()
> C =>  A =>  B =>  Crew1

> 2012-02-24 15:20:39,177 [main] DEBUG     Step index (0), time spend (127),
> score (0hard/-15soft), new best score (0hard/-15soft), accepted move size
> (18) for picked step (Job B ( linked to Crew Crew1) =>  Job A ( linked to Job
> B)).
> 2012-02-24 15:20:39,191 [main] DEBUG     Step index (1), time spend (141),
> score (0hard/-15soft),     best score (0hard/-15soft), accepted move size
> (14) for picked step (Job D ( linked to Crew Crew2) =>  Crew1).
> 2012-02-24 15:20:39,206 [main] DEBUG     Step index (2), time spend (156),
> score (0hard/-16soft),     best score (0hard/-15soft), accepted move size
> (10) for picked step (Job C ( linked to Job A) =>  Job B ( linked to Job A)).
> 2012-02-24 15:20:39,223 [main] DEBUG     Step index (3), time spend (173),
> score (0hard/-16soft),     best score (0hard/-15soft), accepted move size
> (5) for picked step (Job A ( linked to Job B) =>  Job B ( linked to Job A)).
> 2012-02-24 15:20:39,239 [main] WARN      Cancelled step index (4), time
> spend (189): there is no doable move. Terminating phase early.
> 2012-02-24 15:20:39,239 [main] INFO  Phase local search ended: step total
> (4), time spend (189), best score (0hard/-15soft).
> 2012-02-24 15:20:39,239 [main] INFO  Solving ended: time spend (189), best
> score (0hard/-15soft), average calculate count per second (1089).
>
> Best:
> D =>  Crew2
> A =>  B =>  Crew1
> C =>  A =>  B =>  Crew1
> B =>  A =>  B =>  B =>  Crew1
>
I hacked TSP to do multi TSP (see my google+ image), and it worked 
without a problem, so there must be a difference somewhere in your code.

I am working on a vehicle routing example next, you might want to 
compare code with that one as soon as it's done.
> --
> View this message in context: 
> http://drools.46999.n3.nabble.com/Drools-Planner-Vehicle-routing-problems-tp3772797p3772841.html
> Sent from the Drools: User forum mailing list archive at Nabble.com.
> _______________________________________________
> rules-users mailing list
> rules-users@lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/rules-users
>

-- 
With kind regards,
Geoffrey De Smet


_______________________________________________
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users

Reply via email to