Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
11/24/15 16:01:02 (9 years ago)
Author:
mkommend
Message:

#2521: Adapted real vector encoding, test function problems, P3, CMA-ES and optimization.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/ProblemRefactoring/HeuristicLab.Algorithms.CMAEvolutionStrategy/3.4/CMAEvolutionStrategy.cs

    r13173 r13361  
    6363
    6464    #region Problem Properties
     65
    6566    public override Type ProblemType {
    66       get { return typeof(ISingleObjectiveHeuristicOptimizationProblem); }
    67     }
    68     public new ISingleObjectiveHeuristicOptimizationProblem Problem {
    69       get { return (ISingleObjectiveHeuristicOptimizationProblem)base.Problem; }
     67      get { return typeof(ISingleObjectiveProblem<RealVectorEncoding, RealVector>); }
     68    }
     69    public new ISingleObjectiveProblem<RealVectorEncoding, RealVector> Problem {
     70      get { return (ISingleObjectiveProblem<RealVectorEncoding, RealVector>)base.Problem; }
    7071      set { base.Problem = value; }
    7172    }
     
    378379    }
    379380
    380     protected override void OnStarted() {
    381       if (!(Problem.SolutionCreator is IRealVectorCreator))
    382         throw new InvalidOperationException("Problems that do not use RealVectorEncoding cannot be solved by CMA-ES.");
    383       base.OnStarted();
    384     }
    385 
    386381    #region Events
    387382    protected override void OnProblemChanged() {
Note: See TracChangeset for help on using the changeset viewer.