20#ifndef jkqtpgraphsevaluatedfunction_H
21#define jkqtpgraphsevaluatedfunction_H
28#include "jkqtplotter/graphs/jkqtpscatter.h"
29#include "jkqtplotter/jkqtpgraphsbasestylingmixins.h"
30#include "jkqtplotter/jkqtplotter_imexport.h"
31#include "jkqtcommon/jkqtpgeometrytools.h"
32#include "jkqtplotter/graphs/jkqtpevaluatedfunctionbase.h"
327 virtual bool getXMinMax(
double& minx,
double& maxx,
double& smallestGreaterZero)
override;
329 virtual bool getYMinMax(
double& miny,
double& maxy,
double& smallestGreaterZero)
override;
378 virtual bool getXMinMax(
double& minx,
double& maxx,
double& smallestGreaterZero)
override;
380 virtual bool getYMinMax(
double& miny,
double& maxy,
double& smallestGreaterZero)
override;
base class for 2D plotter classes (used by the plotter widget JKQTPlotter)
Definition jkqtpbaseplotter.h:394
this class extends the QPainter
Definition jkqtpenhancedpainter.h:33
JKQTPEvaluatedFunctionWithErrorsGraphBase(JKQTBasePlotter *parent=nullptr)
class constructor
bool drawErrorLines
indicates whether error lines should be drawn
Definition jkqtpevaluatedfunction.h:118
void drawYGraph(JKQTPEnhancedPainter &painter)
plots the graph to the plotter object specified as parent
virtual void setErrorLineColor(const QColor &__value)
color of the error graph
virtual void drawKeyMarker(JKQTPEnhancedPainter &painter, const QRectF &rect) override
plots a key marker inside the specified rectangle rect
virtual void setErrorLineWidth(double __value)
width (pixels) of the error graph
virtual ~JKQTPEvaluatedFunctionWithErrorsGraphDrawingBase() override
class destructor
void drawXGraph(JKQTPEnhancedPainter &painter)
plots the graph to the plotter object specified as parent
virtual QColor getErrorLineColor() const
color of the error graph
double errorLineWidth
width (pixels) of the error graph
Definition jkqtpevaluatedfunction.h:129
virtual QColor getKeyLabelColor() const override
returns the color to be used for the key label
JKQTPEvaluatedFunctionWithErrorsGraphDrawingBase(JKQTBasePlotter *parent=nullptr)
class constructor
Qt::BrushStyle errorFillStyle
fill style, if the error curve should be filled
Definition jkqtpevaluatedfunction.h:131
virtual Qt::PenStyle getErrorLineStyle() const
linestyle of the error graph lines
QColor errorColor
color of the error graph
Definition jkqtpevaluatedfunction.h:123
void setDrawErrorLines(bool __value)
indicates whether error lines should be drawn
QPen getErrorLinePen(JKQTPEnhancedPainter &painter) const
Qt::PenStyle errorStyle
linestyle of the error graph lines
Definition jkqtpevaluatedfunction.h:127
virtual void setErrorFillStyle(Qt::BrushStyle __value)
fill style, if the error curve should be filled
virtual void setErrorFillColor(const QColor &__value)
color of the error graph fill
virtual void setErrorLineStyle(Qt::PenStyle __value)
linestyle of the error graph lines
bool getDrawErrorPolygons() const
indicates whether an error polygon should be drawn
bool getDrawErrorLines() const
indicates whether error lines should be drawn
void setDrawErrorPolygons(bool __value)
indicates whether an error polygon should be drawn
bool drawErrorPolygons
indicates whether an error polygon should be drawn
Definition jkqtpevaluatedfunction.h:116
virtual Qt::BrushStyle getErrorFillStyle() const
fill style, if the error curve should be filled
void setColor(QColor c)
set color, fill color and error color at the same time
JKQTPEvaluatedFunctionWithErrorsGraphDrawingBase(JKQTPlotter *parent)
class constructor
QColor errorFillColor
color of the error graph fill
Definition jkqtpevaluatedfunction.h:125
QBrush getErrorBrush(JKQTPEnhancedPainter &painter) const
virtual double getErrorLineWidth() const
width (pixels) of the error graph
virtual QColor getErrorFillColor() const
color of the error graph fill
virtual void setPlotFunctionFunctor(jkqtpSimplePlotFunctionType &&__value)
sets a functor to be plotted
jkqtpSimplePlotFunctionType errorSimplePlotFunction
this function calculates the error at a given position, simplified form without parameters
Definition jkqtpevaluatedfunction.h:271
jkqtpSimplePlotFunctionType simplePlotFunction
a simple function to be plotted, simplified form without parameters
Definition jkqtpevaluatedfunction.h:265
virtual jkqtpSimplePlotFunctionType getErrorSimplePlotFunction() const
this function calculates the error at a given position, simplified form without parameters
JKQTPFunctorLineGraphBase(const jkqtpSimplePlotFunctionType &f, const QString &title, JKQTBasePlotter *parent=nullptr)
class constructor
virtual void setPlotFunctionFunctor(jkqtpPlotFunctionType &&__value)
sets a functor to be plotted
virtual void setErrorPlotFunction(jkqtpSimplePlotFunctionType &&__value)
sets a functor to be used for calculating errors
void setSpecialFunction(SpecialFunction function)
sets function to the given special function
bool isSimplePlotFunction() const
returns whether the plot function was defined as a jkqtpSimpleParametricCurveFunctionType (true ) or ...
JKQTPFunctorLineGraphBase(SpecialFunction type, const QVector< double > ¶ms, const QString &title, JKQTPlotter *parent)
class constructor
virtual void setPlotFunctionFunctor(const jkqtpSimplePlotFunctionType &__value)
sets a functor to be plotted
virtual void setErrorPlotFunction(const jkqtpPlotFunctionType &__value)
sets a functor to be used for calculating errors
SpecialFunction
Definition jkqtpevaluatedfunction.h:170
@ PowerLaw
an exponential function or or (depending on the number of parameters) The parameters params have t...
Definition jkqtpevaluatedfunction.h:174
@ Line
a polynomial The parameters params have to be point to a QVector<double> and contain the parameters
Definition jkqtpevaluatedfunction.h:172
@ Exponential
an exponential function or (depending on the number of parameters). The parameters params have to b...
Definition jkqtpevaluatedfunction.h:173
@ Polynomial
a polynomial The parameters params have to be point to a QVector<double> and contain the parameters
Definition jkqtpevaluatedfunction.h:171
JKQTPFunctorLineGraphBase(jkqtpSimplePlotFunctionType &&f, const QString &title, JKQTBasePlotter *parent=nullptr)
class constructor
virtual void setPlotFunctionFunctor(const jkqtpPlotFunctionType &__value)
sets a functor to be plotted
JKQTPFunctorLineGraphBase(JKQTBasePlotter *parent=nullptr)
class constructor
jkqtpPlotFunctionType plotFunction
the function to be plotted
Definition jkqtpevaluatedfunction.h:263
virtual ~JKQTPFunctorLineGraphBase() override
class destructor
virtual jkqtpSimplePlotFunctionType getSimplePlotFunction() const
a simple function to be plotted, simplified form without parameters
virtual void setErrorPlotFunction(const jkqtpSimplePlotFunctionType &__value)
sets a functor to be used for calculating errors
JKQTPFunctorLineGraphBase(jkqtpSimplePlotFunctionType &&f, const QString &title, JKQTPlotter *parent)
class constructor
virtual void setErrorPlotFunction(jkqtpPlotFunctionType &&__value)
sets a functor to be used for calculating errors
virtual jkqtpPlotFunctionType getPlotFunctionFunctor() const
the function to be plotted
JKQTPFunctorLineGraphBase(JKQTPlotter *parent)
class constructor
JKQTPFunctorLineGraphBase(SpecialFunction type, const QVector< double > ¶ms, const QString &title, JKQTBasePlotter *parent)
class constructor
jkqtpPlotFunctionType errorPlotFunction
this function calculates the error at a given position
Definition jkqtpevaluatedfunction.h:269
virtual jkqtpPlotFunctionType getErrorPlotFunction() const
this function calculates the error at a given position
JKQTPFunctorLineGraphBase(const jkqtpSimplePlotFunctionType &f, const QString &title, JKQTPlotter *parent)
class constructor
JKQTPGraphLineAndFillStyleMixin()
class constructor
JKQTBasePlotter * parent
the plotter object this object belongs to
Definition jkqtpgraphsbase.h:386
QString title
title of the plot (for display in key!). If no title is supplied, no key entry is drawn.
Definition jkqtpgraphsbase.h:121
JKQTPXFunctionLineGraph(SpecialFunction type, const QVector< double > ¶ms, const QString &title, JKQTBasePlotter *parent)
class constructor
virtual ~JKQTPXFunctionLineGraph() override
class destructor
virtual PlotFunctorSpec buildPlotFunctorSpec() override
this function returns a functor that is used to generate the plot data in coordinate space,...
JKQTPXFunctionLineGraph(JKQTPlotter *parent)
class constructor
JKQTPXFunctionLineGraph(const jkqtpSimplePlotFunctionType &f, const QString &title, JKQTPlotter *parent)
class constructor
JKQTPXFunctionLineGraph(JKQTBasePlotter *parent=nullptr)
class constructor
virtual bool getYMinMax(double &miny, double &maxy, double &smallestGreaterZero) override
get the maximum and minimum y-value of the graph
virtual void draw(JKQTPEnhancedPainter &painter) override
plots the graph to the plotter object specified as parent
JKQTPXFunctionLineGraph(jkqtpSimplePlotFunctionType &&f, const QString &title, JKQTPlotter *parent)
class constructor
JKQTPXFunctionLineGraph(jkqtpSimplePlotFunctionType &&f, const QString &title, JKQTBasePlotter *parent=nullptr)
class constructor
JKQTPXFunctionLineGraph(SpecialFunction type, const QVector< double > ¶ms, const QString &title, JKQTPlotter *parent)
class constructor
JKQTPXFunctionLineGraph(const jkqtpSimplePlotFunctionType &f, const QString &title, JKQTBasePlotter *parent=nullptr)
class constructor
virtual std::function< QPointF(double)> buildErrorFunctorSpec() override
this function returns a functor that is used to generate the plot data in coordinate space,...
virtual bool getXMinMax(double &minx, double &maxx, double &smallestGreaterZero) override
get the maximum and minimum x-value of the graph
virtual void draw(JKQTPEnhancedPainter &painter) override
plots the graph to the plotter object specified as parent
virtual bool getXMinMax(double &minx, double &maxx, double &smallestGreaterZero) override
get the maximum and minimum x-value of the graph
virtual std::function< QPointF(double)> buildErrorFunctorSpec() override
this function returns a functor that is used to generate the plot data in coordinate space,...
JKQTPYFunctionLineGraph(const jkqtpSimplePlotFunctionType &f, const QString &title, JKQTPlotter *parent)
class constructor
JKQTPYFunctionLineGraph(jkqtpSimplePlotFunctionType &&f, const QString &title, JKQTBasePlotter *parent=nullptr)
class constructor
JKQTPYFunctionLineGraph(JKQTBasePlotter *parent=nullptr)
class constructor
JKQTPYFunctionLineGraph(SpecialFunction type, const QVector< double > ¶ms, const QString &title, JKQTBasePlotter *parent)
class constructor
virtual PlotFunctorSpec buildPlotFunctorSpec() override
this function returns a functor that is used to generate the plot data in coordinate space,...
JKQTPYFunctionLineGraph(JKQTPlotter *parent)
class constructor
virtual bool getYMinMax(double &miny, double &maxy, double &smallestGreaterZero) override
get the maximum and minimum y-value of the graph
JKQTPYFunctionLineGraph(jkqtpSimplePlotFunctionType &&f, const QString &title, JKQTPlotter *parent)
class constructor
JKQTPYFunctionLineGraph(SpecialFunction type, const QVector< double > ¶ms, const QString &title, JKQTPlotter *parent)
class constructor
JKQTPYFunctionLineGraph(const jkqtpSimplePlotFunctionType &f, const QString &title, JKQTBasePlotter *parent=nullptr)
class constructor
plotter widget for scientific plots (uses JKQTBasePlotter to do the actual drawing)
Definition jkqtplotter.h:374
std::function< double(double)> jkqtpSimplePlotFunctionType
simplified type of functions (without parameters) that may be plotted by JKQTPXFunctionLineGraph and ...
Definition jkqtpevaluatedfunction.h:157
std::function< double(double, const QVector< double > &)> jkqtpPlotFunctionType
type of functions that may be plotted by JKQTPXFunctionLineGraph and JKQTPYFunctionLineGraph
Definition jkqtpevaluatedfunction.h:149
#define JKQTPLOTTER_LIB_EXPORT
Definition jkqtplotter_imexport.h:89
specifies an internal plot functor
Definition jkqtpevaluatedfunctionbase.h:152