// ETrackGenerator.hpp #ifndef ETrackGenerator_H #define ETrackGenerator_H // Generates ETrack objects with parameters drawn randomly // from a flat distribution in the parameter space. // The track surface and the ranges for the parameters are // specified in the constructor. #include "trfbase/VTrackGenerator.h" #include "trfbase/Surface.h" #include "trfbase/SurfacePtr.h" #include "trfutil/RandomGenerator.h" #include "trfbase/TrackVector.h" #include "trfbase/VTrack.h" #include "trfbase/ETrack.h" #include "trffit/HTrackGenerator.h" #include "trfbase/HitGenerator.h" #include "ETrackGeneratorLimits.hpp" // class ETrack; class ETrackGenerator : public trf::VTrackGenerator { private: // attributes // min and max values for each parameter. trf::TrackError _emin,_emax; public: // constructors // ...with quick and easy limits ETrackGenerator(const trf::SurfacePtr srf, const ETrackGeneratorLimits etgLimits); // ...with manual limits, but otherwise as above ETrackGenerator(const trf::SurfacePtr srf, const trf::TrackVector& min, const trf::TrackVector& max, const trf::TrackError& emin, const trf::TrackError& emax); // note that only the diagonals of the TrackError matrix // will limit the result, the off-diagonals will be functions // of the diagonals. // destructor ~ETrackGenerator() {}; // Generate a new track. User must delete. trf::ETrack* new_track(); }; using std::sqrt; // needed for error matrix generation #endif