ECCE @ EIC Software
Reference for
ECCE @ EIC
simulation and reconstruction software on GitHub
|
#include <coresoftware/blob/master/simulation/g4simulation/g4tpc/PHG4TpcDirectLaser.h>
Classes | |
class | Laser |
stores laser position and direction along z More... | |
Public Member Functions | |
PHG4TpcDirectLaser (const std::string &name="PHG4TpcDirectLaser") | |
constructor | |
~PHG4TpcDirectLaser () override=default | |
destructor | |
int | InitRun (PHCompositeNode *) override |
run initialization | |
int | process_event (PHCompositeNode *) override |
per event processing | |
void | SetDefaultParameters () override |
default parameters | |
void | Detector (const std::string &d) |
detector name | |
void | SetPhiStepping (int n, double min, double max) |
define steps along phi | |
void | SetThetaStepping (int n, double min, double max) |
define steps along theta | |
int | GetNpatternSteps () const |
get total number of steps | |
void | SetCurrentPatternStep (int value) |
set current patter step | |
void | SetDirectLaserAuto (bool value) |
advance automatically through patterns | |
Public Member Functions inherited from SubsysReco | |
~SubsysReco () override | |
virtual int | End (PHCompositeNode *) |
Called at the end of all processing. | |
virtual int | EndRun (const int) |
Called at the end of each run. | |
virtual int | Init (PHCompositeNode *) |
virtual int | Reset (PHCompositeNode *) |
Reset. | |
virtual int | ResetEvent (PHCompositeNode *) |
Clean up after each event. | |
void | Print (const std::string &="ALL") const override |
Public Member Functions inherited from Fun4AllBase | |
virtual | ~Fun4AllBase () |
virtual const std::string | Name () const |
Returns the name of this module. | |
virtual void | Name (const std::string &name) |
Sets the name of this module. | |
virtual void | Verbosity (const int ival) |
Sets the verbosity of this module (0 by default=quiet). | |
virtual void | Verbosity (enu_Verbosity ival) |
Sets the verbosity of this module (0 by default=quiet). | |
virtual int | Verbosity () const |
Gets the verbosity of this module. | |
Public Member Functions inherited from PHParameterInterface | |
PHParameterInterface (const std::string &name) | |
PHParameterInterface (const PHParameterInterface &)=delete | |
virtual | ~PHParameterInterface () |
void | set_paramname (const std::string &name) |
void | set_double_param (const std::string &name, const double dval) |
double | get_double_param (const std::string &name) const |
void | set_int_param (const std::string &name, const int ival) |
int | get_int_param (const std::string &name) const |
void | set_string_param (const std::string &name, const std::string &sval) |
std::string | get_string_param (const std::string &name) const |
void | UpdateParametersWithMacro () |
void | SaveToNodeTree (PHCompositeNode *runNode, const std::string &nodename) |
void | PutOnParNode (PHCompositeNode *parNode, const std::string &nodename) |
Private Member Functions | |
void | SetupLasers () |
define lasers | |
void | AimToThetaPhi (double theta, double phi) |
aim lasers to a given theta and phi angle | |
void | AimToPatternStep (int n) |
aim lasers to a give step | |
void | AimToNextPatternStep () |
aim to next step | |
void | AppendLaserTrack (double theta, double phi, const Laser &) |
append track in given angular direction and for a given laser | |
Private Attributes | |
std::string | detector = "TPC" |
detector name | |
std::string | hitnodename |
g4hitnode name | |
std::vector< Laser > | m_lasers |
lasers | |
int | electrons_per_cm = 300 |
number of electrons deposited per cm laser track | |
double | electrons_per_gev = NAN |
int | currentPatternStep = 0 |
bool | m_autoAdvanceDirectLaser = false |
set to true to change direct laser tracks from one event to the other | |
PHG4HitContainer * | m_g4hitcontainer = nullptr |
g4hit container | |
PHG4TruthInfoContainer * | m_g4truthinfo = nullptr |
truth information | |
std::string | m_track_map_name = "SvtxTrackMap" |
track map, used to store track parameters | |
SvtxTrackMap * | m_track_map = nullptr |
default phi and theta steps | |
int | nPhiSteps = 1 |
int | nThetaSteps = 1 |
int | nTotalSteps = 1 |
double | minPhi = 0 |
double | maxPhi = 0 |
double | minTheta = 0 |
double | maxTheta = 0 |
Additional Inherited Members | |
Public Types inherited from Fun4AllBase | |
enum | enu_Verbosity { VERBOSITY_QUIET = 0, VERBOSITY_SOME = 1, VERBOSITY_MORE = 2, VERBOSITY_EVEN_MORE = 3, VERBOSITY_A_LOT = 4, VERBOSITY_MAX = INT_MAX - 10 } |
Protected Member Functions inherited from SubsysReco | |
SubsysReco (const std::string &name="NONAME") | |
Protected Member Functions inherited from PHParameterInterface | |
void | set_default_double_param (const std::string &name, const double dval) |
void | set_default_int_param (const std::string &name, const int ival) |
void | set_default_string_param (const std::string &name, const std::string &sval) |
void | InitializeParameters () |
Definition at line 19 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 19 of file PHG4TpcDirectLaser.h
PHG4TpcDirectLaser::PHG4TpcDirectLaser | ( | const std::string & | name = "PHG4TpcDirectLaser" | ) |
constructor
Definition at line 169 of file PHG4TpcDirectLaser.cc.
View newest version in sPHENIX GitHub at line 169 of file PHG4TpcDirectLaser.cc
References PHParameterInterface::InitializeParameters().
|
overridedefault |
destructor
|
private |
aim to next step
Definition at line 373 of file PHG4TpcDirectLaser.cc.
View newest version in sPHENIX GitHub at line 373 of file PHG4TpcDirectLaser.cc
References AimToPatternStep(), currentPatternStep, and nTotalSteps.
Referenced by process_event().
aim lasers to a give step
Definition at line 398 of file PHG4TpcDirectLaser.cc.
View newest version in sPHENIX GitHub at line 398 of file PHG4TpcDirectLaser.cc
References AimToThetaPhi(), currentPatternStep, maxPhi, maxTheta, minPhi, minTheta, n, nPhiSteps, nThetaSteps, nTotalSteps, phi, theta(), and Fun4AllBase::Verbosity().
Referenced by AimToNextPatternStep().
|
private |
aim lasers to a given theta and phi angle
Definition at line 383 of file PHG4TpcDirectLaser.cc.
View newest version in sPHENIX GitHub at line 383 of file PHG4TpcDirectLaser.cc
References AppendLaserTrack(), m_lasers, and Fun4AllBase::Verbosity().
Referenced by AimToPatternStep(), and process_event().
append track in given angular direction and for a given laser
Definition at line 426 of file PHG4TpcDirectLaser.cc.
View newest version in sPHENIX GitHub at line 426 of file PHG4TpcDirectLaser.cc
References PHG4HitContainer::AddHit(), PHG4TruthInfoContainer::AddParticle(), PHG4TruthInfoContainer::AddVertex(), cm, Acts::Test::delta, dir, electrons_per_cm, electrons_per_gev, SvtxTrackMap::insert(), PHG4TpcDirectLaser::Laser::m_direction, m_g4hitcontainer, m_g4truthinfo, PHG4TpcDirectLaser::Laser::m_phi, PHG4TpcDirectLaser::Laser::m_position, m_track_map, PHG4TruthInfoContainer::maxtrkindex(), PHG4TruthInfoContainer::maxvtxindex(), particle, PHWHERE, pos(), SvtxTrack_v2::set_px(), SvtxTrack_v2::set_py(), SvtxTrack_v2::set_pz(), SvtxTrack_v2::set_x(), SvtxTrack_v2::set_y(), SvtxTrack_v2::set_z(), start(), Acts::Test::step(), track, and Fun4AllBase::Verbosity().
Referenced by AimToThetaPhi().
|
inline |
detector name
Definition at line 38 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 38 of file PHG4TpcDirectLaser.h
|
inline |
get total number of steps
Definition at line 50 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 50 of file PHG4TpcDirectLaser.h
References nPhiSteps, and nThetaSteps.
|
overridevirtual |
run initialization
Reimplemented from SubsysReco.
Definition at line 177 of file PHG4TpcDirectLaser.cc.
View newest version in sPHENIX GitHub at line 177 of file PHG4TpcDirectLaser.cc
References Fun4AllReturnCodes::ABORTRUN, PHCompositeNode::addNode(), detector, electrons_per_cm, electrons_per_gev, Fun4AllReturnCodes::EVENT_OK, PHNodeIterator::findFirst(), PHParameterInterface::get_double_param(), PHParameterInterface::get_int_param(), hitnodename, m_autoAdvanceDirectLaser, m_g4truthinfo, m_track_map, m_track_map_name, maxPhi, maxTheta, minPhi, minTheta, Fun4AllBase::Name(), nPhiSteps, nThetaSteps, nTotalSteps, PHWHERE, SetupLasers(), and PHParameterInterface::UpdateParametersWithMacro().
|
overridevirtual |
per event processing
Reimplemented from SubsysReco.
Definition at line 251 of file PHG4TpcDirectLaser.cc.
View newest version in sPHENIX GitHub at line 251 of file PHG4TpcDirectLaser.cc
References AimToNextPatternStep(), AimToThetaPhi(), Fun4AllReturnCodes::EVENT_OK, hitnodename, m_autoAdvanceDirectLaser, m_g4hitcontainer, m_g4truthinfo, M_PI, m_track_map, and m_track_map_name.
set current patter step
Definition at line 56 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 56 of file PHG4TpcDirectLaser.h
References currentPatternStep.
|
overridevirtual |
default parameters
Implements PHParameterInterface.
Definition at line 279 of file PHG4TpcDirectLaser.cc.
View newest version in sPHENIX GitHub at line 279 of file PHG4TpcDirectLaser.cc
References e6, PHParameterInterface::set_default_double_param(), and PHParameterInterface::set_default_int_param().
|
inline |
advance automatically through patterns
Definition at line 62 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 62 of file PHG4TpcDirectLaser.h
References m_autoAdvanceDirectLaser.
define steps along phi
Definition at line 303 of file PHG4TpcDirectLaser.cc.
View newest version in sPHENIX GitHub at line 303 of file PHG4TpcDirectLaser.cc
References max, maxPhi, min, minPhi, n, nPhiSteps, nThetaSteps, nTotalSteps, and PHWHERE.
define steps along theta
Definition at line 317 of file PHG4TpcDirectLaser.cc.
View newest version in sPHENIX GitHub at line 317 of file PHG4TpcDirectLaser.cc
References max, maxTheta, min, minTheta, n, nPhiSteps, nThetaSteps, nTotalSteps, and PHWHERE.
|
private |
define lasers
Definition at line 333 of file PHG4TpcDirectLaser.cc.
View newest version in sPHENIX GitHub at line 333 of file PHG4TpcDirectLaser.cc
References PHG4TpcDirectLaser::Laser::m_direction, m_lasers, PHG4TpcDirectLaser::Laser::m_phi, M_PI, and PHG4TpcDirectLaser::Laser::m_position.
Referenced by InitRun().
|
private |
Definition at line 130 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 130 of file PHG4TpcDirectLaser.h
Referenced by AimToNextPatternStep(), AimToPatternStep(), and SetCurrentPatternStep().
|
private |
detector name
Definition at line 99 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 99 of file PHG4TpcDirectLaser.h
Referenced by Detector(), and InitRun().
|
private |
number of electrons deposited per cm laser track
Definition at line 108 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 108 of file PHG4TpcDirectLaser.h
Referenced by AppendLaserTrack(), and InitRun().
|
private |
it is used to convert a given number of electrons into an energy as expected by G4Hit. The energy is then converted back to a number of electrons inside PHG4TpcElectronDrift
Definition at line 116 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 116 of file PHG4TpcDirectLaser.h
Referenced by AppendLaserTrack(), and InitRun().
|
private |
g4hitnode name
Definition at line 102 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 102 of file PHG4TpcDirectLaser.h
Referenced by InitRun(), and process_event().
|
private |
set to true to change direct laser tracks from one event to the other
Definition at line 133 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 133 of file PHG4TpcDirectLaser.h
Referenced by InitRun(), process_event(), and SetDirectLaserAuto().
|
private |
g4hit container
Definition at line 136 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 136 of file PHG4TpcDirectLaser.h
Referenced by AppendLaserTrack(), and process_event().
|
private |
truth information
Definition at line 139 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 139 of file PHG4TpcDirectLaser.h
Referenced by AppendLaserTrack(), InitRun(), and process_event().
|
private |
lasers
Definition at line 105 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 105 of file PHG4TpcDirectLaser.h
Referenced by AimToThetaPhi(), and SetupLasers().
|
private |
Definition at line 143 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 143 of file PHG4TpcDirectLaser.h
Referenced by AppendLaserTrack(), InitRun(), and process_event().
|
private |
track map, used to store track parameters
Definition at line 142 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 142 of file PHG4TpcDirectLaser.h
Referenced by InitRun(), and process_event().
|
private |
Definition at line 124 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 124 of file PHG4TpcDirectLaser.h
Referenced by AimToPatternStep(), InitRun(), and SetPhiStepping().
|
private |
Definition at line 126 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 126 of file PHG4TpcDirectLaser.h
Referenced by AimToPatternStep(), InitRun(), and SetThetaStepping().
|
private |
Definition at line 123 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 123 of file PHG4TpcDirectLaser.h
Referenced by AimToPatternStep(), InitRun(), and SetPhiStepping().
|
private |
Definition at line 125 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 125 of file PHG4TpcDirectLaser.h
Referenced by AimToPatternStep(), InitRun(), and SetThetaStepping().
|
private |
Definition at line 120 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 120 of file PHG4TpcDirectLaser.h
Referenced by AimToPatternStep(), GetNpatternSteps(), InitRun(), SetPhiStepping(), and SetThetaStepping().
|
private |
Definition at line 121 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 121 of file PHG4TpcDirectLaser.h
Referenced by AimToPatternStep(), GetNpatternSteps(), InitRun(), SetPhiStepping(), and SetThetaStepping().
|
private |
Definition at line 122 of file PHG4TpcDirectLaser.h.
View newest version in sPHENIX GitHub at line 122 of file PHG4TpcDirectLaser.h
Referenced by AimToNextPatternStep(), AimToPatternStep(), InitRun(), SetPhiStepping(), and SetThetaStepping().