26 #ifndef CLASSIC_Cyclotron_HH
27 #define CLASSIC_Cyclotron_HH
126 virtual void getDimensions(
double& zBegin,
double& zEnd)
const;
133 void setRfPhi(std::vector<double> f);
134 double getRfPhi(
unsigned int i)
const;
161 virtual double getEScale(
unsigned int i)
const;
163 void setTrimCoils(
const std::vector<TrimCoil*>& trimcoils);
169 virtual double getMinR()
const;
171 virtual double getMaxR()
const;
174 virtual double getMinZ()
const;
176 virtual double getMaxZ()
const;
193 virtual void apply(
const double&
rad,
const double& z,
194 const double& tet_rad,
double& br,
195 double& bt,
double& bz);
203 virtual bool bends()
const;
205 virtual double getRmax()
const;
207 virtual double getRmin()
const;
210 const double& tet_rad,
215 void read(
const double& scaleFactor);
225 void applyTrimCoil (
const double r,
const double z,
const double tet_rad,
double& br,
double& bz);
227 void applyTrimCoil_m(
const double r,
const double z,
const double tet_rad,
double* br,
double* bz);
233 double gutdf5d(
double* f,
double dx,
const int kor,
const int krl,
const int lpr);
235 void initR(
double rmin,
double dr,
int nrad);
252 std::vector< std::vector<double> >
rffc_m;
254 std::vector< std::vector<double> >
rfvc_m;
constexpr double e
The value of.
T rad(T x)
Convert degrees to radians.
Interface for a single beam element.
std::vector< double > dbrrt_m
std::vector< double > g3_m
std::vector< double > dbtt_m
std::vector< double > dbrtt_m
std::vector< double > f3_m
std::vector< double > dbrr_m
std::vector< double > dbrrr_m
std::vector< double > dbttt_m
std::vector< double > dbrt_m
std::vector< double > dbr_m
std::vector< double > dbt_m
std::vector< double > bfld_m
std::vector< double > f2_m
std::vector< double > rarr_m
void setTrimCoilThreshold(double)
void setZinit(double zinit)
virtual double getStepsize() const =0
Get stepsize.
virtual double getCyclHarm() const
virtual void getDimensions(double &zBegin, double &zEnd) const
std::vector< std::string > RFfilename_m
virtual bool getSpiralFlag() const
virtual bool bends() const
void getFieldFromFile_CYCIAE(const double &scaleFactor)
virtual ElementBase::ElementType getType() const
Get element type std::string.
void setSpiralFlag(bool spiral_flag)
virtual double getPRinit() const
void getFieldFromFile_BandRF(const double &scaleFactor)
void setSuperpose(std::vector< bool > flag)
double getRfFrequ(unsigned int i) const
virtual double getTrimCoilThreshold() const
void setCyclotronType(std::string t)
void setRfPhi(std::vector< double > f)
void setRFVCoeffFN(std::vector< std::string > rfv_coeff_fn)
void setPZinit(double zinit)
virtual void accept(BeamlineVisitor &) const
Apply visitor to Cyclotron.
virtual double getPZinit() const
virtual std::string getFieldMapFN() const
virtual double getRmin() const
void read(const double &scaleFactor)
int idx(int irad, int ktet)
virtual double getMaxR() const
void setEScale(std::vector< double > bs)
void setSymmetry(double symmetry)
std::vector< bool > superpose_m
std::vector< double > escale_m
std::vector< std::string > RFVCoeff_fn_m
std::vector< double > rffrequ_m
void getFieldFromFile_AVFEQ(const double &scaleFactor)
virtual bool getSuperpose(unsigned int i) const
virtual double getRmax() const
virtual double getFMHighE() const
double gutdf5d(double *f, double dx, const int kor, const int krl, const int lpr)
double trimCoilThreshold_m
virtual double getMaxZ() const
virtual double getBScale() const
void operator=(const Cyclotron &)=delete
virtual double getZinit() const
void getFieldFromFile_Carbon(const double &scaleFactor)
virtual double getEScale(unsigned int i) const
void writeOutputFieldFiles()
virtual double getPHIinit() const
double getRfPhi(unsigned int i) const
std::vector< TrimCoil * > trimcoils_m
std::vector< std::string > RFFCoeff_fn_m
void setTrimCoils(const std::vector< TrimCoil * > &trimcoils)
virtual double getSymmetry() const
void setCyclHarm(double h)
virtual double getMinZ() const
void getFieldFromFile_Synchrocyclotron(const double &scaleFactor)
void applyTrimCoil_m(const double r, const double z, const double tet_rad, double *br, double *bz)
Apply trim coils (calculate field contributions)
virtual void initialise(PartBunchBase< double, 3 > *bunch, double &startField, double &endField)
void getFieldFromFile_FFA(const double &scaleFactor)
void initR(double rmin, double dr, int nrad)
void setPHIinit(double phiinit)
void setRfFrequ(std::vector< double > f)
void setPRinit(double prinit)
void applyTrimCoil(const double r, const double z, const double tet_rad, double &br, double &bz)
Apply trim coils (calculate field contributions) with smooth field transition.
virtual bool apply(const size_t &id, const double &t, Vector_t &E, Vector_t &B)
void setRfFieldMapFN(std::vector< std::string > rffmapfn)
bool interpolate(const double &rad, const double &tet_rad, double &br, double &bt, double &bz)
void setFMHighE(double e)
std::vector< Fieldmap * > RFfields_m
std::vector< double > rfphi_m
std::vector< double > rfvrequ_m
void setRinit(double rinit)
std::vector< std::vector< double > > rfvc_m
void setFieldMapFN(std::string fmapfn)
std::vector< std::vector< double > > rffc_m
virtual double getFMLowE() const
std::unique_ptr< LossDataSink > lossDs_m
unsigned int getNumberOfTrimcoils() const
virtual double getRinit() const
void getFieldFromFile_Ring(const double &scaleFactor)
virtual double getMinR() const
const std::string & getCyclotronType() const
void setRFFCoeffFN(std::vector< std::string > rff_coeff_fn)
void setBScale(double bs)
virtual double getSlices() const =0
Get number of slices.