3 #include <utl/ErrorLogger.h>
16 namespace MdLDFFinderAG
24 siteCS = det::Detector::GetInstance().GetSiteCoordinateSystem();
31 double nLogLikelihood = 0;
39 return nLogLikelihood;
49 std::ostringstream info(
"");
53 double nLogLikelihood = 0;
64 const double xcore = par[2];
65 const double ycore = par[3];
72 const mdet::MDetector& mDetector = det::Detector::GetInstance().GetMDetector();
79 unsigned int counterId = co->
GetId();
85 if(!im->IsCandidate()) {
89 unsigned int moduleId = im->
GetId();
92 const double moduleArea = im->GetRecData().GetActiveArea();
97 size_t activeChannels = im->GetNumberOfActiveChannels();
98 const utl::TraceUI& channelsOn = im->GetRecData().GetChannelsOn();
101 const double muonDensity = (*fLDFunction)( coreDistance, &par[0] );
102 const double predictedMuons = muonDensity * moduleArea *
cosTheta;
119 ProfLike nLogLike1(activeChannels,channelsOn);
122 const double nLogLikelihood1 = nLogLike1(predictedMuons);
125 nLogLikelihood += nLogLikelihood1;
141 return nLogLikelihood;
const Module & GetModule(const int mId) const
Retrieve by id a constant module.
unsigned int fSilentLimit
double CalculateCandidateLikelihood(const std::vector< double > &par) const
CounterList fCandidateCounters
Counter level event data.
double operator()(const std::vector< double > &par) const
Perform the actual count.
double DistanceInShowerPlane(const utl::Vector v) const
utl::Point GetPosition() const
Detector associated to muon detector hierarchy.
utl::CoordinateSystemPtr siteCS
const VLDFFunctor * fLDFunction
ModuleConstIterator ModulesBegin() const
Common interface for functors performing the muon LDF fitting.
double CalculateSilentLikelihood(const std::vector< double > &par) const
Likelihood of silent counters.
Root detector of the muon detector hierarchy.
int GetId() const
The id of the counter.
ModuleConstIterator ModulesEnd() const
Template class for a FADC data or calibrated data container. Use the typedefs (TraceD, TraceI, etc.) defined in Trace-fwd.h.
int GetId() const
The id of this component.
const Counter & GetCounter(int id) const
Retrieve Counter by id.
Likelihood2(const VLDFFunctor *ldfFnc, bool useSil, unsigned int silLim)
Creates the likelihood.