Public Member Functions | Protected Attributes | Friends

Allows to manage sub-windows of user-specified plot windows for algorithmic outputs (for internal use). More...

#include <plot_window_subplot.hpp>

List of all members.

Public Member Functions

returnValue addData (const VariablesGrid &_newData)
returnValue addLine (double _lineValue)
PlotWindowSubplotgetNext () const
uint getNumData () const
uint getNumLines () const
PlotName getPlotEnum () const
PlotFormat getPlotFormat () const
PlotMode getPlotMode () const
returnValue getRanges (double &_xRangeLowerLimit, double &_xRangeUpperLimit, double &_yRangeLowerLimit, double &_yRangeUpperLimit) const
SubPlotType getSubPlotType () const
returnValue getTitle (std::string &_title)
returnValue getXLabel (std::string &_xLabel)
ExpressiongetXPlotExpression () const
VariableType getXVariableType () const
returnValue getYLabel (std::string &_yLabel)
ExpressiongetYPlotExpression () const
VariableType getYVariableType () const
PlotWindowSubplotoperator= (const PlotWindowSubplot &rhs)
 PlotWindowSubplot ()
 PlotWindowSubplot (const Expression &_expression, 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)
 PlotWindowSubplot (const Expression &_expressionX, const Expression &_expressionY, 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)
 PlotWindowSubplot (PlotName _name, 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)
 PlotWindowSubplot (const VariablesGrid &_plotVariable, 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, BooleanType _plot3D=BT_FALSE)
 PlotWindowSubplot (const Curve &_curve, double _xRangeLowerLimit=0.0, double _xRangeUpperLimit=1.0, const char *const _title="", const char *const _xLabel="", const char *const _yLabel="", PlotMode _plotMode=PM_UNKNOWN, double _yRangeLowerLimit=INFTY, double _yRangeUpperLimit=INFTY)
 PlotWindowSubplot (const PlotWindowSubplot &rhs)
returnValue setNext (PlotWindowSubplot *const _next)
returnValue setPlotFormat (PlotFormat _plotFormat)
returnValue setPlotMode (PlotMode _plotMode)
returnValue setRanges (double _xRangeLowerLimit, double _xRangeUpperLimit, double _yRangeLowerLimit, double _yRangeUpperLimit)
returnValue setTitle (const std::string &_title)
returnValue setXLabel (const std::string &_xLabel)
returnValue setYLabel (const std::string &_yLabel)
 ~PlotWindowSubplot ()

Protected Attributes

VariablesGrid ** data
double * lineValues
uint nData
PlotWindowSubplotnext
uint nLines
BooleanType plot3D
PlotName plotEnum
ExpressionplotExpressionX
ExpressionplotExpressionY
PlotFormat plotFormat
PlotMode plotMode
VariablesGridplotVariablesGrid
ExpressionplotVariableX
ExpressionplotVariableY
std::string title
std::string xLabel
double xRangeLowerLimit
double xRangeUpperLimit
std::string yLabel
double yRangeLowerLimit
double yRangeUpperLimit

Friends

class GnuplotWindow

Detailed Description

Allows to manage sub-windows of user-specified plot windows for algorithmic outputs (for internal use).

The class PlotWindowSubplot allows to manage sub-windows of user-specified plot windows for algorithmic outputs to be plotted during runtime. It is intended for internal use only and is used by the class PlotWindow.

The class stores the internal name or the symbolic expression to be plotted within one sub-plot of a figure. Moreover, output settings like title, axis labels or ranges of the sub-plot are stored.

Note that PlotWindowSubplot is always stored in a basic singly-linked list within a PlotWindow. Thus, also a pointer to the next subplot is stored. Also the actual numerical data to be plotted is stored centrally for each PlotWindow.

Author:
Hans Joachim Ferreau, Boris Houska

Definition at line 65 of file plot_window_subplot.hpp.


Constructor & Destructor Documentation

Default constructor.

Definition at line 46 of file plot_window_subplot.cpp.

PlotWindowSubplot::PlotWindowSubplot ( const Expression _expression,
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 
)

Constructor which takes the symbolic expression to be plotted along with settings defining the output format of the subplot.

Parameters:
[in]_expressionSymbolic expression to be plotted on the y-axis.
[in]_titleTitle of the subplot.
[in]_xLabelLabel of x-axis of the subplot.
[in]_yLabelLabel of y-axis of the subplot.
[in]_plotModePlot mode, see the PlotMode documentation for details.
[in]_xRangeLowerLimitLower limit of the x-axis.
[in]_xRangeUpperLimitUpper limit of the x-axis.
[in]_yRangeLowerLimitLower limit of the y-axis.
[in]_yRangeUpperLimitUpper limit of the y-axis.

Definition at line 76 of file plot_window_subplot.cpp.

PlotWindowSubplot::PlotWindowSubplot ( const Expression _expressionX,
const Expression _expressionY,
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 
)

Constructor which takes symbolic expressions to be plotted along with settings defining the output format of the subplot.

Parameters:
[in]_expressionXSymbolic expression to be plotted on the x-axis.
[in]_expressionYSymbolic expression to be plotted on the y-axis.
[in]_titleTitle of the subplot.
[in]_xLabelLabel of x-axis of the subplot.
[in]_yLabelLabel of y-axis of the subplot.
[in]_plotModePlot mode, see the PlotMode documentation for details.
[in]_xRangeLowerLimitLower limit of the x-axis.
[in]_xRangeUpperLimitUpper limit of the x-axis.
[in]_yRangeLowerLimitLower limit of the y-axis.
[in]_yRangeUpperLimitUpper limit of the y-axis.

Definition at line 128 of file plot_window_subplot.cpp.

PlotWindowSubplot::PlotWindowSubplot ( PlotName  _name,
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 
)

Constructor which takes the internal name of pre-defined information to be plotted along with settings defining the output format of the subplot.

Parameters:
[in]_nameInternal name of pre-defined information to be plotted.
[in]_titleTitle of the subplot.
[in]_xLabelLabel of x-axis of the subplot.
[in]_yLabelLabel of y-axis of the subplot.
[in]_plotModePlot mode, see the PlotMode documentation for details.
[in]_xRangeLowerLimitLower limit of the x-axis.
[in]_xRangeUpperLimitUpper limit of the x-axis.
[in]_yRangeLowerLimitLower limit of the y-axis.
[in]_yRangeUpperLimitUpper limit of the y-axis.

Definition at line 182 of file plot_window_subplot.cpp.

PlotWindowSubplot::PlotWindowSubplot ( const VariablesGrid _plotVariable,
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,
BooleanType  _plot3D = BT_FALSE 
)

Constructor which takes discrete data to be plotted along with settings defining the output format of the subplot.

Parameters:
[in]_variableDiscrete data to be plotted on the y-axis.
[in]_titleTitle of the subplot.
[in]_xLabelLabel of x-axis of the subplot.
[in]_yLabelLabel of y-axis of the subplot.
[in]_plotModePlot mode, see the PlotMode documentation for details.
[in]_xRangeLowerLimitLower limit of the x-axis.
[in]_xRangeUpperLimitUpper limit of the x-axis.
[in]_yRangeLowerLimitLower limit of the y-axis.
[in]_yRangeUpperLimitUpper limit of the y-axis.

Definition at line 221 of file plot_window_subplot.cpp.

PlotWindowSubplot::PlotWindowSubplot ( const Curve _curve,
double  _xRangeLowerLimit = 0.0,
double  _xRangeUpperLimit = 1.0,
const char *const  _title = "",
const char *const  _xLabel = "",
const char *const  _yLabel = "",
PlotMode  _plotMode = PM_UNKNOWN,
double  _yRangeLowerLimit = INFTY,
double  _yRangeUpperLimit = INFTY 
)

Constructor which takes ...

Definition at line 260 of file plot_window_subplot.cpp.

Copy constructor (deep copy).

Parameters:
[in]rhsRight-hand side object.

Definition at line 304 of file plot_window_subplot.cpp.

Destructor.

Definition at line 364 of file plot_window_subplot.cpp.


Member Function Documentation

Adds an additional discrete data points to be plotted within the subplot.

Parameters:
[in]_newDataAdditional discrete data points.
Returns:
SUCCESSFUL_RETURN

Definition at line 492 of file plot_window_subplot.cpp.

returnValue PlotWindowSubplot::addLine ( double  _lineValue)

Adds an additional horizontal lines to be plotted within the subplot.

Parameters:
[in]_lineValueY-value of the additional horizontal line.
Returns:
SUCCESSFUL_RETURN

Definition at line 481 of file plot_window_subplot.cpp.

Returns pointer to next SubPlotWindow within a PlotWindow.

Returns:
Pointer to next subplot (or NULL iff subplot is terminal element).
uint PlotWindowSubplot::getNumData ( ) const [inline]

Returns number of additional discrete data grids of the subplot.

Returns:
Number of additional discrete data grids

Returns number of additional horizontal lines of the subplot.

Returns:
Number of additional horizontal lines

Returns name of pre-defined information to be plotted in the subplot.

Returns:
Name of pre-defined information to be plotted

Returns current plot format of the subplot.

Returns:
Current plot format

Returns current plot mode of the subplot.

Returns:
Current plot mode
returnValue PlotWindowSubplot::getRanges ( double &  _xRangeLowerLimit,
double &  _xRangeUpperLimit,
double &  _yRangeLowerLimit,
double &  _yRangeUpperLimit 
) const [inline]

Returns current ranges of the axes of the subplot.

Parameters:
[out]_xRangeLowerLimitCurrent lower limit of the x-axis.
[out]_xRangeUpperLimitCurrent upper limit of the x-axis.
[out]_yRangeLowerLimitCurrent lower limit of the y-axis.
[out]_yRangeUpperLimitCurrent upper limit of the y-axis.
Returns:
SUCCESSFUL_RETURN

Returns internal type of the subplot.

Returns:
Internal type of the subplot
returnValue PlotWindowSubplot::getTitle ( std::string &  _title) [inline]

Returns current title of the subplot.

Parameters:
[out]_titleCurrent title.
Returns:
SUCCESSFUL_RETURN
returnValue PlotWindowSubplot::getXLabel ( std::string &  _xLabel) [inline]

Returns current label of x-axis of the subplot.

Parameters:
[out]_xLabelCurrent label of x-axis.
Returns:
SUCCESSFUL_RETURN

Returns pointer to the expression on the x-axis of the subplot.

Returns:
Pointer to the expression on the x-axis of the subplot.

Returns type of the variable on the x-axis of the subplot.

Returns:
Type of the variable on the x-axis
returnValue PlotWindowSubplot::getYLabel ( std::string &  _yLabel) [inline]

Returns current label of y-axis of the subplot.

Parameters:
[out]_yLabelCurrent label of y-axis.
Returns:
SUCCESSFUL_RETURN

Returns pointer to the expression on the y-axis of the subplot.

Returns:
Pointer to the expression on the y-axis of the subplot.

Returns type of the variable on the y-axis of the subplot.

Returns:
Type of the variable on the x-axis
PlotWindowSubplot & PlotWindowSubplot::operator= ( const PlotWindowSubplot rhs)

Assignment operator (deep copy).

Parameters:
[in]rhsRight-hand side object.

Definition at line 393 of file plot_window_subplot.cpp.

Assigns pointer to next SubPlotWindow within a PlotWindow.

Parameters:
[in]_nextNew pointer to next item.
Returns:
SUCCESSFUL_RETURN

Sets plot format of the axes of the subplot.

Parameters:
[in]_plotFormatNew plot format, see the PlotFormat documentation for details.
Returns:
SUCCESSFUL_RETURN

Sets plot mode of the subplot, defining how the data points are to be plotted.

Parameters:
[in]_plotModeNew plot mode, see the PlotMode documentation for details.
Returns:
SUCCESSFUL_RETURN
returnValue PlotWindowSubplot::setRanges ( double  _xRangeLowerLimit,
double  _xRangeUpperLimit,
double  _yRangeLowerLimit,
double  _yRangeUpperLimit 
) [inline]

Sets ranges of the axes of the subplot.

Parameters:
[in]_xRangeLowerLimitLower limit of the x-axis.
[in]_xRangeUpperLimitUpper limit of the x-axis.
[in]_yRangeLowerLimitLower limit of the y-axis.
[in]_yRangeUpperLimitUpper limit of the y-axis.
Returns:
SUCCESSFUL_RETURN,
RET_INVALID_ARGUMENTS
returnValue PlotWindowSubplot::setTitle ( const std::string &  _title) [inline]

Sets title of the subplot.

Parameters:
[in]_titleNew title.
Returns:
SUCCESSFUL_RETURN
returnValue PlotWindowSubplot::setXLabel ( const std::string &  _xLabel) [inline]

Sets label of x-axis of the subplot.

Parameters:
[in]_xLabelNew label of x-axis.
Returns:
SUCCESSFUL_RETURN
returnValue PlotWindowSubplot::setYLabel ( const std::string &  _yLabel) [inline]

Sets label of y-axis of the subplot.

Parameters:
[in]_yLabelNew label of y-axis.
Returns:
SUCCESSFUL_RETURN

Friends And Related Function Documentation

friend class GnuplotWindow [friend]

Definition at line 67 of file plot_window_subplot.hpp.


Member Data Documentation

Values of additional discrete data points to be plotted.

Definition at line 441 of file plot_window_subplot.hpp.

double* PlotWindowSubplot::lineValues [protected]

Values of additional horizontal lines to be plotted.

Definition at line 438 of file plot_window_subplot.hpp.

Number of additional discrete data points to be plotted.

Definition at line 440 of file plot_window_subplot.hpp.

Pointer to next subplot within a PlotWindow.

Definition at line 443 of file plot_window_subplot.hpp.

Number of additional horizontal lines to be plotted.

Definition at line 437 of file plot_window_subplot.hpp.

Flag indicating whether data is to be plotted in 3D.

Definition at line 435 of file plot_window_subplot.hpp.

Pre-defined information to be plotted (on y-axis).

Definition at line 421 of file plot_window_subplot.hpp.

Continuous expression on x-axis to be plotted.

Definition at line 419 of file plot_window_subplot.hpp.

Continuous expression on x-axis to be plotted.

Definition at line 420 of file plot_window_subplot.hpp.

Plot format of the axes of the subplot.

Definition at line 428 of file plot_window_subplot.hpp.

Plot mode defining how the data points are to be plotted.

Definition at line 427 of file plot_window_subplot.hpp.

Discrete data to be plotted (time on x-axis, data on y-axis).

Definition at line 418 of file plot_window_subplot.hpp.

Continuous variable on x-axis to be plotted.

Definition at line 416 of file plot_window_subplot.hpp.

Continuous variable on y-axis to be plotted.

Definition at line 417 of file plot_window_subplot.hpp.

std::string PlotWindowSubplot::title [protected]

Title of the subplot.

Definition at line 423 of file plot_window_subplot.hpp.

std::string PlotWindowSubplot::xLabel [protected]

Label of x-axis of the subplot.

Definition at line 424 of file plot_window_subplot.hpp.

Lower limit of the x-axis.

Definition at line 430 of file plot_window_subplot.hpp.

Upper limit of the x-axis.

Definition at line 431 of file plot_window_subplot.hpp.

std::string PlotWindowSubplot::yLabel [protected]

Label of y-axis of the subplot.

Definition at line 425 of file plot_window_subplot.hpp.

Lower limit of the y-axis.

Definition at line 432 of file plot_window_subplot.hpp.

Upper limit of the y-axis.

Definition at line 433 of file plot_window_subplot.hpp.


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


acado
Author(s): Milan Vukov, Rien Quirynen
autogenerated on Sat Jun 8 2019 19:40:25