CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
FcnBeamSpotFitPV.h
Go to the documentation of this file.
1 #ifndef FcnBeamSpotFitPV_h_
2 #define FcnBeamSpotFitPV_h_
3 
18 #include "Minuit2/FCNBase.h"
19 
20 #include <vector>
21 
22 class FcnBeamSpotFitPV : public ROOT::Minuit2::FCNBase {
23 public:
24  // constructor from vertex data
25  FcnBeamSpotFitPV(const std::vector<BeamSpotFitPVData>& data);
26  ~FcnBeamSpotFitPV() override {}
27  // additional vertex selection using limits in x, y, z
28  void setLimits(float xmin, float xmax, float ymin, float ymax, float zmin, float zmax);
29  // deltaFcn for definition of the uncertainty
30  double Up() const override { return errorDef_; }
31  // -2lnL value based on vector of parameters
32  double operator()(const std::vector<double>&) const override;
33  // vertex count used for the fit (after selection)
34  unsigned int nrOfVerticesUsed() const;
35 
36 private:
37  const std::vector<BeamSpotFitPVData>& data_; //< vertex data
38  double errorDef_; //< error definition for Minuit
39 
40  float lowerLimits_[3]; //< lower limits for x,y,z
41  float upperLimits_[3]; //< upper limits for x,y,z
42 };
43 #endif
double Up() const override
FcnBeamSpotFitPV(const std::vector< BeamSpotFitPVData > &data)
~FcnBeamSpotFitPV() override
void setLimits(float xmin, float xmax, float ymin, float ymax, float zmin, float zmax)
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:79
unsigned int nrOfVerticesUsed() const
const std::vector< BeamSpotFitPVData > & data_
double operator()(const std::vector< double > &) const override