Logo ROOT   6.12/07
Reference Guide
TF12.h
Go to the documentation of this file.
1 // @(#)root/hist:$Id$
2 // Author: Rene Brun 05/04/2003
3 
4 /*************************************************************************
5  * Copyright (C) 1995-2003, Rene Brun and Fons Rademakers. *
6  * All rights reserved. *
7  * *
8  * For the licensing terms see $ROOTSYS/LICENSE. *
9  * For the list of contributors see $ROOTSYS/README/CREDITS. *
10  *************************************************************************/
11 
12 #ifndef ROOT_TF12
13 #define ROOT_TF12
14 
15 //////////////////////////////////////////////////////////////////////////
16 // //
17 // TF12 //
18 // //
19 // Projection of a TF2 along x or y //
20 // //
21 //////////////////////////////////////////////////////////////////////////
22 
23 #include "TF2.h"
24 
25 class TF12 : public TF1 {
26 
27 protected:
28  Double_t fXY; //Value along Y (if projection X) or X (if projection Y)
29  Int_t fCase; //projection along X(0), or Y(1)
30  TF2 *fF2; //pointer to the mother TF2
31 
32 public:
33  TF12();
34  TF12(const char *name, TF2 *f2, Double_t xy, Option_t *option="x");
35  TF12(const TF12 &f12);
36  virtual ~TF12();
37  virtual void Copy(TObject &f12) const;
38  virtual TF1 *DrawCopy(Option_t *option="") const;
39  virtual Double_t Eval(Double_t x, Double_t y=0, Double_t z=0, Double_t t=0) const;
40  virtual Double_t EvalPar(const Double_t *x, const Double_t *params=0);
41 
42 #ifdef R__HAS_VECCORE
43  using TF1::Eval; // to not hide the vectorized version
44  using TF1::EvalPar; // to not hide the vectorized version
45 #endif
46 
47  virtual Double_t GetXY() const {return fXY;}
48  virtual void SavePrimitive(std::ostream &out, Option_t *option = "");
49  virtual void SetXY(Double_t xy); // *MENU*
50 
51  ClassDef(TF12,1) //Projection of a TF2 along x or y
52 };
53 
54 #endif
TF12()
TF12 default constructor.
Definition: TF12.cxx:33
A projection of a TF2 along X or Y.
Definition: TF12.h:25
Double_t fXY
Definition: TF12.h:28
const char Option_t
Definition: RtypesCore.h:62
int Int_t
Definition: RtypesCore.h:41
virtual void SetXY(Double_t xy)
Set the value of the constant for the TF2.
Definition: TF12.cxx:184
virtual Double_t GetXY() const
Definition: TF12.h:47
TF2 * fF2
Definition: TF12.h:30
Double_t x[n]
Definition: legend1.C:17
#define ClassDef(name, id)
Definition: Rtypes.h:320
Int_t fCase
Definition: TF12.h:29
virtual void Copy(TObject &f12) const
Copy this F2 to a new F2.
Definition: TF12.cxx:92
virtual ~TF12()
F2 default destructor.
Definition: TF12.cxx:75
virtual TF1 * DrawCopy(Option_t *option="") const
Draw a copy of this function with its current attributes.
Definition: TF12.cxx:118
XPoint xy[kMAXMK]
Definition: TGX11.cxx:122
A 2-Dim function with parameters.
Definition: TF2.h:29
virtual Double_t Eval(Double_t x, Double_t y=0, Double_t z=0, Double_t t=0) const
Evaluate this function.
Definition: TF1.cxx:1334
double Double_t
Definition: RtypesCore.h:55
Double_t y[n]
Definition: legend1.C:17
Mother of all ROOT objects.
Definition: TObject.h:37
you should not use this method at all Int_t Int_t z
Definition: TRolke.cxx:630
1-Dim function class
Definition: TF1.h:211
virtual Double_t Eval(Double_t x, Double_t y=0, Double_t z=0, Double_t t=0) const
Evaluate this formula.
Definition: TF12.cxx:133
virtual Double_t EvalPar(const Double_t *x, const Double_t *params=0)
Evaluate function with given coordinates and parameters.
Definition: TF1.cxx:1363
char name[80]
Definition: TGX11.cxx:109
virtual void SavePrimitive(std::ostream &out, Option_t *option="")
Save primitive as a C++ statement(s) on output stream out.
Definition: TF12.cxx:170
virtual Double_t EvalPar(const Double_t *x, const Double_t *params=0)
Evaluate this function at point x[0].
Definition: TF12.cxx:151