#ifndef CSRIGFWAKEFUNCTION_HH #define CSRIGFWAKEFUNCTION_HH #include "Solvers/WakeFunction.hh" #include #include class ElementBase; class Filter; class CSRIGFWakeFunction: public WakeFunction { public: CSRIGFWakeFunction(const std::string &name, ElementBase *element, std::vector filters, const unsigned int &N); void apply(PartBunch &bunch); void initialize(const ElementBase * ref); virtual const std::string getType() const; private: void calculateLineDensity(PartBunch & bunch, double meshSpacing); void calculateContributionInside(size_t sliceNumber, double angleOfSlice, double meshSpacing); void calculateContributionAfter(size_t sliceNumber, double angleOfSlice, double meshSpacing); void calculateGreenFunction(PartBunch &bunch, double meshSpacing); double calcPsi(const double &psiInitial, const double &x, const double &Ds) const; std::vector filters_m; LineDensity lineDensity_m; LineDensity dlineDensitydz_m; // Longitudinal CSR field. std::vector Ez_m; // Chi used to calculate the Green's function std::vector Chi_m; // Green's function std::vector Grn_m; // Retarded angle Psi; (for after dipole, Stupakov) std::vector Psi_m; // Start position of CSR wake. double Begin_m; // Start position of equivalent hard edge dipole that approximates actual // dipole. double FieldBegin_m; // Effective length of dipole. double Length_m; // Radius of curvature of effective dipole. double bendRadius_m; std::string bendName_m; double totalBendAngle_m; }; #endif //CSRIGFWAKEFUNCTION_HH