1.8.0
CCC
 
Loading...
Searching...
No Matches
gstlrn::Chebychev Class Reference

#include <Chebychev.hpp>

Inheritance diagram for gstlrn::Chebychev:
gstlrn::APolynomial gstlrn::AStringable gstlrn::ICloneable

Public Member Functions

 Chebychev ()
 
virtual ~Chebychev ()
 
void evalOp (MatrixSparse *S, const constvect x, vect y) const override
 ICloneable interface.
 
double eval (double x) const override
 
Id fit (const std::function< double(double)> &f, double a=0., double b=1., double tol=EPSILON5) override
 
void init (Id ncMax=10001, Id nDisc=100, double a=0., double b=1., bool verbose=false)
 
void setCoeffs (const 1 &coeffs)
 
Id getNcMax () const
 
Id getNDisc () const
 
double getA () const
 
double getB () const
 
bool getVerbose () const
 
void setA (double a)
 
void setB (double b)
 
void setNcMax (Id ncMax)
 
void setNDisc (Id nDisc)
 
void setVerbose (bool verbose)
 
Id fit2 (AFunction *f, double a=0., double b=1., double tol=EPSILON5)
 
- Public Member Functions inherited from gstlrn::APolynomial
 APolynomial ()
 
 APolynomial (const 1 &coeffs)
 
 APolynomial (const APolynomial &m)
 
APolynomialoperator= (const APolynomial &p)
 
virtual ~APolynomial ()
 
String toString (const AStringFormat *strfmt=nullptr) const override
 Interface for AStringable.
 
void init (const 1 &coeffs)
 
virtual void evalOp (MatrixSparse *Op, const 1 &inv, 1 &outv) const
 
 evalOp (MatrixSparse *Op, const constvect inv) const
 
virtual void evalOpTraining (MatrixSparse *Op, const constvect inv, std::vector< std::vector< double > > &outv, std::vector< double > &work) const
 
virtual double evalOpByRank (MatrixSparse *Op, Id rank) const
 
void addEvalOp (const ALinearOp *Op, const constvect inv, vect outv) const
 
 getCoeffs () const
 
void setCoeffs (const 1 &coeffs)
 
Id getDegree () const
 
- Public Member Functions inherited from gstlrn::AStringable
 AStringable ()
 
 AStringable (const AStringable &r)
 
AStringableoperator= (const AStringable &r)
 
virtual ~AStringable ()
 
virtual void display (const AStringFormat *strfmt=nullptr) const final
 
virtual void display (Id level) const final
 
- Public Member Functions inherited from gstlrn::ICloneable
 ICloneable ()
 
virtual ~ICloneable ()
 
virtual ICloneableclone () const =0
 
std::shared_ptr< ICloneablecloneShared () const
 
std::unique_ptr< ICloneablecloneUnique () const
 

Static Public Member Functions

static ChebychevcreateFromCoeffs (const 1 &coeffs)
 

Constructor & Destructor Documentation

◆ Chebychev()

gstlrn::Chebychev::Chebychev ( )

◆ ~Chebychev()

gstlrn::Chebychev::~Chebychev ( )
virtual

Member Function Documentation

◆ createFromCoeffs()

Chebychev * gstlrn::Chebychev::createFromCoeffs ( const 1 &  coeffs)
static

◆ eval()

double gstlrn::Chebychev::eval ( double  x) const
overridevirtual

Implements gstlrn::APolynomial.

◆ evalOp()

void gstlrn::Chebychev::evalOp ( MatrixSparse S,
const constvect  x,
vect  y 
) const
overridevirtual

ICloneable interface.

Interface for Apolynomial

Implements gstlrn::APolynomial.

◆ fit()

Id gstlrn::Chebychev::fit ( const std::function< double(double)> &  f,
double  a = 0.,
double  b = 1.,
double  tol = EPSILON5 
)
overridevirtual

Reimplemented from gstlrn::APolynomial.

◆ fit2()

Id gstlrn::Chebychev::fit2 ( AFunction f,
double  a = 0.,
double  b = 1.,
double  tol = EPSILON5 
)

◆ getA()

double gstlrn::Chebychev::getA ( ) const
inline

◆ getB()

double gstlrn::Chebychev::getB ( ) const
inline

◆ getNcMax()

Id gstlrn::Chebychev::getNcMax ( ) const
inline

◆ getNDisc()

Id gstlrn::Chebychev::getNDisc ( ) const
inline

◆ getVerbose()

bool gstlrn::Chebychev::getVerbose ( ) const
inline

◆ init()

void gstlrn::Chebychev::init ( Id  ncMax = 10001,
Id  nDisc = 100,
double  a = 0.,
double  b = 1.,
bool  verbose = false 
)

◆ setA()

void gstlrn::Chebychev::setA ( double  a)
inline

◆ setB()

void gstlrn::Chebychev::setB ( double  b)
inline

◆ setCoeffs()

void gstlrn::Chebychev::setCoeffs ( const 1 &  coeffs)
inline

◆ setNcMax()

void gstlrn::Chebychev::setNcMax ( Id  ncMax)
inline

◆ setNDisc()

void gstlrn::Chebychev::setNDisc ( Id  nDisc)
inline

◆ setVerbose()

void gstlrn::Chebychev::setVerbose ( bool  verbose)
inline

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