OPAL (Object Oriented Parallel Accelerator Library)  2021.1.99
OPAL
Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
TrackRun Class Reference

#include <TrackRun.h>

Inheritance diagram for TrackRun:
Inheritance graph
[legend]
Collaboration diagram for TrackRun:
Collaboration graph
[legend]

Public Member Functions

 TrackRun ()
 Exemplar constructor. More...
 
virtual ~TrackRun ()
 
virtual TrackRunclone (const std::string &name)
 Make clone. More...
 
virtual void execute ()
 Execute the command. More...
 
- Public Member Functions inherited from Action
virtual ~Action ()
 
virtual bool canReplaceBy (Object *object)
 Test if replacement is allowed. More...
 
virtual const std::string getCategory () const
 Return the object category as a string. More...
 
virtual bool shouldTrace () const
 Trace flag. More...
 
virtual bool shouldUpdate () const
 Update flag. More...
 
- Public Member Functions inherited from Object
virtual ~Object ()
 
void copyAttributes (const Object &)
 Copy attributes from another object. More...
 
virtual AttributefindAttribute (const std::string &name)
 Find an attribute by name. More...
 
virtual const AttributefindAttribute (const std::string &name) const
 Find an attribute by name. More...
 
virtual ObjectmakeTemplate (const std::string &, TokenStream &, Statement &)
 Macro handler function. More...
 
virtual ObjectmakeInstance (const std::string &name, Statement &, const Parser *)
 Macro handler function. More...
 
virtual void parse (Statement &)
 Parse the object. More...
 
virtual void parseShortcut (Statement &, bool eval=true)
 Parser for single-attribute commands. More...
 
virtual void print (std::ostream &) const
 Print the object. More...
 
virtual void printValue (std::ostream &) const
 
virtual void printHelp (std::ostream &) const
 Print help. More...
 
virtual void replace (Object *oldObject, Object *newObject)
 Replace references. More...
 
virtual void update ()
 Update this object. More...
 
bool isBuiltin () const
 True, if [b]this[/b] is a built-in object. More...
 
virtual bool isShared () const
 Shared flag. More...
 
virtual void setShared (bool)
 Set/reset shared flag. More...
 
void setDirty (bool)
 Set/reset the [b]modified[/b] flag. More...
 
bool isDirty () const
 True, if the [b]modified[/b] flag is set. More...
 
void setFlag (bool)
 Flag/unflag this object, e. g. to control output of objects for. More...
 
bool isFlagged () const
 True, if [b]this[/b] is flagged by setFlag(true). More...
 
const ObjectgetBaseObject () const
 Return the object's base type object. More...
 
const std::string & getOpalName () const
 Return object name. More...
 
ObjectgetParent () const
 Return parent pointer. More...
 
bool isTreeMember (const Object *subTree) const
 Test for tree membership. More...
 
void setOpalName (const std::string &name)
 Set object name. More...
 
void setParent (Object *)
 Set parent object. More...
 
void clear ()
 Clear the occurrence counter. More...
 
int increment ()
 Increment and return the occurrence counter. More...
 
int occurrenceCount ()
 Return the occurrence counter. More...
 
void registerReference (Invalidator *a)
 Register a reference to this object. More...
 
void unregisterReference (Invalidator *a)
 Unegister a reference to this object. More...
 
void registerOwnership (const AttributeHandler::OwnerType &itsClass) const
 
- Public Member Functions inherited from RCObject
int addReference () const
 Increment reference count. More...
 
int removeReference () const
 Decrement the reference count. More...
 
bool isShared () const
 Test for sharing. More...
 

Private Member Functions

 TrackRun (const TrackRun &)
 
void operator= (const TrackRun &)
 
 TrackRun (const std::string &name, TrackRun *parent)
 
void setupTTracker ()
 
void setupCyclotronTracker ()
 
void setupThickTracker ()
 
void setupFieldsolver ()
 
void initDataSink (const int &numBunch=1)
 
double setDistributionParallelT (Beam *beam)
 

Private Attributes

TrackeritsTracker
 
Distributiondist
 
std::vector< Distribution * > distrs_m
 
FieldSolverfs
 
DataSinkds
 
H5PartWrapperphaseSpaceSink_m
 
OpalDataopal
 

Static Private Attributes

static const std::string defaultDistribution
 

Additional Inherited Members

- Public Attributes inherited from Object
std::vector< AttributeitsAttr
 The object attributes. More...
 
- Protected Member Functions inherited from Action
 Action (int size, const char *name, const char *help)
 Constructor for exemplars. More...
 
 Action (const std::string &name, Action *parent)
 Constructor for cloning. More...
 
- Protected Member Functions inherited from Object
 Object (int size, const char *name, const char *help)
 Constructor for exemplars. More...
 
 Object (const std::string &name, Object *parent)
 Constructor for clones. More...
 
- Protected Member Functions inherited from RCObject
 RCObject ()
 Default constructor. More...
 
 RCObject (const RCObject &)
 Copy constructor. More...
 
virtual ~RCObject ()=0
 
RCObjectoperator= (const RCObject &right)
 
- Protected Attributes inherited from Object
bool builtin
 Built-in flag. More...
 
bool modified
 Dirty flag. More...
 
bool flagged
 Object flag. More...
 

Detailed Description

Definition at line 35 of file TrackRun.h.

Constructor & Destructor Documentation

◆ TrackRun() [1/3]

TrackRun::TrackRun ( )

◆ ~TrackRun()

TrackRun::~TrackRun ( )
virtual

Definition at line 131 of file TrackRun.cpp.

References phaseSpaceSink_m.

◆ TrackRun() [2/3]

TrackRun::TrackRun ( const TrackRun )
private

◆ TrackRun() [3/3]

TrackRun::TrackRun ( const std::string &  name,
TrackRun parent 
)
private

Definition at line 120 of file TrackRun.cpp.

References OpalData::getInstance(), and opal.

Here is the call graph for this function:

Member Function Documentation

◆ clone()

TrackRun * TrackRun::clone ( const std::string &  name)
virtual

Make clone.

Implements Object.

Definition at line 137 of file TrackRun.cpp.

References name, and TrackRun().

Here is the call graph for this function:

◆ execute()

void TrackRun::execute ( )
virtual

◆ initDataSink()

void TrackRun::initDataSink ( const int &  numBunch = 1)
private

◆ operator=()

void TrackRun::operator= ( const TrackRun )
private

◆ setDistributionParallelT()

double TrackRun::setDistributionParallelT ( Beam beam)
private

◆ setupCyclotronTracker()

void TrackRun::setupCyclotronTracker ( )
private

getFrequency() gets RF frequency [MHz], NOT isochronous revolution frequency of particle! getCurrent() gets beamcurrent [A]

Definition at line 426 of file TrackRun.cpp.

References abs(), Track::block, Track::bunch, PartBunchBase< T, Dim >::calcBeamParameters(), BoundaryGeometry::clone(), Distribution::createOpalCycl(), defaultDistribution, dist, Attrib::Legacy::Distribution::DISTRIBUTION, Distribution::doRestartOpalCycl(), ds, Track::dT, endl(), Physics::epsilon_0, BeamSequence::fetchLine(), Distribution::find(), Beam::find(), BoundaryGeometry::find(), fs, H5PartWrapperForPC::getAzimuth(), Beam::getCharge(), Beam::getChargePerParticle(), Beam::getCurrent(), H5PartWrapperForPC::getElevation(), Beam::getFrequency(), OpalData::getInputBasename(), OpalData::getInstance(), Beam::getMass(), Beam::getMassPerParticle(), H5PartWrapperForPC::getMeanMomentum(), Beam::getNumberOfParticles(), Beam::getParticleName(), H5PartWrapperForPC::getPreviousH5Local(), Attributes::getReal(), H5PartWrapperForPC::getReferencePr(), H5PartWrapperForPC::getReferencePt(), H5PartWrapperForPC::getReferencePz(), H5PartWrapperForPC::getReferenceR(), H5PartWrapperForPC::getReferenceT(), H5PartWrapperForPC::getReferenceZ(), OpalData::getRestartFileName(), OpalData::getRestartStep(), Attributes::getString(), Attributes::getStringArray(), gmsg, OpalData::hasBunchAllocated(), initDataSink(), OpalData::inRestartRun(), Object::itsAttr, itsTracker, Track::localTimeSteps, opal, phaseSpaceSink_m, Physics::pi, PartBunchBase< T, Dim >::POrigin, Options::psDumpFreq, Physics::q_e, Track::reference, REGULAR, ParallelCyclotronTracker::setBeGa(), PartBunchBase< T, Dim >::setCharge(), PartBunchBase< T, Dim >::setCouplingConstant(), PartBunchBase< T, Dim >::setdT(), OpalData::setGlobalGeometry(), OpalData::setInOPALCyclMode(), ParallelCyclotronTracker::setLastDumpedStep(), PartBunchBase< T, Dim >::setMass(), ParallelCyclotronTracker::setPhi(), ParallelCyclotronTracker::setPr(), ParallelCyclotronTracker::setPreviousH5Local(), ParallelCyclotronTracker::setPsi(), ParallelCyclotronTracker::setPt(), PartBunchBase< T, Dim >::setPType(), ParallelCyclotronTracker::setPz(), ParallelCyclotronTracker::setR(), PartBunchBase< T, Dim >::setStepsPerTurn(), ParallelCyclotronTracker::setTheta(), setupFieldsolver(), ParallelCyclotronTracker::setZ(), Options::statDumpFreq, Track::stepsPerTurn, Track::timeIntegrator, and Track::use.

Referenced by execute().

◆ setupFieldsolver()

void TrackRun::setupFieldsolver ( )
private

◆ setupThickTracker()

void TrackRun::setupThickTracker ( )
private

◆ setupTTracker()

void TrackRun::setupTTracker ( )
private

Member Data Documentation

◆ defaultDistribution

const std::string TrackRun::defaultDistribution
staticprivate

Definition at line 83 of file TrackRun.h.

Referenced by setDistributionParallelT(), and setupCyclotronTracker().

◆ dist

Distribution* TrackRun::dist
private

◆ distrs_m

std::vector<Distribution *> TrackRun::distrs_m
private

Definition at line 73 of file TrackRun.h.

Referenced by setDistributionParallelT().

◆ ds

DataSink* TrackRun::ds
private

Definition at line 77 of file TrackRun.h.

Referenced by initDataSink(), setupCyclotronTracker(), setupThickTracker(), and setupTTracker().

◆ fs

FieldSolver* TrackRun::fs
private

◆ itsTracker

Tracker* TrackRun::itsTracker
private

Definition at line 69 of file TrackRun.h.

Referenced by execute(), setupCyclotronTracker(), setupThickTracker(), and setupTTracker().

◆ opal

OpalData* TrackRun::opal
private

◆ phaseSpaceSink_m

H5PartWrapper* TrackRun::phaseSpaceSink_m
private

The documentation for this class was generated from the following files: