101 while ( current != 0 )
137 while ( current != 0 )
171 return replot( _frequency );
317 const char*
const _title,
318 const char*
const _xLabel,
319 const char*
const _yLabel,
321 double _xRangeLowerLimit,
322 double _xRangeUpperLimit,
323 double _yRangeLowerLimit,
324 double _yRangeUpperLimit
329 for( run1 = 0; run1 < _expression.
getDim(); run1++ ){
332 _title,_xLabel,_yLabel,_plotMode,
333 _xRangeLowerLimit,_xRangeUpperLimit,
334 _yRangeLowerLimit,_yRangeUpperLimit );
362 const char*
const _title,
363 const char*
const _xLabel,
364 const char*
const _yLabel,
366 double _xRangeLowerLimit,
367 double _xRangeUpperLimit,
368 double _yRangeLowerLimit,
369 double _yRangeUpperLimit
377 for( run1 = 0; run1 < _expressionX.
getDim(); run1++ ){
380 _title,_xLabel,_yLabel,_plotMode,
381 _xRangeLowerLimit,_xRangeUpperLimit,
382 _yRangeLowerLimit,_yRangeUpperLimit );
415 const char*
const _title,
416 const char*
const _xLabel,
417 const char*
const _yLabel,
419 double _xRangeLowerLimit,
420 double _xRangeUpperLimit,
421 double _yRangeLowerLimit,
422 double _yRangeUpperLimit
426 _title,_xLabel,_yLabel,_plotMode,
427 _xRangeLowerLimit,_xRangeUpperLimit,
428 _yRangeLowerLimit,_yRangeUpperLimit );
457 const char*
const _title,
458 const char*
const _xLabel,
459 const char*
const _yLabel,
461 double _xRangeLowerLimit,
462 double _xRangeUpperLimit,
463 double _yRangeLowerLimit,
464 double _yRangeUpperLimit ){
468 _title,_xLabel,_yLabel,_plotMode,
469 _xRangeLowerLimit,_xRangeUpperLimit,
470 _yRangeLowerLimit,_yRangeUpperLimit,
492 const char*
const _title,
493 const char*
const _xLabel,
494 const char*
const _yLabel,
496 double _xRangeLowerLimit,
497 double _xRangeUpperLimit,
498 double _yRangeLowerLimit,
499 double _yRangeUpperLimit )
503 _title,_xLabel,_yLabel,_plotMode,
504 _xRangeLowerLimit,_xRangeUpperLimit,
505 _yRangeLowerLimit,_yRangeUpperLimit,
527 double _xRangeLowerLimit,
528 double _xRangeUpperLimit,
529 const char*
const _title,
530 const char*
const _xLabel,
531 const char*
const _yLabel,
533 double _yRangeLowerLimit,
534 double _yRangeUpperLimit
538 _xRangeLowerLimit,_xRangeUpperLimit,
539 _title,_xLabel,_yLabel,_plotMode,
540 _yRangeLowerLimit,_yRangeUpperLimit );
566 while ( current != 0 )
591 if ( _expression != 0 )
737 switch ( _frequency )
760 Grid& _discretizationGrid
788 if ( dataGridTmp.getNumValues( ) <= (
uint)component )
791 dataGridComponent = dataGridTmp(component);
794 return getDataGrids( &dataGridComponent,_type,_dataGrid,_discretizationGrid );
803 if ( dataGridTmp.getNumValues( ) <= (
uint)component )
806 dataGridComponent = dataGridTmp(component);
809 return getDataGrids( &dataGridComponent,_type,_dataGrid,_discretizationGrid );
825 if ( dataGridTmp.getNumValues( ) > (
uint)component )
826 _dataGrid = dataGridTmp(component);
830 _discretizationGrid.
init();
838 if ( dataGridTmp.getNumValues( ) > (
uint)component )
839 _dataGrid = dataGridTmp(component);
845 tmp.
getGrid( _discretizationGrid );
854 Grid& _discretizationGrid
879 returnValue returnvalue = f.
evaluate( &loggedX,&loggedXA,&loggedP,&loggedU,&loggedW, &_dataGrid );
885 tmp.
getGrid( _discretizationGrid );
894 Grid& _discretizationGrid
898 _discretizationGrid.
init( );
900 _type = variablesGrid->
getType( );
909 _discretizationGrid.
addTime( 0.0 );
922 _dataGrid = *variablesGrid;
942 double maxValue = dataGridY.
getMax( );
943 double minValue = dataGridY.
getMin( );
944 double meanValue = dataGridY.
getMean( );
947 meanValue = 0.1 / 0.025;
949 lowerLimit = minValue - 0.1*( maxValue-minValue ) - 0.025*meanValue - 1.0e-8;
950 upperLimit = maxValue + 0.1*( maxValue-minValue ) + 0.025*meanValue + 1.0e-8;
958 upperLimit = upperLimit *
sqrt(10.0);
returnValue setXLabel(const std::string &_xLabel)
returnValue addData(const VariablesGrid &_newData)
BooleanType isVariable() const
returnValue setType(VariableType _type)
virtual returnValue replot(PlotFrequency _frequency=PLOT_IN_ANY_CASE)
returnValue setYLabel(const std::string &_yLabel)
returnValue addItem(LogName _name, const char *const _label=DEFAULT_LABEL)
IntermediateState sqrt(const Expression &arg)
returnValue evaluate(double *x, double *_result)
PlotWindowSubplot * getNext() const
virtual returnValue addLine(uint idx, double _lineValue)
Allows to setup and evaluate output functions based on SymbolicExpressions.
double getTime(uint pointIdx) const
uint getNumSubplots() const
virtual PlotWindow * clone() const
virtual returnValue plot(PlotFrequency _frequency=PLOT_IN_ANY_CASE)
virtual returnValue setLabelX(uint idx, const char *const xLabel_)
BEGIN_NAMESPACE_ACADO const double EPS
Provides a time grid consisting of vector-valued optimization variables at each grid point...
Allows to pass back messages to the calling function.
virtual returnValue setTitle(uint idx, const char *const title_)
LogName convertPlotToLogName(PlotName _name) const
BEGIN_NAMESPACE_ACADO typedef unsigned int uint
returnValue getVariableDataGrids(const Expression *const variable, VariableType &_type, VariablesGrid &_dataGrid, Grid &_discretizationGrid)
Allows to conveniently handle (one-dimensional) grids consisting of time points.
BooleanType isEmpty() const
PlotWindowSubplot * first
BooleanType acadoIsGreater(double x, double y, double TOL)
returnValue setTitle(const std::string &_title)
BooleanType shallPlotNominalControls
#define CLOSE_NAMESPACE_ACADO
returnValue addSubplot(PlotWindowSubplot &_subplot)
returnValue getLast(LogName _name, DMatrix &lastValue) const
Expression * getXPlotExpression() const
BooleanType acadoIsStrictlySmaller(double x, double y, double TOL)
Base class for all variables within the symbolic expressions family.
returnValue addLine(double _lineValue)
Allows to setup and plot user-specified plot windows for algorithmic outputs.
returnValue getExpressionDataGrids(const Expression *const expression, VariableType &_type, VariablesGrid &_dataGrid, Grid &_discretizationGrid)
VariableType getType() const
PlotWindow & operator=(const PlotWindow &rhs)
virtual returnValue setRanges(uint idx, double xRange1, double xRange2, double yRange1, double yRange2)
returnValue addVector(const DVector &newVector, double newTime=-INFTY)
returnValue setRanges(double _xRangeLowerLimit, double _xRangeUpperLimit, double _yRangeLowerLimit, double _yRangeUpperLimit)
returnValue addSubplot3D(const VariablesGrid &_variable, const char *const _title="", const char *const _xLabel="", const char *const _yLabel="", PlotMode _plotMode=PM_UNKNOWN, double _xRangeLowerLimit=INFTY, double _xRangeUpperLimit=INFTY, double _yRangeLowerLimit=INFTY, double _yRangeUpperLimit=INFTY)
returnValue operator<<(PlotWindowSubplot &_subplot)
returnValue getGrid(Grid &_grid) const
DVector getLastVector() const
virtual returnValue setPlotMode(uint idx, PlotMode plotMode)
returnValue refineGrid(const Grid &arg, InterpolationMode mode=IM_CONSTANT)
virtual returnValue setLabelY(uint idx, const char *const yLabel_)
returnValue init(uint _nPoints=0, const double *const _times=0)
returnValue setPlotMode(PlotMode _plotMode)
BooleanType acadoIsSmaller(double x, double y, double TOL)
virtual returnValue init()
Allows to work with piecewise-continous function defined over a scalar time interval.
void rhs(const real_t *x, real_t *f)
virtual returnValue addData(uint idx, const VariablesGrid &_newData)
int acadoMin(const int x, const int y)
VariableType getYVariableType() const
BooleanType acadoIsZero(double x, double TOL)
returnValue addPlotDataItem(VariableType _type)
Allows to manage sub-windows of user-specified plot windows for algorithmic outputs (for internal use...
VariableType getVariableType() const
returnValue addTime(double _time)
uint getNumPoints() const
returnValue setupLogFrequency(PlotFrequency _frequency=PLOT_AT_EACH_ITERATION)
returnValue setNext(PlotWindowSubplot *const _next)
BooleanType shallPlotNominalOutputs
DVector getVector(uint pointIdx) const
double getLastTime() const
uint getComponent(const unsigned int idx) const
Expression * getYPlotExpression() const
returnValue clearAllSubplots()
#define BEGIN_NAMESPACE_ACADO
BooleanType shallPlotNominalParameters
returnValue getDataGrids(const VariablesGrid *const variablesGrid, VariableType &_type, VariablesGrid &_dataGrid, Grid &_discretizationGrid)
PlotName convertLogToPlotName(LogName _name) const
returnValue setPlotFormat(PlotFormat _plotFormat)
PlotName getPlotEnum() const
returnValue setLogFrequency(LogFrequency _frequency)
BooleanType acadoIsStrictlyGreater(double x, double y, double TOL)
VariableType getXVariableType() const
#define ACADOERROR(retval)
PlotWindowSubplot & operator()(uint idx)
returnValue getAutoScaleYLimits(const VariablesGrid &dataGridY, PlotFormat plotFormat, double &lowerLimit, double &upperLimit) const