net.sf.cpsolver.ifs.criteria
Interface Criterion<V extends Variable<V,T>,T extends Value<V,T>>

All Superinterfaces:
InfoProvider<V>, ModelListener<V,T>
All Known Implementing Classes:
AbstractCriterion, AssignedValue, AssignmentCount, BackToBackInstructorPreferences, BrokenTimePatterns, DeltaTimePreference, DepartmentBalancingPenalty, DistanceToStronglyPreferredRoom, DistributionPenalty, DistributionPreferences, DistributionViolation, ExamCriterion, ExamRotationPenalty, ExamSplitter, FlexibleConstraintCriterion, HardConflicts, IgnoredCommittedStudentConflict, IgnoredStudentConflict, ImportantStudentConflict, ImportantStudentHardConflict, InstructorBackToBackConflicts, InstructorDirectConflicts, InstructorDistanceBackToBackConflicts, InstructorLunchBreak, InstructorMoreThan2ADayConflicts, InstructorNotAvailableConflicts, InstructorStudentConflict, InstructorStudentHardConflict, LargeExamsPenalty, PeriodIndexPenalty, PeriodPenalty, PeriodSizePenalty, PeriodViolation, PerturbationPenalty, Perturbations, PlacementSelectionCriterion, PotentialHardConflicts, QuadraticStudentConflict, QuadraticStudentHardConflict, RoomPenalty, RoomPerturbationPenalty, RoomPreferences, RoomSizePenalty, RoomSizePenalty, RoomSplitDistancePenalty, RoomSplitPenalty, RoomViolation, RoomViolations, SameSubpartBalancingPenalty, StudentBackToBackConflicts, StudentCommittedConflict, StudentConflict, StudentDirectConflicts, StudentDistanceBackToBackConflicts, StudentDistanceConflict, StudentHardConflict, StudentLuchBreak, StudentMoreThan2ADayConflicts, StudentNotAvailableConflicts, StudentOverlapConflict, TimePreferences, TimetablingCriterion, TimeViolations, TooBigRooms, UselessHalfHours, WeightedHardConflicts

public interface Criterion<V extends Variable<V,T>,T extends Value<V,T>>
extends ModelListener<V,T>, InfoProvider<V>

Criterion.

An optimization objective can be split into several (optimization) criteria and modeled as a weighted sum of these. This makes the implementation of a particular problem more versatile as it allows for an easier modification of the optimization objective.

Version:
IFS 1.2 (Iterative Forward Search)
Copyright (C) 2006 - 2011 Tomas Muller
muller@unitime.org
http://muller.unitime.org

This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.

This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with this library; if not see http://www.gnu.org/licenses/.

Method Summary
 void bestRestored()
          Notification that the current solution has been restored from the best.
 void bestSaved()
          Notification that the current solution has been saved to the best.
 double getBest()
          Best value (value of the criterion in the best solution)
 double[] getBounds()
          Bounds (minimum and maximum) estimate for the value
 double[] getBounds(Collection<V> variables)
          Value bounds (minimum and maximum) of the criterion on a part of the problem
 String getName()
          Criterion name
 double getValue()
          Current value of the criterion (optimization objective)
 double getValue(Collection<V> variables)
          Value of a part of the problem (given by the collection of variables)
 double getValue(T value, Set<T> conflicts)
          Value of a proposed assignment (including hard conflicts)
 double getWeight()
          Weight of the criterion
 double getWeightedBest()
          Weighted best value of the objective (value in the best solution).
 double getWeightedValue()
          Weighted value of the objectives
 double getWeightedValue(Collection<V> variables)
          Weighted value of a part of the problem (given by the collection of variables)
 double getWeightedValue(T value, Set<T> conflicts)
          Weighted value of a proposed assignment (including hard conflicts)
 void inc(double value)
          Outside update of the criterion (usefull when the criterion is driven by a set of constraints).
 
Methods inherited from interface net.sf.cpsolver.ifs.model.ModelListener
afterAssigned, afterUnassigned, beforeAssigned, beforeUnassigned, constraintAdded, constraintRemoved, init, variableAdded, variableRemoved
 
Methods inherited from interface net.sf.cpsolver.ifs.model.InfoProvider
getInfo, getInfo
 

Method Detail

getValue

double getValue()
Current value of the criterion (optimization objective)


getWeightedValue

double getWeightedValue()
Weighted value of the objectives


getBounds

double[] getBounds()
Bounds (minimum and maximum) estimate for the value


getWeightedBest

double getWeightedBest()
Weighted best value of the objective (value in the best solution).


getBest

double getBest()
Best value (value of the criterion in the best solution)


getWeight

double getWeight()
Weight of the criterion


getWeightedValue

double getWeightedValue(T value,
                        Set<T> conflicts)
Weighted value of a proposed assignment (including hard conflicts)


getValue

double getValue(T value,
                Set<T> conflicts)
Value of a proposed assignment (including hard conflicts)


getWeightedValue

double getWeightedValue(Collection<V> variables)
Weighted value of a part of the problem (given by the collection of variables)


getValue

double getValue(Collection<V> variables)
Value of a part of the problem (given by the collection of variables)


getBounds

double[] getBounds(Collection<V> variables)
Value bounds (minimum and maximum) of the criterion on a part of the problem


getName

String getName()
Criterion name


inc

void inc(double value)
Outside update of the criterion (usefull when the criterion is driven by a set of constraints).


bestSaved

void bestSaved()
Notification that the current solution has been saved to the best.


bestRestored

void bestRestored()
Notification that the current solution has been restored from the best.



Copyright © 2014 UniTime LLC. All Rights Reserved.