#ifndef _OmegaPiLh_H #define _OmegaPiLh_H #include <iostream> #include <fstream> #include <string> #include <vector> #include <complex> #include <cassert> #include <boost/shared_ptr.hpp> #include <boost/archive/text_oarchive.hpp> #include <boost/archive/text_iarchive.hpp> #include <boost/serialization/vector.hpp> #include "TROOT.h" // #include <TSystem.h> #include "qft++/topincludes/relativistic-quantum-mechanics.hh" #include "Examples/MATpbarpToOmegaPi/OmegaPiData.hh" #include "Examples/MATpbarpToOmegaPi/OmegaPiEventList.hh" #include "PwaUtils/DataUtils.hh" // using namespace std; class OmegaPiEventList; class pbarpToOmegaPi0States; class OmegaPiLh { friend class boost::serialization::access; template<typename Archive> void serialize(Archive & ar, const unsigned int) { using boost::serialization::make_nvp; //ar & make_nvp("omegaPiEventListPtr",_omegaPiEventListPtr); //ar & make_nvp("omegaPi0StatesPtr",_omegaPi0StatesPtr); //ar & make_nvp("evtDataVec",_evtDataVec); //ar & make_nvp("evtMCVec",_evtMCVec); } public: // create/copy/destroy: ///Constructor OmegaPiLh(boost::shared_ptr<pbarpToOmegaPi0States>); OmegaPiLh(boost::shared_ptr<OmegaPiLh>); /** Destructor */ virtual ~OmegaPiLh(); OmegaPiLh* clone_() const { return new OmegaPiLh(_omegaPi0StatesPtr); } // Getters: double calcLogLh(const OmegaPiData::fitParamVal& theParamVal); double calcEvtIntensity(OmegaPiData::OmPiEvtData* theData, const OmegaPiData::fitParamVal& theParamVal); boost::shared_ptr<OmegaPiEventList> getEventList() const {return OmegaPiEventList::getList();} boost::shared_ptr<pbarpToOmegaPi0States> omegaPi0States() const {return _omegaPi0StatesPtr;} void print(std::ostream& os) const; protected: private: OmegaPiLh(); //for serialization only boost::shared_ptr<const OmegaPiEventList> _omegaPiEventListPtr; boost::shared_ptr<pbarpToOmegaPi0States> _omegaPi0StatesPtr; std::vector<OmegaPiData::OmPiEvtData*> _evtDataVec; std::vector<OmegaPiData::OmPiEvtData*> _evtMCVec; complex<double> calcCoherentAmp(Spin lamgamma, Spin Minit, std::map< boost::shared_ptr<const JPCLS>, pair<double, double>, pawian::Collection::SharedPtrLess >& fitParm, OmegaPiData::OmPiEvtData* theData); }; #endif