Esempio n. 1
0
 public override bool IsAllowedMovement(InterSwap m)
 {
     if (m.deRoute.IsEmpty)
     {
         return(Math.Max(ProblemData.Clients[m.current[m.orIndex]].Delivery, ProblemData.Clients[m.current[m.orIndex]].Pickup) <= m.deRoute.Vehicle.Capacity);
     }
     return(ProblemData.StrongReplaceOverload(m.deRoute, m.deIndex, 1, new List <int> {
         m.current[m.orIndex]
     }) <= epsilon);
 }
Esempio n. 2
0
 public override bool IsAllowedMovement(InterSwap m)
 {
     return(AlphaWeakFeasibilityAfterReplace(m.current, new List <int> {
         m.current[m.orIndex]
     }, new List <int> {
         m.deRoute[m.deIndex]
     }) < WeakThreshold &&
            AlphaWeakFeasibilityAfterReplace(m.deRoute, new List <int> {
         m.deRoute[m.deIndex]
     }, new List <int> {
         m.current[m.orIndex]
     }) < WeakThreshold);
 }
 public override bool IsAllowedMovement(InterSwap m)
 {
     return(WeakFeasibleAfterReplace(m.current, m.current.GetRange(m.orIndex, 1), m.deRoute.GetRange(m.deIndex, 1)) &&
            WeakFeasibleAfterReplace(m.deRoute, m.deRoute.GetRange(m.deIndex, 1), m.current.GetRange(m.orIndex, 1)));
 }