Changeset 5609 for branches/VNS/HeuristicLab.Algorithms.VariableNeighborhoodSearch/3.3/VariableNeighborhoodSearchMainLoop.cs
- Timestamp:
- 03/04/11 17:23:40 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/VNS/HeuristicLab.Algorithms.VariableNeighborhoodSearch/3.3/VariableNeighborhoodSearchMainLoop.cs
r5603 r5609 126 126 QualityComparator qualityComparator = new QualityComparator(); 127 127 ConditionalBranch improvesQualityBranch = new ConditionalBranch(); 128 ConditionalBranch improvesQualityBranch2 = new ConditionalBranch(); 128 129 129 130 Assigner bestQualityUpdater = new Assigner(); … … 134 135 Assigner indexResetter = new Assigner(); 135 136 136 SubScopesRemover remover = new SubScopesRemover(); 137 SubScopesRemover remover1 = new SubScopesRemover(); 138 SubScopesRemover remover2 = new SubScopesRemover(); 137 139 Placeholder analyzer2 = new Placeholder(); 138 140 … … 145 147 variableCreator.CollectedValues.Add(new ValueParameter<IntValue>("Iterations", new IntValue(0))); 146 148 variableCreator.CollectedValues.Add(new ValueParameter<DoubleValue>("Index", new DoubleValue(0))); 149 variableCreator.CollectedValues.Add(new ValueParameter<BoolValue>("Continue", new BoolValue(false))); 147 150 variableCreator.CollectedValues.Add(new ValueParameter<DoubleValue>("BestQuality", new DoubleValue(0))); 148 151 … … 183 186 evaluator.OperatorParameter.ActualName = EvaluatorParameter.Name; 184 187 185 qualityComparator.LeftSideParameter.ActualName = "OriginalQuality";186 qualityComparator.RightSideParameter.ActualName = QualityParameter.Name;188 qualityComparator.LeftSideParameter.ActualName = QualityParameter.Name; 189 qualityComparator.RightSideParameter.ActualName = "OriginalQuality"; 187 190 qualityComparator.ResultParameter.ActualName = "IsBetter"; 188 191 189 192 improvesQualityBranch.ConditionParameter.ActualName = "IsBetter"; 193 improvesQualityBranch2.ConditionParameter.ActualName = "IsBetter"; 190 194 191 195 bestQualityUpdater.Name = "Update BestQuality"; … … 194 198 195 199 cleaner.Name = "Clean scope"; 200 cleaner.ClearSubScopesParameter.Value = new BoolValue(false); 196 201 originalRestorer.Name = "Restore original solution"; 197 202 … … 204 209 indexResetter.RightSideParameter.Value = new IntValue(0); 205 210 206 remover .Name = "Remove subscope";211 remover1.Name = remover2.Name = "Remove subscope"; 207 212 208 213 analyzer2.Name = "Analyzer (placeholder)"; … … 253 258 improvesQualityBranch.TrueBranch = bestQualityUpdater; 254 259 improvesQualityBranch.FalseBranch = cleaner; 255 improvesQualityBranch.Successor = remover;256 260 257 261 bestQualityUpdater.Successor = indexResetter; 262 indexResetter.Successor = remover1; 258 263 259 264 cleaner.Successor = originalRestorer; 260 originalRestorer.Successor = indexCounter; 265 originalRestorer.Successor = remover2; 266 remover2.Successor = indexCounter; 261 267 ///////// 262 indexTermination.TrueBranch = null; 263 indexTermination.FalseBranch = iterationInit; 268 indexTermination.TrueBranch = improvesQualityBranch2; 269 indexTermination.FalseBranch = null; 270 271 improvesQualityBranch2.TrueBranch = null; 272 improvesQualityBranch2.FalseBranch = createChild; 264 273 265 274 iterationsCounter.Successor = iterationsComparator;
Note: See TracChangeset
for help on using the changeset viewer.