|
Laura++
3.6.0
A maximum likelihood fitting package for performing Dalitz-plot analysis.
|
Class for defining a 2D cubic spline based on an input histogram.
More...
#include <Lau2DCubicSpline.hh>
|
enum | { NCoeff = 16,
CoeffRecLen = 17
} |
| Length of coefficient record in array.
|
|
|
| Lau2DCubicSpline (const Lau2DCubicSpline &rhs) |
| Copy constructor - not implemented.
|
|
Lau2DCubicSpline & | operator= (const Lau2DCubicSpline &rhs) |
| Copy assignment operator - not implemented.
|
|
Double_t | histcont (const TH2 &h, Int_t xbin, Int_t ybin) const |
| Get contents of a given bin from a histogram. More...
|
|
Double_t | dhistdx (const TH2 &h, Int_t xbin, Int_t ybin) const |
| Get d/dx finite difference in a given bin from a histogram. More...
|
|
Double_t | dhistdy (const TH2 &h, Int_t xbin, Int_t ybin) const |
| Get d/dy finite difference in a given bin from a histogram. More...
|
|
Double_t | d2histdxdy (const TH2 &h, Int_t xbin, Int_t ybin) const |
| Get d^2/dydx finite difference in a given bin from a histogram. More...
|
|
const Double_t & | coeff (Int_t binx, Int_t biny, Int_t theCoeff) const |
| Const access to coefficients. More...
|
|
Double_t & | coeff (Int_t binx, Int_t biny, Int_t theCoeff) |
| Access to coefficients. More...
|
|
Double_t | evalX (Double_t x1, Double_t x2, Double_t y) const |
| Evaluate integral over x at a given y from (x1, y) to (x2, y) More...
|
|
Double_t | evalY (Double_t x, Double_t y1, Double_t y2) const |
| Evaluate integral over y at a given x from (x, y1) to (x, y2) More...
|
|
Double_t | evalXY (Double_t x1, Double_t x2, Double_t y1, Double_t y2) const |
| Evaluate integral over x and y from (x1, y1) to (x2, y2) More...
|
|
|
Int_t | nBinsX |
| Number of bins in x axis.
|
|
Int_t | nBinsY |
| Number of bins in y axis.
|
|
Double_t | binSizeX |
| Bin size in x.
|
|
Double_t | binSizeY |
| Bin size in y.
|
|
Double_t | xmin |
| Minimum x value.
|
|
Double_t | xmax |
| Maximum x value.
|
|
Double_t | ymin |
| Minimum y value.
|
|
Double_t | ymax |
| Maximum y value.
|
|
std::vector< Double_t > | coeffs |
| Coefficients of interpolation polynomials.
|
|
Class for defining a 2D cubic spline based on an input histogram.
Class for defining a 2D cubic spline based on RooBinned2DBicubicBase by Manuel Tobias Schiller manue.nosp@m.l.sc.nosp@m.hille.nosp@m.r@ni.nosp@m.khef..nosp@m.nl (2012-08-29).
Smoothly interpolate between bin midpoints of a 2D histogram with equal-sized bins
The interpolation function coincides with the saved histogram values in bin midpoints; a cubic interpolation polynomial is used. Bins must all have the same size. The interpolation polynomial in a "cell" between four bin midpoints is:
The coefficients are determined by the requirement that function value, first derivatives and the mixed second derivative must agree with that of the binned function at the four bin midpoints at the edges of the cell. Symmetric finite differences are used to approximate these derivatives.
For each cell, the coefficients are determined at constuction time. The object also keeps a cache of 2D integrals over complete cells, such that 2D integrations can be done analytically in a reasonably short amount of time.
Definition at line 65 of file Lau2DCubicSpline.hh.
◆ Lau2DCubicSpline()
Lau2DCubicSpline::Lau2DCubicSpline |
( |
const TH2 & |
h | ) |
|
◆ analyticalIntegral()
Double_t Lau2DCubicSpline::analyticalIntegral |
( |
Double_t |
x1, |
|
|
Double_t |
x2, |
|
|
Double_t |
y1, |
|
|
Double_t |
y2 |
|
) |
| const |
|
virtual |
Evaluate analytical integral in x, y, or x and y.
- Parameters
-
[in] | x1 | the lower x limit |
[in] | x2 | the upper x limit |
[in] | y1 | the lower y limit |
[in] | y2 | the upper y limit |
Definition at line 217 of file Lau2DCubicSpline.cc.
◆ coeff() [1/2]
Double_t& Lau2DCubicSpline::coeff |
( |
Int_t |
binx, |
|
|
Int_t |
biny, |
|
|
Int_t |
theCoeff |
|
) |
| |
|
inlineprivate |
Access to coefficients.
- Parameters
-
[in] | binx | the x bin index |
[in] | biny | the y bin index |
[in] | theCoeff | the coefficient index |
- Returns
- the coefficient
Definition at line 191 of file Lau2DCubicSpline.hh.
◆ coeff() [2/2]
const Double_t& Lau2DCubicSpline::coeff |
( |
Int_t |
binx, |
|
|
Int_t |
biny, |
|
|
Int_t |
theCoeff |
|
) |
| const |
|
inlineprivate |
Const access to coefficients.
- Parameters
-
[in] | binx | the x bin index |
[in] | biny | the y bin index |
[in] | theCoeff | the coefficient index |
- Returns
- the coefficient
Definition at line 179 of file Lau2DCubicSpline.hh.
◆ d2histdxdy()
Double_t Lau2DCubicSpline::d2histdxdy |
( |
const TH2 & |
h, |
|
|
Int_t |
xbin, |
|
|
Int_t |
ybin |
|
) |
| const |
|
inlineprivate |
Get d^2/dydx finite difference in a given bin from a histogram.
- Parameters
-
[in] | h | the histogram |
[in] | xbin | the x bin index |
[in] | ybin | the y bin index |
- Returns
- the d^2/dydx finite difference
Definition at line 74 of file Lau2DCubicSpline.cc.
◆ dhistdx()
Double_t Lau2DCubicSpline::dhistdx |
( |
const TH2 & |
h, |
|
|
Int_t |
xbin, |
|
|
Int_t |
ybin |
|
) |
| const |
|
inlineprivate |
Get d/dx finite difference in a given bin from a histogram.
- Parameters
-
[in] | h | the histogram |
[in] | xbin | the x bin index |
[in] | ybin | the y bin index |
- Returns
- the d/dx finite difference
Definition at line 64 of file Lau2DCubicSpline.cc.
◆ dhistdy()
Double_t Lau2DCubicSpline::dhistdy |
( |
const TH2 & |
h, |
|
|
Int_t |
xbin, |
|
|
Int_t |
ybin |
|
) |
| const |
|
inlineprivate |
Get d/dy finite difference in a given bin from a histogram.
- Parameters
-
[in] | h | the histogram |
[in] | xbin | the x bin index |
[in] | ybin | the y bin index |
- Returns
- the d/dy finite difference
Definition at line 69 of file Lau2DCubicSpline.cc.
◆ evaluate()
Double_t Lau2DCubicSpline::evaluate |
( |
Double_t |
x, |
|
|
Double_t |
y |
|
) |
| const |
|
virtual |
Evaluate the function at given point.
- Parameters
-
[in] | x | the x co-ordinate |
[in] | y | the y co-ordinate |
Definition at line 185 of file Lau2DCubicSpline.cc.
◆ evalX()
Double_t Lau2DCubicSpline::evalX |
( |
Double_t |
x1, |
|
|
Double_t |
x2, |
|
|
Double_t |
y |
|
) |
| const |
|
private |
Evaluate integral over x at a given y from (x1, y) to (x2, y)
- Parameters
-
[in] | x1 | lower x limit |
[in] | x2 | upper x limit |
[in] | y | y value |
- Returns
- integral over x
Definition at line 226 of file Lau2DCubicSpline.cc.
◆ evalXY()
Double_t Lau2DCubicSpline::evalXY |
( |
Double_t |
x1, |
|
|
Double_t |
x2, |
|
|
Double_t |
y1, |
|
|
Double_t |
y2 |
|
) |
| const |
|
private |
Evaluate integral over x and y from (x1, y1) to (x2, y2)
- Parameters
-
[in] | x1 | lower x limit |
[in] | x2 | upper x limit |
[in] | y1 | lower y limit |
[in] | y2 | upper y limit |
- Returns
- integral over x and y
Definition at line 312 of file Lau2DCubicSpline.cc.
◆ evalY()
Double_t Lau2DCubicSpline::evalY |
( |
Double_t |
x, |
|
|
Double_t |
y1, |
|
|
Double_t |
y2 |
|
) |
| const |
|
private |
Evaluate integral over y at a given x from (x, y1) to (x, y2)
- Parameters
-
[in] | x | x value |
[in] | y1 | lower y limit |
[in] | y2 | upper y limit |
- Returns
- integral over y
Definition at line 269 of file Lau2DCubicSpline.cc.
◆ histcont()
Double_t Lau2DCubicSpline::histcont |
( |
const TH2 & |
h, |
|
|
Int_t |
xbin, |
|
|
Int_t |
ybin |
|
) |
| const |
|
inlineprivate |
Get contents of a given bin from a histogram.
- Parameters
-
[in] | h | the histogram |
[in] | xbin | the x bin index |
[in] | ybin | the y bin index |
- Returns
- the bin contents
Definition at line 45 of file Lau2DCubicSpline.cc.
The documentation for this class was generated from the following files:
|