The SUMO toolbox  2018a
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Pages
Public Member Functions | List of all members
Constraint Class Reference

Abstract base class representing a constraint. More...

Inheritance diagram for Constraint:
Inheritance graph
[legend]

Public Member Functions

function Constraint (var config)
 Class constructor. More...
 
function initNewSamples (var state)
 Called when the number of samples changes. More...
 
function setTransformationFunctions (var inFunc, var outFunc)
 Sets transformation functions. More...
 
function satisfy (var x)
 Checks if the constraint is satisfied. More...
 
function preEvaluation (var samples)
 runs samples through the SampleManager constraint. More...
 
function getInternal ()
 Gets internal representation of the constraint. More...
 
function evaluate (var x)
 Evaluates a constraint. More...
 
function evaluateInModelSpace (var x)
 

Detailed Description

Abstract base class representing a constraint.

Only provides a logger to the derived classes

Constructor & Destructor Documentation

function Constraint ( var  config)
inline

Class constructor.

Abstract class

Member Function Documentation

function evaluate ( var  x)
inline

Evaluates a constraint.

Calls preEvaluation and then process of the derived constraint

Parameters
xinput point
Return values
yconstraint value
Todo:
remove preEvaluation if transformation func's work properly
Todo:
transformation functions don't handle input selection, dummy, default values, etc...
function evaluateInModelSpace ( var  x)
function getInternal ( )
inline

Gets internal representation of the constraint.

Returns function handle by default

Return values
outfunction handle to constraint
function initNewSamples ( var  state)
inline

Called when the number of samples changes.

Todo:
copied from CandidateRanker, should be more general (just init(state))
function preEvaluation ( var  samples)
inline

runs samples through the SampleManager constraint.

  • model space -> simulator space
  • input select
  • dummy values
  • ...
Parameters
samplessample matrix
Return values
newSamplesprocessed sample matrix
newIdsprocessed sample id's
function satisfy ( var  x)
inline

Checks if the constraint is satisfied.

Overrided by subclasses

Parameters
xinput point
Return values
yesboolean
function setTransformationFunctions ( var  inFunc,
var  outFunc 
)
inline

Sets transformation functions.

These are transformation functions are executed before evaluating the constraints. It's main (only) use at the moment is for simulator constraints in simulator.xml


The documentation for this class was generated from the following file: