Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
01/26/12 00:36:45 (12 years ago)
Author:
abeham
Message:

#1614

  • renamed AssemblyInfo frame files to proper name
  • fixed discovery of move operators
  • fixed a bug in the move evaluator
  • fixed a bug in the DiscreteLocationCrossover
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/GeneralizedQAP/HeuristicLab.Problems.GeneralizedQuadraticAssignment/3.3/Operators/DiscreteLocationCrossover.cs

    r7407 r7413  
    6464      foreach (var i in Enumerable.Range(0, locations).Shuffle(random)) {
    6565        int parent = random.Next(parents.Length);
     66        if (!groupedLocations[parent].ContainsKey(i)) {
     67          int tmp = parent;
     68          do {
     69            tmp = (tmp + 1) % parents.Length;
     70          } while (tmp != parent && !groupedLocations[tmp].ContainsKey(i));
     71          if (parent == tmp) continue;
     72          else parent = tmp;
     73        }
    6674        foreach (var item in groupedLocations[parent][i]) {
    6775          if (remainingEquipment.Contains(item.Equipment)) {
Note: See TracChangeset for help on using the changeset viewer.