Chi2ForSphericalWaveFitVarC.h
Go to the documentation of this file.
1 
3 #ifndef _Chi2ForSphericalWaveFitVarC_h_
4 #define _Chi2ForSphericalWaveFitVarC_h_
5 
6 #include <iostream>
7 #include <fstream>
8 #include <vector>
9 #include <TVector3.h>
10 #include <TMath.h>
11 
12 #include <utl/Vector.h>
13 #include <utl/Point.h>
14 #include <utl/TimeStamp.h>
15 #include <utl/PhysicalConstants.h>
16 
17 #include <Math/IFunction.h>
18 
19 
20 
21 class Chi2ForSphericalWaveFitVarC : public ROOT::Math::IBaseFunctionMultiDim
22 {
23 public:
26 
27  // Set Antenna Times and Positions
28  void Set(const std::vector<utl::Vector> &_AntennaPositions, const std::vector<double> &_AntennaTimes, const std::vector<double> &_AntennaTimesError, const utl::CoordinateSystemPtr &_fgLocalCS);
29 
30  void SetSigmaGamma(double _sigma_gamma);
31 
32  // using penalty term in chi squared computation
33  void SetPenalty(bool dP);
34 
35  // Mandatory functions of Clone, NDim ROOT::Math::IBaseFunctionMultiDim:
36  virtual ROOT::Math::IBaseFunctionMultiDim* Clone() const {Chi2ForSphericalWaveFitVarC* foo = new Chi2ForSphericalWaveFitVarC();
38  return foo;};
39  unsigned int NDim() const {int n=4;return n;};
40 
41  // Objective function
42  double DoEval(const double* x) const;
43 
44 private:
45  std::vector<utl::Vector> AntennaPositions;
46  std::vector<double> AntennaTimes;
47  std::vector<double> AntennaTimesError;
49 
50  bool Spherical;
51  bool doPenalty;
53  double sigma_gamma;
54 };
55 
56 #endif
boost::shared_ptr< const CoordinateTransformer > CoordinateSystemPtr
Shared pointer for coordinate systems.
std::vector< utl::Vector > AntennaPositions
virtual ROOT::Math::IBaseFunctionMultiDim * Clone() const
void Set(const std::vector< utl::Vector > &_AntennaPositions, const std::vector< double > &_AntennaTimes, const std::vector< double > &_AntennaTimesError, const utl::CoordinateSystemPtr &_fgLocalCS)
void SetSigmaGamma(double _sigma_gamma)
double DoEval(const double *x) const
Objective function for the spherical wave fit including the speed of light.

, generated on Tue Sep 26 2023.