Example of Chebyshev polynomials using new TFormula pre-defined definitions of chebyshev polynomials
void ChebyshevPol() {
auto legend =
new TLegend(0.88,0.4,1.,1.);
int colors[] = {
kRed,
kRed+3,
kMagenta,
kMagenta+3,
kBlue,
kBlue+3,
kCyan+3,
kGreen,
kGreen+3,
kYellow,
kOrange };
for (int degree=0; degree <=10; ++degree) {
TString opt = (degree == 0) ?
"" :
"same";
}
legend->Draw();
}
virtual void SetLineColor(Color_t lcolor)
Set the line color.
virtual void SetMaximum(Double_t maximum=-1111)
Set the maximum value along Y for this function In case the function is already drawn,...
void SetTitle(const char *title="") override
Set function title if title has the form "fffffff;xxxx;yyyy", it is assumed that the function title i...
virtual void SetNpx(Int_t npx=100)
Set the number of points used to draw the function.
void Draw(Option_t *option="") override
Draw this function with its current attributes.
virtual void SetMinimum(Double_t minimum=-1111)
Set the minimum value along Y for this function In case the function is already drawn,...
virtual void SetParameter(Int_t param, Double_t value)
This class displays a legend box (TPaveText) containing several legend entries.
static TString Format(const char *fmt,...)
Static method which formats a string using a printf style format descriptor and return a TString.
- Author
- Lorenzo Moneta
Definition in file ChebyshevPol.C.