mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-01-19 00:37:25 +01:00
25 lines
700 B
C++
25 lines
700 B
C++
#ifndef REGRESSION_CUBIC_MODEL_H
|
|
#define REGRESSION_CUBIC_MODEL_H
|
|
|
|
#include "model.h"
|
|
|
|
namespace Regression {
|
|
|
|
class CubicModel : public Model {
|
|
public:
|
|
using Model::Model;
|
|
Poincare::Layout layout() override;
|
|
I18n::Message formulaMessage() const override { return I18n::Message::CubicRegressionFormula; }
|
|
double evaluate(double * modelCoefficients, double x) const override;
|
|
double partialDerivate(double * modelCoefficients, int derivateCoefficientIndex, double x) const override;
|
|
int numberOfCoefficients() const override { return 4; }
|
|
int bannerLinesCount() const override { return 4; }
|
|
private:
|
|
Poincare::Expression expression(double * modelCoefficients) override;
|
|
};
|
|
|
|
}
|
|
|
|
|
|
#endif
|