Changeset 15492 for branches/GeneralizedQAP/HeuristicLab.Problems.GeneralizedQuadraticAssignment/3.3
- Timestamp:
- 12/04/17 23:19:44 (6 years ago)
- Location:
- branches/GeneralizedQAP/HeuristicLab.Problems.GeneralizedQuadraticAssignment/3.3
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/GeneralizedQAP/HeuristicLab.Problems.GeneralizedQuadraticAssignment/3.3/HeuristicLab.Problems.GeneralizedQuadraticAssignment-3.3.csproj
r15491 r15492 186 186 <Private>False</Private> 187 187 </ProjectReference> 188 <ProjectReference Include="..\..\HeuristicLab.Problems.GeneralizedQuadraticAssignment.Common\3.3\HeuristicLab.Problems.GeneralizedQuadraticAssignment.Common-3.3.csproj">189 <Project>{DA367BE5-4F53-4243-933B-32AAB86189D5}</Project>190 <Name>HeuristicLab.Problems.GeneralizedQuadraticAssignment.Common-3.3</Name>191 <Private>False</Private>192 </ProjectReference>193 188 </ItemGroup> 194 189 <ItemGroup /> -
branches/GeneralizedQAP/HeuristicLab.Problems.GeneralizedQuadraticAssignment/3.3/Operators/Crossovers/GQAPPathRelinking.cs
r15490 r15492 137 137 var fix = new HashSet<int>(); 138 138 var nonFix = new HashSet<int>(Enumerable.Range(0, demands.Length)); 139 var phi = new HashSet<int>(( pi_prime.GetDifferingIndices(target)));139 var phi = new HashSet<int>((IntegerVectorEqualityComparer.GetDifferingIndices(pi_prime, target))); 140 140 141 141 while (phi.Any()) { … … 176 176 bool contains = false; 177 177 foreach (var b in B) { 178 if (! solution.Assignment.GetDifferingIndices(b.Assignment).Any()) {178 if (!IntegerVectorEqualityComparer.GetDifferingIndices(solution.Assignment, b.Assignment).Any()) { 179 179 contains = true; 180 180 break; … … 189 189 if (maximization.Value) pi = B.SampleProportional(random, 1, B.Select(x => x.Quality.Value), false).First(); 190 190 else pi = B.SampleProportional(random, 1, B.Select(x => 1.0 / x.Quality.Value), false).First(); 191 var diff = pi.Assignment.GetDifferingIndices(target);191 var diff = IntegerVectorEqualityComparer.GetDifferingIndices(pi.Assignment, target); 192 192 var I = phi.Except(diff); 193 193 var i = I.SampleRandom(random); … … 203 203 } 204 204 } else return result; 205 phi = new HashSet<int>( pi_prime.GetDifferingIndices(target));205 phi = new HashSet<int>(IntegerVectorEqualityComparer.GetDifferingIndices(pi_prime, target)); 206 206 } 207 207 -
branches/GeneralizedQAP/HeuristicLab.Problems.GeneralizedQuadraticAssignment/3.3/Operators/PopulationReducers/GQAPQualitySimilarityReducer.cs
r15490 r15492 27 27 using HeuristicLab.Encodings.IntegerVectorEncoding; 28 28 using HeuristicLab.Operators; 29 using HeuristicLab.Optimization; 29 30 using HeuristicLab.Parameters; 30 31 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 31 using HeuristicLab.Problems.GeneralizedQuadraticAssignment.Common;32 32 33 33 namespace HeuristicLab.Problems.GeneralizedQuadraticAssignment.Operators {
Note: See TracChangeset
for help on using the changeset viewer.