mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-03-25 08:41:01 +01:00
[apps] Graph: first version of a function minimum finding algorithm
This commit is contained in:
committed by
EmilieNumworks
parent
7077cb4f58
commit
03ebffa09d
@@ -13,8 +13,17 @@ public:
|
||||
void setDisplayDerivative(bool display);
|
||||
double approximateDerivative(double x, Poincare::Context * context) const;
|
||||
double sumBetweenBounds(double start, double end, Poincare::Context * context) const override;
|
||||
struct Point {
|
||||
double abscissa;
|
||||
double value;
|
||||
};
|
||||
Point mininimumBetweenBounds(double start, double end, Poincare::Context * context) const;
|
||||
char symbol() const override;
|
||||
private:
|
||||
constexpr static double k_sqrtEps = 1.4901161193847656E-8; // sqrt(DBL_EPSILON)
|
||||
constexpr static double k_goldenRatio = 0.381966011250105151795413165634361882279690820194237137864; // (3-sqrt(5))/2
|
||||
double bracketFunction(double x, double z, Poincare::Context * context);
|
||||
Point brentAlgorithm(double ax, double bx, Poincare::Context * context) const;
|
||||
bool m_displayDerivative;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user