All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
Public Member Functions | Public Attributes | Protected Types | Protected Member Functions | Protected Attributes | Private Member Functions | List of all members
TGeant3 Class Reference

#include <TGeant3.h>

Inheritance diagram for TGeant3:
TGeant3f77 TGeant3TGeo

Public Member Functions

 TGeant3 ()
 
 TGeant3 (const char *title, Int_t nwgeant=0)
 
virtual ~TGeant3 ()
 
virtual void LoadAddress ()
 
virtual Bool_t IsRootGeometrySupported () const
 
void GeomIter ()
 
Int_t CurrentMaterial (Float_t &a, Float_t &z, Float_t &dens, Float_t &radl, Float_t &absl) const
 
Int_t NextVolUp (Text_t *name, Int_t &copy)
 
Int_t CurrentVolID (Int_t &copy) const
 
Int_t CurrentVolOffID (Int_t off, Int_t &copy) const
 
const char * CurrentVolName () const
 
const char * CurrentVolOffName (Int_t off) const
 
const char * CurrentVolPath ()
 
Int_t VolId (const Text_t *name) const
 
Int_t MediumId (const Text_t *name) const
 
Int_t IdFromPDG (Int_t pdg) const
 
Int_t PDGFromId (Int_t pdg) const
 
const char * VolName (Int_t id) const
 
Double_t Xsec (char *reac, Double_t energy, Int_t part, Int_t mate)
 
void TrackPosition (TLorentzVector &xyz) const
 
void TrackPosition (Double_t &x, Double_t &y, Double_t &z) const
 
void TrackMomentum (TLorentzVector &xyz) const
 
void TrackMomentum (Double_t &px, Double_t &py, Double_t &pz, Double_t &etot) const
 
Int_t NofVolumes () const
 
Int_t NofVolDaughters (const char *volName) const
 
const char * VolDaughterName (const char *volName, Int_t i) const
 
Int_t VolDaughterCopyNo (const char *volName, Int_t i) const
 
Int_t VolId2Mate (Int_t id) const
 
Double_t TrackTime () const
 
Double_t TrackCharge () const
 
Double_t TrackMass () const
 
Double_t TrackStep () const
 
Double_t TrackLength () const
 
Int_t TrackPid () const
 
Bool_t IsNewTrack () const
 
Bool_t IsTrackInside () const
 
Bool_t IsTrackEntering () const
 
Bool_t IsTrackExiting () const
 
Bool_t IsTrackOut () const
 
Bool_t IsTrackDisappeared () const
 
Bool_t IsTrackStop () const
 
Bool_t IsTrackAlive () const
 
Int_t NSecondaries () const
 
Int_t CurrentEvent () const
 
TMCProcess ProdProcess (Int_t isec) const
 
Int_t StepProcesses (TArrayI &proc) const
 
void GetSecondary (Int_t isec, Int_t &ipart, TLorentzVector &x, TLorentzVector &p)
 
Bool_t SecondariesAreOrdered () const
 
void StopTrack ()
 
void StopEvent ()
 
void StopRun ()
 
Double_t MaxStep () const
 
void SetMaxStep (Double_t maxstep)
 
void SetMaxNStep (Int_t maxnstp)
 
Int_t GetMaxNStep () const
 
void ForceDecayTime (Float_t time)
 
void SetSkipNeutrinos (Bool_t flag)
 
Bool_t SkipNeutrinos ()
 
Bool_t SetCut (const char *cutName, Double_t cutValue)
 
Bool_t SetProcess (const char *flagName, Int_t flagValue)
 
const char * GetPath ()
 
const char * GetNodeName ()
 
Bool_t DefineParticle (Int_t pdg, const char *name, TMCParticleType mcType, Double_t mass, Double_t charge, Double_t lifetime)
 
Bool_t DefineParticle (Int_t pdg, const char *name, TMCParticleType mcType, Double_t mass, Double_t charge, Double_t lifetime, const TString &, Double_t, Int_t, Int_t, Int_t, Int_t, Int_t, Int_t, Int_t, Int_t, Bool_t, Bool_t=kFALSE, const TString &="", Int_t=0, Double_t=0.0, Double_t=0.0)
 
Bool_t DefineIon (const char *name, Int_t Z, Int_t A, Int_t Q, Double_t excEnergy, Double_t mass)
 
virtual TString ParticleName (Int_t pdg) const
 
virtual Double_t ParticleMass (Int_t pdg) const
 
virtual Double_t ParticleCharge (Int_t pdg) const
 
virtual Double_t ParticleLifeTime (Int_t pdg) const
 
virtual TMCParticleType ParticleMCType (Int_t pdg) const
 
virtual Int_t CurrentMedium () const
 
virtual Int_t GetMedium () const
 
virtual Double_t Edep () const
 
virtual Double_t Etot () const
 
virtual void Material (Int_t &kmat, const char *name, Double_t a, Double_t z, Double_t dens, Double_t radl, Double_t absl, Float_t *buf=0, Int_t nwbuf=0)
 
virtual void Material (Int_t &kmat, const char *name, Double_t a, Double_t z, Double_t dens, Double_t radl, Double_t absl, Double_t *buf, Int_t nwbuf)
 
virtual void Mixture (Int_t &kmat, const char *name, Float_t *a, Float_t *z, Double_t dens, Int_t nlmat, Float_t *wmat)
 
virtual void Mixture (Int_t &kmat, const char *name, Double_t *a, Double_t *z, Double_t dens, Int_t nlmat, Double_t *wmat)
 
virtual void Medium (Int_t &kmed, const char *name, Int_t nmat, Int_t isvol, Int_t ifield, Double_t fieldm, Double_t tmaxfd, Double_t stemax, Double_t deemax, Double_t epsil, Double_t stmin, Float_t *ubuf=0, Int_t nbuf=0)
 
virtual void Medium (Int_t &kmed, const char *name, Int_t nmat, Int_t isvol, Int_t ifield, Double_t fieldm, Double_t tmaxfd, Double_t stemax, Double_t deemax, Double_t epsil, Double_t stmin, Double_t *ubuf, Int_t nbuf)
 
virtual void Matrix (Int_t &krot, Double_t thex, Double_t phix, Double_t they, Double_t phiy, Double_t thez, Double_t phiz)
 
virtual void SetRootGeometry ()
 
virtual void SetUserParameters (Bool_t isUserParameters)
 
Bool_t GetTransformation (const TString &volumePath, TGeoHMatrix &mat)
 
Bool_t GetShape (const TString &volumePath, TString &shapeType, TArrayD &par)
 
Bool_t GetMaterial (const TString &volumeName, TString &name, Int_t &imat, Double_t &a, Double_t &z, Double_t &den, Double_t &radl, Double_t &inter, TArrayD &par)
 
Bool_t GetMedium (const TString &volumeName, TString &name, Int_t &imed, Int_t &nmat, Int_t &isvol, Int_t &ifield, Double_t &fieldm, Double_t &tmaxfd, Double_t &stemax, Double_t &deemax, Double_t &epsil, Double_t &stmin, TArrayD &par)
 
virtual Quest_tQuest () const
 
virtual Gcbank_tGcbank () const
 
virtual Gclink_tGclink () const
 
virtual Gccuts_tGccuts () const
 
virtual Gcmore_tGcmore () const
 
virtual Gcmulo_tGcmulo () const
 
virtual Gcmate_tGcmate () const
 
virtual Gctpol_tGctpol () const
 
virtual Gcnum_tGcnum () const
 
virtual Gcsets_tGcsets () const
 
virtual Gcopti_tGcopti () const
 
virtual Gctlit_tGctlit () const
 
virtual Gcvdma_tGcvdma () const
 
virtual Gcvolu_tGcvolu () const
 
virtual Gckine_tGckine () const
 
virtual Gcflag_tGcflag () const
 
virtual Gctmed_tGctmed () const
 
virtual Gcphys_tGcphys () const
 
virtual Gcphlt_tGcphlt () const
 
virtual Gcking_tGcking () const
 
virtual Gckin2_tGckin2 () const
 
virtual Gckin3_tGckin3 () const
 
virtual Gctrak_tGctrak () const
 
virtual Int_t * Iq () const
 
virtual Int_t * Lq () const
 
virtual Float_t * Q () const
 
virtual Ertrio_tErtrio () const
 
virtual Eropts_tEropts () const
 
virtual Eroptc_tEroptc () const
 
virtual Erwork_tErwork () const
 
virtual Trcom3_tTrcom3 () const
 
virtual Gconst_tGconst () const
 
virtual Gconsx_tGconsx () const
 
virtual Gcjump_tGcjump () const
 
virtual void Gpcxyz ()
 
virtual void Ggclos ()
 
virtual void Gfile (const char *filename, const char *option="I")
 
virtual void Glast ()
 
virtual void Gprint (const char *name)
 
virtual void Grun ()
 
virtual void Gtrig ()
 
virtual void Gtrigc ()
 
virtual void Gtrigi ()
 
virtual void Gwork (Int_t nwork)
 
virtual void Gzinit ()
 
virtual void Gfmate (Int_t imat, char *name, Float_t &a, Float_t &z, Float_t &dens, Float_t &radl, Float_t &absl, Float_t *ubuf, Int_t &nbuf)
 
virtual void Gfmate (Int_t imat, char *name, Double_t &a, Double_t &z, Double_t &dens, Double_t &radl, Double_t &absl, Double_t *ubuf, Int_t &nbuf)
 
virtual void Gfpart (Int_t ipart, char *name, Int_t &itrtyp, Float_t &amass, Float_t &charge, Float_t &tlife) const
 
virtual void Gftmed (Int_t numed, char *name, Int_t &nmat, Int_t &isvol, Int_t &ifield, Float_t &fieldm, Float_t &tmaxfd, Float_t &stemax, Float_t &deemax, Float_t &epsil, Float_t &stmin, Float_t *buf=0, Int_t *nbuf=0)
 
virtual void Gftmat (Int_t imate, Int_t ipart, char *chmeca, Int_t kdim, Float_t *tkin, Float_t *value, Float_t *pcut, Int_t &ixst)
 
virtual Float_t Gbrelm (Float_t z, Float_t t, Float_t cut)
 
virtual Float_t Gprelm (Float_t z, Float_t t, Float_t cut)
 
virtual void Gmate ()
 
virtual void Gpart ()
 
virtual void Gsckov (Int_t itmed, Int_t npckov, Float_t *ppckov, Float_t *absco, Float_t *effic, Float_t *rindex)
 
virtual void Gsdk (Int_t ipart, Float_t *bratio, Int_t *mode)
 
virtual void Gsmate (Int_t imat, const char *name, Float_t a, Float_t z, Float_t dens, Float_t radl, Float_t absl)
 
virtual void Gfang (Float_t *p, Float_t &costh, Float_t &sinth, Float_t &cosph, Float_t &sinph, Int_t &rotate)
 
virtual void Gsmixt (Int_t imat, const char *name, Float_t *a, Float_t *z, Float_t dens, Int_t nlmat, Float_t *wmat)
 
virtual void Gspart (Int_t ipart, const char *name, Int_t itrtyp, Double_t amass, Double_t charge, Double_t tlife)
 
virtual void Gstmed (Int_t numed, const char *name, Int_t nmat, Int_t isvol, Int_t ifield, Float_t fieldm, Float_t tmaxfd, Float_t stemax, Float_t deemax, Float_t epsil, Float_t stmin)
 
virtual void Gstpar (Int_t itmed, const char *param, Double_t parval)
 
virtual void SetCerenkov (Int_t itmed, Int_t npckov, Float_t *ppckov, Float_t *absco, Float_t *effic, Float_t *rindex)
 
virtual void SetCerenkov (Int_t itmed, Int_t npckov, Double_t *ppckov, Double_t *absco, Double_t *effic, Double_t *rindex)
 
virtual void DefineOpSurface (const char *name, EMCOpSurfaceModel model, EMCOpSurfaceType surfaceType, EMCOpSurfaceFinish surfaceFinish, Double_t sigmaAlpha)
 
virtual void SetBorderSurface (const char *name, const char *vol1Name, int vol1CopyNo, const char *vol2Name, int vol2CopyNo, const char *opSurfaceName)
 
virtual void SetSkinSurface (const char *name, const char *volName, const char *opSurfaceName)
 
virtual void SetMaterialProperty (Int_t itmed, const char *propertyName, Int_t np, Double_t *pp, Double_t *values)
 
virtual void SetMaterialProperty (Int_t itmed, const char *propertyName, Double_t value)
 
virtual void SetMaterialProperty (const char *surfaceName, const char *propertyName, Int_t np, Double_t *pp, Double_t *values)
 
virtual void Gfkine (Int_t itra, Float_t *vert, Float_t *pvert, Int_t &ipart, Int_t &nvert)
 
virtual void Gfvert (Int_t nvtx, Float_t *v, Int_t &ntbeam, Int_t &nttarg, Float_t &tofg)
 
virtual Int_t Gskine (Float_t *plab, Int_t ipart, Int_t nv, Float_t *ubuf=0, Int_t nwbuf=0)
 
virtual Int_t Gsvert (Float_t *v, Int_t ntbeam, Int_t nttarg, Float_t *ubuf=0, Int_t nwbuf=0)
 
virtual void Gphysi ()
 
virtual void Gdebug ()
 
virtual void Gekbin ()
 
virtual void Gfinds ()
 
virtual void Gsking (Int_t igk)
 
virtual void Gskpho (Int_t igk)
 
virtual void Gsstak (Int_t iflag)
 
virtual void Gsxyz ()
 
virtual void Gtrack ()
 
virtual void Gtreve ()
 
virtual void GtreveRoot ()
 
virtual void Grndm (Float_t *rvec, Int_t len) const
 
virtual void Grndmq (Int_t &is1, Int_t &is2, Int_t iseq, const Text_t *chopt)
 
virtual void Gdxyz (Int_t it)
 
virtual void Gdcxyz ()
 
virtual void Gdtom (Float_t *xd, Float_t *xm, Int_t iflag)
 
virtual void Gdtom (Double_t *xd, Double_t *xm, Int_t iflag)
 
virtual void Glmoth (const char *iudet, Int_t iunum, Int_t &nlev, Int_t *lvols, Int_t *lindx)
 
virtual void Gmedia (Float_t *x, Int_t &numed)
 
virtual void Gmtod (Float_t *xm, Float_t *xd, Int_t iflag)
 
virtual void Gmtod (Double_t *xm, Double_t *xd, Int_t iflag)
 
virtual void Gsdvn (const char *name, const char *mother, Int_t ndiv, Int_t iaxis)
 
virtual void Gsdvn2 (const char *name, const char *mother, Int_t ndiv, Int_t iaxis, Double_t c0i, Int_t numed)
 
virtual void Gsdvs (const char *name, const char *mother, Float_t step, Int_t iaxis, Int_t numed)
 
virtual void Gsdvs2 (const char *name, const char *mother, Float_t step, Int_t iaxis, Float_t c0, Int_t numed)
 
virtual void Gsdvt (const char *name, const char *mother, Double_t step, Int_t iaxis, Int_t numed, Int_t ndvmx)
 
virtual void Gsdvt2 (const char *name, const char *mother, Double_t step, Int_t iaxis, Double_t c0, Int_t numed, Int_t ndvmx)
 
virtual void Gsord (const char *name, Int_t iax)
 
virtual void Gspos (const char *name, Int_t nr, const char *mother, Double_t x, Double_t y, Double_t z, Int_t irot, const char *konly="ONLY")
 
virtual void Gsposp (const char *name, Int_t nr, const char *mother, Double_t x, Double_t y, Double_t z, Int_t irot, const char *konly, Float_t *upar, Int_t np)
 
virtual void Gsposp (const char *name, Int_t nr, const char *mother, Double_t x, Double_t y, Double_t z, Int_t irot, const char *konly, Double_t *upar, Int_t np)
 
virtual void Gsrotm (Int_t nmat, Float_t theta1, Float_t phi1, Float_t theta2, Float_t phi2, Float_t theta3, Float_t phi3)
 
virtual void Gprotm (Int_t nmat=0)
 
virtual Int_t Gsvolu (const char *name, const char *shape, Int_t nmed, Float_t *upar, Int_t np)
 
virtual Int_t Gsvolu (const char *name, const char *shape, Int_t nmed, Double_t *upar, Int_t np)
 
virtual void Gsatt (const char *name, const char *att, Int_t val)
 
virtual void Gfpara (const char *name, Int_t number, Int_t intext, Int_t &npar, Int_t &natt, Float_t *par, Float_t *att)
 
virtual void Gckpar (Int_t ish, Int_t npar, Float_t *par)
 
virtual void Gckmat (Int_t itmed, char *natmed)
 
virtual Int_t Glvolu (Int_t nlev, Int_t *lnam, Int_t *lnum)
 
virtual void Gsbool (const char *, const char *)
 
virtual void DefaultRange ()
 
virtual void InitHIGZ ()
 
virtual void Gdopen (Int_t view)
 
virtual void Gdclose ()
 
virtual void Gdelete (Int_t view)
 
virtual void Gdshow (Int_t view)
 
virtual void Gdopt (const char *name, const char *value)
 
virtual void Gdraw (const char *name, Double_t theta=30, Double_t phi=30, Double_t psi=0, Double_t u0=10, Double_t v0=10, Double_t ul=0.01, Double_t vl=0.01)
 
virtual void Gdrawc (const char *name, Int_t axis=1, Float_t cut=0, Float_t u0=10, Float_t v0=10, Float_t ul=0.01, Float_t vl=0.01)
 
virtual void Gdrawx (const char *name, Float_t cutthe, Float_t cutphi, Float_t cutval, Float_t theta=30, Float_t phi=30, Float_t u0=10, Float_t v0=10, Float_t ul=0.01, Float_t vl=0.01)
 
virtual void Gdhead (Int_t isel, const char *name, Double_t chrsiz=0.6)
 
virtual void Gdman (Double_t u0, Double_t v0, const char *type="MAN")
 
virtual void Gdspec (const char *name)
 
virtual void DrawOneSpec (const char *name)
 
virtual void Gdtree (const char *name, Int_t levmax=15, Int_t ispec=0)
 
virtual void GdtreeParent (const char *name, Int_t levmax=15, Int_t ispec=0)
 
virtual void WriteEuclid (const char *filnam, const char *topvol, Int_t number, Int_t nlevel)
 
virtual void SetABAN (Int_t par=1)
 
virtual void SetANNI (Int_t par=1)
 
virtual void SetAUTO (Int_t par=1)
 
virtual void SetBOMB (Float_t bomb=1)
 
virtual void SetBREM (Int_t par=1)
 
virtual void SetCKOV (Int_t par=1)
 
virtual void SetClipBox (const char *name, Double_t xmin=-9999, Double_t xmax=0, Double_t ymin=-9999, Double_t ymax=0, Double_t zmin=-9999, Double_t zmax=0)
 
virtual void SetCOMP (Int_t par=1)
 
virtual void SetCUTS (Float_t cutgam, Float_t cutele, Float_t cutneu, Float_t cuthad, Float_t cutmuo, Float_t bcute, Float_t bcutm, Float_t dcute, Float_t dcutm, Float_t ppcutm, Float_t tofmax, Float_t *gcuts)
 
virtual void InitGEANE ()
 
virtual void SetClose (Int_t iclose, Float_t *pf, Float_t dstrt, Float_t *w1, Float_t *w2, Float_t *p1, Float_t *p2, Float_t *p3, Float_t *cl)
 
virtual void GetClose (Float_t *p1, Float_t *p2, Float_t *p3, Float_t *len)
 
virtual void SetECut (Float_t gcalpha)
 
virtual void SetDCAY (Int_t par=1)
 
virtual void SetDEBU (Int_t emin=1, Int_t emax=999, Int_t emod=1)
 
virtual void SetDRAY (Int_t par=1)
 
virtual void SetERAN (Float_t ekmin=1.e-5, Float_t ekmax=1.e4, Int_t nekbin=90)
 
virtual void SetHADR (Int_t par=1)
 
virtual void SetKINE (Int_t kine, Float_t xk1=0, Float_t xk2=0, Float_t xk3=0, Float_t xk4=0, Float_t xk5=0, Float_t xk6=0, Float_t xk7=0, Float_t xk8=0, Float_t xk9=0, Float_t xk10=0)
 
virtual void SetLOSS (Int_t par=2)
 
virtual void SetMULS (Int_t par=1)
 
virtual void SetMUNU (Int_t par=1)
 
virtual void SetOPTI (Int_t par=2)
 
virtual void SetPAIR (Int_t par=1)
 
virtual void SetPFIS (Int_t par=1)
 
virtual void SetPHOT (Int_t par=1)
 
virtual void SetRAYL (Int_t par=1)
 
virtual void SetSTRA (Int_t par=0)
 
virtual void SetSWIT (Int_t sw, Int_t val=1)
 
virtual void SetTRIG (Int_t nevents=1)
 
virtual void SetUserDecay (Int_t ipart)
 
virtual Bool_t SetDecayMode (Int_t pdg, Float_t bratio[6], Int_t mode[6][3])
 
virtual void Vname (const char *name, char *vname)
 
virtual void InitLego ()
 
virtual void Ertrgo ()
 
virtual void Ertrak (const Float_t *x1, const Float_t *p1, const Float_t *x2, const Float_t *p2, Int_t ipa, Option_t *chopt)
 
virtual void Erxyzc ()
 
virtual void Eufill (Int_t n, Float_t *ein, Float_t *xlf)
 
virtual void Eufilp (const Int_t n, Float_t *ein, Float_t *pli, Float_t *plf)
 
virtual void Eufilv (Int_t n, Float_t *ein, Char_t *namv, Int_t *numv, Int_t *iovl)
 
virtual void Trscsd (Float_t *pc, Float_t *rc, Float_t *pd, Float_t *rd, Float_t *h, Float_t ch, Int_t ierr, Float_t spu, Float_t *dj, Float_t *dk)
 
virtual void Trsdsc (Float_t *pd, Float_t *rd, Float_t *pc, Float_t *rc, Float_t *h, Float_t *ch, Int_t *ierr, Float_t *spu, Float_t *dj, Float_t *dk)
 
virtual void Trscsp (Float_t *ps, Float_t *rs, Float_t *pc, Float_t *rc, Float_t *h, Float_t *ch, Int_t *ierr, Float_t *spx)
 
virtual void Trspsc (Float_t *ps, Float_t *rs, Float_t *pc, Float_t *rc, Float_t *h, Float_t *ch, Int_t *ierr, Float_t *spx)
 
virtual void FinishGeometry ()
 
virtual void BuildPhysics ()
 
virtual void Init ()
 
virtual void ProcessEvent ()
 
virtual Bool_t ProcessRun (Int_t nevent)
 
virtual void AddParticlesToPdgDataBase () const
 
virtual void SetColors ()
 
void SetTrack (Int_t done, Int_t parent, Int_t pdg, Float_t *pmom, Float_t *vpos, Float_t *polar, Float_t tof, TMCProcess mech, Int_t &ntr, Float_t weight, Int_t is)
 

Public Attributes

Ertrio_tfErtrio
 
Ertrio1_tfErtrio1
 ERTRIO common structure. More...
 
Eropts_tfEropts
 ERTRIO1 common structure. More...
 
Eroptc_tfEroptc
 EROPTS common structure. More...
 
Erwork_tfErwork
 EROPTC common structure. More...
 
Trcom3_tfTrcom3
 ERWORK common structure. More...
 

Protected Types

enum  {
  kTRIG = BIT(14), kSWIT = BIT(15), kDEBU = BIT(16), kAUTO = BIT(17),
  kABAN = BIT(18), kOPTI = BIT(19), kERAN = BIT(20)
}
 

Protected Member Functions

TMCProcess G3toVMC (Int_t iproc) const
 
void DefineParticles ()
 
Int_t TransportMethod (TMCParticleType particleType) const
 
TString ParticleClass (TMCParticleType particleType) const
 
TMCParticleType ParticleType (Int_t itrtyp) const
 
 TGeant3 (const TGeant3 &)
 
TGeant3operator= (const TGeant3 &)
 
Float_t * CreateFloatArray (Float_t *array, Int_t size) const
 
Float_t * CreateFloatArray (Double_t *array, Int_t size) const
 
Int_t NextKmat () const
 
void G3Material (Int_t &kmat, const char *name, Double_t a, Double_t z, Double_t dens, Double_t radl, Double_t absl, Float_t *buf=0, Int_t nwbuf=0)
 
void G3Mixture (Int_t &kmat, const char *name, Float_t *a, Float_t *z, Double_t dens, Int_t nlmat, Float_t *wmat)
 
void G3Medium (Int_t &kmed, const char *name, Int_t nmat, Int_t isvol, Int_t ifield, Double_t fieldm, Double_t tmaxfd, Double_t stemax, Double_t deemax, Double_t epsil, Double_t stmin, Float_t *ubuf=0, Int_t nbuf=0)
 
Int_t G3Gsvolu (const char *name, const char *shape, Int_t nmed, Float_t *upar, Int_t np)
 
void G3Gsposp (const char *name, Int_t nr, const char *mother, Double_t x, Double_t y, Double_t z, Int_t irot, const char *konly, Float_t *upar, Int_t np)
 
Int_t GetIonPdg (Int_t z, Int_t a, Int_t i=0) const
 
Int_t GetSpecialPdg (Int_t number) const
 

Protected Attributes

Int_t fNextVol
 
char fPath [512]
 
Int_t * fZiq
 
Int_t * fZlq
 Good Old IQ of Zebra. More...
 
Float_t * fZq
 Good Old LQ of Zebra. More...
 
Quest_tfQuest
 Good Old Q of Zebra. More...
 
Gcbank_tfGcbank
 QUEST common structure. More...
 
Gclink_tfGclink
 GCBANK common structure. More...
 
Gccuts_tfGccuts
 GCLINK common structure. More...
 
Gcmore_tfGcmore
 GCCUTS common structure. More...
 
Gcmulo_tfGcmulo
 GCMORE common structure. More...
 
Gcmate_tfGcmate
 GCMULO common structure. More...
 
Gctpol_tfGctpol
 GCMATE common structure. More...
 
Gcnum_tfGcnum
 GCTPOL common structure. More...
 
Gcsets_tfGcsets
 GCNUM common structure. More...
 
Gcopti_tfGcopti
 GCSETS common structure. More...
 
Gctlit_tfGctlit
 GCOPTI common structure. More...
 
Gcvdma_tfGcvdma
 GCTLIT common structure. More...
 
Gcvolu_tfGcvolu
 GCVDMA common structure. More...
 
Gckine_tfGckine
 GCVOLU common structure. More...
 
Gcflag_tfGcflag
 GCKINE common structure. More...
 
Gctmed_tfGctmed
 GCFLAG common structure. More...
 
Gcphys_tfGcphys
 GCTMED common structure. More...
 
Gcphlt_tfGcphlt
 GCPHYS common structure. More...
 
Gcking_tfGcking
 GCPHLT common structure. More...
 
Gckin2_tfGckin2
 GCKING common structure. More...
 
Gckin3_tfGckin3
 GCKIN2 common structure. More...
 
Gctrak_tfGctrak
 GCKIN3 common structure. More...
 
Gcchan_tfGcchan
 GCTRAK common structure. More...
 
Gconst_tfGconst
 GCCHAN common structure. More...
 
Gconsx_tfGconsx
 GCONST common structure. More...
 
Gcjump_tfGcjump
 GCONSX common structure. More...
 
char(* fVolNames )[5]
 GCJUMP common structure. More...
 
TObjArray fMedNames
 Names of geant volumes as C++ chars. More...
 
Int_t fNG3Particles
 Names of geant medias as TObjString. More...
 
Int_t fNPDGCodes
 
TArrayI fPDGCode
 
TGeoMCGeometry * fMCGeo
 
Bool_t fImportRootGeometry
 
Bool_t fStopRun
 
Bool_t fSkipNeutrinos
 

Private Member Functions

Int_t ConvertVolumePathString (const TString &volumeName, Int_t **lnam, Int_t **lnum)
 TRCOM3 common structure. More...
 
virtual Bool_t GetMaterial (Int_t, TString &, Double_t &, Double_t &, Double_t &, Double_t &, Double_t &, TArrayD &)
 

Detailed Description

Definition at line 641 of file TGeant3.h.

Member Enumeration Documentation

anonymous enum
protected
Enumerator
kTRIG 
kSWIT 
kDEBU 
kAUTO 
kABAN 
kOPTI 
kERAN 

Definition at line 1201 of file TGeant3.h.

1201  {kTRIG = BIT(14),
1202  kSWIT = BIT(15),
1203  kDEBU = BIT(16),
1204  kAUTO = BIT(17),
1205  kABAN = BIT(18),
1206  kOPTI = BIT(19),
1207  kERAN = BIT(20)
1208  };

Constructor & Destructor Documentation

TGeant3::TGeant3 ( )

Definition at line 1110 of file TGeant3.cxx.

1111  : TVirtualMC(),
1112  fNG3Particles(0),
1113  fNPDGCodes(0),
1114  fPDGCode(),
1115  fMCGeo(0),
1116  fImportRootGeometry(kFALSE),
1117  fStopRun(kFALSE)
1118 {
1119  //
1120  // Default constructor
1121  //
1122  geant3 = this;
1123 }
Int_t fNG3Particles
Names of geant medias as TObjString.
Definition: TGeant3.h:1183
TArrayI fPDGCode
Definition: TGeant3.h:1186
Bool_t fStopRun
Definition: TGeant3.h:1191
Int_t fNPDGCodes
Definition: TGeant3.h:1184
Bool_t fImportRootGeometry
Definition: TGeant3.h:1188
TGeant3 * geant3
Definition: TGeant3.cxx:1072
TGeoMCGeometry * fMCGeo
Definition: TGeant3.h:1187
TGeant3::TGeant3 ( const char *  title,
Int_t  nwgeant = 0 
)

Definition at line 1126 of file TGeant3.cxx.

1127  : TVirtualMC("TGeant3",title, kFALSE),
1128  fNG3Particles(0),
1129  fNPDGCodes(0),
1130  fPDGCode(),
1131  fMCGeo(0),
1132  fImportRootGeometry(kFALSE),
1133  fStopRun(kFALSE),
1134  fSkipNeutrinos(kTRUE)
1135 {
1136  //
1137  // Standard constructor for TGeant3 with ZEBRA initialization
1138  //
1139 
1140 #ifdef STATISTICS
1141  statfile = new TFile("stat.root","recreate");
1142  stattree = new TTree("stat","stat tree");
1143  stattree->Branch("statcode",&statcode,"statcode/I");
1144  stattree->Branch("statsame",&statsame,"statsame/I");
1145  stattree->Branch("statpath",statpath,"statpath/C");
1146  stattree->Branch("oldvect",oldvect,"oldvect[6]/D");
1147  stattree->Branch("oldsafety",&oldsafety,"oldsafety/D");
1148  stattree->Branch("oldstep",&oldstep,"oldstep/D");
1149  stattree->Branch("snext",&statsnext,"statsnext/D");
1150  stattree->Branch("safety",&statsafety,"statsafety/D");
1151 #endif
1152 
1153  geant3 = this;
1154 
1155  if(nwgeant) {
1156  g3zebra(nwgeant);
1157  g3init();
1158  g3zinit();
1159  } else {
1160  g3cinit();
1161  }
1162  //
1163  // Load Address of Geant3 commons
1164  LoadAddress();
1165  //
1166  // Zero number of particles
1167  fNG3Particles = 0;
1168  fNPDGCodes=0;
1169 
1170  // Set initial size to fPDGCode table
1171  fPDGCode.Set(100);
1172 
1173  //set pointers to tracker functions
1174  fginvol = g3invol;
1175  fgtmedi = g3tmedi;
1176  fgtmany = g3tmany;
1177  fgtonly = gtonlyg3;
1178  fgmedia = g3media;
1179  fglvolu = g3lvolu;
1180  fgtnext = g3tnext;
1181  fggperp = g3gperp;
1182 
1183  InitGEANE();
1184 }
#define g3cinit
Definition: TGeant3.cxx:538
virtual void InitGEANE()
Definition: TGeant3.cxx:1227
void(* fgtmany)(Int_t &)=0
Definition: TGeant3.cxx:1090
void(* fglvolu)(Int_t &nlev, Int_t *lnam, Int_t *lnum, Int_t &ier)=0
Definition: TGeant3.cxx:1093
virtual void LoadAddress()
Definition: TGeant3.cxx:1245
Int_t fNG3Particles
Names of geant medias as TObjString.
Definition: TGeant3.h:1183
#define g3invol
Definition: TGeant3.cxx:976
TArrayI fPDGCode
Definition: TGeant3.h:1186
#define g3zinit
Definition: TGeant3.cxx:544
#define g3media
Definition: TGeant3.cxx:978
#define g3gperp
Definition: TGeant3.cxx:981
void(* fgtnext)()=0
Definition: TGeant3.cxx:1094
#define g3tmany
Definition: TGeant3.cxx:979
void(* fgtmedi)(Float_t *, Int_t &)=0
Definition: TGeant3.cxx:1089
void(* fginvol)(Float_t *, Int_t &)=0
Definition: TGeant3.cxx:1088
void(* fgmedia)(Float_t *, Int_t &, Int_t &)=0
Definition: TGeant3.cxx:1092
#define g3tnext
Definition: TGeant3.cxx:980
Bool_t fStopRun
Definition: TGeant3.h:1191
void(* fggperp)(Float_t *, Float_t *, Int_t &)=0
Definition: TGeant3.cxx:1095
Bool_t fSkipNeutrinos
Definition: TGeant3.h:1192
#define g3lvolu
Definition: TGeant3.cxx:599
void(* fgtonly)(Int_t &)=0
Definition: TGeant3.cxx:1091
#define g3init
Definition: TGeant3.cxx:537
Int_t fNPDGCodes
Definition: TGeant3.h:1184
#define g3tmedi
Definition: TGeant3.cxx:977
Bool_t fImportRootGeometry
Definition: TGeant3.h:1188
TGeant3 * geant3
Definition: TGeant3.cxx:1072
#define g3zebra
Definition: TGeant3.cxx:532
TGeoMCGeometry * fMCGeo
Definition: TGeant3.h:1187
type_of_call void gtonlyg3(Int_t &)
GCJUMP common structure.
Definition: TGeant3.cxx:6572
TGeant3::~TGeant3 ( )
virtual

Definition at line 1187 of file TGeant3.cxx.

1188 {
1189  if(fVolNames) {
1190  delete [] fVolNames;
1191  fVolNames=0;
1192  }
1193 }
char(* fVolNames)[5]
GCJUMP common structure.
Definition: TGeant3.h:1180
TGeant3::TGeant3 ( const TGeant3 )
inlineprotected

Definition at line 1209 of file TGeant3.h.

1209 : TVirtualMC() {}

Member Function Documentation

void TGeant3::AddParticlesToPdgDataBase ( ) const
virtual

Definition at line 1335 of file TGeant3.cxx.

1336 {
1337 
1338 //
1339 // Add particles to the PDG data base
1340 
1341  TDatabasePDG *pdgDB = TDatabasePDG::Instance();
1342 
1343  const Double_t kAu2Gev=0.9314943228;
1344  const Double_t khSlash = 1.0545726663e-27;
1345  const Double_t kErg2Gev = 1/1.6021773349e-3;
1346  const Double_t khShGev = khSlash*kErg2Gev;
1347  const Double_t kYear2Sec = 3600*24*365.25;
1348 //
1349 // Bottom mesons
1350 // mass and life-time from PDG
1351 //
1352 // Done by default now from Pythia6 table!
1353 //
1354 //
1355 // Ions
1356 //
1357 
1358  if ( !pdgDB->GetParticle(GetIonPdg(1,2)) )
1359  pdgDB->AddParticle("Deuteron","Deuteron",2*kAu2Gev+8.071e-3,kTRUE,
1360  0,3,"Ion",GetIonPdg(1,2));
1361 
1362  if ( !pdgDB->GetParticle(GetIonPdg(1,3)) )
1363  pdgDB->AddParticle("Triton","Triton",3*kAu2Gev+14.931e-3,kFALSE,
1364  khShGev/(12.33*kYear2Sec),3,"Ion",GetIonPdg(1,3));
1365 
1366  if ( !pdgDB->GetParticle(GetIonPdg(2,4)) )
1367  pdgDB->AddParticle("Alpha","Alpha",4*kAu2Gev+2.424e-3,kTRUE,
1368  khShGev/(12.33*kYear2Sec),6,"Ion",GetIonPdg(2,4));
1369 
1370  if ( !pdgDB->GetParticle(GetIonPdg(2,3)) )
1371  pdgDB->AddParticle("HE3","HE3",3*kAu2Gev+14.931e-3,kFALSE,
1372  0,6,"Ion",GetIonPdg(2,3));
1373 
1374 // Special particles
1375 //
1376  if ( !pdgDB->GetParticle(GetSpecialPdg(50)) )
1377  pdgDB->AddParticle("Cherenkov","Cherenkov",0,kFALSE,
1378  0,0,"Special",GetSpecialPdg(50));
1379 
1380  if ( !pdgDB->GetParticle(GetSpecialPdg(51)) )
1381  pdgDB->AddParticle("FeedbackPhoton","FeedbackPhoton",0,kFALSE,
1382  0,0,"Special",GetSpecialPdg(51));
1383 
1384 }
Int_t GetSpecialPdg(Int_t number) const
Definition: TGeant3.cxx:7005
Int_t GetIonPdg(Int_t z, Int_t a, Int_t i=0) const
Definition: TGeant3.cxx:6996
void TGeant3::BuildPhysics ( )
virtual

Definition at line 1329 of file TGeant3.cxx.

1330 {
1331  Gphysi();
1332 }
virtual void Gphysi()
Definition: TGeant3.cxx:3704
Int_t TGeant3::ConvertVolumePathString ( const TString &  volumeName,
Int_t **  lnam,
Int_t **  lnum 
)
private

TRCOM3 common structure.

Definition at line 6909 of file TGeant3.cxx.

6910  {
6911  // Parses the TString volumePath into an array of volume names
6912  // (4 character long limit) and copy numbers in a form used
6913  // by Geant3.
6914  // Inputs:
6915  // TString& volumePath The volume path to the specific volume
6916  // for which you want the matrix. Volume name
6917  // hierarchy is separated by "/" while the
6918  // copy number is appended using a "_".
6919  // Outputs:
6920  // Int_t lnam An integer array, created by this routine,
6921  // containing the 4 character long volume names.
6922  // Int_t lnum An integer array, created by this routine,
6923  // containing the copy numbers.
6924  // Return:
6925  // The size of the arrays lnam an lnum, the number of volumes down
6926  // the geometry tree. Note, These arrays are allocated within this
6927  // routine, but must be deleted outside of this routine.
6928  Int_t i,j=0,k=0,ireturn,ichar,*inam;
6929  Char_t *buf,**levels,**copies,nam[4];
6930 
6931  inam = (Int_t*)nam; // Setup to convert character string to integer.
6932  buf = new Char_t[volumePath.Length()+1];
6933  for(i=0;i<volumePath.Length();i++) {
6934  if(volumePath[i]!=' ')buf[j++] = volumePath[i]; // remove blanks
6935  if(volumePath[i]=='/') k++;
6936  } // end for i
6937  buf[j] = '\0';
6938  if(buf[j-1]=='/') {k--; buf[j-1]='\0';}// if path ends with '/' ignore
6939  // it, remove it.
6940  levels = new Char_t*[k];
6941  copies = new Char_t*[k];
6942  (*lnam) = new Int_t[k]; // Allocate Geant3 volume name array
6943  (*lnum) = new Int_t[k]; // Allocate Geant3 copy number array
6944  ireturn = k;
6945  ichar = j;
6946  k = 0;
6947  j = 0;
6948  for(i=0;i<ichar;i++) {
6949  if(buf[i]=='/'){
6950  levels[k++] = &(buf[i+1]);
6951  buf[i] = '\0'; // Terminate this sub string.
6952  } // end if == '/'
6953  if(buf[i]=='_'){
6954  copies[j++] = &(buf[i+1]);
6955  buf[i] = '\0'; // Terminate this sub string.
6956  } // end if =='_'
6957  } // end for i
6958  if(k!=j){ // Error, different number of copy numbers and volume names.
6959  // clean up everything.
6960  delete[] buf;
6961  delete[] levels;
6962  delete[] copies;
6963  delete[] (*lnam);
6964  delete[] (*lnum);
6965  (*lnam) = 0;
6966  (*lnum) = 0;
6967  Error("ConvertVolumePathString","Different number of volume names %d"
6968  " and copy numbers %d in volumePath:%s",k,j,volumePath.Data());
6969  return 0;
6970  } // end if k!=j
6971  for(i=0;i<k;i++){
6972  *inam = 0;
6973  (*lnum)[i] = atoi(copies[i]);
6974  for(j=0;j<4;j++) {
6975  if(levels[i][j] == 0) break; // If at end of string exit loop
6976  nam[j] = levels[i][j];
6977  } // end for j
6978  (*lnam)[i] = *inam;
6979  } // end for i
6980  // clean up all but lnam and lnum
6981  delete[] buf;
6982  delete[] levels;
6983  delete[] copies;
6984  return ireturn; // return the size of lnam and lnum.
6985 }
Float_t * TGeant3::CreateFloatArray ( Float_t *  array,
Int_t  size 
) const
protected

Definition at line 6383 of file TGeant3.cxx.

6384 {
6385 // Converts Double_t* array to Float_t*,
6386 // !! The new array has to be deleted by user.
6387 // ---
6388 
6389  Float_t* floatArray;
6390  if (size>0) {
6391  floatArray = new Float_t[size];
6392  for (Int_t i=0; i<size; i++)
6393  if (array[i] >= FLT_MAX )
6394  floatArray[i] = FLT_MAX/100.;
6395  else
6396  floatArray[i] = array[i];
6397  }
6398  else {
6399  //floatArray = 0;
6400  floatArray = new Float_t[1];
6401  }
6402  return floatArray;
6403 }
auto array(Array const &a)
Returns a manipulator which will print the specified array.
Definition: DumpUtils.h:228
Float_t * TGeant3::CreateFloatArray ( Double_t *  array,
Int_t  size 
) const
protected

Definition at line 6407 of file TGeant3.cxx.

6408 {
6409 // Converts Double_t* array to Float_t*,
6410 // !! The new array has to be deleted by user.
6411 // ---
6412 
6413  Float_t* floatArray;
6414  if (size>0) {
6415  floatArray = new Float_t[size];
6416  for (Int_t i=0; i<size; i++)
6417  if (array[i] >= FLT_MAX )
6418  floatArray[i] = FLT_MAX/100.;
6419  else
6420  floatArray[i] = array[i];
6421  }
6422  else {
6423  //floatArray = 0;
6424  floatArray = new Float_t[1];
6425  }
6426  return floatArray;
6427 }
auto array(Array const &a)
Returns a manipulator which will print the specified array.
Definition: DumpUtils.h:228
Int_t TGeant3::CurrentEvent ( ) const

Definition at line 2384 of file TGeant3.cxx.

2385 {
2386  //
2387  // Number of the current event
2388  //
2389  return fGcflag->idevt;
2390 }
Gcflag_t * fGcflag
GCKINE common structure.
Definition: TGeant3.h:1159
Int_t idevt
Definition: TGeant3.h:149
Int_t TGeant3::CurrentMaterial ( Float_t &  a,
Float_t &  z,
Float_t &  dens,
Float_t &  radl,
Float_t &  absl 
) const

Definition at line 1196 of file TGeant3.cxx.

1198 {
1199  //
1200  // Return the parameters of the current material during transport
1201  //
1202  z = fGcmate->z;
1203  a = fGcmate->a;
1204  dens = fGcmate->dens;
1205  radl = fGcmate->radl;
1206  absl = fGcmate->absl;
1207  return 1; //this could be the number of elements in mixture
1208 }
Float_t z
Definition: TGeant3.h:211
Float_t a
Definition: TGeant3.h:210
double z
Float_t radl
Definition: TGeant3.h:213
Float_t dens
Definition: TGeant3.h:212
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
Definition: pointer.h:1124
Gcmate_t * fGcmate
GCMULO common structure.
Definition: TGeant3.h:1150
Float_t absl
Definition: TGeant3.h:214
Int_t TGeant3::CurrentMedium ( ) const
virtual

Definition at line 2950 of file TGeant3.cxx.

2951 {
2952  //
2953  // Return the number of the current medium
2954  //
2955 //#ifdef WITHROOT
2956 // Int_t imed = 0;
2957 // TGeoNode *node = gGeoManager->GetCurrentNode();
2958 // if (!node) imed = gGeoManager->GetTopNode()->GetVolume()->
2959 // GetMedium()->GetId();
2960 // else imed = node->GetVolume()->GetMedium()->GetId();
2961  //printf("==GetMedium: ROOT id=%i numed=%i\n", imed,fGctmed->numed);
2962 //#endif
2963  return fGctmed->numed;
2964 }
Int_t numed
Definition: TGeant3.h:221
Gctmed_t * fGctmed
GCFLAG common structure.
Definition: TGeant3.h:1160
Int_t TGeant3::CurrentVolID ( Int_t &  copy) const

Definition at line 1388 of file TGeant3.cxx.

1389 {
1390  //
1391  // Returns the current volume ID and copy number
1392  //
1393  Int_t i, gname;
1394  if( (i=fGcvolu->nlevel-1) < 0 ) {
1395  Warning("CurrentVolID","Stack depth only %d\n",fGcvolu->nlevel);
1396  } else {
1397  gname=fGcvolu->names[i];
1398  copy=fGcvolu->number[i];
1399  i=fGcvolu->lvolum[i];
1400  if(gname == fZiq[fGclink->jvolum+i]) return i;
1401  else Warning("CurrentVolID","Volume %4s not found\n",(char*)&gname);
1402  }
1403  return 0;
1404 }
Gcvolu_t * fGcvolu
GCVDMA common structure.
Definition: TGeant3.h:1157
Int_t number[15]
Definition: TGeant3.h:287
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t names[15]
Definition: TGeant3.h:286
Int_t lvolum[15]
Definition: TGeant3.h:288
Int_t nlevel
Definition: TGeant3.h:285
T copy(T const &v)
Int_t * fZiq
Definition: TGeant3.h:1140
const char * TGeant3::CurrentVolName ( ) const

Definition at line 1428 of file TGeant3.cxx.

1429 {
1430  //
1431  // Returns the current volume name
1432  //
1433  Int_t i;
1434  if( (i=fGcvolu->nlevel-1) < 0 ) {
1435  Warning("CurrentVolName","Stack depth %d\n",fGcvolu->nlevel);
1436  return 0;
1437  }
1438  Int_t gname=fGcvolu->names[i];
1439  i=fGcvolu->lvolum[i];
1440  if(gname == fZiq[fGclink->jvolum+i]) return fVolNames[i-1];
1441  else Warning("CurrentVolName","Volume %4s not found\n",(char*) &gname);
1442  return 0;
1443 }
Gcvolu_t * fGcvolu
GCVDMA common structure.
Definition: TGeant3.h:1157
char(* fVolNames)[5]
GCJUMP common structure.
Definition: TGeant3.h:1180
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t names[15]
Definition: TGeant3.h:286
Int_t lvolum[15]
Definition: TGeant3.h:288
Int_t nlevel
Definition: TGeant3.h:285
Int_t * fZiq
Definition: TGeant3.h:1140
Int_t TGeant3::CurrentVolOffID ( Int_t  off,
Int_t &  copy 
) const

Definition at line 1407 of file TGeant3.cxx.

1408 {
1409  //
1410  // Return the current volume "off" upward in the geometrical tree
1411  // ID and copy number
1412  //
1413  Int_t i, gname;
1414  if( (i=fGcvolu->nlevel-off-1) < 0 ) {
1415  Warning("CurrentVolOffID","Offset requested %d but stack depth %d\n",
1416  off,fGcvolu->nlevel);
1417  } else {
1418  gname=fGcvolu->names[i];
1419  copy=fGcvolu->number[i];
1420  i=fGcvolu->lvolum[i];
1421  if(gname == fZiq[fGclink->jvolum+i]) return i;
1422  else Warning("CurrentVolOffID","Volume %4s not found\n",(char*)&gname);
1423  }
1424  return 0;
1425 }
Gcvolu_t * fGcvolu
GCVDMA common structure.
Definition: TGeant3.h:1157
Int_t number[15]
Definition: TGeant3.h:287
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t names[15]
Definition: TGeant3.h:286
Int_t lvolum[15]
Definition: TGeant3.h:288
Int_t nlevel
Definition: TGeant3.h:285
T copy(T const &v)
Int_t * fZiq
Definition: TGeant3.h:1140
const char * TGeant3::CurrentVolOffName ( Int_t  off) const

Definition at line 1446 of file TGeant3.cxx.

1447 {
1448  //
1449  // Return the current volume "off" upward in the geometrical tree
1450  // ID, name and copy number
1451  // if name=0 no name is returned
1452  //
1453  Int_t i;
1454  if( (i=fGcvolu->nlevel-off-1) < 0 ) {
1455  Warning("CurrentVolOffName",
1456  "Offset requested %d but stack depth %d\n",off,fGcvolu->nlevel);
1457  return 0;
1458  }
1459  Int_t gname=fGcvolu->names[i];
1460  i=fGcvolu->lvolum[i];
1461  if(gname == fZiq[fGclink->jvolum+i]) return fVolNames[i-1];
1462  else Warning("CurrentVolOffName","Volume %4s not found\n",(char*)&gname);
1463  return 0;
1464 }
Gcvolu_t * fGcvolu
GCVDMA common structure.
Definition: TGeant3.h:1157
char(* fVolNames)[5]
GCJUMP common structure.
Definition: TGeant3.h:1180
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t names[15]
Definition: TGeant3.h:286
Int_t lvolum[15]
Definition: TGeant3.h:288
Int_t nlevel
Definition: TGeant3.h:285
Int_t * fZiq
Definition: TGeant3.h:1140
const char * TGeant3::CurrentVolPath ( )

Definition at line 1467 of file TGeant3.cxx.

1468 {
1469 // Return the path in geometry tree for the current volume
1470 // ---
1471 
1472  return GetPath();
1473 }
const char * GetPath()
Definition: TGeant3.cxx:3003
void TGeant3::DefaultRange ( )
virtual

Definition at line 1211 of file TGeant3.cxx.

1212 {
1213  //
1214  // Set range of current drawing pad to 20x20 cm
1215  //
1216 }
Bool_t TGeant3::DefineIon ( const char *  name,
Int_t  Z,
Int_t  A,
Int_t  Q,
Double_t  excEnergy,
Double_t  mass 
)

Definition at line 2089 of file TGeant3.cxx.

2091 {
2092 //
2093 // Set a user defined ion.
2094 // ---
2095 
2096  // Define pdgEncoding
2097  //
2098  Int_t pdg = GetIonPdg(Z, A);
2099  Int_t pdgMax = pdg + 9;
2100 
2101  // Find isomer number which is not yet used
2102  while (TDatabasePDG::Instance()->GetParticle(pdg) &&
2103  pdg < pdgMax)
2104  pdg++;
2105  if (TDatabasePDG::Instance()->GetParticle(pdg)) {
2106  Fatal("SetIon", "All isomer numbers are already used");
2107  return kFALSE;
2108  }
2109 
2110  // Particle properties
2111  // excitation energy not used by G3
2112  if (mass < 1e-09) mass = 0.9382723 * A;
2113  // approximative mass if not specified by user
2114  Double_t charge = Q;
2115  TMCParticleType partType = kPTIon;
2116  Double_t lifetime = 1.e20;
2117 
2118  // Call DefineParticle now
2119  return DefineParticle(
2120  pdg, name, partType, mass, charge, lifetime,
2121  "nucleus", 0.0, 1, 1, 0, 1, 1, 0, 0, 1, kTRUE);
2122 }
Bool_t DefineParticle(Int_t pdg, const char *name, TMCParticleType mcType, Double_t mass, Double_t charge, Double_t lifetime)
Definition: TGeant3.cxx:2026
const double e
Int_t GetIonPdg(Int_t z, Int_t a, Int_t i=0) const
Definition: TGeant3.cxx:6996
static const double A
Definition: Units.h:82
virtual Float_t * Q() const
Definition: TGeant3.h:832
void TGeant3::DefineOpSurface ( const char *  name,
EMCOpSurfaceModel  model,
EMCOpSurfaceType  surfaceType,
EMCOpSurfaceFinish  surfaceFinish,
Double_t  sigmaAlpha 
)
virtual

Definition at line 3534 of file TGeant3.cxx.

3537 {
3538 
3539  Warning("DefineOpSurface",
3540  Form("Called for surface %s. Not applicable in Geant3 - setting is ignored.", name));
3541 }
Bool_t TGeant3::DefineParticle ( Int_t  pdg,
const char *  name,
TMCParticleType  mcType,
Double_t  mass,
Double_t  charge,
Double_t  lifetime 
)

Definition at line 2026 of file TGeant3.cxx.

2028 {
2029 // Old function definition, now replaced with more arguments
2030 
2031  TVirtualMC::DefineParticle(pdg, name, type, mass, charge, lifetime);
2032 
2033  return false;
2034 }
Bool_t TGeant3::DefineParticle ( Int_t  pdg,
const char *  name,
TMCParticleType  mcType,
Double_t  mass,
Double_t  charge,
Double_t  lifetime,
const TString &  ,
Double_t  ,
Int_t  ,
Int_t  ,
Int_t  ,
Int_t  ,
Int_t  ,
Int_t  ,
Int_t  ,
Int_t  ,
Bool_t  ,
Bool_t  = kFALSE,
const TString &  = "",
Int_t  = 0,
Double_t  = 0.0,
Double_t  = 0.0 
)

Definition at line 2038 of file TGeant3.cxx.

2048 {
2049 //
2050 // Set a user defined particle
2051 // Function is ignored if particle with specified pdg
2052 // already exists and error report is printed.
2053 // ---
2054 
2055  // Check if particle with specified pdg already exists
2056  // in TGeant3
2057  if (IdFromPDG(pdg) > 0) {
2058  Error("SetParticle", "Particle already exists.");
2059  return kFALSE;
2060  }
2061 
2062  // Check if particle type is known to Geant3
2063  Int_t itrtyp = TransportMethod(mcType);
2064  if (itrtyp < 0) {
2065  Error("SetParticle", "Unknown particle transport.");
2066  return kFALSE;
2067  }
2068 
2069  // Add particle to Geant3
2070  Gspart(fNG3Particles++, name, itrtyp, mass, charge, lifetime);
2071 
2072  // Add particle to TDatabasePDG
2073  // (if it does not yet exist here)
2074  if (!TDatabasePDG::Instance()->GetParticle(pdg))
2075  TDatabasePDG::Instance()
2076  ->AddParticle(name, name, mass, kTRUE, 0, charge*3,
2077  ParticleClass(mcType).Data(), pdg);
2078 
2079  // Resize fPDGCode table if needed
2080  if ( fNPDGCodes >= fPDGCode.GetSize() )
2081  fPDGCode.Set( fPDGCode.GetSize() + 100);
2082 
2083  fPDGCode[fNPDGCodes++] = pdg;
2084 
2085  return kTRUE;
2086 }
Int_t fNG3Particles
Names of geant medias as TObjString.
Definition: TGeant3.h:1183
TArrayI fPDGCode
Definition: TGeant3.h:1186
Int_t IdFromPDG(Int_t pdg) const
Definition: TGeant3.cxx:1476
Int_t TransportMethod(TMCParticleType particleType) const
Definition: TGeant3.cxx:6143
Int_t fNPDGCodes
Definition: TGeant3.h:1184
virtual void Gspart(Int_t ipart, const char *name, Int_t itrtyp, Double_t amass, Double_t charge, Double_t tlife)
Definition: TGeant3.cxx:3404
TString ParticleClass(TMCParticleType particleType) const
Definition: TGeant3.cxx:6183
void TGeant3::DefineParticles ( )
protected

Definition at line 1497 of file TGeant3.cxx.

1498 {
1499  //
1500  // Define standard Geant 3 particles
1501  Gpart();
1502  //
1503  // Load standard numbers for GEANT particles and PDG conversion
1504  fPDGCode[fNPDGCodes++]=-99; // 0 = unused location
1505  fPDGCode[fNPDGCodes++]=22; // 1 = photon
1506  fPDGCode[fNPDGCodes++]=-11; // 2 = positron
1507  fPDGCode[fNPDGCodes++]=11; // 3 = electron
1508  fPDGCode[fNPDGCodes++]=12; // 4 = neutrino e
1509  fPDGCode[fNPDGCodes++]=-13; // 5 = muon +
1510  fPDGCode[fNPDGCodes++]=13; // 6 = muon -
1511  fPDGCode[fNPDGCodes++]=111; // 7 = pi0
1512  fPDGCode[fNPDGCodes++]=211; // 8 = pi+
1513  fPDGCode[fNPDGCodes++]=-211; // 9 = pi-
1514  fPDGCode[fNPDGCodes++]=130; // 10 = Kaon Long
1515  fPDGCode[fNPDGCodes++]=321; // 11 = Kaon +
1516  fPDGCode[fNPDGCodes++]=-321; // 12 = Kaon -
1517  fPDGCode[fNPDGCodes++]=2112; // 13 = Neutron
1518  fPDGCode[fNPDGCodes++]=2212; // 14 = Proton
1519  fPDGCode[fNPDGCodes++]=-2212; // 15 = Anti Proton
1520  fPDGCode[fNPDGCodes++]=310; // 16 = Kaon Short
1521  fPDGCode[fNPDGCodes++]=221; // 17 = Eta
1522  fPDGCode[fNPDGCodes++]=3122; // 18 = Lambda
1523  fPDGCode[fNPDGCodes++]=3222; // 19 = Sigma +
1524  fPDGCode[fNPDGCodes++]=3212; // 20 = Sigma 0
1525  fPDGCode[fNPDGCodes++]=3112; // 21 = Sigma -
1526  fPDGCode[fNPDGCodes++]=3322; // 22 = Xi0
1527  fPDGCode[fNPDGCodes++]=3312; // 23 = Xi-
1528  fPDGCode[fNPDGCodes++]=3334; // 24 = Omega-
1529  fPDGCode[fNPDGCodes++]=-2112; // 25 = Anti Neutron
1530  fPDGCode[fNPDGCodes++]=-3122; // 26 = Anti Lambda
1531  fPDGCode[fNPDGCodes++]=-3222; // 27 = Anti Sigma -
1532  fPDGCode[fNPDGCodes++]=-3212; // 28 = Anti Sigma 0
1533  fPDGCode[fNPDGCodes++]=-3112; // 29 = Anti Sigma +
1534  fPDGCode[fNPDGCodes++]=-3322; // 30 = Anti Xi 0
1535  fPDGCode[fNPDGCodes++]=-3312; // 31 = Anti Xi +
1536  fPDGCode[fNPDGCodes++]=-3334; // 32 = Anti Omega +
1537 
1538 
1539  Int_t mode[6];
1540  Int_t kz, ipa;
1541  Float_t bratio[6];
1542 
1543  fNG3Particles = 33;
1544 
1545  /* --- Define additional particles */
1546  Gspart(fNG3Particles++,"OMEGA(782)",3,0.782,0.,7.836e-23);// 33 = OMEGA(782)
1547  fPDGCode[fNPDGCodes++]=223; // 33 = Omega(782)
1548 
1549  Gspart(fNG3Particles++,"PHI(1020)",3,1.019,0.,1.486e-22);// 34 = PHI(1020)
1550  fPDGCode[fNPDGCodes++]=333; // 34 = PHI (1020)
1551 
1552  Gspart(fNG3Particles++, "D +", 4, 1.8693, 1., 1.040e-12); // 35 = D+ // G4DMesonPlus
1553  fPDGCode[fNPDGCodes++]=411; // 35 = D+
1554 
1555  Gspart(fNG3Particles++, "D -", 4, 1.8693, -1., 1.040e-12); // 36 = D- // G4DMesonMinus
1556  fPDGCode[fNPDGCodes++]=-411; // 36 = D-
1557 
1558  Gspart(fNG3Particles++, "D 0", 3, 1.8645, 0., 0.415e-12); // 37 = D0 // G4DMesonZero
1559  fPDGCode[fNPDGCodes++]=421; // 37 = D0
1560 
1561  Gspart(fNG3Particles++,"ANTI D 0",3,1.8645,0.,0.415e-12); // 38 = Anti D0 // G4AntiDMesonZero
1562  fPDGCode[fNPDGCodes++]=-421; // 38 = D0 bar
1563 
1564 
1565  fNG3Particles++;
1566  fPDGCode[fNPDGCodes++]=-99; // 39 = unassigned
1567 
1568  fNG3Particles++;
1569  fPDGCode[fNPDGCodes++]=-99; // 40 = unassigned
1570 
1571  fNG3Particles++;
1572  fPDGCode[fNPDGCodes++]=-99; // 41 = unassigned
1573 
1574  Gspart(fNG3Particles++, "RHO +", 4, 0.768, 1., 4.353e-24); // 42 = Rho+
1575  fPDGCode[fNPDGCodes++]=213; // 42 = RHO+
1576 
1577  Gspart(fNG3Particles++, "RHO -", 4, 0.768, -1., 4.353e-24); // 43 = Rho-
1578  fPDGCode[fNPDGCodes++]=-213; // 43 = RHO-
1579 
1580  Gspart(fNG3Particles++, "RHO 0", 3, 0.768, 0., 4.353e-24); // 44 = Rho0
1581  fPDGCode[fNPDGCodes++]=113; // 44 = RHO0
1582 
1583 //
1584 // Ions
1585 
1586  fNG3Particles++;
1587  fPDGCode[fNPDGCodes++]=GetIonPdg(1, 2); // 45 = Deuteron
1588 
1589  fNG3Particles++;
1590  fPDGCode[fNPDGCodes++]=GetIonPdg(1, 3); // 46 = Triton
1591 
1592  fNG3Particles++;
1593  fPDGCode[fNPDGCodes++]=GetIonPdg(2, 4); // 47 = Alpha
1594 
1595  fNG3Particles++;
1596  fPDGCode[fNPDGCodes++]=0; // 48 = geantino mapped to rootino
1597 
1598  fNG3Particles++;
1599  fPDGCode[fNPDGCodes++]=GetIonPdg(2, 3); // 49 = HE3
1600 
1601  fNG3Particles++;
1602  fPDGCode[fNPDGCodes++]=GetSpecialPdg(50); // 50 = Cherenkov
1603 // special
1604  Gspart(fNG3Particles++, "FeedbackPhoton", 7, 0., 0.,1.e20 );
1605  fPDGCode[fNPDGCodes++]=GetSpecialPdg(51); // 51 = FeedbackPhoton
1606 //
1607 
1608  Gspart(fNG3Particles++, "Lambda_c-", 4, 2.28646, +1., 2.06e-13);
1609  // Gspart(fNG3Particles++, "Lambda_c+", 4, 2.28646, +1., 0.200e-12); // G4LambdacPlus
1610  fPDGCode[fNPDGCodes++]=4122; //52 = Lambda_c+
1611 
1612  Gspart(fNG3Particles++, "Lambda_c-", 4, 2.28646, -1., 2.06e-13);
1613  // Gspart(fNG3Particles++, "Lambda_c-", 4, 2.2849, -1., 0.200e-12); // G4AntiLamdacPlus
1614  fPDGCode[fNPDGCodes++]=-4122; //53 = Lambda_c-
1615 
1616  Gspart(fNG3Particles++, "D_s+", 4, 1.9682, +1., 0.490e-12); // G4DsMesonPlus * booklet (July 2006): lifetime=0.500e-12
1617  fPDGCode[fNPDGCodes++]=431; //54 = D_s+
1618 
1619  Gspart(fNG3Particles++, "D_s-", 4, 1.9682, -1., 0.490e-12); // G4DsMesonMinus * booklet: lifetime=0.500e-12
1620  fPDGCode[fNPDGCodes++]=-431; //55 = D_s-
1621 
1622  Gspart(fNG3Particles++, "Tau+", 5, 1.77699, +1., 290.6e-15); // G4TauPlus *
1623  fPDGCode[fNPDGCodes++]=-15; //56 = Tau+
1624 
1625  Gspart(fNG3Particles++, "Tau-", 5, 1.77699, -1., 290.6e-15); // G4TauMinus *
1626  fPDGCode[fNPDGCodes++]= 15; //57 = Tau-
1627 
1628  Gspart(fNG3Particles++, "B0", 3, 5.2794, +0., 1.532e-12); // G4BMesonZero
1629  fPDGCode[fNPDGCodes++]=511; //58 = B0
1630 
1631  Gspart(fNG3Particles++, "B0 bar", 3, 5.2794, -0., 1.532e-12); // G4AntiBMesonZero
1632  fPDGCode[fNPDGCodes++]=-511; //58 = B0bar
1633 
1634  Gspart(fNG3Particles++, "B+", 4, 5.2790, +1., 1.638e-12); // G4BMesonPlus *
1635  fPDGCode[fNPDGCodes++]=521; //60 = B+
1636 
1637  Gspart(fNG3Particles++, "B-", 4, 5.2790, -1., 1.638e-12); // G4BMesonMinus *
1638  fPDGCode[fNPDGCodes++]=-521; //61 = B-
1639 
1640  Gspart(fNG3Particles++, "Bs", 3, 5.3675, +0., 1.466e-12); // G4BsMesonZero
1641  fPDGCode[fNPDGCodes++]=531; //62 = B_s
1642 
1643  Gspart(fNG3Particles++, "Bs bar", 3, 5.3675, -0., 1.466e-12); // G4AntiBsMesonZero
1644  fPDGCode[fNPDGCodes++]=-531; //63 = B_s bar
1645 
1646  Gspart(fNG3Particles++, "Lambda_b", 3, 5.624, +0., 1.24e-12);
1647  fPDGCode[fNPDGCodes++]=5122; //64 = Lambda_b
1648 
1649  Gspart(fNG3Particles++, "Lambda_b bar", 3, 5.624, -0., 1.24e-12);
1650  fPDGCode[fNPDGCodes++]=-5122; //65 = Lambda_b bar
1651 
1652  Gspart(fNG3Particles++, "J/Psi", 3, 3.096916, 0., 7.6e-21); // G4JPsi
1653  fPDGCode[fNPDGCodes++]=443; // 66 = J/Psi
1654 
1655  Gspart(fNG3Particles++, "Psi Prime", 3, 3.686, 0., 0.);
1656  fPDGCode[fNPDGCodes++]=20443; // 67 = Psi prime
1657 
1658  Gspart(fNG3Particles++, "Upsilon(1S)", 3, 9.46037, 0., 0.);
1659  fPDGCode[fNPDGCodes++]=553; // 68 = Upsilon(1S)
1660 
1661  Gspart(fNG3Particles++, "Upsilon(2S)", 3, 10.0233, 0., 0.);
1662  fPDGCode[fNPDGCodes++]=20553; // 69 = Upsilon(2S)
1663 
1664  Gspart(fNG3Particles++, "Upsilon(3S)", 3, 10.3553, 0., 0.);
1665  fPDGCode[fNPDGCodes++]=30553; // 70 = Upsilon(3S)
1666 
1667  Gspart(fNG3Particles++, "Anti Neutrino (e)", 3, 0., 0., 1.e20);
1668  fPDGCode[fNPDGCodes++]=-12; // 71 = anti electron neutrino
1669 
1670  Gspart(fNG3Particles++, "Neutrino (mu)", 3, 0., 0., 1.e20);
1671  fPDGCode[fNPDGCodes++]=14; // 72 = muon neutrino
1672 
1673  Gspart(fNG3Particles++, "Anti Neutrino (mu)", 3, 0., 0., 1.e20);
1674  fPDGCode[fNPDGCodes++]=-14; // 73 = anti muon neutrino
1675 
1676  Gspart(fNG3Particles++, "Neutrino (tau)", 3, 0., 0., 1.e20);
1677  fPDGCode[fNPDGCodes++]=16; // 74 = tau neutrino
1678 
1679  Gspart(fNG3Particles++, "Anti Neutrino (tau)",3, 0., 0., 1.e20);
1680  fPDGCode[fNPDGCodes++]=-16; // 75 = anti tau neutrino
1681 
1682 /* --- Define additional decay modes --- */
1683 /* --- omega(783) --- */
1684  for (kz = 0; kz < 6; ++kz) {
1685  bratio[kz] = 0.;
1686  mode[kz] = 0;
1687  }
1688  ipa = 33;
1689  bratio[0] = 89.;
1690  bratio[1] = 8.5;
1691  bratio[2] = 2.5;
1692  mode[0] = 70809;
1693  mode[1] = 107;
1694  mode[2] = 908;
1695  Gsdk(ipa, bratio, mode);
1696 /* --- phi(1020) --- */
1697  for (kz = 0; kz < 6; ++kz) {
1698  bratio[kz] = 0.;
1699  mode[kz] = 0;
1700  }
1701  ipa = 34;
1702  bratio[0] = 49.;
1703  bratio[1] = 34.4;
1704  bratio[2] = 12.9;
1705  bratio[3] = 2.4;
1706  bratio[4] = 1.3;
1707  mode[0] = 1112;
1708  mode[1] = 1610;
1709  mode[2] = 4407;
1710  mode[3] = 90807;
1711  mode[4] = 1701;
1712  Gsdk(ipa, bratio, mode);
1713 /* --- D+ --- */
1714  /*
1715  for (kz = 0; kz < 6; ++kz) {
1716  bratio[kz] = 0.;
1717  mode[kz] = 0;
1718  }
1719  ipa = 35;
1720  bratio[0] = 25.;
1721  bratio[1] = 25.;
1722  bratio[2] = 25.;
1723  bratio[3] = 25.;
1724  mode[0] = 80809;
1725  mode[1] = 120808;
1726  mode[2] = 111208;
1727  mode[3] = 110809;
1728  Gsdk(ipa, bratio, mode);
1729  */
1730 /* --- D- --- */
1731  /*
1732  for (kz = 0; kz < 6; ++kz) {
1733  bratio[kz] = 0.;
1734  mode[kz] = 0;
1735  }
1736  ipa = 36;
1737  bratio[0] = 25.;
1738  bratio[1] = 25.;
1739  bratio[2] = 25.;
1740  bratio[3] = 25.;
1741  mode[0] = 90908;
1742  mode[1] = 110909;
1743  mode[2] = 121109;
1744  mode[3] = 120908;
1745  Gsdk(ipa, bratio, mode);
1746  */
1747 /* --- D0 --- */
1748  /*
1749  for (kz = 0; kz < 6; ++kz) {
1750  bratio[kz] = 0.;
1751  mode[kz] = 0;
1752  }
1753  ipa = 37;
1754  bratio[0] = 33.;
1755  bratio[1] = 33.;
1756  bratio[2] = 33.;
1757  mode[0] = 809;
1758  mode[1] = 1208;
1759  mode[2] = 1112;
1760  Gsdk(ipa, bratio, mode);
1761  */
1762 /* --- Anti D0 --- */
1763  /*
1764  for (kz = 0; kz < 6; ++kz) {
1765  bratio[kz] = 0.;
1766  mode[kz] = 0;
1767  }
1768  ipa = 38;
1769  bratio[0] = 33.;
1770  bratio[1] = 33.;
1771  bratio[2] = 33.;
1772  mode[0] = 809;
1773  mode[1] = 1109;
1774  mode[2] = 1112;
1775  Gsdk(ipa, bratio, mode);
1776  */
1777 /* --- rho+ --- */
1778  for (kz = 0; kz < 6; ++kz) {
1779  bratio[kz] = 0.;
1780  mode[kz] = 0;
1781  }
1782  ipa = 42;
1783  bratio[0] = 100.;
1784  mode[0] = 807;
1785  Gsdk(ipa, bratio, mode);
1786 /* --- rho- --- */
1787  for (kz = 0; kz < 6; ++kz) {
1788  bratio[kz] = 0.;
1789  mode[kz] = 0;
1790  }
1791  ipa = 43;
1792  bratio[0] = 100.;
1793  mode[0] = 907;
1794  Gsdk(ipa, bratio, mode);
1795 /* --- rho0 --- */
1796  for (kz = 0; kz < 6; ++kz) {
1797  bratio[kz] = 0.;
1798  mode[kz] = 0;
1799  }
1800  ipa = 44;
1801  bratio[0] = 100.;
1802  mode[0] = 809;
1803  Gsdk(ipa, bratio, mode);
1804  /*
1805 // --- jpsi ---
1806  for (kz = 0; kz < 6; ++kz) {
1807  bratio[kz] = 0.;
1808  mode[kz] = 0;
1809  }
1810  ipa = 113;
1811  bratio[0] = 50.;
1812  bratio[1] = 50.;
1813  mode[0] = 506;
1814  mode[1] = 605;
1815  Gsdk(ipa, bratio, mode);
1816 // --- upsilon ---
1817  ipa = 114;
1818  Gsdk(ipa, bratio, mode);
1819 // --- phi ---
1820  ipa = 115;
1821  Gsdk(ipa, bratio, mode);
1822  */
1823 //
1825 }
Int_t fNG3Particles
Names of geant medias as TObjString.
Definition: TGeant3.h:1183
TArrayI fPDGCode
Definition: TGeant3.h:1186
virtual void Gpart()
Definition: TGeant3.cxx:3335
Int_t GetSpecialPdg(Int_t number) const
Definition: TGeant3.cxx:7005
const double e
Int_t GetIonPdg(Int_t z, Int_t a, Int_t i=0) const
Definition: TGeant3.cxx:6996
virtual void AddParticlesToPdgDataBase() const
Definition: TGeant3.cxx:1335
Int_t fNPDGCodes
Definition: TGeant3.h:1184
virtual void Gsdk(Int_t ipart, Float_t *bratio, Int_t *mode)
Definition: TGeant3.cxx:3345
virtual void Gspart(Int_t ipart, const char *name, Int_t itrtyp, Double_t amass, Double_t charge, Double_t tlife)
Definition: TGeant3.cxx:3404
void TGeant3::DrawOneSpec ( const char *  name)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4773 of file TGeant3.cxx.

4774 {
4775  //
4776  // Function called when one double-clicks on a volume name
4777  // in a TPavelabel drawn by Gdtree.
4778  //
4779 }
Double_t TGeant3::Edep ( ) const
virtual

Definition at line 3045 of file TGeant3.cxx.

3046 {
3047  //
3048  // Return the energy lost in the current step
3049  //
3050  return fGctrak->destep;
3051 }
Float_t destep
Definition: TGeant3.h:256
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
virtual Eroptc_t* TGeant3::Eroptc ( ) const
inlinevirtual

Definition at line 838 of file TGeant3.h.

838 {return fEroptc;}
Eroptc_t * fEroptc
EROPTS common structure.
Definition: TGeant3.h:1125
virtual Eropts_t* TGeant3::Eropts ( ) const
inlinevirtual

Definition at line 837 of file TGeant3.h.

837 {return fEropts;}
Eropts_t * fEropts
ERTRIO1 common structure.
Definition: TGeant3.h:1124
void TGeant3::Ertrak ( const Float_t *  x1,
const Float_t *  p1,
const Float_t *  x2,
const Float_t *  p2,
Int_t  ipa,
Option_t *  chopt 
)
virtual

Definition at line 5380 of file TGeant3.cxx.

5383 {
5384  //************************************************************************
5385  //* *
5386  //* Perform the tracking of the track from point X1 to *
5387  //* point X2 *
5388  //* (Before calling this routine the user should also provide *
5389  //* the input informations in /EROPTS/ and /ERTRIO/ *
5390  //* using subroutine EUFIL(L/P/V) *
5391  //* X1 - Starting coordinates (Cartesian) *
5392  //* P1 - Starting 3-momentum (Cartesian) *
5393  //* X2 - Final coordinates (Cartesian) *
5394  //* P2 - Final 3-momentum (Cartesian) *
5395  //* IPA - Particle code (a la GEANT) of the track *
5396  //* *
5397  //* CHOPT *
5398  //* 'B' 'Backward tracking' - i.e. energy loss *
5399  //* added to the current energy *
5400  //* 'E' 'Exact' calculation of errors assuming *
5401  //* helix (i.e. path-length not *
5402  //* assumed as infinitesimal) *
5403  //* 'L' Tracking up to prescribed Lengths reached *
5404  //* 'M' 'Mixed' prediction (not yet coded) *
5405  //* 'O' Tracking 'Only' without calculating errors *
5406  //* 'P' Tracking up to prescribed Planes reached *
5407  //* 'V' Tracking up to prescribed Volumes reached *
5408  //* 'X' Tracking up to prescribed Point approached *
5409  //* *
5410  //* Interface with GEANT : *
5411  //* Track parameters are in /CGKINE/ and /GCTRAK/ *
5412  //* *
5413  //* ==>Called by : USER *
5414  //* Authors M.Maire, E.Nagy ********//* *
5415  //* *
5416  //************************************************************************
5417  ertrak(x1,p1,x2,p2,ipa,PASSCHARD(chopt) PASSCHARL(chopt));
5418 }
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define ertrak
Definition: TGeant3.cxx:603
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::Ertrgo ( )
virtual

Definition at line 5371 of file TGeant3.cxx.

5372 {
5373  //
5374  // Perform the tracking of the track Track parameters are in VECT
5375  //
5376  ertrgo();
5377 }
#define ertrgo
Definition: TGeant3.cxx:604
virtual Ertrio_t* TGeant3::Ertrio ( ) const
inlinevirtual

Definition at line 836 of file TGeant3.h.

836 {return fErtrio;}
Ertrio_t * fErtrio
Definition: TGeant3.h:1122
virtual Erwork_t* TGeant3::Erwork ( ) const
inlinevirtual

Definition at line 839 of file TGeant3.h.

839 {return fErwork;}
Erwork_t * fErwork
EROPTC common structure.
Definition: TGeant3.h:1126
void TGeant3::Erxyzc ( )
virtual

Definition at line 5420 of file TGeant3.cxx.

5420  {
5421 //
5422 // ******************************************************************
5423 // * *
5424 // * Print track and volume parameters at current point *
5425 // * *
5426 // * ==>Called by : <USER,EUSTEP> *
5427 // * Author R.Brun ********* *
5428 // * *
5429 // ******************************************************************
5430 //
5431 
5432 
5433  erxyzc();
5434 }
#define erxyzc
Definition: TGeant3.cxx:612
Double_t TGeant3::Etot ( ) const
virtual

Definition at line 3054 of file TGeant3.cxx.

3055 {
3056  //
3057  // Return the total energy of the current track
3058  //
3059  return fGctrak->getot;
3060 }
Float_t getot
Definition: TGeant3.h:248
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
void TGeant3::Eufill ( Int_t  n,
Float_t *  ein,
Float_t *  xlf 
)
virtual

Definition at line 5438 of file TGeant3.cxx.

5438  {
5439 
5440 // C. ******************************************************************
5441 // C. * *
5442 // C. * User routine to fill the input values of the commons : *
5443 // C. * /EROPTS/, /EROPTC/ and /ERTRIO/ for CHOPT = 'L' *
5444 // C. * N Number of predictions where to store results *
5445 // C. * EIN Input error matrix *
5446 // C. * XLF Defines the tracklengths which if passed the *
5447 // C. * result should be stored *
5448 // C. * *
5449 // C. * *
5450 // C. * ==>Called by : USER (before calling ERTRAK) *
5451 // C. * Author M.Maire, E.Nagy ********* *
5452 // C. * *
5453 // C. ******************************************************************
5454  for(Int_t i=0;i<15;i++) fErtrio->errin[i]=ein[i];
5455  const Int_t mxpred=10;
5456  if (n<mxpred) {
5457  fErtrio->nepred=n;
5458  } else {
5459  fErtrio->nepred=mxpred;
5460  }
5461  for(Int_t i=0;i<15;i++) fErtrio->errin[i]=ein[i];
5462  for(Int_t i=0;i<fErtrio->nepred;i++) fEropts->erleng[i]=xlf[i];
5463 // eufill(n,ein,xlf);
5464 }
Int_t nepred
Definition: TGeant3.h:544
Eropts_t * fEropts
ERTRIO1 common structure.
Definition: TGeant3.h:1124
Float_t errin[15]
Definition: TGeant3.h:537
Float_t erleng[MXPRED]
Definition: TGeant3.h:569
Ertrio_t * fErtrio
Definition: TGeant3.h:1122
void TGeant3::Eufilp ( const Int_t  n,
Float_t *  ein,
Float_t *  pli,
Float_t *  plf 
)
virtual

Definition at line 5466 of file TGeant3.cxx.

5468 {
5469  // ******************************************************************
5470  // * *
5471  // * User routine to fill the input values of the commons : *
5472  // * /EROPTS/, /EROPTC/ and /ERTRIO/ for CHOPT = 'P' *
5473  // * N Number of predictions where to store results *
5474  // * EIN Input error matrix (in the 'Plane' system ) *
5475  // * PLI Defines the start plane *
5476  // * PLI(3,1) - and *
5477  // * PLI(3,2) - 2 unit vectors in the plane *
5478  // * PLF Defines the end plane *
5479  // * PLF(3,1,I) - and *
5480  // * PLF(3,2,I) - 2 unit vectors in the plane *
5481  // * PLF(3,3,I) - point on the plane *
5482  // * at intermediate point I *
5483  // * *
5484  // * ==>Called by : USER (before calling ERTRAK) *
5485  // * Author M.Maire, E.Nagy ********* *
5486  // * *
5487  // ******************************************************************
5488  for(Int_t i=0;i<15;i++) fErtrio->errin[i]=ein[i];
5489  const Int_t mxpred=10;
5490  if (n<mxpred) {
5491  fErtrio->nepred=n;
5492  } else {
5493  fErtrio->nepred=mxpred;
5494  }
5495  for(Int_t i=0;i<6;i++) fEropts->erpli[i]=pli[i];
5496 
5497  for (Int_t j=0;j<n;j++) {
5498  for(Int_t i=0;i<9;i++) {
5499  fEropts->erplo[i+12*j]=plf[i+12*j];
5500  }
5501  TVector3 v1(fEropts->erplo[0+12*j],fEropts->erplo[1+12*j],fEropts->erplo[2+12*j]);
5502  TVector3 v2(fEropts->erplo[3+12*j],fEropts->erplo[4+12*j],fEropts->erplo[5+12*j]);
5503  TVector3 v3=v1.Cross(v2);
5504  fEropts->erplo[9]=v3(0);
5505  fEropts->erplo[10]=v3(1);
5506  fEropts->erplo[11]=v3(2);
5507  }
5508 
5509 
5510 }
Int_t nepred
Definition: TGeant3.h:544
Eropts_t * fEropts
ERTRIO1 common structure.
Definition: TGeant3.h:1124
Float_t errin[15]
Definition: TGeant3.h:537
Float_t erpli[3 *2]
Definition: TGeant3.h:567
for(std::string line;std::getline(inFile, line);)
Definition: regex_t.cc:35
Float_t erplo[MXPRED *3 *4]
Definition: TGeant3.h:568
Ertrio_t * fErtrio
Definition: TGeant3.h:1122
void TGeant3::Eufilv ( Int_t  n,
Float_t *  ein,
Char_t *  namv,
Int_t *  numv,
Int_t *  iovl 
)
virtual

Definition at line 5511 of file TGeant3.cxx.

5513 {
5514 
5515  // ******************************************************************
5516  // * *
5517  // * User routine to fill the input values of the commons : *
5518  // * /EROPTS/, /EROPTC/ and /ERTRIO/ for CHOPT = 'V' *
5519  // * N Number of predictions where to store results *
5520  // * EIN Input error matrix *
5521  // * CNAMV Volume name of the prediction *
5522  // * NUMV Volume number (if 0 = all volumes) *
5523  // * IOVL = 1 prediction when entering in the volume *
5524  // * = 2 prediction when leaving the volume *
5525  // * *
5526  // * ==>Called by : USER (before calling ERTRAK) *
5527  // * Author M.Maire, E.Nagy ********* *
5528  // * *
5529  // ******************************************************************
5530 
5531  for(Int_t i=0;i<15;i++) fErtrio->errin[i]=ein[i];
5532  const Int_t mxpred=15;
5533  if (n<mxpred) {
5534  fErtrio->nepred=n;
5535  } else {
5536  fErtrio->nepred=mxpred;
5537  }
5538 
5539  for(Int_t i=0;i<fErtrio->nepred;i++) {
5540  fEropts->nameer[i]=*((int*)namv);
5541  fEropts->iovler[i]=iovl[i];
5542  fEropts->numver[i]=numv[i];
5543  }
5544 }
Int_t nepred
Definition: TGeant3.h:544
Eropts_t * fEropts
ERTRIO1 common structure.
Definition: TGeant3.h:1124
Float_t errin[15]
Definition: TGeant3.h:537
Int_t iovler[MXPRED]
Definition: TGeant3.h:572
Int_t numver[MXPRED]
Definition: TGeant3.h:571
Int_t nameer[MXPRED]
Definition: TGeant3.h:570
Ertrio_t * fErtrio
Definition: TGeant3.h:1122
void TGeant3::FinishGeometry ( )
virtual

Reimplemented in TGeant3TGeo.

Definition at line 6205 of file TGeant3.cxx.

6206 {
6207  //
6208  // Finalize geometry construction
6209  //
6210 
6211  //Close the geometry structure
6212  if (gDebug > 0) printf("FinishGeometry, calling ggclos\n");
6213  Ggclos();
6214 
6215 
6216  // gROOT->GetListOfBrowsables()->Add(gGeoManager);
6217  if (gDebug > 0) printf("FinishGeometry, calling SetColors\n");
6218 
6219  //Create the color table
6220  SetColors();
6221  if (gDebug > 0) printf("FinishGeometry, returning\n");
6222 }
virtual void Ggclos()
Definition: TGeant3.cxx:3108
virtual void SetColors()
Definition: TGeant3.cxx:6303
void TGeant3::ForceDecayTime ( Float_t  time)

Definition at line 2593 of file TGeant3.cxx.

2594 {
2595  //
2596  // Force the decay time of the current particle
2597  //
2598  TLorentzVector p;
2599  TrackMomentum(p);
2600  Gcphys()->sumlif = time / p.Beta() / p.Gamma() * 2.99792458e10;
2601 }
void TrackMomentum(TLorentzVector &xyz) const
Definition: TGeant3.cxx:2247
virtual Gcphys_t * Gcphys() const
Definition: TGeant3.h:824
p
Definition: test.py:223
Float_t sumlif
Definition: TGeant3.h:446
void TGeant3::G3Gsposp ( const char *  name,
Int_t  nr,
const char *  mother,
Double_t  x,
Double_t  y,
Double_t  z,
Int_t  irot,
const char *  konly,
Float_t *  upar,
Int_t  np 
)
protected

Definition at line 4192 of file TGeant3.cxx.

4195 {
4196  //
4197  // Place a copy of generic volume NAME with user number
4198  // NR inside MOTHER, with its parameters UPAR(1..NP)
4199  //
4200  TString only = konly;
4201  only.ToLower();
4202  Bool_t isOnly = kFALSE;
4203  if (only.Contains("only")) isOnly = kTRUE;
4204  char vname[5];
4205  Vname(name,vname);
4206  char vmother[5];
4207  Vname(mother,vmother);
4208 
4209  Float_t fx = x;
4210  Float_t fy = y;
4211  Float_t fz = z;
4212  g3sposp(PASSCHARD(vname), nr, PASSCHARD(vmother), fx, fy, fz, irot,
4213  PASSCHARD(konly), upar, np PASSCHARL(vname) PASSCHARL(vmother)
4214  PASSCHARL(konly));
4215 }
virtual void Vname(const char *name, char *vname)
Definition: TGeant3.cxx:5357
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3sposp
Definition: TGeant3.cxx:589
double y
double z
list x
Definition: train.py:276
#define PASSCHARD(string)
Definition: TCallf77.h:11
Int_t TGeant3::G3Gsvolu ( const char *  name,
const char *  shape,
Int_t  nmed,
Float_t *  upar,
Int_t  np 
)
protected

Definition at line 4275 of file TGeant3.cxx.

4277 {
4278  //
4279  // NAME Volume name
4280  // SHAPE Volume type
4281  // NUMED Tracking medium number
4282  // NPAR Number of shape parameters
4283  // UPAR Vector containing shape parameters
4284  //
4285  // It creates a new volume in the JVOLUM data structure.
4286  //
4287  Int_t ivolu = 0;
4288  char vname[5];
4289  Vname(name,vname);
4290  char vshape[5];
4291  Vname(shape,vshape);
4292 
4293  g3svolu(PASSCHARD(vname), PASSCHARD(vshape), nmed, upar, npar, ivolu
4294  PASSCHARL(vname) PASSCHARL(vshape));
4295 
4296  return ivolu;
4297 }
virtual void Vname(const char *name, char *vname)
Definition: TGeant3.cxx:5357
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3svolu
Definition: TGeant3.cxx:592
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::G3Material ( Int_t &  kmat,
const char *  name,
Double_t  a,
Double_t  z,
Double_t  dens,
Double_t  radl,
Double_t  absl,
Float_t *  buf = 0,
Int_t  nwbuf = 0 
)
protected

Definition at line 2613 of file TGeant3.cxx.

2616 {
2617  //
2618  // Defines a Material
2619  //
2620  // kmat number assigned to the material
2621  // name material name
2622  // a atomic mass in au
2623  // z atomic number
2624  // dens density in g/cm3
2625  // absl absorption length in cm
2626  // if >=0 it is ignored and the program
2627  // calculates it, if <0. -absl is taken
2628  // radl radiation length in cm
2629  // if >=0 it is ignored and the program
2630  // calculates it, if <0. -radl is taken
2631  // buf pointer to an array of user words
2632  // nbuf number of user words
2633  //
2634  Int_t jmate=fGclink->jmate;
2635  kmat=1;
2636  Int_t ns, i;
2637  if(jmate>0) {
2638  ns=fZiq[jmate-2];
2639  kmat=ns+1;
2640  for(i=1; i<=ns; i++) {
2641  if(fZlq[jmate-i]==0) {
2642  kmat=i;
2643  break;
2644  }
2645  }
2646  }
2647  Float_t fa = a;
2648  Float_t fz = z;
2649  Float_t fdens = dens;
2650  Float_t fradl = radl;
2651  Float_t fabsl = absl;
2652 
2653  g3smate(kmat,PASSCHARD(name), fa, fz, fdens, fradl, fabsl, buf,
2654  nwbuf PASSCHARL(name));
2655 }
#define PASSCHARL(string)
Definition: TCallf77.h:12
static const double ns
Definition: Units.h:102
#define g3smate
Definition: TGeant3.cxx:552
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t * fZlq
Good Old IQ of Zebra.
Definition: TGeant3.h:1141
double z
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
Definition: pointer.h:1124
#define PASSCHARD(string)
Definition: TCallf77.h:11
Int_t * fZiq
Definition: TGeant3.h:1140
void TGeant3::G3Medium ( Int_t &  kmed,
const char *  name,
Int_t  nmat,
Int_t  isvol,
Int_t  ifield,
Double_t  fieldm,
Double_t  tmaxfd,
Double_t  stemax,
Double_t  deemax,
Double_t  epsil,
Double_t  stmin,
Float_t *  ubuf = 0,
Int_t  nbuf = 0 
)
protected

Definition at line 2810 of file TGeant3.cxx.

2814 {
2815  //
2816  // kmed tracking medium number assigned
2817  // name tracking medium name
2818  // nmat material number
2819  // isvol sensitive volume flag
2820  // ifield magnetic field
2821  // fieldm max. field value (kilogauss)
2822  // tmaxfd max. angle due to field (deg/step)
2823  // stemax max. step allowed
2824  // deemax max. fraction of energy lost in a step
2825  // epsil tracking precision (cm)
2826  // stmin min. step due to continuous processes (cm)
2827  //
2828  // ifield = 0 if no magnetic field; ifield = -1 if user decision in guswim;
2829  // ifield = 1 if tracking performed with g3rkuta; ifield = 2 if tracking
2830  // performed with g3helix; ifield = 3 if tracking performed with g3helx3.
2831  //
2832  Int_t jtmed=fGclink->jtmed;
2833  kmed=1;
2834  Int_t ns, i;
2835  if(jtmed>0) {
2836  ns=fZiq[jtmed-2];
2837  kmed=ns+1;
2838  for(i=1; i<=ns; i++) {
2839  if(fZlq[jtmed-i]==0) {
2840  kmed=i;
2841  break;
2842  }
2843  }
2844  }
2845  Float_t ffieldm = fieldm;
2846  Float_t ftmaxfd = tmaxfd;
2847  Float_t fstemax = stemax;
2848  Float_t fdeemax = deemax;
2849  Float_t fepsil = epsil;
2850  Float_t fstmin = stmin;
2851  g3stmed(kmed, PASSCHARD(name),nmat,isvol,ifield,ffieldm,ftmaxfd,fstemax,
2852  fdeemax, fepsil, fstmin, ubuf, nbuf PASSCHARL(name));
2853 
2854  fMedNames.AddAtAndExpand(new TObjString(name), kmed);
2855 }
#define PASSCHARL(string)
Definition: TCallf77.h:12
static const double ns
Definition: Units.h:102
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t * fZlq
Good Old IQ of Zebra.
Definition: TGeant3.h:1141
#define g3stmed
Definition: TGeant3.cxx:556
TObjArray fMedNames
Names of geant volumes as C++ chars.
Definition: TGeant3.h:1181
#define PASSCHARD(string)
Definition: TCallf77.h:11
Int_t * fZiq
Definition: TGeant3.h:1140
void TGeant3::G3Mixture ( Int_t &  kmat,
const char *  name,
Float_t *  a,
Float_t *  z,
Double_t  dens,
Int_t  nlmat,
Float_t *  wmat 
)
protected

Definition at line 2713 of file TGeant3.cxx.

2715 {
2716  //
2717  // Defines mixture OR COMPOUND IMAT as composed by
2718  // THE BASIC NLMAT materials defined by arrays A,Z and WMAT
2719  //
2720  // If NLMAT > 0 then wmat contains the proportion by
2721  // weights of each basic material in the mixture.
2722  //
2723  // If nlmat < 0 then WMAT contains the number of atoms
2724  // of a given kind into the molecule of the COMPOUND
2725  // In this case, WMAT in output is changed to relative
2726  // weights.
2727  //
2728 
2729  Int_t jmate=fGclink->jmate;
2730  kmat=1;
2731  Int_t ns, i;
2732  if(jmate>0) {
2733  ns=fZiq[jmate-2];
2734  kmat=ns+1;
2735  for(i=1; i<=ns; i++) {
2736  if(fZlq[jmate-i]==0) {
2737  kmat=i;
2738  break;
2739  }
2740  }
2741  }
2742  g3smixt(kmat,PASSCHARD(name),a,z,Float_t(dens),nlmat,wmat PASSCHARL(name));
2743 }
#define PASSCHARL(string)
Definition: TCallf77.h:12
static const double ns
Definition: Units.h:102
#define g3smixt
Definition: TGeant3.cxx:554
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t * fZlq
Good Old IQ of Zebra.
Definition: TGeant3.h:1141
double z
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
Definition: pointer.h:1124
#define PASSCHARD(string)
Definition: TCallf77.h:11
Int_t * fZiq
Definition: TGeant3.h:1140
TMCProcess TGeant3::G3toVMC ( Int_t  iproc) const
protected

Definition at line 2456 of file TGeant3.cxx.

2457 {
2458  //
2459  // Conversion between GEANT and TMC processes
2460  //
2461 
2462  const TMCProcess kPG2MC1[30] = {
2463  kPTransportation, kPMultipleScattering, kPEnergyLoss, kPMagneticFieldL, kPDecay,
2464  kPPair, kPCompton, kPPhotoelectric, kPBrem, kPDeltaRay,
2465  kPAnnihilation, kPHadronic, kPHCElastic, kPEvaporation, kPNuclearFission,
2466  kPNuclearAbsorption, kPPbarAnnihilation, kPNCapture, kPHIElastic,
2467  kPHInhelastic, kPMuonNuclear, kPTOFlimit, kPPhotoFission, kPNoProcess,
2468  kPRayleigh, kPNoProcess, kPNoProcess, kPNoProcess, kPNull, kPStop};
2469 
2470  const TMCProcess kPG2MC2[9] = {
2471  kPLightAbsorption, kPLightScattering, kStepMax, kPNoProcess, kPCerenkov,
2472  kPLightReflection, kPLightRefraction, kPSynchrotron, kPNoProcess};
2473 
2474  TMCProcess proc=kPNoProcess;
2475  if(0<iproc && iproc<=30) proc= kPG2MC1[iproc-1];
2476  else if(101<=iproc && iproc<=109) proc= kPG2MC2[iproc-100-1];
2477  return proc;
2478 }
Float_t TGeant3::Gbrelm ( Float_t  z,
Float_t  t,
Float_t  cut 
)
virtual

Definition at line 3308 of file TGeant3.cxx.

3309 {
3310  //
3311  // To calculate energy loss due to soft muon BREMSSTRAHLUNG
3312  //
3313  return g3brelm(z,t,bcut);
3314 }
double z
#define g3brelm
Definition: TGeant3.cxx:616
virtual Gcbank_t* TGeant3::Gcbank ( ) const
inlinevirtual

Definition at line 808 of file TGeant3.h.

808 {return fGcbank;}
Gcbank_t * fGcbank
QUEST common structure.
Definition: TGeant3.h:1145
virtual Gccuts_t* TGeant3::Gccuts ( ) const
inlinevirtual

Definition at line 810 of file TGeant3.h.

810 {return fGccuts;}
Gccuts_t * fGccuts
GCLINK common structure.
Definition: TGeant3.h:1147
virtual Gcflag_t* TGeant3::Gcflag ( ) const
inlinevirtual

Definition at line 822 of file TGeant3.h.

822 {return fGcflag;}
Gcflag_t * fGcflag
GCKINE common structure.
Definition: TGeant3.h:1159
virtual Gcjump_t* TGeant3::Gcjump ( ) const
inlinevirtual

Definition at line 843 of file TGeant3.h.

843 {return fGcjump;}
Gcjump_t * fGcjump
GCONSX common structure.
Definition: TGeant3.h:1173
virtual Gckin2_t* TGeant3::Gckin2 ( ) const
inlinevirtual

Definition at line 827 of file TGeant3.h.

827 {return fGckin2;}
Gckin2_t * fGckin2
GCKING common structure.
Definition: TGeant3.h:1164
virtual Gckin3_t* TGeant3::Gckin3 ( ) const
inlinevirtual

Definition at line 828 of file TGeant3.h.

828 {return fGckin3;}
Gckin3_t * fGckin3
GCKIN2 common structure.
Definition: TGeant3.h:1165
virtual Gckine_t* TGeant3::Gckine ( ) const
inlinevirtual

Definition at line 821 of file TGeant3.h.

821 {return fGckine;}
Gckine_t * fGckine
GCVOLU common structure.
Definition: TGeant3.h:1158
virtual Gcking_t* TGeant3::Gcking ( ) const
inlinevirtual

Definition at line 826 of file TGeant3.h.

826 {return fGcking;}
Gcking_t * fGcking
GCPHLT common structure.
Definition: TGeant3.h:1163
void TGeant3::Gckmat ( Int_t  itmed,
char *  natmed 
)
virtual

Definition at line 4511 of file TGeant3.cxx.

4512 {
4513  //
4514  // Check the parameters of a tracking medium
4515  //
4516  g3ckmat(itmed, PASSCHARD(natmed) PASSCHARL(natmed));
4517 }
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3ckmat
Definition: TGeant3.cxx:598
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::Gckpar ( Int_t  ish,
Int_t  npar,
Float_t *  par 
)
virtual

Definition at line 4502 of file TGeant3.cxx.

4503 {
4504  //
4505  // Check the parameters of a shape
4506  //
4507  gckpar(ish,npar,par);
4508 }
#define gckpar
Definition: TGeant3.cxx:597
virtual Gclink_t* TGeant3::Gclink ( ) const
inlinevirtual

Definition at line 809 of file TGeant3.h.

809 {return fGclink;}
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
virtual Gcmate_t* TGeant3::Gcmate ( ) const
inlinevirtual

Definition at line 813 of file TGeant3.h.

813 {return fGcmate;}
Gcmate_t * fGcmate
GCMULO common structure.
Definition: TGeant3.h:1150
virtual Gcmore_t* TGeant3::Gcmore ( ) const
inlinevirtual

Definition at line 811 of file TGeant3.h.

811 {return fGcmore;}
Gcmore_t * fGcmore
GCCUTS common structure.
Definition: TGeant3.h:1148
virtual Gcmulo_t* TGeant3::Gcmulo ( ) const
inlinevirtual

Definition at line 812 of file TGeant3.h.

812 {return fGcmulo;}
Gcmulo_t * fGcmulo
GCMORE common structure.
Definition: TGeant3.h:1149
virtual Gcnum_t* TGeant3::Gcnum ( ) const
inlinevirtual

Definition at line 815 of file TGeant3.h.

815 {return fGcnum;}
Gcnum_t * fGcnum
GCTPOL common structure.
Definition: TGeant3.h:1152
virtual Gconst_t* TGeant3::Gconst ( ) const
inlinevirtual

Definition at line 841 of file TGeant3.h.

841 {return fGconst;}
Gconst_t * fGconst
GCCHAN common structure.
Definition: TGeant3.h:1171
virtual Gconsx_t* TGeant3::Gconsx ( ) const
inlinevirtual

Definition at line 842 of file TGeant3.h.

842 {return fGconsx;}
Gconsx_t * fGconsx
GCONST common structure.
Definition: TGeant3.h:1172
virtual Gcopti_t* TGeant3::Gcopti ( ) const
inlinevirtual

Definition at line 817 of file TGeant3.h.

817 {return fGcopti;}
Gcopti_t * fGcopti
GCSETS common structure.
Definition: TGeant3.h:1154
virtual Gcphlt_t* TGeant3::Gcphlt ( ) const
inlinevirtual

Definition at line 825 of file TGeant3.h.

825 {return fGcphlt;}
Gcphlt_t * fGcphlt
GCPHYS common structure.
Definition: TGeant3.h:1162
virtual Gcphys_t* TGeant3::Gcphys ( ) const
inlinevirtual

Definition at line 824 of file TGeant3.h.

824 {return fGcphys;}
Gcphys_t * fGcphys
GCTMED common structure.
Definition: TGeant3.h:1161
virtual Gcsets_t* TGeant3::Gcsets ( ) const
inlinevirtual

Definition at line 816 of file TGeant3.h.

816 {return fGcsets;}
Gcsets_t * fGcsets
GCNUM common structure.
Definition: TGeant3.h:1153
virtual Gctlit_t* TGeant3::Gctlit ( ) const
inlinevirtual

Definition at line 818 of file TGeant3.h.

818 {return fGctlit;}
Gctlit_t * fGctlit
GCOPTI common structure.
Definition: TGeant3.h:1155
virtual Gctmed_t* TGeant3::Gctmed ( ) const
inlinevirtual

Definition at line 823 of file TGeant3.h.

823 {return fGctmed;}
Gctmed_t * fGctmed
GCFLAG common structure.
Definition: TGeant3.h:1160
virtual Gctpol_t* TGeant3::Gctpol ( ) const
inlinevirtual

Definition at line 814 of file TGeant3.h.

814 {return fGctpol;}
Gctpol_t * fGctpol
GCMATE common structure.
Definition: TGeant3.h:1151
virtual Gctrak_t* TGeant3::Gctrak ( ) const
inlinevirtual

Definition at line 829 of file TGeant3.h.

829 {return fGctrak;}
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
virtual Gcvdma_t* TGeant3::Gcvdma ( ) const
inlinevirtual

Definition at line 819 of file TGeant3.h.

819 {return fGcvdma;}
Gcvdma_t * fGcvdma
GCTLIT common structure.
Definition: TGeant3.h:1156
virtual Gcvolu_t* TGeant3::Gcvolu ( ) const
inlinevirtual

Definition at line 820 of file TGeant3.h.

820 {return fGcvolu;}
Gcvolu_t * fGcvolu
GCVDMA common structure.
Definition: TGeant3.h:1157
void TGeant3::Gdclose ( )
virtual

Definition at line 4572 of file TGeant3.cxx.

4573 {
4574  //
4575  // It closes the currently open view bank; it must be called after the
4576  // end of the drawing to be stored.
4577  //
4578 }
void TGeant3::Gdcxyz ( )
virtual

Definition at line 3867 of file TGeant3.cxx.

3868 {
3869  //
3870  // Draw the position of the current track
3871  //
3872 }
void TGeant3::Gdebug ( )
virtual

Definition at line 3720 of file TGeant3.cxx.

3721 {
3722  //
3723  // Debug the current step
3724  //
3725  g3debug();
3726 }
#define g3debug
Definition: TGeant3.cxx:564
void TGeant3::Gdelete ( Int_t  view)
virtual

Definition at line 4545 of file TGeant3.cxx.

4546 {
4547  //
4548  // IVIEW View number
4549  //
4550  // It deletes a view bank from memory.
4551  //
4552 }
void TGeant3::Gdhead ( Int_t  isel,
const char *  name,
Double_t  chrsiz = 0.6 
)
virtual

Definition at line 4719 of file TGeant3.cxx.

4720 {
4721  //
4722  // Parameters
4723  // +
4724  // ISEL Option flag D=111110
4725  // NAME Title
4726  // CHRSIZ Character size (cm) of title NAME D=0.6
4727  //
4728  // ISEL =
4729  // 0 to have only the header lines
4730  // xxxxx1 to add the text name centered on top of header
4731  // xxxx1x to add global detector name (first volume) on left
4732  // xxx1xx to add date on right
4733  // xx1xxx to select thick characters for text on top of header
4734  // x1xxxx to add the text 'EVENT NR x' on top of header
4735  // 1xxxxx to add the text 'RUN NR x' on top of header
4736  // NOTE that ISEL=x1xxx1 or ISEL=1xxxx1 are illegal choices,
4737  // i.e. they generate overwritten text.
4738  //
4739 }
void TGeant3::Gdman ( Double_t  u0,
Double_t  v0,
const char *  type = "MAN" 
)
virtual

Definition at line 4742 of file TGeant3.cxx.

4743 {
4744  //
4745  // Draw a 2D-man at position (U0,V0)
4746  // Parameters
4747  // U U-coord. (horizontal) of the center of man' R
4748  // V V-coord. (vertical) of the center of man' R
4749  // TYPE D='MAN' possible values: 'MAN,WM1,WM2,WM3'
4750  //
4751  // CALL GDMAN(u,v),CALL GDWMN1(u,v),CALL GDWMN2(u,v),CALL GDWMN2(u,v)
4752  // It superimposes the picture of a man or of a woman, chosen among
4753  // three different ones, with the same scale factors as the detector
4754  // in the current drawing.
4755  //
4756 }
void TGeant3::Gdopen ( Int_t  view)
virtual

Definition at line 4555 of file TGeant3.cxx.

4556 {
4557  //
4558  // IVIEW View number
4559  //
4560  // When a drawing is very complex and requires a long time to be
4561  // executed, it can be useful to store it in a view bank: after a
4562  // call to DOPEN and the execution of the drawing (nothing will
4563  // appear on the screen), and after a necessary call to DCLOSE,
4564  // the contents of the bank can be displayed in a very fast way
4565  // through a call to DSHOW; therefore, the detector can be easily
4566  // zoomed many times in different ways. Please note that the pictures
4567  // with solid colors can now be stored in a view bank or in 'PICTURE FILES'
4568  //
4569 }
void TGeant3::Gdopt ( const char *  name,
const char *  value 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4592 of file TGeant3.cxx.

4593 {
4594  //
4595  // NAME Option name
4596  // VALUE Option value
4597  //
4598  // To set/modify the drawing options.
4599  // IOPT IVAL Action
4600  //
4601  // THRZ ON Draw tracks in R vs Z
4602  // OFF (D) Draw tracks in X,Y,Z
4603  // 180
4604  // 360
4605  // PROJ PARA (D) Parallel projection
4606  // PERS Perspective
4607  // TRAK LINE (D) Trajectory drawn with lines
4608  // POIN " " with markers
4609  // HIDE ON Hidden line removal using the CG package
4610  // OFF (D) No hidden line removal
4611  // SHAD ON Fill area and shading of surfaces.
4612  // OFF (D) Normal hidden line removal.
4613  // RAYT ON Ray-tracing on.
4614  // OFF (D) Ray-tracing off.
4615  // EDGE OFF Does not draw contours when shad is on.
4616  // ON (D) Normal shading.
4617  // MAPP 1,2,3,4 Mapping before ray-tracing.
4618  // 0 (D) No mapping.
4619  // USER ON User graphics options in the ray tracing.
4620  // OFF (D) Automatic graphics options.
4621  //
4622 
4623  char vname[5];
4624  Vname(name,vname);
4625  char vvalue[5];
4626  Vname(value,vvalue);
4627  //g3dopt(PASSCHARD(vname), PASSCHARD(vvalue) PASSCHARL(vname)
4628  // PASSCHARL(vvalue));
4629 }
virtual void Vname(const char *name, char *vname)
Definition: TGeant3.cxx:5357
const GenericPointer< typename T::ValueType > T2 value
Definition: pointer.h:1225
void TGeant3::Gdraw ( const char *  name,
Double_t  theta = 30,
Double_t  phi = 30,
Double_t  psi = 0,
Double_t  u0 = 10,
Double_t  v0 = 10,
Double_t  ul = 0.01,
Double_t  vl = 0.01 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4632 of file TGeant3.cxx.

4635 {
4636  //
4637  // NAME Volume name
4638  // +
4639  // THETA Viewing angle theta (for 3D projection)
4640  // PHI Viewing angle phi (for 3D projection)
4641  // PSI Viewing angle psi (for 2D rotation)
4642  // U0 U-coord. (horizontal) of volume origin
4643  // V0 V-coord. (vertical) of volume origin
4644  // SU Scale factor for U-coord.
4645  // SV Scale factor for V-coord.
4646  //
4647  // This function will draw the volumes,
4648  // selected with their graphical attributes, set by the Gsatt
4649  // facility. The drawing may be performed with hidden line removal
4650  // and with shading effects according to the value of the options HIDE
4651  // and SHAD; if the option SHAD is ON, the contour's edges can be
4652  // drawn or not. If the option HIDE is ON, the detector can be
4653  // exploded (BOMB), clipped with different shapes (CVOL), and some
4654  // of its parts can be shifted from their original
4655  // position (SHIFT). When HIDE is ON, if
4656  // the drawing requires more than the available memory, the program
4657  // will evaluate and display the number of missing words
4658  // (so that the user can increase the
4659  // size of its ZEBRA store). Finally, at the end of each drawing (with
4660  // HIDE on), the program will print messages about the memory used and
4661  // statistics on the volumes' visibility.
4662  // The following commands will produce the drawing of a green
4663  // volume, specified by NAME, without using the hidden line removal
4664  // technique, using the hidden line removal technique,
4665  // with different line width and color (red), with
4666  // solid color, with shading of surfaces, and without edges.
4667  // Finally, some examples are given for the ray-tracing. (A possible
4668  // string for the NAME of the volume can be found using the command DTREE).
4669  //
4670 }
void TGeant3::Gdrawc ( const char *  name,
Int_t  axis = 1,
Float_t  cut = 0,
Float_t  u0 = 10,
Float_t  v0 = 10,
Float_t  ul = 0.01,
Float_t  vl = 0.01 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4673 of file TGeant3.cxx.

4675 {
4676  //
4677  // NAME Volume name
4678  // CAXIS Axis value
4679  // CUTVAL Cut plane distance from the origin along the axis
4680  // +
4681  // U0 U-coord. (horizontal) of volume origin
4682  // V0 V-coord. (vertical) of volume origin
4683  // SU Scale factor for U-coord.
4684  // SV Scale factor for V-coord.
4685  //
4686  // The cut plane is normal to caxis (X,Y,Z), corresponding to iaxis (1,2,3),
4687  // and placed at the distance cutval from the origin.
4688  // The resulting picture is seen from the the same axis.
4689  // When HIDE Mode is ON, it is possible to get the same effect with
4690  // the CVOL/BOX function.
4691  //
4692 }
void TGeant3::Gdrawx ( const char *  name,
Float_t  cutthe,
Float_t  cutphi,
Float_t  cutval,
Float_t  theta = 30,
Float_t  phi = 30,
Float_t  u0 = 10,
Float_t  v0 = 10,
Float_t  ul = 0.01,
Float_t  vl = 0.01 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4695 of file TGeant3.cxx.

4698 {
4699  //
4700  // NAME Volume name
4701  // CUTTHE Theta angle of the line normal to cut plane
4702  // CUTPHI Phi angle of the line normal to cut plane
4703  // CUTVAL Cut plane distance from the origin along the axis
4704  // +
4705  // THETA Viewing angle theta (for 3D projection)
4706  // PHI Viewing angle phi (for 3D projection)
4707  // U0 U-coord. (horizontal) of volume origin
4708  // V0 V-coord. (vertical) of volume origin
4709  // SU Scale factor for U-coord.
4710  // SV Scale factor for V-coord.
4711  //
4712  // The cut plane is normal to the line given by the cut angles
4713  // cutthe and cutphi and placed at the distance cutval from the origin.
4714  // The resulting picture is seen from the viewing angles theta,phi.
4715  //
4716 }
void TGeant3::Gdshow ( Int_t  view)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4581 of file TGeant3.cxx.

4582 {
4583  //
4584  // IVIEW View number
4585  //
4586  // It shows on the screen the contents of a view bank. It
4587  // can be called after a view bank has been closed.
4588  //
4589 }
void TGeant3::Gdspec ( const char *  name)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4759 of file TGeant3.cxx.

4760 {
4761  //
4762  // NAME Volume name
4763  //
4764  // Shows 3 views of the volume (two cut-views and a 3D view), together with
4765  // its geometrical specifications. The 3D drawing will
4766  // be performed according the current values of the options HIDE and
4767  // SHAD and according the current SetClipBox clipping parameters for that
4768  // volume.
4769  //
4770 }
void TGeant3::Gdtom ( Float_t *  xd,
Float_t *  xm,
Int_t  iflag 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 3881 of file TGeant3.cxx.

3882 {
3883  //
3884  // Computes coordinates XM (Master Reference System
3885  // knowing the coordinates XD (Detector Ref System)
3886  // The local reference system can be initialized by
3887  // - the tracking routines and GDTOM used in GUSTEP
3888  // - a call to GSCMED(NLEVEL,NAMES,NUMBER)
3889  // (inverse routine is GMTOD)
3890  //
3891  // If IFLAG=1 convert coordinates
3892  // IFLAG=2 convert direction cosines
3893  //
3894  g3dtom(xd, xm, iflag);
3895 }
#define g3dtom
Definition: TGeant3.cxx:577
void TGeant3::Gdtom ( Double_t *  xd,
Double_t *  xm,
Int_t  iflag 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 3898 of file TGeant3.cxx.

3899 {
3900  //
3901  // Computes coordinates XM (Master Reference System
3902  // knowing the coordinates XD (Detector Ref System)
3903  // The local reference system can be initialized by
3904  // - the tracking routines and GDTOM used in GUSTEP
3905  // - a call to GSCMED(NLEVEL,NAMES,NUMBER)
3906  // (inverse routine is GMTOD)
3907  //
3908  // If IFLAG=1 convert coordinates
3909  // IFLAG=2 convert direction cosines
3910  //
3911 
3912  Float_t* fxd = CreateFloatArray(xd, 3);
3913  Float_t* fxm = CreateFloatArray(xm, 3);
3914 
3915  Gdtom(fxd, fxm, iflag) ;
3916 
3917  for (Int_t i=0; i<3; i++) {
3918  xd[i] = fxd[i]; xm[i] = fxm[i];
3919  }
3920 
3921  delete [] fxd;
3922  delete [] fxm;
3923 }
Float_t * CreateFloatArray(Float_t *array, Int_t size) const
Definition: TGeant3.cxx:6383
virtual void Gdtom(Float_t *xd, Float_t *xm, Int_t iflag)
Definition: TGeant3.cxx:3881
void TGeant3::Gdtree ( const char *  name,
Int_t  levmax = 15,
Int_t  ispec = 0 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4782 of file TGeant3.cxx.

4783 {
4784  //
4785  // NAME Volume name
4786  // LEVMAX Depth level
4787  // ISELT Options
4788  //
4789  // This function draws the logical tree,
4790  // Each volume in the tree is represented by a TPaveTree object.
4791  // Double-clicking on a TPaveTree draws the specs of the corresponding
4792  // volume.
4793  // Use TPaveTree pop-up menu to select:
4794  // - drawing specs
4795  // - drawing tree
4796  // - drawing tree of parent
4797  //
4798 }
void TGeant3::GdtreeParent ( const char *  name,
Int_t  levmax = 15,
Int_t  ispec = 0 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4801 of file TGeant3.cxx.

4802 {
4803  //
4804  // NAME Volume name
4805  // LEVMAX Depth level
4806  // ISELT Options
4807  //
4808  // This function draws the logical tree of the parent of name.
4809  //
4810 }
void TGeant3::Gdxyz ( Int_t  it)
virtual

Definition at line 3859 of file TGeant3.cxx.

3860 {
3861  //
3862  // Draw the points stored with Gsxyz relative to track it
3863  //
3864 }
void TGeant3::Gekbin ( )
virtual

Definition at line 3729 of file TGeant3.cxx.

3730 {
3731  //
3732  // To find bin number in kinetic energy table
3733  // stored in ELOW(NEKBIN)
3734  //
3735  g3ekbin();
3736 }
#define g3ekbin
Definition: TGeant3.cxx:565
void TGeant3::GeomIter ( )

Definition at line 1299 of file TGeant3.cxx.

1300 {
1301  //
1302  // Geometry iterator for moving upward in the geometry tree
1303  // Initialize the iterator
1304  //
1306 }
Gcvolu_t * fGcvolu
GCVDMA common structure.
Definition: TGeant3.h:1157
Int_t fNextVol
Definition: TGeant3.h:1137
Int_t nlevel
Definition: TGeant3.h:285
void TGeant3::GetClose ( Float_t *  p1,
Float_t *  p2,
Float_t *  p3,
Float_t *  len 
)
virtual

Definition at line 5027 of file TGeant3.cxx.

5028 {
5029  p1[0] = fGcmore->p1[0];
5030  p1[1] = fGcmore->p1[1];
5031  p1[2] = fGcmore->p1[2];
5032  p2[0] = fGcmore->p2[0];
5033  p2[1] = fGcmore->p2[1];
5034  p2[2] = fGcmore->p2[2];
5035  p3[0] = fGcmore->p3[0];
5036  p3[1] = fGcmore->p3[1];
5037  p3[2] = fGcmore->p3[2];
5038  len[0] = fGcmore->cleng[0];
5039  len[1] = fGcmore->cleng[1];
5040  len[2] = fGcmore->cleng[2];
5041 }
Float_t p2[3]
Definition: TGeant3.h:358
Float_t p3[3]
Definition: TGeant3.h:359
Float_t p1[3]
Definition: TGeant3.h:357
Float_t cleng[3]
Definition: TGeant3.h:360
Gcmore_t * fGcmore
GCCUTS common structure.
Definition: TGeant3.h:1148
Int_t TGeant3::GetIonPdg ( Int_t  z,
Int_t  a,
Int_t  i = 0 
) const
protected

Definition at line 6996 of file TGeant3.cxx.

6997 {
6998 // Acording to
6999 // http://cepa.fnal.gov/psm/stdhep/pdg/montecarlorpp-2006.pdf
7000 
7001  return 1000000000 + 10*1000*z + 10*a + i;
7002 }
double z
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
Definition: pointer.h:1124
Bool_t TGeant3::GetMaterial ( const TString &  volumeName,
TString &  name,
Int_t &  imat,
Double_t &  a,
Double_t &  z,
Double_t &  den,
Double_t &  radl,
Double_t &  inter,
TArrayD &  par 
)

Definition at line 6784 of file TGeant3.cxx.

6787  {
6788  // Returns the Material and its parameters for the volume specified
6789  // by volumeName.
6790  // Note, Geant3 stores and uses mixtures as an element with an effective
6791  // Z and A. Consequently, if the parameter Z is not integer, then
6792  // this material represents some sort of mixture.
6793  // Inputs:
6794  // TString& volumeName The volume name
6795  // Outputs:
6796  // TSrting &name Material name
6797  // Int_t &imat Material index number
6798  // Double_t &a Average Atomic mass of material
6799  // Double_t &z Average Atomic number of material
6800  // Double_t &dens Density of material [g/cm^3]
6801  // Double_t &radl Average radiation length of material [cm]
6802  // Double_t &inter Average interaction length of material [cm]
6803  // TArrayD &par A TArrayD of user defined parameters.
6804  // Return:
6805  // kTRUE if no errors
6806  Int_t i,volid,jma,nbuf;
6807  Float_t af,zf,densf,radlf,interf;
6808  Float_t *ubuf;
6809  Char_t *ch,namec[20] = {20*'\0'};
6810 
6811  volid = VolId(volumeName.Data());
6812  if(volid==0) return kFALSE; // Error
6813  if(volid>0){ // Get Material number, imat.
6814  Int_t imed = (Int_t) (this->Q()[this->Lq()[
6815  this->Gclink()->jvolum-volid]+4]);
6816  Int_t jtm = this->Lq()[this->Gclink()->jtmed-imed];
6817  imat = (Int_t)(this->Q()[jtm+6]);
6818  } else {
6819  i = this->Gclink()->jvolum + volid;
6820  Int_t jdiv = this->Lq()[i];
6821  Int_t ivin = (Int_t) (this->Q()[jdiv+2]);
6822  i = this->Gclink()->jvolum - ivin;
6823  Int_t jvin = this->Lq()[i];
6824  Int_t idmed = (Int_t)(this->Q()[jvin+4]);
6825  i = this->Gclink()->jtmed-idmed;
6826  Int_t jtm = this->Lq()[i];
6827  imat = (Int_t)(this->Q()[jtm+6]);
6828  } // end if-else
6829  nbuf = jma = this->Lq()[this->Gclink()->jmate-imat];
6830  ubuf = new Float_t[nbuf];
6831  Gfmate(imat,namec,af,zf,densf,radlf,interf,ubuf,nbuf);
6832  // Problem with getting namec back from Gfmate, get it from
6833  // the Zebra bank directly.
6834  ch = (char *)(this->Iq()+jma+1);
6835  for(i=0;i<20;i++) if(ch[i]!=' ') namec[i] = ch[i];
6836  name = namec;
6837  name = name.Strip();
6838  //
6839  par.Set(nbuf);
6840  for(i=0;i<nbuf;i++) par.AddAt(((Double_t)ubuf[i]),i);
6841  delete[] ubuf;
6842  a = (Double_t) af;
6843  z = (Double_t) zf;
6844  dens = (Double_t) densf;
6845  radl = (Double_t) radlf;
6846  inter = (Double_t) interf;
6847  return kTRUE;
6848 }
virtual void Gfmate(Int_t imat, char *name, Float_t &a, Float_t &z, Float_t &dens, Float_t &radl, Float_t &absl, Float_t *ubuf, Int_t &nbuf)
Definition: TGeant3.cxx:3227
double z
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
Definition: pointer.h:1124
virtual Float_t * Q() const
Definition: TGeant3.h:832
virtual Int_t * Lq() const
Definition: TGeant3.h:831
Int_t VolId(const Text_t *name) const
Definition: TGeant3.cxx:1828
virtual Gclink_t * Gclink() const
Definition: TGeant3.h:809
virtual Int_t * Iq() const
Definition: TGeant3.h:830
virtual Bool_t TGeant3::GetMaterial ( Int_t  ,
TString &  ,
Double_t &  ,
Double_t &  ,
Double_t &  ,
Double_t &  ,
Double_t &  ,
TArrayD &   
)
inlineprivatevirtual

Definition at line 1240 of file TGeant3.h.

1241  { throw std::logic_error(std::string(__func__) + "::setData(TMatrixT, GFDetPlane, TMatrixT) not available"); }
std::string string
Definition: nybbler.cc:12
Int_t TGeant3::GetMaxNStep ( ) const

Definition at line 2604 of file TGeant3.cxx.

2605 {
2606  //
2607  // Maximum number of steps allowed in current medium
2608  //
2609  return fGctrak->maxnst;
2610 }
Int_t maxnst
Definition: TGeant3.h:255
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
Int_t TGeant3::GetMedium ( ) const
virtual

Reimplemented in TGeant3TGeo.

Definition at line 2967 of file TGeant3.cxx.

2968 {
2969  //
2970  // Return the number of the current medium
2971  // Deprecated function - replaced with CurrentMedium()
2972  //
2973 
2974  Warning("GetMedium",
2975  "Deprecated function - use CurrentMedium() instead");
2976 
2977  return CurrentMedium();
2978 }
virtual Int_t CurrentMedium() const
Definition: TGeant3.cxx:2950
Bool_t TGeant3::GetMedium ( const TString &  volumeName,
TString &  name,
Int_t &  imed,
Int_t &  nmat,
Int_t &  isvol,
Int_t &  ifield,
Double_t &  fieldm,
Double_t &  tmaxfd,
Double_t &  stemax,
Double_t &  deemax,
Double_t &  epsil,
Double_t &  stmin,
TArrayD &  par 
)

Definition at line 6850 of file TGeant3.cxx.

6854  {
6855  // Returns the Medium and its parameters for the volume specified
6856  // by volumeName.
6857  // Inputs:
6858  // TString& volumeName The volume name.
6859  // Outputs:
6860  // TString &name Medium name
6861  // Int_t &nmat Material number defined for this medium
6862  // Int_t &imed The medium index number
6863  // Int_t &isvol volume number defined for this medium
6864  // Int_t &iflield Magnetic field flag
6865  // Double_t &fieldm Magnetic field strength
6866  // Double_t &tmaxfd Maximum angle of deflection per step
6867  // Double_t &stemax Maximum step size
6868  // Double_t &deemax Maximum fraction of energy allowed to be lost
6869  // to continuous process.
6870  // Double_t &epsil Boundary crossing precision
6871  // Double_t &stmin Minimum step size allowed
6872  // TArrayD &par A TArrayD of user parameters with all of the
6873  // parameters of the specified medium.
6874  // Return:
6875  // kTRUE if there where no errors
6876  Int_t i,volid,nbuf;
6877  Float_t fieldmf,tmaxfdf,stemaxf,deemaxf,epsilf,stminf;
6878  Float_t *buf;
6879  Char_t namec[25] = {25*'\0'};
6880 
6881  volid = VolId(volumeName.Data());
6882  if(volid==0) return kFALSE; // Error
6883  if(volid>0){ // Get Material number, imat.
6884  imed = (Int_t)(this->Q()[this->Lq()[this->Gclink()->jvolum-volid]+4]);
6885  } else {
6886  Int_t jdiv = this->Lq()[this->Gclink()->jvolum + volid];
6887  Int_t ivin = (Int_t) (this->Q()[jdiv+2]);
6888  Int_t jvin = this->Lq()[this->Gclink()->jvolum - ivin];
6889  imed = (Int_t)(this->Q()[jvin+4]);
6890  } // end if-else
6891  nbuf = this->Lq()[this->Gclink()->jtmed-imed];
6892  buf = new Float_t[nbuf];
6893  Gftmed(imed,namec,nmat,isvol,ifield,fieldmf,tmaxfdf,stemaxf,deemaxf,
6894  epsilf,stminf,buf,&nbuf);
6895  name = namec;
6896  name = name.Strip();
6897  par.Set(nbuf);
6898  for(i=0;i<nbuf;i++) par.AddAt(((Double_t)buf[i]),i);
6899  delete[] buf;
6900  fieldm = (Double_t) fieldmf;
6901  tmaxfd = (Double_t) tmaxfdf;
6902  stemax = (Double_t) stemaxf;
6903  deemax = (Double_t) deemaxf;
6904  epsil = (Double_t) epsilf;
6905  stmin = (Double_t) stminf;
6906  return kTRUE;
6907 }
virtual void Gftmed(Int_t numed, char *name, Int_t &nmat, Int_t &isvol, Int_t &ifield, Float_t &fieldm, Float_t &tmaxfd, Float_t &stemax, Float_t &deemax, Float_t &epsil, Float_t &stmin, Float_t *buf=0, Int_t *nbuf=0)
Definition: TGeant3.cxx:3281
virtual Float_t * Q() const
Definition: TGeant3.h:832
virtual Int_t * Lq() const
Definition: TGeant3.h:831
Int_t VolId(const Text_t *name) const
Definition: TGeant3.cxx:1828
virtual Gclink_t * Gclink() const
Definition: TGeant3.h:809
const char * TGeant3::GetNodeName ( )

Definition at line 3030 of file TGeant3.cxx.

3031 {
3032 // Get name of current G3 node
3033  Int_t i=fGcvolu->nlevel-1;
3034  if (i<0) return "";
3035  Int_t gname = fGcvolu->names[i];
3036  Int_t copy = fGcvolu->number[i];
3037  char name[10];
3038  memcpy(name, &gname, 4);
3039  name[4] = 0;
3040  sprintf(fPath, "%s_%d", name, copy);
3041  return fPath;
3042 }
Gcvolu_t * fGcvolu
GCVDMA common structure.
Definition: TGeant3.h:1157
char fPath[512]
Definition: TGeant3.h:1138
Int_t number[15]
Definition: TGeant3.h:287
Int_t names[15]
Definition: TGeant3.h:286
Int_t nlevel
Definition: TGeant3.h:285
T copy(T const &v)
const char * TGeant3::GetPath ( )

Definition at line 3003 of file TGeant3.cxx.

3004 {
3005 // Get current path inside G3 geometry
3006  Int_t i,j;
3007  if ((i=fGcvolu->nlevel-1)<0) {
3008  Warning("GetPath", "level null");
3009  return fPath;
3010  }
3011  fPath[0] = '/';
3012  char name[10];
3013  char *namcur = fPath+1;
3014  Int_t gname, copy;
3015  Int_t nch=0;
3016  for (j=0; j<i+1; j++) {
3017  gname = fGcvolu->names[j];
3018  copy = fGcvolu->number[j];
3019  memcpy(name, &gname, 4);
3020  name[4]=0;
3021  sprintf(namcur, "%s_%d/", name, copy);
3022  nch = strlen(fPath);
3023  namcur = fPath+nch;
3024  }
3025  fPath[nch-1]=0;
3026  return fPath;
3027 }
Gcvolu_t * fGcvolu
GCVDMA common structure.
Definition: TGeant3.h:1157
char fPath[512]
Definition: TGeant3.h:1138
Int_t number[15]
Definition: TGeant3.h:287
Int_t names[15]
Definition: TGeant3.h:286
Int_t nlevel
Definition: TGeant3.h:285
T copy(T const &v)
void TGeant3::GetSecondary ( Int_t  isec,
Int_t &  ipart,
TLorentzVector &  x,
TLorentzVector &  p 
)

Definition at line 2482 of file TGeant3.cxx.

2484 {
2485  //
2486  // Get the parameters of the secondary track number isec produced
2487  // in the current step
2488  //
2489  Int_t i;
2490  if(-1<isec && isec<fGcking->ngkine) {
2491  ipart=Int_t (fGcking->gkin[isec][4] +0.5);
2492  for(i=0;i<3;i++) {
2493  x[i]=fGckin3->gpos[isec][i];
2494  p[i]=fGcking->gkin[isec][i];
2495  }
2496  x[3]=fGcking->tofd[isec];
2497  p[3]=fGcking->gkin[isec][3];
2498  } else {
2499  printf(" * TGeant3::GetSecondary * Secondary %d does not exist\n",isec);
2500  x[0]=x[1]=x[2]=x[3]=p[0]=p[1]=p[2]=p[3]=0;
2501  ipart=0;
2502  }
2503 }
Float_t gpos[MXGKIN][3]
Definition: TGeant3.h:202
Gcking_t * fGcking
GCPHLT common structure.
Definition: TGeant3.h:1163
Gckin3_t * fGckin3
GCKIN2 common structure.
Definition: TGeant3.h:1165
p
Definition: test.py:223
list x
Definition: train.py:276
Float_t gkin[MXGKIN][5]
Definition: TGeant3.h:186
Float_t tofd[MXGKIN]
Definition: TGeant3.h:187
Bool_t TGeant3::GetShape ( const TString &  volumePath,
TString &  shapeType,
TArrayD &  par 
)

Definition at line 6729 of file TGeant3.cxx.

6730  {
6731  // Returns the shape and its parameters for the volume specified
6732  // by the path volumePath. The format of the path volumePath is as
6733  // follows (assuming ALIC is the Top volume)
6734  // "/ALIC_1/DDIP_1/S05I_2/S05H_1/S05G_3". Here ALIC is the top most
6735  // or master volume which has only 1 instance of. Of all of the daughter
6736  // volumes of ALICE, DDIP volume copy #1 is indicated. Similarly for
6737  // the daughter volume of DDIP is S05I copy #2 and so on.
6738  // Inputs:
6739  // TString& volumePath The volume path to the specific volume
6740  // for which you want the matrix. Volume name
6741  // hierarchy is separated by "/" while the
6742  // copy number is appended using a "_".
6743  // Outputs:
6744  // TString &shapeType Shape type
6745  // TArrayD &par A TArrayD of parameters with all of the
6746  // parameters of the specified shape.
6747  // Return:
6748  // A logical indicating whether there was an error in getting this
6749  // information
6750  const Int_t nshapes = 16;
6751  const Char_t *vname[nshapes] = {"BOX","TRD1","TRD2","TRAP","TUBE","TUBS",
6752  "CONE","CONS","SPHE","PARA","PGON","PCON",
6753  "ELTU","HYPE","GTRA","CTUB"};
6754  Int_t volid,i,k,jv0,ishape,npar,*lnam=0,*lnum=0;
6755  Float_t *qpar;
6756 
6757  k=ConvertVolumePathString(volumePath,&lnam,&lnum);//Creates lnam, and lnum
6758  if(k<=0) { // Error from Convert volumePathString.
6759  delete[] lnam;
6760  delete[] lnum;
6761  return kFALSE;
6762  } // end if k<=0
6763  this->Gcvolu()->nlevel = 0;
6764  i = this->Glvolu(k,lnam,lnum);
6765  delete[] lnam;
6766  delete[] lnum;
6767  if(i!=0) {// error
6768  par.Set(0);
6769  return kFALSE;
6770  } // end if i!=1
6771  volid = this->Gcvolu()->lvolum[this->Gcvolu()->nlevel-1];
6772  jv0 = this->Lq()[this->Gclink()->jvolum-volid];
6773  ishape = (Int_t)(this->Q()[jv0+2]);
6774  if(ishape<1||ishape>nshapes) return kFALSE; // error unknown shape
6775  npar = (Int_t)(this->Q()[jv0+5]);
6776  qpar = (this->Q())+jv0+7;
6777  par.Set(npar); // Resize TArrayD
6778  for(i=0;i<npar;i++) par.AddAt((Double_t)qpar[i],i);
6779  shapeType = vname[ishape-1];
6780  shapeType = shapeType.Strip();
6781  return kTRUE;
6782 }
virtual Gcvolu_t * Gcvolu() const
Definition: TGeant3.h:820
Int_t ConvertVolumePathString(const TString &volumeName, Int_t **lnam, Int_t **lnum)
TRCOM3 common structure.
Definition: TGeant3.cxx:6909
Int_t lvolum[15]
Definition: TGeant3.h:288
virtual Float_t * Q() const
Definition: TGeant3.h:832
Int_t nlevel
Definition: TGeant3.h:285
virtual Int_t * Lq() const
Definition: TGeant3.h:831
virtual Int_t Glvolu(Int_t nlev, Int_t *lnam, Int_t *lnum)
Definition: TGeant3.cxx:4520
virtual Gclink_t * Gclink() const
Definition: TGeant3.h:809
Int_t TGeant3::GetSpecialPdg ( Int_t  number) const
protected

Definition at line 7005 of file TGeant3.cxx.

7006 {
7007 // Numbering for special particles
7008 
7009  return 50000000 + number;
7010 }
Bool_t TGeant3::GetTransformation ( const TString &  volumePath,
TGeoHMatrix &  mat 
)

Definition at line 6640 of file TGeant3.cxx.

6640  {
6641  // Returns the Transformation matrix between the volume specified
6642  // by the path volumePath and the Top or mater volume. The format
6643  // of the path volumePath is as follows (assuming ALIC is the Top volume)
6644  // "/ALIC_1/DDIP_1/S05I_2/S05H_1/S05G_3". Here ALIC is the top most
6645  // or master volume which has only 1 instance of. Of all of the daughter
6646  // volumes of ALICE, DDIP volume copy #1 is indicated. Similarly for
6647  // the daughter volume of DDIP is S05I copy #2 and so on.
6648  // Inputs:
6649  // TString& volumePath The volume path to the specific volume
6650  // for which you want the matrix. Volume name
6651  // hierarchy is separated by "/" while the
6652  // copy number is appended using a "_".
6653  // Outputs:
6654  // TGeoHMatrix &mat A matrix with its values set to those
6655  // appropriate to the Local to Master transformation
6656  // Return:
6657  // A logical value if kFALSE then an error occurred and no change to
6658  // mat was made.
6659  Int_t i,n,k,*lnam=0,*lnum=0;
6660  // Default rotation matrix, Unit
6661  Double_t m[9] = {1.0,0.0,0.0,0.0,1.0,0.0,0.0,0.0,1.0};
6662  Double_t s[3] = {1.0,1.0,1.0}; // Default scale, Unit
6663  Double_t t[3] = {0.0,0.0,0.0}; // Default translation, none.
6664 
6665  k =ConvertVolumePathString(volumePath,&lnam,&lnum);//Creates lnam, and lnum
6666  if(k<=0) { // Error from Convert volumePathString.
6667  delete[] lnam;
6668  delete[] lnum;
6669  return kFALSE;
6670  } // end if k<=0
6671  if(k==1){// only one volume listed, must be top most, return unit..
6672  delete[] lnam;
6673  delete[] lnum;
6674  mat.SetRotation(m);
6675  mat.SetTranslation(t);
6676  mat.SetScale(s);
6677  return kTRUE;
6678  } // end if k==1
6679  this->Gcvolu()->nlevel = 0;
6680  i = this->Glvolu(k,lnam,lnum);
6681  n = this->Gcvolu()->nlevel -1;
6682  delete[] lnam; // created in ConvertVolumePathString.
6683  delete[] lnum; // created in ConvertVolumePathString.
6684  if(i!=0) return kFALSE; // Error
6685  mat.SetScale(s); // Geant scale always 1.
6686  if(!((this->Gcvolu()->grmat[n][9])==0.0)) { // not Unit matrix
6687  for(i=0;i<9;i++) m[i] = (Double_t) this->Gcvolu()->grmat[n][i];
6688  } // end if
6689  mat.SetRotation(m);
6690  for(i=0;i<3;i++) t[i] = (Double_t) (this->Gcvolu()->gtran[n][i]);
6691  mat.SetTranslation(t);
6692  return kTRUE;
6693 }/*
static const double m
Definition: Units.h:79
virtual Gcvolu_t * Gcvolu() const
Definition: TGeant3.h:820
Int_t ConvertVolumePathString(const TString &volumeName, Int_t **lnam, Int_t **lnum)
TRCOM3 common structure.
Definition: TGeant3.cxx:6909
Float_t grmat[15][10]
Definition: TGeant3.h:295
Int_t nlevel
Definition: TGeant3.h:285
virtual Int_t Glvolu(Int_t nlev, Int_t *lnam, Int_t *lnum)
Definition: TGeant3.cxx:4520
static const double s
Definition: Units.h:99
Float_t gtran[15][3]
Definition: TGeant3.h:294
void TGeant3::Gfang ( Float_t *  p,
Float_t &  costh,
Float_t &  sinth,
Float_t &  cosph,
Float_t &  sinph,
Int_t &  rotate 
)
virtual

Definition at line 6988 of file TGeant3.cxx.

6990 {
6991 
6992  g3fang(p, costh, sinth, cosph, sinph, rotate );
6993 }
#define g3fang
Definition: TGeant3.cxx:553
p
Definition: test.py:223
void TGeant3::Gfile ( const char *  filename,
const char *  option = "I" 
)
virtual

Definition at line 3069 of file TGeant3.cxx.

3070 {
3071  //
3072  // Routine to open a GEANT/RZ data base.
3073  //
3074  // LUN logical unit number associated to the file
3075  //
3076  // CHFILE RZ file name
3077  //
3078  // CHOPT is a character string which may be
3079  // N To create a new file
3080  // U to open an existing file for update
3081  // " " to open an existing file for read only
3082  // Q The initial allocation (default 1000 records)
3083  // is given in IQUEST(10)
3084  // X Open the file in exchange format
3085  // I Read all data structures from file to memory
3086  // O Write all data structures from memory to file
3087  //
3088  // Note:
3089  // If options "I" or "O" all data structures are read or
3090  // written from/to file and the file is closed.
3091  // See routine GRMDIR to create subdirectories
3092  // See routines GROUT,GRIN to write,read objects
3093  //
3094  //g3rfile(21, PASSCHARD(filename), PASSCHARD(option) PASSCHARL(filename)
3095 // PASSCHARL(option));
3096 }
void TGeant3::Gfinds ( )
virtual

Definition at line 3739 of file TGeant3.cxx.

3740 {
3741  //
3742  // Returns the set/volume parameters corresponding to
3743  // the current space point in /GCTRAK/
3744  // and fill common /GCSETS/
3745  //
3746  // IHSET user set identifier
3747  // IHDET user detector identifier
3748  // ISET set number in JSET
3749  // IDET detector number in JS=LQ(JSET-ISET)
3750  // IDTYPE detector type (1,2)
3751  // NUMBV detector volume numbers (array of length NVNAME)
3752  // NVNAME number of volume levels
3753  //
3754  g3finds();
3755 }
#define g3finds
Definition: TGeant3.cxx:566
void TGeant3::Gfkine ( Int_t  itra,
Float_t *  vert,
Float_t *  pvert,
Int_t &  ipart,
Int_t &  nvert 
)
virtual

Definition at line 3616 of file TGeant3.cxx.

3618 {
3619  // Storing/Retrieving Vertex and Track parameters
3620  // ----------------------------------------------
3621  //
3622  // Stores vertex parameters.
3623  // VERT array of (x,y,z) position of the vertex
3624  // NTBEAM beam track number origin of the vertex
3625  // =0 if none exists
3626  // NTTARG target track number origin of the vertex
3627  // UBUF user array of NUBUF floating point numbers
3628  // NUBUF
3629  // NVTX new vertex number (=0 in case of error).
3630  // Prints vertex parameters.
3631  // IVTX for vertex IVTX.
3632  // (For all vertices if IVTX=0)
3633  // Stores long life track parameters.
3634  // PLAB components of momentum
3635  // IPART type of particle (see GSPART)
3636  // NV vertex number origin of track
3637  // UBUF array of NUBUF floating point user parameters
3638  // NUBUF
3639  // NT track number (if=0 error).
3640  // Retrieves long life track parameters.
3641  // ITRA track number for which parameters are requested
3642  // VERT vector origin of the track
3643  // PVERT 4 momentum components at the track origin
3644  // IPART particle type (=0 if track ITRA does not exist)
3645  // NVERT vertex number origin of the track
3646  // UBUF user words stored in GSKINE.
3647  // Prints initial track parameters.
3648  // ITRA for track ITRA
3649  // (For all tracks if ITRA=0)
3650  //
3651  Float_t *ubuf=0;
3652  Int_t nbuf;
3653  g3fkine(itra,vert,pvert,ipart,nvert,ubuf,nbuf);
3654 }
#define g3fkine
Definition: TGeant3.cxx:559
void TGeant3::Gfmate ( Int_t  imat,
char *  name,
Float_t &  a,
Float_t &  z,
Float_t &  dens,
Float_t &  radl,
Float_t &  absl,
Float_t *  ubuf,
Int_t &  nbuf 
)
virtual

Definition at line 3227 of file TGeant3.cxx.

3230 {
3231  //
3232  // Return parameters for material IMAT
3233  //
3234  g3fmate(imat, PASSCHARD(name), a, z, dens, radl, absl, ubuf, nbuf
3235  PASSCHARL(name));
3236 }
#define PASSCHARL(string)
Definition: TCallf77.h:12
double z
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
Definition: pointer.h:1124
#define g3fmate
Definition: TGeant3.cxx:545
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::Gfmate ( Int_t  imat,
char *  name,
Double_t &  a,
Double_t &  z,
Double_t &  dens,
Double_t &  radl,
Double_t &  absl,
Double_t *  ubuf,
Int_t &  nbuf 
)
virtual

Definition at line 3239 of file TGeant3.cxx.

3242 {
3243  //
3244  // Return parameters for material IMAT
3245  //
3246  Float_t fa = a;
3247  Float_t fz = z;
3248  Float_t fdens = dens;
3249  Float_t fradl = radl;
3250  Float_t fabsl = absl;
3251  Float_t* fubuf = CreateFloatArray(ubuf, nbuf);
3252 
3253  Gfmate(imat, name, fa, fz, fdens, fradl, fabsl, fubuf, nbuf);
3254 
3255  a = fa;
3256  z = fz;
3257  dens = fdens;
3258  radl = fradl;
3259  absl = fabsl;
3260  for (Int_t i=0; i<nbuf; i++) ubuf[i] = fubuf[i];
3261 
3262  delete [] fubuf;
3263 }
Float_t * CreateFloatArray(Float_t *array, Int_t size) const
Definition: TGeant3.cxx:6383
virtual void Gfmate(Int_t imat, char *name, Float_t &a, Float_t &z, Float_t &dens, Float_t &radl, Float_t &absl, Float_t *ubuf, Int_t &nbuf)
Definition: TGeant3.cxx:3227
double z
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
Definition: pointer.h:1124
void TGeant3::Gfpara ( const char *  name,
Int_t  number,
Int_t  intext,
Int_t &  npar,
Int_t &  natt,
Float_t *  par,
Float_t *  att 
)
virtual

Definition at line 4491 of file TGeant3.cxx.

4493 {
4494  //
4495  // Find the parameters of a volume
4496  //
4497  g3fpara(PASSCHARD(name), number, intext, npar, natt, par, att
4498  PASSCHARL(name));
4499 }
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3fpara
Definition: TGeant3.cxx:596
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::Gfpart ( Int_t  ipart,
char *  name,
Int_t &  itrtyp,
Float_t &  amass,
Float_t &  charge,
Float_t &  tlife 
) const
virtual

Definition at line 3266 of file TGeant3.cxx.

3268 {
3269  //
3270  // Return parameters for particle of type IPART
3271  //
3272  //Float_t *ubuf=0;
3273  Float_t ubuf[100];
3274  Int_t nbuf;
3275  Int_t igpart = IdFromPDG(ipart);
3276  g3fpart(igpart, PASSCHARD(name), itrtyp, amass, charge, tlife, ubuf, nbuf
3277  PASSCHARL(name));
3278 }
#define PASSCHARL(string)
Definition: TCallf77.h:12
Int_t IdFromPDG(Int_t pdg) const
Definition: TGeant3.cxx:1476
#define PASSCHARD(string)
Definition: TCallf77.h:11
#define g3fpart
Definition: TGeant3.cxx:546
void TGeant3::Gftmat ( Int_t  imate,
Int_t  ipart,
char *  chmeca,
Int_t  kdim,
Float_t *  tkin,
Float_t *  value,
Float_t *  pcut,
Int_t &  ixst 
)
virtual

Definition at line 3295 of file TGeant3.cxx.

3298 {
3299  //
3300  // Return parameters for material imate
3301  //
3302  g3ftmat(imate, ipart, PASSCHARD(chmeca), kdim,
3303  tkin, value, pcut, ixst PASSCHARL(chmeca));
3304 
3305 }
#define PASSCHARL(string)
Definition: TCallf77.h:12
const GenericPointer< typename T::ValueType > T2 value
Definition: pointer.h:1225
#define g3ftmat
Definition: TGeant3.cxx:548
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::Gftmed ( Int_t  numed,
char *  name,
Int_t &  nmat,
Int_t &  isvol,
Int_t &  ifield,
Float_t &  fieldm,
Float_t &  tmaxfd,
Float_t &  stemax,
Float_t &  deemax,
Float_t &  epsil,
Float_t &  stmin,
Float_t *  buf = 0,
Int_t *  nbuf = 0 
)
virtual

Definition at line 3281 of file TGeant3.cxx.

3285 {
3286  //
3287  // Return parameters for tracking medium NUMED
3288  //
3289  g3ftmed(numed, PASSCHARD(name), nmat, isvol, ifield, fieldm, tmaxfd, stemax,
3290  deemax, epsil, stmin, ubuf, nbuf PASSCHARL(name));
3291 }
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3ftmed
Definition: TGeant3.cxx:547
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::Gfvert ( Int_t  nvtx,
Float_t *  v,
Int_t &  ntbeam,
Int_t &  nttarg,
Float_t &  tofg 
)
virtual

Definition at line 3657 of file TGeant3.cxx.

3659 {
3660  //
3661  // Retrieves the parameter of a vertex bank
3662  // Vertex is generated from tracks NTBEAM NTTARG
3663  // NVTX is the new vertex number
3664  //
3665  Float_t *ubuf=0;
3666  Int_t nbuf;
3667  g3fvert(nvtx,v,ntbeam,nttarg,tofg,ubuf,nbuf);
3668 }
#define g3fvert
Definition: TGeant3.cxx:560
void TGeant3::Ggclos ( )
virtual

Reimplemented in TGeant3TGeo.

Definition at line 3108 of file TGeant3.cxx.

3109 {
3110  //
3111  // Closes off the geometry setting.
3112  // Initializes the search list for the contents of each
3113  // volume following the order they have been positioned, and
3114  // inserting the content '0' when a call to GSNEXT (-1) has
3115  // been required by the user.
3116  // Performs the development of the JVOLUM structure for all
3117  // volumes with variable parameters, by calling GGDVLP.
3118  // Interprets the user calls to GSORD, through GGORD.
3119  // Computes and stores in a bank (next to JVOLUM mother bank)
3120  // the number of levels in the geometrical tree and the
3121  // maximum number of contents per level, by calling GGNLEV.
3122  // Sets status bit for CONCAVE volumes, through GGCAVE.
3123  // Completes the JSET structure with the list of volume names
3124  // which identify uniquely a given physical detector, the
3125  // list of bit numbers to pack the corresponding volume copy
3126  // numbers, and the generic path(s) in the JVOLUM tree,
3127  // through the routine GHCLOS.
3128  //
3129  g3gclos();
3130  // Create internal list of volumes
3131  fVolNames = new char[fGcnum->nvolum+1][5];
3132  Int_t i;
3133  for(i=0; i<fGcnum->nvolum; ++i) {
3134  strncpy(fVolNames[i], (char *) &fZiq[fGclink->jvolum+i+1], 4);
3135  fVolNames[i][4]='\0';
3136  }
3137  strcpy(fVolNames[fGcnum->nvolum],"NULL");
3138 }
Gcnum_t * fGcnum
GCTPOL common structure.
Definition: TGeant3.h:1152
#define g3gclos
Definition: TGeant3.cxx:535
char(* fVolNames)[5]
GCJUMP common structure.
Definition: TGeant3.h:1180
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t nvolum
Definition: TGeant3.h:317
Int_t * fZiq
Definition: TGeant3.h:1140
void TGeant3::Glast ( )
virtual

Definition at line 3141 of file TGeant3.cxx.

3142 {
3143  //
3144  // Finish a Geant run
3145  //
3146  g3last();
3147 }
#define g3last
Definition: TGeant3.cxx:975
void TGeant3::Glmoth ( const char *  iudet,
Int_t  iunum,
Int_t &  nlev,
Int_t *  lvols,
Int_t *  lindx 
)
virtual

Definition at line 3926 of file TGeant3.cxx.

3928 {
3929  //
3930  // Loads the top part of the Volume tree in LVOLS (IVO's),
3931  // LINDX (IN indices) for a given volume defined through
3932  // its name IUDET and number IUNUM.
3933  //
3934  // The routine stores only up to the last level where JVOLUM
3935  // data structure is developed. If there is no development
3936  // above the current level, it returns NLEV zero.
3937  Int_t *idum=0;
3938  g3lmoth(PASSCHARD(iudet), iunum, nlev, lvols, lindx, idum PASSCHARL(iudet));
3939 }
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3lmoth
Definition: TGeant3.cxx:578
#define PASSCHARD(string)
Definition: TCallf77.h:11
Int_t TGeant3::Glvolu ( Int_t  nlev,
Int_t *  lnam,
Int_t *  lnum 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4520 of file TGeant3.cxx.

4521 {
4522  //
4523  // nlev number of levels deep into the volume tree
4524  // size of the arrays lnam and lnum
4525  // lnam an integer array who's 4 bytes contain the ASCII code for the
4526  // volume names
4527  // lnum an integer array containing the copy numbers for that specific
4528  // volume
4529  //
4530  // This routine fills the volume parameters in common /gcvolu/ for a
4531  // physical tree, specified by the list lnam and lnum of volume names
4532  // and numbers, and for all its ascendants up to level 1. This routine
4533  // is optimized and does not re-compute the part of the history already
4534  // available in GCVOLU. This means that if it is used in user programs
4535  // outside the usual framework of the tracking, the user has to initialize
4536  // to zero NLEVEL in the common GCVOLU. It return 0 if there were no
4537  // problems in make the call.
4538  //
4539  Int_t ier;
4540  g3lvolu(nlev, lnam, lnum, ier);
4541  return ier;
4542 }
#define g3lvolu
Definition: TGeant3.cxx:599
void TGeant3::Gmate ( )
virtual

Definition at line 3326 of file TGeant3.cxx.

3327 {
3328  //
3329  // Define standard GEANT materials
3330  //
3331  g3mate();
3332 }
#define g3mate
Definition: TGeant3.cxx:549
void TGeant3::Gmedia ( Float_t *  x,
Int_t &  numed 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 3942 of file TGeant3.cxx.

3943 {
3944  //
3945  // Finds in which volume/medium the point X is, and updates the
3946  // common /GCVOLU/ and the structure JGPAR accordingly.
3947  //
3948  // NUMED returns the tracking medium number, or 0 if point is
3949  // outside the experimental setup.
3950  //
3951 
3952  static Int_t check = 0;
3953  g3media(x,numed,check);
3954 }
#define g3media
Definition: TGeant3.cxx:978
bool check(const std::vector< std::vector< float > > &outputs)
list x
Definition: train.py:276
void TGeant3::Gmtod ( Float_t *  xm,
Float_t *  xd,
Int_t  iflag 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 3957 of file TGeant3.cxx.

3958 {
3959  //
3960  // Computes coordinates XD (in DRS)
3961  // from known coordinates XM in MRS
3962  // The local reference system can be initialized by
3963  // - the tracking routines and GMTOD used in GUSTEP
3964  // - a call to GMEDIA(XM,NUMED,CHECK)
3965  // - a call to GLVOLU(NLEVEL,NAMES,NUMBER,IER)
3966  // (inverse routine is GDTOM)
3967  //
3968  // If IFLAG=1 convert coordinates
3969  // IFLAG=2 convert direction cosines
3970  //
3971  g3mtod(xm, xd, iflag);
3972 }
#define g3mtod
Definition: TGeant3.cxx:580
void TGeant3::Gmtod ( Double_t *  xm,
Double_t *  xd,
Int_t  iflag 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 3975 of file TGeant3.cxx.

3976 {
3977  //
3978  // Computes coordinates XD (in DRS)
3979  // from known coordinates XM in MRS
3980  // The local reference system can be initialized by
3981  // - the tracking routines and GMTOD used in GUSTEP
3982  // - a call to GMEDIA(XM,NUMED,CHECK)
3983  // - a call to GLVOLU(NLEVEL,NAMES,NUMBER,IER)
3984  // (inverse routine is GDTOM)
3985  //
3986  // If IFLAG=1 convert coordinates
3987  // IFLAG=2 convert direction cosines
3988  //
3989 
3990 
3991  Float_t* fxm = CreateFloatArray(xm, 3);
3992  Float_t* fxd = CreateFloatArray(xd, 3);
3993 
3994  Gmtod(fxm, fxd, iflag) ;
3995 
3996  for (Int_t i=0; i<3; i++) {
3997  xm[i] = fxm[i]; xd[i] = fxd[i];
3998  }
3999 
4000  delete [] fxm;
4001  delete [] fxd;
4002 }
Float_t * CreateFloatArray(Float_t *array, Int_t size) const
Definition: TGeant3.cxx:6383
virtual void Gmtod(Float_t *xm, Float_t *xd, Int_t iflag)
Definition: TGeant3.cxx:3957
void TGeant3::Gpart ( )
virtual

Definition at line 3335 of file TGeant3.cxx.

3336 {
3337  //
3338  // Define standard GEANT particles plus selected decay modes
3339  // and branching ratios.
3340  //
3341  g3part();
3342 }
#define g3part
Definition: TGeant3.cxx:550
void TGeant3::Gpcxyz ( )
virtual

Definition at line 3099 of file TGeant3.cxx.

3100 {
3101  //
3102  // Print track and volume parameters at current point
3103  //
3104 
3105  g3pcxyz();
3106 }
#define g3pcxyz
Definition: TGeant3.cxx:534
void TGeant3::Gphysi ( )
virtual

Definition at line 3704 of file TGeant3.cxx.

3705 {
3706  //
3707  // Initialize material constants for all the physics
3708  // mechanisms used by GEANT
3709  //
3710  g3physi();
3711 }
#define g3physi
Definition: TGeant3.cxx:563
Float_t TGeant3::Gprelm ( Float_t  z,
Float_t  t,
Float_t  cut 
)
virtual

Definition at line 3317 of file TGeant3.cxx.

3318 {
3319  //
3320  // To calculate DE/DX in GeV*barn/atom for direct pair production by muons
3321  //
3322  return g3prelm(z,t,bcut);
3323 }
#define g3prelm
Definition: TGeant3.cxx:617
double z
void TGeant3::Gprint ( const char *  name)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 3150 of file TGeant3.cxx.

3151 {
3152  //
3153  // Routine to print data structures
3154  // CHNAME name of a data structure
3155  //
3156  char vname[5];
3157  Vname(name,vname);
3158  g3print(PASSCHARD(vname),0 PASSCHARL(vname));
3159 }
virtual void Vname(const char *name, char *vname)
Definition: TGeant3.cxx:5357
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3print
Definition: TGeant3.cxx:593
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::Gprotm ( Int_t  nmat = 0)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4265 of file TGeant3.cxx.

4266 {
4267  //
4268  // To print rotation matrices structure JROTM
4269  // nmat Rotation matrix number
4270  //
4271  g3protm(nmat);
4272  }
#define g3protm
Definition: TGeant3.cxx:591
void TGeant3::Grndm ( Float_t *  rvec,
Int_t  len 
) const
virtual

Definition at line 3831 of file TGeant3.cxx.

3832 {
3833  //
3834  // To set/retrieve the seed of the random number generator
3835  //
3836  TRandom* r=gMC->GetRandom();
3837  for(Int_t i=0; i<len; rvec[i++]=r->Rndm()) {};
3838 }
void TGeant3::Grndmq ( Int_t &  is1,
Int_t &  is2,
Int_t  iseq,
const Text_t *  chopt 
)
virtual

Definition at line 3841 of file TGeant3.cxx.

3843 {
3844  //
3845  // To set/retrieve the seed of the random number generator
3846  //
3847  /*printf("Dummy grndmq called\n");*/
3848  is1 = gRandom->GetSeed();
3849  is2 = 0;
3850 }
void TGeant3::Grun ( )
virtual

Definition at line 3162 of file TGeant3.cxx.

3163 {
3164  //
3165  // Steering function to process one run
3166  //
3167  g3run();
3168 }
#define g3run
Definition: TGeant3.cxx:539
void TGeant3::Gsatt ( const char *  name,
const char *  att,
Int_t  val 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4397 of file TGeant3.cxx.

4398 {
4399  //
4400  // NAME Volume name
4401  // IOPT Name of the attribute to be set
4402  // IVAL Value to which the attribute is to be set
4403  //
4404  // name= "*" stands for all the volumes.
4405  // iopt can be chosen among the following :
4406  //
4407  // WORK 0=volume name is inactive for the tracking
4408  // 1=volume name is active for the tracking (default)
4409  //
4410  // SEEN 0=volume name is invisible
4411  // 1=volume name is visible (default)
4412  // -1=volume invisible with all its descendants in the tree
4413  // -2=volume visible but not its descendants in the tree
4414  //
4415  // LSTY line style 1,2,3,... (default=1)
4416  // LSTY=7 will produce a very precise approximation for
4417  // revolution bodies.
4418  //
4419  // LWID line width -7,...,1,2,3,..7 (default=1)
4420  // LWID<0 will act as abs(LWID) was set for the volume
4421  // and for all the levels below it. When SHAD is 'ON', LWID
4422  // represent the line width of the scan lines filling the surfaces
4423  // (whereas the FILL value represent their number). Therefore
4424  // tuning this parameter will help to obtain the desired
4425  // quality/performance ratio.
4426  //
4427  // COLO color code -166,...,1,2,..166 (default=1)
4428  // n=1=black
4429  // n=2=red; n=17+m, m=0,25, increasing luminosity according to 'm';
4430  // n=3=green; n=67+m, m=0,25, increasing luminosity according to 'm';
4431  // n=4=blue; n=117+m, m=0,25, increasing luminosity according to 'm';
4432  // n=5=yellow; n=42+m, m=0,25, increasing luminosity according to 'm';
4433  // n=6=violet; n=142+m, m=0,25, increasing luminosity according to 'm';
4434  // n=7=light-blue; n=92+m, m=0,25, increasing luminosity according to 'm';
4435  // color=n*10+m, m=1,2,...9, will produce the same color
4436  // as 'n', but with increasing luminosity according to 'm';
4437  // COLO<0 will act as if abs(COLO) was set for the volume
4438  // and for all the levels below it.
4439  // When for a volume the attribute FILL is > 1 (and the
4440  // option SHAD is on), the ABS of its color code must be < 8
4441  // because an automatic shading of its faces will be
4442  // performed.
4443  //
4444  // FILL (1992) fill area -7,...,0,1,...7 (default=0)
4445  // when option SHAD is "on" the FILL attribute of any
4446  // volume can be set different from 0 (normal drawing);
4447  // if it is set to 1, the faces of such volume will be filled
4448  // with solid colors; if ABS(FILL) is > 1, then a light
4449  // source is placed along the observer line, and the faces of
4450  // such volumes will be painted by colors whose luminosity
4451  // will depend on the amount of light reflected;
4452  // if ABS(FILL) = 1, then it is possible to use all the 166
4453  // colors of the color table, because the automatic shading
4454  // is not performed;
4455  // for increasing values of FILL the drawing will be performed
4456  // with higher and higher resolution improving the quality (the
4457  // number of scan lines used to fill the faces increases with
4458  // FILL); it is possible to set different values of FILL
4459  // for different volumes, in order to optimize at the same time
4460  // the performance and the quality of the picture;
4461  // FILL<0 will act as if abs(FILL) was set for the volume
4462  // and for all the levels below it.
4463  // This kind of drawing can be saved in 'picture files'
4464  // or in view banks.
4465  // 0=drawing without fill area
4466  // 1=faces filled with solid colors and resolution = 6
4467  // 2=lowest resolution (very fast)
4468  // 3=default resolution
4469  // 4=.................
4470  // 5=.................
4471  // 6=.................
4472  // 7=max resolution
4473  // Finally, if a colored background is desired, the FILL
4474  // attribute for the first volume of the tree must be set
4475  // equal to -abs(colo), colo being >0 and <166.
4476  //
4477  // SET set number associated to volume name
4478  // DET detector number associated to volume name
4479  // DTYP detector type (1,2)
4480  //
4481 
4482  char vname[5];
4483  Vname(name,vname);
4484  char vatt[5];
4485  Vname(att,vatt);
4486  g3satt(PASSCHARD(vname), PASSCHARD(vatt), val PASSCHARL(vname)
4487  PASSCHARL(vatt));
4488 }
virtual void Vname(const char *name, char *vname)
Definition: TGeant3.cxx:5357
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3satt
Definition: TGeant3.cxx:595
#define PASSCHARD(string)
Definition: TCallf77.h:11
virtual void TGeant3::Gsbool ( const char *  ,
const char *   
)
inlinevirtual

Definition at line 1002 of file TGeant3.h.

1003  {}
void TGeant3::Gsckov ( Int_t  itmed,
Int_t  npckov,
Float_t *  ppckov,
Float_t *  absco,
Float_t *  effic,
Float_t *  rindex 
)
virtual

Definition at line 3457 of file TGeant3.cxx.

3459 {
3460  //
3461  // Stores the tables for UV photon tracking in medium ITMED
3462  // Please note that it is the user's responsibility to
3463  // provide all the coefficients:
3464  //
3465  //
3466  // ITMED Tracking medium number
3467  // NPCKOV Number of bins of each table
3468  // PPCKOV Value of photon momentum (in GeV)
3469  // ABSCO Absorption coefficients
3470  // dielectric: absorption length in cm
3471  // metals : absorption fraction (0<=x<=1)
3472  // EFFIC Detection efficiency for UV photons
3473  // RINDEX Refraction index (if=0 metal)
3474  //
3475  g3sckov(itmed,npckov,ppckov,absco,effic,rindex);
3476 }
#define g3sckov
Definition: TGeant3.cxx:557
void TGeant3::Gsdk ( Int_t  ipart,
Float_t *  bratio,
Int_t *  mode 
)
virtual

Definition at line 3345 of file TGeant3.cxx.

3346 {
3347 // Defines branching ratios and decay modes for standard
3348 // GEANT particles.
3349  g3sdk(ipart,bratio,mode);
3350 }
#define g3sdk
Definition: TGeant3.cxx:551
void TGeant3::Gsdvn ( const char *  name,
const char *  mother,
Int_t  ndiv,
Int_t  iaxis 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4005 of file TGeant3.cxx.

4007 {
4008  //
4009  // Create a new volume by dividing an existing one
4010  //
4011  // NAME Volume name
4012  // MOTHER Mother volume name
4013  // NDIV Number of divisions
4014  // IAXIS Axis value
4015  //
4016  // X,Y,Z of CAXIS will be translated to 1,2,3 for IAXIS.
4017  // It divides a previously defined volume.
4018  //
4019  char vname[5];
4020  Vname(name,vname);
4021  char vmother[5];
4022  Vname(mother,vmother);
4023 
4024  g3sdvn(PASSCHARD(vname), PASSCHARD(vmother), ndiv, iaxis PASSCHARL(vname)
4025  PASSCHARL(vmother));
4026 }
virtual void Vname(const char *name, char *vname)
Definition: TGeant3.cxx:5357
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3sdvn
Definition: TGeant3.cxx:581
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::Gsdvn2 ( const char *  name,
const char *  mother,
Int_t  ndiv,
Int_t  iaxis,
Double_t  c0i,
Int_t  numed 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4029 of file TGeant3.cxx.

4031 {
4032  //
4033  // Create a new volume by dividing an existing one
4034  //
4035  // Divides mother into ndiv divisions called name
4036  // along axis iaxis starting at coordinate value c0.
4037  // the new volume created will be medium number numed.
4038  //
4039  char vname[5];
4040  Vname(name,vname);
4041  char vmother[5];
4042  Vname(mother,vmother);
4043 
4044  Float_t fc0i = c0i;
4045  g3sdvn2(PASSCHARD(vname), PASSCHARD(vmother), ndiv, iaxis, fc0i, numed
4046  PASSCHARL(vname) PASSCHARL(vmother));
4047 }
virtual void Vname(const char *name, char *vname)
Definition: TGeant3.cxx:5357
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3sdvn2
Definition: TGeant3.cxx:582
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::Gsdvs ( const char *  name,
const char *  mother,
Float_t  step,
Int_t  iaxis,
Int_t  numed 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4050 of file TGeant3.cxx.

4052 {
4053  //
4054  // Create a new volume by dividing an existing one
4055  //
4056  char vname[5];
4057  Vname(name,vname);
4058  char vmother[5];
4059  Vname(mother,vmother);
4060 
4061  g3sdvs(PASSCHARD(vname), PASSCHARD(vmother), step, iaxis, numed
4062  PASSCHARL(vname) PASSCHARL(vmother));
4063 }
virtual void Vname(const char *name, char *vname)
Definition: TGeant3.cxx:5357
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3sdvs
Definition: TGeant3.cxx:583
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::Gsdvs2 ( const char *  name,
const char *  mother,
Float_t  step,
Int_t  iaxis,
Float_t  c0,
Int_t  numed 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4066 of file TGeant3.cxx.

4068 {
4069  //
4070  // Create a new volume by dividing an existing one
4071  //
4072  char vname[5];
4073  Vname(name,vname);
4074  char vmother[5];
4075  Vname(mother,vmother);
4076 
4077  g3sdvs2(PASSCHARD(vname), PASSCHARD(vmother), step, iaxis, c0, numed
4078  PASSCHARL(vname) PASSCHARL(vmother));
4079 }
virtual void Vname(const char *name, char *vname)
Definition: TGeant3.cxx:5357
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3sdvs2
Definition: TGeant3.cxx:584
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::Gsdvt ( const char *  name,
const char *  mother,
Double_t  step,
Int_t  iaxis,
Int_t  numed,
Int_t  ndvmx 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4082 of file TGeant3.cxx.

4084 {
4085  //
4086  // Create a new volume by dividing an existing one
4087  //
4088  // Divides MOTHER into divisions called NAME along
4089  // axis IAXIS in steps of STEP. If not exactly divisible
4090  // will make as many as possible and will center them
4091  // with respect to the mother. Divisions will have medium
4092  // number NUMED. If NUMED is 0, NUMED of MOTHER is taken.
4093  // NDVMX is the expected maximum number of divisions
4094  // (If 0, no protection tests are performed)
4095  //
4096  char vname[5];
4097  Vname(name,vname);
4098  char vmother[5];
4099  Vname(mother,vmother);
4100 
4101  Float_t fstep = step;
4102  g3sdvt(PASSCHARD(vname), PASSCHARD(vmother), fstep, iaxis, numed, ndvmx
4103  PASSCHARL(vname) PASSCHARL(vmother));
4104 }
virtual void Vname(const char *name, char *vname)
Definition: TGeant3.cxx:5357
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3sdvt
Definition: TGeant3.cxx:585
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::Gsdvt2 ( const char *  name,
const char *  mother,
Double_t  step,
Int_t  iaxis,
Double_t  c0,
Int_t  numed,
Int_t  ndvmx 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4107 of file TGeant3.cxx.

4109 {
4110  //
4111  // Create a new volume by dividing an existing one
4112  //
4113  // Divides MOTHER into divisions called NAME along
4114  // axis IAXIS starting at coordinate value C0 with step
4115  // size STEP.
4116  // The new volume created will have medium number NUMED.
4117  // If NUMED is 0, NUMED of mother is taken.
4118  // NDVMX is the expected maximum number of divisions
4119  // (If 0, no protection tests are performed)
4120  //
4121  char vname[5];
4122  Vname(name,vname);
4123  char vmother[5];
4124  Vname(mother,vmother);
4125 
4126  Float_t fstep = step;
4127  Float_t fc0 = c0;
4128  g3sdvt2(PASSCHARD(vname), PASSCHARD(vmother), fstep, iaxis, fc0,
4129  numed, ndvmx PASSCHARL(vname) PASSCHARL(vmother));
4130 }
virtual void Vname(const char *name, char *vname)
Definition: TGeant3.cxx:5357
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3sdvt2
Definition: TGeant3.cxx:586
#define PASSCHARD(string)
Definition: TCallf77.h:11
Int_t TGeant3::Gskine ( Float_t *  plab,
Int_t  ipart,
Int_t  nv,
Float_t *  ubuf = 0,
Int_t  nwbuf = 0 
)
virtual

Definition at line 3671 of file TGeant3.cxx.

3673 {
3674  //
3675  // Store kinematics of track NT into data structure
3676  // Track is coming from vertex NV
3677  //
3678  Int_t nt = 0;
3679  g3skine(plab, ipart, nv, buf, nwbuf, nt);
3680  return nt;
3681 }
#define g3skine
Definition: TGeant3.cxx:561
void TGeant3::Gsking ( Int_t  igk)
virtual

Definition at line 3758 of file TGeant3.cxx.

3759 {
3760  //
3761  // Stores in stack JSTAK either the IGKth track of /GCKING/,
3762  // or the NGKINE tracks when IGK is 0.
3763  //
3764  g3sking(igk);
3765 }
#define g3sking
Definition: TGeant3.cxx:567
void TGeant3::Gskpho ( Int_t  igk)
virtual

Definition at line 3768 of file TGeant3.cxx.

3769 {
3770  //
3771  // Stores in stack JSTAK either the IGKth Cherenkov photon of
3772  // /GCKIN2/, or the NPHOT tracks when IGK is 0.
3773  //
3774  g3skpho(igk);
3775 }
#define g3skpho
Definition: TGeant3.cxx:568
void TGeant3::Gsmate ( Int_t  imat,
const char *  name,
Float_t  a,
Float_t  z,
Float_t  dens,
Float_t  radl,
Float_t  absl 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 3353 of file TGeant3.cxx.

3355 {
3356  //
3357  // Defines a Material
3358  //
3359  // kmat number assigned to the material
3360  // name material name
3361  // a atomic mass in au
3362  // z atomic number
3363  // dens density in g/cm3
3364  // absl absorption length in cm
3365  // if >=0 it is ignored and the program
3366  // calculates it, if <0. -absl is taken
3367  // radl radiation length in cm
3368  // if >=0 it is ignored and the program
3369  // calculates it, if <0. -radl is taken
3370  // buf pointer to an array of user words
3371  // nbuf number of user words
3372  //
3373  Float_t *ubuf=0;
3374  Int_t nbuf=0;
3375  if (dens <= 0 && a != 0 && z != 0) {
3376  Warning("Gsmate","Density was o, set to 0.01 for imat=%d, name=%s",
3377  imat,name);
3378  dens = 0.01;
3379  }
3380  g3smate(imat,PASSCHARD(name), a, z, dens, radl, absl, ubuf, nbuf
3381  PASSCHARL(name));
3382 }
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3smate
Definition: TGeant3.cxx:552
double z
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
Definition: pointer.h:1124
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::Gsmixt ( Int_t  imat,
const char *  name,
Float_t *  a,
Float_t *  z,
Float_t  dens,
Int_t  nlmat,
Float_t *  wmat 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 3385 of file TGeant3.cxx.

3387 {
3388  //
3389  // Defines mixture OR COMPOUND IMAT as composed by
3390  // THE BASIC NLMAT materials defined by arrays A,Z and WMAT
3391  //
3392  // If NLMAT.GT.0 then WMAT contains the PROPORTION BY
3393  // WEIGHTS OF EACH BASIC MATERIAL IN THE MIXTURE.
3394  //
3395  // If NLMAT.LT.0 then WMAT contains the number of atoms
3396  // of a given kind into the molecule of the COMPOUND
3397  // In this case, WMAT in output is changed to relative
3398  // weights.
3399  //
3400  g3smixt(imat,PASSCHARD(name), a, z,dens, nlmat,wmat PASSCHARL(name));
3401 }
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3smixt
Definition: TGeant3.cxx:554
double z
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
Definition: pointer.h:1124
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::Gsord ( const char *  name,
Int_t  iax 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4133 of file TGeant3.cxx.

4134 {
4135  //
4136  // Flags volume CHNAME whose contents will have to be ordered
4137  // along axis IAX, by setting the search flag to -IAX
4138  // IAX = 1 X axis
4139  // IAX = 2 Y axis
4140  // IAX = 3 Z axis
4141  // IAX = 4 Rxy (static ordering only -> GTMEDI)
4142  // IAX = 14 Rxy (also dynamic ordering -> GTNEXT)
4143  // IAX = 5 Rxyz (static ordering only -> GTMEDI)
4144  // IAX = 15 Rxyz (also dynamic ordering -> GTNEXT)
4145  // IAX = 6 PHI (PHI=0 => X axis)
4146  // IAX = 7 THETA (THETA=0 => Z axis)
4147  //
4148 
4149  char vname[5];
4150  Vname(name,vname);
4151  g3sord(PASSCHARD(vname), iax PASSCHARL(vname));
4152 }
virtual void Vname(const char *name, char *vname)
Definition: TGeant3.cxx:5357
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3sord
Definition: TGeant3.cxx:587
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::Gspart ( Int_t  ipart,
const char *  name,
Int_t  itrtyp,
Double_t  amass,
Double_t  charge,
Double_t  tlife 
)
virtual

Definition at line 3404 of file TGeant3.cxx.

3406 {
3407  //
3408  // Store particle parameters
3409  //
3410  // ipart particle code
3411  // name particle name
3412  // itrtyp transport method (see GEANT manual)
3413  // amass mass in GeV/c2
3414  // charge charge in electron units
3415  // tlife lifetime in seconds
3416  //
3417  Float_t *ubuf=0;
3418  Int_t nbuf=0;
3419  Float_t fmass = amass;
3420  Float_t fcharge = charge;
3421  Float_t flife = tlife;
3422 
3423  g3spart(ipart,PASSCHARD(name), itrtyp, fmass, fcharge, flife, ubuf, nbuf
3424  PASSCHARL(name));
3425 }
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3spart
Definition: TGeant3.cxx:555
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::Gspos ( const char *  name,
Int_t  nr,
const char *  mother,
Double_t  x,
Double_t  y,
Double_t  z,
Int_t  irot,
const char *  konly = "ONLY" 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4155 of file TGeant3.cxx.

4158 {
4159  //
4160  // Position a volume into an existing one
4161  //
4162  // NAME Volume name
4163  // NUMBER Copy number of the volume
4164  // MOTHER Mother volume name
4165  // X X coord. of the volume in mother ref. sys.
4166  // Y Y coord. of the volume in mother ref. sys.
4167  // Z Z coord. of the volume in mother ref. sys.
4168  // IROT Rotation matrix number w.r.t. mother ref. sys.
4169  // ONLY ONLY/MANY flag
4170  //
4171  // It positions a previously defined volume in the mother.
4172  //
4173 
4174  TString only = konly;
4175  only.ToLower();
4176  Bool_t isOnly = kFALSE;
4177  if (only.Contains("only")) isOnly = kTRUE;
4178  char vname[5];
4179  Vname(name,vname);
4180  char vmother[5];
4181  Vname(mother,vmother);
4182 
4183  Float_t fx = x;
4184  Float_t fy = y;
4185  Float_t fz = z;
4186  g3spos(PASSCHARD(vname), nr, PASSCHARD(vmother), fx, fy, fz, irot,
4187  PASSCHARD(konly) PASSCHARL(vname) PASSCHARL(vmother)
4188  PASSCHARL(konly));
4189 }
virtual void Vname(const char *name, char *vname)
Definition: TGeant3.cxx:5357
#define PASSCHARL(string)
Definition: TCallf77.h:12
double y
#define g3spos
Definition: TGeant3.cxx:588
double z
list x
Definition: train.py:276
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::Gsposp ( const char *  name,
Int_t  nr,
const char *  mother,
Double_t  x,
Double_t  y,
Double_t  z,
Int_t  irot,
const char *  konly,
Float_t *  upar,
Int_t  np 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4218 of file TGeant3.cxx.

4221 {
4222  //
4223  // Place a copy of generic volume NAME with user number
4224  // NR inside MOTHER, with its parameters UPAR(1..NP)
4225  //
4226 
4227  G3Gsposp(name, nr, mother, x, y, z, irot, konly, upar, np);
4228 }
double y
double z
void G3Gsposp(const char *name, Int_t nr, const char *mother, Double_t x, Double_t y, Double_t z, Int_t irot, const char *konly, Float_t *upar, Int_t np)
Definition: TGeant3.cxx:4192
list x
Definition: train.py:276
void TGeant3::Gsposp ( const char *  name,
Int_t  nr,
const char *  mother,
Double_t  x,
Double_t  y,
Double_t  z,
Int_t  irot,
const char *  konly,
Double_t *  upar,
Int_t  np 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4231 of file TGeant3.cxx.

4234 {
4235  //
4236  // Place a copy of generic volume NAME with user number
4237  // NR inside MOTHER, with its parameters UPAR(1..NP)
4238  //
4239 
4240  Float_t* fupar = CreateFloatArray(upar, np);
4241  G3Gsposp(name, nr, mother, x, y, z, irot, konly, fupar, np);
4242  delete [] fupar;
4243 }
Float_t * CreateFloatArray(Float_t *array, Int_t size) const
Definition: TGeant3.cxx:6383
double y
double z
void G3Gsposp(const char *name, Int_t nr, const char *mother, Double_t x, Double_t y, Double_t z, Int_t irot, const char *konly, Float_t *upar, Int_t np)
Definition: TGeant3.cxx:4192
list x
Definition: train.py:276
void TGeant3::Gsrotm ( Int_t  nmat,
Float_t  theta1,
Float_t  phi1,
Float_t  theta2,
Float_t  phi2,
Float_t  theta3,
Float_t  phi3 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4246 of file TGeant3.cxx.

4248 {
4249  //
4250  // nmat Rotation matrix number
4251  // THETA1 Polar angle for axis I
4252  // PHI1 Azimuthal angle for axis I
4253  // THETA2 Polar angle for axis II
4254  // PHI2 Azimuthal angle for axis II
4255  // THETA3 Polar angle for axis III
4256  // PHI3 Azimuthal angle for axis III
4257  //
4258  // It defines the rotation matrix number IROT.
4259  //
4260 
4261  g3srotm(nmat, theta1, phi1, theta2, phi2, theta3, phi3);
4262 }
#define g3srotm
Definition: TGeant3.cxx:590
void TGeant3::Gsstak ( Int_t  iflag)
virtual

Definition at line 3778 of file TGeant3.cxx.

3779 {
3780  //
3781  // Stores in auxiliary stack JSTAK the particle currently
3782  // described in common /GCKINE/.
3783  //
3784  // On request, creates also an entry in structure JKINE :
3785  // IFLAG =
3786  // 0 : No entry in JKINE structure required (user)
3787  // 1 : New entry in JVERTX / JKINE structures required (user)
3788  // <0 : New entry in JKINE structure at vertex -IFLAG (user)
3789  // 2 : Entry in JKINE structure exists already (from GTREVE)
3790  //
3791  g3sstak(iflag);
3792 }
#define g3sstak
Definition: TGeant3.cxx:569
void TGeant3::Gstmed ( Int_t  numed,
const char *  name,
Int_t  nmat,
Int_t  isvol,
Int_t  ifield,
Float_t  fieldm,
Float_t  tmaxfd,
Float_t  stemax,
Float_t  deemax,
Float_t  epsil,
Float_t  stmin 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 3428 of file TGeant3.cxx.

3432 {
3433  //
3434  // NTMED Tracking medium number
3435  // NAME Tracking medium name
3436  // NMAT Material number
3437  // ISVOL Sensitive volume flag
3438  // IFIELD Magnetic field
3439  // FIELDM Max. field value (Kilogauss)
3440  // TMAXFD Max. angle due to field (deg/step)
3441  // STEMAX Max. step allowed
3442  // DEEMAX Max. fraction of energy lost in a step
3443  // EPSIL Tracking precision (cm)
3444  // STMIN Min. step due to continuous processes (cm)
3445  //
3446  // IFIELD = 0 if no magnetic field; IFIELD = -1 if user decision in GUSWIM;
3447  // IFIELD = 1 if tracking performed with G3RKUTA; IFIELD = 2 if tracking
3448  // performed with G3HELIX; IFIELD = 3 if tracking performed with G3HELX3.
3449  //
3450  Float_t *ubuf=0;
3451  Int_t nbuf=0;
3452  g3stmed(numed,PASSCHARD(name), nmat, isvol, ifield, fieldm, tmaxfd, stemax,
3453  deemax, epsil, stmin, ubuf, nbuf PASSCHARL(name));
3454 }
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3stmed
Definition: TGeant3.cxx:556
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::Gstpar ( Int_t  itmed,
const char *  param,
Double_t  parval 
)
virtual

Definition at line 3590 of file TGeant3.cxx.

3591 {
3592  //
3593  // To change the value of cut or mechanism "CHPAR"
3594  // to a new value PARVAL for tracking medium ITMED
3595  // The data structure JTMED contains the standard tracking
3596  // parameters (CUTS and flags to control the physics processes) which
3597  // are used by default for all tracking media. It is possible to
3598  // redefine individually with GSTPAR any of these parameters for a
3599  // given tracking medium.
3600  // ITMED tracking medium number
3601  // CHPAR is a character string (variable name)
3602  // PARVAL must be given as a floating point.
3603  //
3604 
3605  Float_t fparval = parval;
3606  g3stpar(itmed,PASSCHARD(param), fparval PASSCHARL(param));
3607 }
#define PASSCHARL(string)
Definition: TCallf77.h:12
#define g3stpar
Definition: TGeant3.cxx:558
#define PASSCHARD(string)
Definition: TCallf77.h:11
Int_t TGeant3::Gsvert ( Float_t *  v,
Int_t  ntbeam,
Int_t  nttarg,
Float_t *  ubuf = 0,
Int_t  nwbuf = 0 
)
virtual

Definition at line 3684 of file TGeant3.cxx.

3686 {
3687  //
3688  // Creates a new vertex bank
3689  // Vertex is generated from tracks NTBEAM NTTARG
3690  // NVTX is the new vertex number
3691  //
3692  Int_t nwtx = 0;
3693  g3svert(v, ntbeam, nttarg, ubuf, nwbuf, nwtx);
3694  return nwtx;
3695 }
#define g3svert
Definition: TGeant3.cxx:562
Int_t TGeant3::Gsvolu ( const char *  name,
const char *  shape,
Int_t  nmed,
Float_t *  upar,
Int_t  np 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4299 of file TGeant3.cxx.

4301 {
4302  //
4303  // NAME Volume name
4304  // SHAPE Volume type
4305  // NUMED Tracking medium number
4306  // NPAR Number of shape parameters
4307  // UPAR Vector containing shape parameters
4308  //
4309  // It creates a new volume in the JVOLUM data structure.
4310  //
4311 
4312  Int_t ivolu = 0;
4313  ivolu = G3Gsvolu(name, shape, nmed, upar, npar);
4314  return ivolu;
4315 
4316 }
Int_t G3Gsvolu(const char *name, const char *shape, Int_t nmed, Float_t *upar, Int_t np)
Definition: TGeant3.cxx:4275
Int_t TGeant3::Gsvolu ( const char *  name,
const char *  shape,
Int_t  nmed,
Double_t *  upar,
Int_t  np 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 4319 of file TGeant3.cxx.

4321 {
4322  //
4323  // NAME Volume name
4324  // SHAPE Volume type
4325  // NUMED Tracking medium number
4326  // NPAR Number of shape parameters
4327  // UPAR Vector containing shape parameters
4328  //
4329  // It creates a new volume in the JVOLUM data structure.
4330  //
4331 
4332 
4333  Int_t ivolu = 0;
4334  Float_t* fupar = CreateFloatArray(upar, npar);
4335  ivolu = G3Gsvolu(name, shape, nmed, fupar, npar);
4336  delete [] fupar;
4337  return ivolu;
4338 }
Float_t * CreateFloatArray(Float_t *array, Int_t size) const
Definition: TGeant3.cxx:6383
Int_t G3Gsvolu(const char *name, const char *shape, Int_t nmed, Float_t *upar, Int_t np)
Definition: TGeant3.cxx:4275
void TGeant3::Gsxyz ( )
virtual

Definition at line 3795 of file TGeant3.cxx.

3796 {
3797  //
3798  // Store space point VECT in banks JXYZ
3799  //
3800  g3sxyz();
3801 }
#define g3sxyz
Definition: TGeant3.cxx:570
void TGeant3::Gtrack ( )
virtual

Definition at line 3804 of file TGeant3.cxx.

3805 {
3806  //
3807  // Controls tracking of current particle
3808  //
3809  g3track();
3810 }
#define g3track
Definition: TGeant3.cxx:973
void TGeant3::Gtreve ( )
virtual

Reimplemented in TGeant3TGeo.

Definition at line 3813 of file TGeant3.cxx.

3814 {
3815  //
3816  // Controls tracking of all particles belonging to the current event
3817  //
3818  g3treve();
3819 }
#define g3treve
Definition: TGeant3.cxx:573
void TGeant3::GtreveRoot ( )
virtual

Reimplemented in TGeant3TGeo.

Definition at line 3822 of file TGeant3.cxx.

3823 {
3824  //
3825  // Controls tracking of all particles belonging to the current event
3826  //
3827  gtreveroot();
3828 }
#define gtreveroot
Definition: TGeant3.cxx:974
void TGeant3::Gtrig ( )
virtual

Definition at line 3171 of file TGeant3.cxx.

3172 {
3173  //
3174  // Steering function to process one event
3175  //
3176  g3trig();
3177 
3178  //printf("count_gmedia= %8d\n",count_gmedia);
3179  //printf("count_gtmedi= %8d\n",count_gtmedi);
3180  //printf("count_ginvol= %8d\n",count_ginvol);
3181  //printf("count_gtnext= %8d\n",count_gtnext);
3182 }
#define g3trig
Definition: TGeant3.cxx:540
void TGeant3::Gtrigc ( )
virtual

Definition at line 3185 of file TGeant3.cxx.

3186 {
3187  //
3188  // Clear event partition
3189  //
3190  g3trigc();
3191 }
#define g3trigc
Definition: TGeant3.cxx:541
void TGeant3::Gtrigi ( )
virtual

Definition at line 3194 of file TGeant3.cxx.

3195 {
3196  //
3197  // Initializes event partition
3198  //
3199  g3trigi();
3200 }
#define g3trigi
Definition: TGeant3.cxx:542
void TGeant3::Gwork ( Int_t  nwork)
virtual

Definition at line 3203 of file TGeant3.cxx.

3204 {
3205  //
3206  // Allocates workspace in ZEBRA memory
3207  //
3208  g3work(nwork);
3209 }
#define g3work
Definition: TGeant3.cxx:543
void TGeant3::Gzinit ( )
virtual

Definition at line 3212 of file TGeant3.cxx.

3213 {
3214  //
3215  // To initialize GEANT/ZEBRA data structures
3216  //
3217  g3zinit();
3218 }
#define g3zinit
Definition: TGeant3.cxx:544
Int_t TGeant3::IdFromPDG ( Int_t  pdg) const

Definition at line 1476 of file TGeant3.cxx.

1477 {
1478  //
1479  // Return Geant3 code from PDG and pseudo ENDF code
1480  //
1481  for(Int_t i=0;i<fNPDGCodes;++i)
1482  if(pdg==fPDGCode[i]) return i;
1483  return -1;
1484 }
TArrayI fPDGCode
Definition: TGeant3.h:1186
Int_t fNPDGCodes
Definition: TGeant3.h:1184
void TGeant3::Init ( void  )
virtual

Definition at line 6225 of file TGeant3.cxx.

6226 {
6227  //
6228  //=================Create Materials and geometry
6229  //
6230 
6231  // Some default settings, if not changed by user
6232  if (!TestBit(kTRIG)) SetTRIG(1); // Number of events to be processed
6233  if (!TestBit(kSWIT)) SetSWIT(4, 10); //
6234  if (!TestBit(kDEBU)) SetDEBU(0, 0, 1); //
6235  if (!TestBit(kAUTO)) SetAUTO(1); // Select automatic STMIN etc...
6236  // calc. (AUTO 1) or manual (AUTO 0)
6237  if (!TestBit(kABAN)) SetABAN(0); // Restore 3.16 behaviour for
6238  // abandoned tracks
6239  if (!TestBit(kOPTI)) SetOPTI(2); // Select optimisation level for
6240  // GEANT geometry searches (0,1,2)
6241  if (!TestBit(kERAN)) SetERAN(5.e-7); //
6242 
6243  DefineParticles();
6244  fApplication->AddParticles();
6245  fApplication->AddIons();
6246  fApplication->ConstructGeometry();
6247  FinishGeometry();
6248 #if ROOT_VERSION_CODE >= ROOT_VERSION(5,01,1)
6249  fApplication->ConstructOpGeometry();
6250 #endif
6251  fApplication->InitGeometry();
6252 }
virtual void SetABAN(Int_t par=1)
Definition: TGeant3.cxx:4813
virtual void SetSWIT(Int_t sw, Int_t val=1)
Definition: TGeant3.cxx:5251
virtual void SetDEBU(Int_t emin=1, Int_t emax=999, Int_t emod=1)
Definition: TGeant3.cxx:5057
const double e
void DefineParticles()
Definition: TGeant3.cxx:1497
virtual void SetERAN(Float_t ekmin=1.e-5, Float_t ekmax=1.e4, Int_t nekbin=90)
Definition: TGeant3.cxx:5084
virtual void SetOPTI(Int_t par=2)
Definition: TGeant3.cxx:5176
virtual void SetTRIG(Int_t nevents=1)
Definition: TGeant3.cxx:5266
virtual void FinishGeometry()
Definition: TGeant3.cxx:6205
virtual void SetAUTO(Int_t par=1)
Definition: TGeant3.cxx:4840
void TGeant3::InitGEANE ( )
virtual

Definition at line 1227 of file TGeant3.cxx.

1228 {
1229  //
1230  // Initialize GEANE for default use
1231  //
1232  Float_t pf[3]={0.,0.,0.};
1233  Float_t w1[3]={0.,0.,0.};
1234  Float_t w2[3]={0.,0.,0.};
1235  Float_t p1[3]={0.,0.,0.};
1236  Float_t p2[3]={0.,0.,0.};
1237  Float_t p3[3]={0.,0.,0.};
1238  Float_t cl[3]={0.,0.,0.};
1239  geant3 = this;
1240  geant3->SetECut(1.);
1241  geant3->SetClose(0,pf,999.,w1,w2,p1,p2,p3,cl);
1242 }
virtual void SetClose(Int_t iclose, Float_t *pf, Float_t dstrt, Float_t *w1, Float_t *w2, Float_t *p1, Float_t *p2, Float_t *p3, Float_t *cl)
Definition: TGeant3.cxx:4998
TGeant3 * geant3
Definition: TGeant3.cxx:1072
virtual void SetECut(Float_t gcalpha)
Definition: TGeant3.cxx:4993
void TGeant3::InitHIGZ ( )
virtual

Definition at line 1219 of file TGeant3.cxx.

1220 {
1221  //
1222  // Initialize HIGZ
1223  //
1224 }
void TGeant3::InitLego ( )
virtual

Definition at line 2506 of file TGeant3.cxx.

2507 {
2508  //
2509  // Set switches for lego transport
2510  //
2511  SetSWIT(4,0);
2512  SetDEBU(0,0,0); //do not print a message
2513 }
virtual void SetSWIT(Int_t sw, Int_t val=1)
Definition: TGeant3.cxx:5251
virtual void SetDEBU(Int_t emin=1, Int_t emax=999, Int_t emod=1)
Definition: TGeant3.cxx:5057
virtual Int_t* TGeant3::Iq ( ) const
inlinevirtual

Definition at line 830 of file TGeant3.h.

830 {return fZiq;}
Int_t * fZiq
Definition: TGeant3.h:1140
Bool_t TGeant3::IsNewTrack ( ) const

Definition at line 2321 of file TGeant3.cxx.

2322 {
2323  //
2324  // True if the track is not at the boundary of the current volume
2325  //
2326  return (fGctrak->sleng==0);
2327 }
Float_t sleng
Definition: TGeant3.h:259
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
virtual Bool_t TGeant3::IsRootGeometrySupported ( ) const
inlinevirtual

Reimplemented in TGeant3TGeo.

Definition at line 649 of file TGeant3.h.

649 {return kFALSE;}
Bool_t TGeant3::IsTrackAlive ( ) const

Definition at line 2527 of file TGeant3.cxx.

2528 {
2529  //
2530  // True if the current particle is alive and will continue to be
2531  // transported
2532  //
2533  return (fGctrak->istop==0);
2534 }
Int_t istop
Definition: TGeant3.h:268
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
Bool_t TGeant3::IsTrackDisappeared ( ) const

Definition at line 2516 of file TGeant3.cxx.

2517 {
2518  //
2519  // True if the current particle has disappeared
2520  // either because it decayed or because it underwent
2521  // an inelastic collision
2522  //
2523  return (fGctrak->istop==1);
2524 }
Int_t istop
Definition: TGeant3.h:268
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
Bool_t TGeant3::IsTrackEntering ( ) const

Definition at line 2339 of file TGeant3.cxx.

2340 {
2341  //
2342  // True if this is the first step of the track in the current volume
2343  //
2344  return (fGctrak->inwvol==1);
2345 }
Int_t inwvol
Definition: TGeant3.h:267
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
Bool_t TGeant3::IsTrackExiting ( ) const

Definition at line 2348 of file TGeant3.cxx.

2349 {
2350  //
2351  // True if this is the last step of the track in the current volume
2352  //
2353  return (fGctrak->inwvol==2);
2354 }
Int_t inwvol
Definition: TGeant3.h:267
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
Bool_t TGeant3::IsTrackInside ( ) const

Definition at line 2330 of file TGeant3.cxx.

2331 {
2332  //
2333  // True if the track is not at the boundary of the current volume
2334  //
2335  return (fGctrak->inwvol==0);
2336 }
Int_t inwvol
Definition: TGeant3.h:267
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
Bool_t TGeant3::IsTrackOut ( ) const

Definition at line 2357 of file TGeant3.cxx.

2358 {
2359  //
2360  // True if the track is out of the setup
2361  //
2362  return (fGctrak->inwvol==3);
2363 }
Int_t inwvol
Definition: TGeant3.h:267
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
Bool_t TGeant3::IsTrackStop ( ) const

Definition at line 2366 of file TGeant3.cxx.

2367 {
2368  //
2369  // True if the track energy has fallen below the threshold
2370  //
2371  return (fGctrak->istop==2);
2372 }
Int_t istop
Definition: TGeant3.h:268
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
void TGeant3::LoadAddress ( )
virtual

Reimplemented in TGeant3TGeo.

Definition at line 1245 of file TGeant3.cxx.

1246 {
1247  //
1248  // Assigns the address of the GEANT common blocks to the structures
1249  // that allow their access from C++
1250  //
1251  Int_t *addr;
1252  gcomad(PASSCHARD("QUEST"), (int*&) fQuest PASSCHARL("QUEST"));
1253  gcomad(PASSCHARD("GCBANK"),(int*&) fGcbank PASSCHARL("GCBANK"));
1254  gcomad(PASSCHARD("GCLINK"),(int*&) fGclink PASSCHARL("GCLINK"));
1255  gcomad(PASSCHARD("GCCUTS"),(int*&) fGccuts PASSCHARL("GCCUTS"));
1256  gcomad(PASSCHARD("GCMORE"),(int*&) fGcmore PASSCHARL("GCMORE"));
1257  gcomad(PASSCHARD("GCMULO"),(int*&) fGcmulo PASSCHARL("GCMULO"));
1258  gcomad(PASSCHARD("GCFLAG"),(int*&) fGcflag PASSCHARL("GCFLAG"));
1259  gcomad(PASSCHARD("GCKINE"),(int*&) fGckine PASSCHARL("GCKINE"));
1260  gcomad(PASSCHARD("GCKING"),(int*&) fGcking PASSCHARL("GCKING"));
1261  gcomad(PASSCHARD("GCKIN2"),(int*&) fGckin2 PASSCHARL("GCKIN2"));
1262  gcomad(PASSCHARD("GCKIN3"),(int*&) fGckin3 PASSCHARL("GCKIN3"));
1263  gcomad(PASSCHARD("GCMATE"),(int*&) fGcmate PASSCHARL("GCMATE"));
1264  gcomad(PASSCHARD("GCTMED"),(int*&) fGctmed PASSCHARL("GCTMED"));
1265  gcomad(PASSCHARD("GCTRAK"),(int*&) fGctrak PASSCHARL("GCTRAK"));
1266  gcomad(PASSCHARD("GCTPOL"),(int*&) fGctpol PASSCHARL("GCTPOL"));
1267  gcomad(PASSCHARD("GCVOLU"),(int*&) fGcvolu PASSCHARL("GCVOLU"));
1268  gcomad(PASSCHARD("GCNUM"), (int*&) fGcnum PASSCHARL("GCNUM"));
1269  gcomad(PASSCHARD("GCSETS"),(int*&) fGcsets PASSCHARL("GCSETS"));
1270  gcomad(PASSCHARD("GCPHYS"),(int*&) fGcphys PASSCHARL("GCPHYS"));
1271  gcomad(PASSCHARD("GCPHLT"),(int*&) fGcphlt PASSCHARL("GCPHLT"));
1272  gcomad(PASSCHARD("GCOPTI"),(int*&) fGcopti PASSCHARL("GCOPTI"));
1273  gcomad(PASSCHARD("GCTLIT"),(int*&) fGctlit PASSCHARL("GCTLIT"));
1274  gcomad(PASSCHARD("GCVDMA"),(int*&) fGcvdma PASSCHARL("GCVDMA"));
1275  gcomad(PASSCHARD("GCCHAN"),(int*&) gcchan PASSCHARL("GCCHAN"));
1276 
1277  // Commons for GEANE
1278  gcomad(PASSCHARD("ERTRIO"), (int*&) fErtrio PASSCHARL("ERTRIO"));
1279  gcomad(PASSCHARD("ERTRIO1"),(int*&) fErtrio1 PASSCHARL("ERTRIO1"));
1280  gcomad(PASSCHARD("EROPTS"), (int*&) fEropts PASSCHARL("EROPTS"));
1281  gcomad(PASSCHARD("EROPTC"), (int*&) fEroptc PASSCHARL("EROPTC"));
1282  gcomad(PASSCHARD("ERWORK"), (int*&) fErwork PASSCHARL("ERWORK"));
1283  gcomad(PASSCHARD("GCONST"),(int*&) fGconst PASSCHARL("GCONST"));
1284  gcomad(PASSCHARD("GCONSX"),(int*&) fGconsx PASSCHARL("GCONSX"));
1285  gcomad(PASSCHARD("GCJUMP"),(int*&) fGcjump PASSCHARL("GCJUMP"));
1286 
1287  // Variables for ZEBRA store
1288  gcomad(PASSCHARD("IQ"), addr PASSCHARL("IQ"));
1289  fZiq = addr;
1290  gcomad(PASSCHARD("LQ"), addr PASSCHARL("LQ"));
1291  fZlq = addr;
1292  fZq = (float*)fZiq;
1293  gctrak = fGctrak;
1294  gcvolu = fGcvolu;
1295  gckine = fGckine;
1296 }
#define PASSCHARL(string)
Definition: TCallf77.h:12
Gcflag_t * fGcflag
GCKINE common structure.
Definition: TGeant3.h:1159
Gcphlt_t * fGcphlt
GCPHYS common structure.
Definition: TGeant3.h:1162
Eropts_t * fEropts
ERTRIO1 common structure.
Definition: TGeant3.h:1124
Gcjump_t * fGcjump
GCONSX common structure.
Definition: TGeant3.h:1173
Quest_t * fQuest
Good Old Q of Zebra.
Definition: TGeant3.h:1144
Gctlit_t * fGctlit
GCOPTI common structure.
Definition: TGeant3.h:1155
Gcvolu_t * fGcvolu
GCVDMA common structure.
Definition: TGeant3.h:1157
Gcnum_t * fGcnum
GCTPOL common structure.
Definition: TGeant3.h:1152
Float_t * fZq
Good Old LQ of Zebra.
Definition: TGeant3.h:1142
Gccuts_t * fGccuts
GCLINK common structure.
Definition: TGeant3.h:1147
Gcbank_t * fGcbank
QUEST common structure.
Definition: TGeant3.h:1145
Eroptc_t * fEroptc
EROPTS common structure.
Definition: TGeant3.h:1125
Gcphys_t * fGcphys
GCTMED common structure.
Definition: TGeant3.h:1161
Erwork_t * fErwork
EROPTC common structure.
Definition: TGeant3.h:1126
#define gcomad
Definition: TGeant3.cxx:614
Gcking_t * fGcking
GCPHLT common structure.
Definition: TGeant3.h:1163
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t * fZlq
Good Old IQ of Zebra.
Definition: TGeant3.h:1141
Gcmore_t * fGcmore
GCCUTS common structure.
Definition: TGeant3.h:1148
Gckin2_t * fGckin2
GCKING common structure.
Definition: TGeant3.h:1164
Gckin3_t * fGckin3
GCKIN2 common structure.
Definition: TGeant3.h:1165
Gconsx_t * fGconsx
GCONST common structure.
Definition: TGeant3.h:1172
Gcopti_t * fGcopti
GCSETS common structure.
Definition: TGeant3.h:1154
Gctrak_t * gctrak
Definition: TGeant3.cxx:1069
Gcmulo_t * fGcmulo
GCMORE common structure.
Definition: TGeant3.h:1149
Gcmate_t * fGcmate
GCMULO common structure.
Definition: TGeant3.h:1150
Gckine_t * fGckine
GCVOLU common structure.
Definition: TGeant3.h:1158
Gctpol_t * fGctpol
GCMATE common structure.
Definition: TGeant3.h:1151
Gctmed_t * fGctmed
GCFLAG common structure.
Definition: TGeant3.h:1160
Gcvolu_t * gcvolu
Definition: TGeant3.cxx:1070
Ertrio1_t * fErtrio1
ERTRIO common structure.
Definition: TGeant3.h:1123
Gcvdma_t * fGcvdma
GCTLIT common structure.
Definition: TGeant3.h:1156
Gckine_t * gckine
Definition: TGeant3.cxx:1071
constexpr std::enable_if_t< are_cv_compatible< TO, FROM >::value, std::add_pointer_t< std::remove_pointer_t< TO > > > addr(FROM &from)
Definition: ensurePointer.h:35
Gconst_t * fGconst
GCCHAN common structure.
Definition: TGeant3.h:1171
#define PASSCHARD(string)
Definition: TCallf77.h:11
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
Gcsets_t * fGcsets
GCNUM common structure.
Definition: TGeant3.h:1153
Int_t * fZiq
Definition: TGeant3.h:1140
Gcchan_t * gcchan
Definition: TGeant3.cxx:1078
Ertrio_t * fErtrio
Definition: TGeant3.h:1122
virtual Int_t* TGeant3::Lq ( ) const
inlinevirtual

Definition at line 831 of file TGeant3.h.

831 {return fZlq;}
Int_t * fZlq
Good Old IQ of Zebra.
Definition: TGeant3.h:1141
void TGeant3::Material ( Int_t &  kmat,
const char *  name,
Double_t  a,
Double_t  z,
Double_t  dens,
Double_t  radl,
Double_t  absl,
Float_t *  buf = 0,
Int_t  nwbuf = 0 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 2658 of file TGeant3.cxx.

2661 {
2662  //
2663  // Defines a Material
2664  //
2665  // kmat number assigned to the material
2666  // name material name
2667  // a atomic mass in au
2668  // z atomic number
2669  // dens density in g/cm3
2670  // absl absorption length in cm
2671  // if >=0 it is ignored and the program
2672  // calculates it, if <0. -absl is taken
2673  // radl radiation length in cm
2674  // if >=0 it is ignored and the program
2675  // calculates it, if <0. -radl is taken
2676  // buf pointer to an array of user words
2677  // nbuf number of user words
2678  //
2679 
2680  G3Material(kmat, name, a, z, dens, radl, absl, buf, nwbuf);
2681 }
void G3Material(Int_t &kmat, const char *name, Double_t a, Double_t z, Double_t dens, Double_t radl, Double_t absl, Float_t *buf=0, Int_t nwbuf=0)
Definition: TGeant3.cxx:2613
double z
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
Definition: pointer.h:1124
void TGeant3::Material ( Int_t &  kmat,
const char *  name,
Double_t  a,
Double_t  z,
Double_t  dens,
Double_t  radl,
Double_t  absl,
Double_t *  buf,
Int_t  nwbuf 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 2684 of file TGeant3.cxx.

2687 {
2688  //
2689  // Defines a Material
2690  //
2691  // kmat number assigned to the material
2692  // name material name
2693  // a atomic mass in au
2694  // z atomic number
2695  // dens density in g/cm3
2696  // absl absorption length in cm
2697  // if >=0 it is ignored and the program
2698  // calculates it, if <0. -absl is taken
2699  // radl radiation length in cm
2700  // if >=0 it is ignored and the program
2701  // calculates it, if <0. -radl is taken
2702  // buf pointer to an array of user words
2703  // nbuf number of user words
2704  //
2705 
2706 
2707  Float_t* fbuf = CreateFloatArray(buf, nwbuf);
2708  G3Material(kmat, name, a, z, dens, radl, absl, fbuf, nwbuf);
2709  delete [] fbuf;
2710 }
Float_t * CreateFloatArray(Float_t *array, Int_t size) const
Definition: TGeant3.cxx:6383
void G3Material(Int_t &kmat, const char *name, Double_t a, Double_t z, Double_t dens, Double_t radl, Double_t absl, Float_t *buf=0, Int_t nwbuf=0)
Definition: TGeant3.cxx:2613
double z
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
Definition: pointer.h:1124
void TGeant3::Matrix ( Int_t &  krot,
Double_t  thex,
Double_t  phix,
Double_t  they,
Double_t  phiy,
Double_t  thez,
Double_t  phiz 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 2918 of file TGeant3.cxx.

2920 {
2921  //
2922  // krot rotation matrix number assigned
2923  // theta1 polar angle for axis i
2924  // phi1 azimuthal angle for axis i
2925  // theta2 polar angle for axis ii
2926  // phi2 azimuthal angle for axis ii
2927  // theta3 polar angle for axis iii
2928  // phi3 azimuthal angle for axis iii
2929  //
2930  // it defines the rotation matrix number irot.
2931  //
2932  krot = -1;
2933  Int_t jrotm=fGclink->jrotm;
2934  krot=1;
2935  Int_t ns, i;
2936  if(jrotm>0) {
2937  ns=fZiq[jrotm-2];
2938  krot=ns+1;
2939  for(i=1; i<=ns; i++) {
2940  if(fZlq[jrotm-i]==0) {
2941  krot=i;
2942  break;
2943  }
2944  }
2945  }
2946  g3srotm(krot, thex, phix, they, phiy, thez, phiz);
2947 }
#define g3srotm
Definition: TGeant3.cxx:590
static const double ns
Definition: Units.h:102
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t * fZlq
Good Old IQ of Zebra.
Definition: TGeant3.h:1141
Int_t * fZiq
Definition: TGeant3.h:1140
Double_t TGeant3::MaxStep ( ) const

Definition at line 2567 of file TGeant3.cxx.

2568 {
2569  //
2570  // Return the maximum step length in the current medium
2571  //
2572  return fGctmed->stemax;
2573 }
Float_t stemax
Definition: TGeant3.h:227
Gctmed_t * fGctmed
GCFLAG common structure.
Definition: TGeant3.h:1160
void TGeant3::Medium ( Int_t &  kmed,
const char *  name,
Int_t  nmat,
Int_t  isvol,
Int_t  ifield,
Double_t  fieldm,
Double_t  tmaxfd,
Double_t  stemax,
Double_t  deemax,
Double_t  epsil,
Double_t  stmin,
Float_t *  ubuf = 0,
Int_t  nbuf = 0 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 2858 of file TGeant3.cxx.

2862 {
2863  //
2864  // kmed tracking medium number assigned
2865  // name tracking medium name
2866  // nmat material number
2867  // isvol sensitive volume flag
2868  // ifield magnetic field
2869  // fieldm max. field value (kilogauss)
2870  // tmaxfd max. angle due to field (deg/step)
2871  // stemax max. step allowed
2872  // deemax max. fraction of energy lost in a step
2873  // epsil tracking precision (cm)
2874  // stmin min. step due to continuous processes (cm)
2875  //
2876  // ifield = 0 if no magnetic field; ifield = -1 if user decision in guswim;
2877  // ifield = 1 if tracking performed with g3rkuta; ifield = 2 if tracking
2878  // performed with g3helix; ifield = 3 if tracking performed with g3helx3.
2879  //
2880 
2881  G3Medium(kmed,name,nmat,isvol,ifield,fieldm,tmaxfd,stemax,deemax,epsil,
2882  stmin, ubuf, nbuf);
2883 
2884 }
void G3Medium(Int_t &kmed, const char *name, Int_t nmat, Int_t isvol, Int_t ifield, Double_t fieldm, Double_t tmaxfd, Double_t stemax, Double_t deemax, Double_t epsil, Double_t stmin, Float_t *ubuf=0, Int_t nbuf=0)
Definition: TGeant3.cxx:2810
void TGeant3::Medium ( Int_t &  kmed,
const char *  name,
Int_t  nmat,
Int_t  isvol,
Int_t  ifield,
Double_t  fieldm,
Double_t  tmaxfd,
Double_t  stemax,
Double_t  deemax,
Double_t  epsil,
Double_t  stmin,
Double_t *  ubuf,
Int_t  nbuf 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 2887 of file TGeant3.cxx.

2891 {
2892  //
2893  // kmed tracking medium number assigned
2894  // name tracking medium name
2895  // nmat material number
2896  // isvol sensitive volume flag
2897  // ifield magnetic field
2898  // fieldm max. field value (kilogauss)
2899  // tmaxfd max. angle due to field (deg/step)
2900  // stemax max. step allowed
2901  // deemax max. fraction of energy lost in a step
2902  // epsil tracking precision (cm)
2903  // stmin min. step due to continuous processes (cm)
2904  //
2905  // ifield = 0 if no magnetic field; ifield = -1 if user decision in guswim;
2906  // ifield = 1 if tracking performed with g3rkuta; ifield = 2 if tracking
2907  // performed with g3helix; ifield = 3 if tracking performed with g3helx3.
2908  //
2909 
2910  Float_t* fubuf = CreateFloatArray(ubuf, nbuf);
2911  G3Medium(kmed,name,nmat,isvol,ifield,fieldm,tmaxfd,stemax,deemax,epsil,
2912  stmin, fubuf, nbuf);
2913  delete [] fubuf;
2914 
2915 }
Float_t * CreateFloatArray(Float_t *array, Int_t size) const
Definition: TGeant3.cxx:6383
void G3Medium(Int_t &kmed, const char *name, Int_t nmat, Int_t isvol, Int_t ifield, Double_t fieldm, Double_t tmaxfd, Double_t stemax, Double_t deemax, Double_t epsil, Double_t stmin, Float_t *ubuf=0, Int_t nbuf=0)
Definition: TGeant3.cxx:2810
Int_t TGeant3::MediumId ( const Text_t *  name) const

Definition at line 1842 of file TGeant3.cxx.

1843 {
1844  // Return the unique numeric identifier for medium name
1845 
1846  Int_t nmed = fMedNames.GetEntriesFast();
1847  for ( Int_t imed = 1; imed < nmed; imed++ ) {
1848 
1849  TString name = ((TObjString*)fMedNames.At(imed))->GetString();
1850  if ( name == TString(medName) ) return imed;
1851  }
1852  printf("MediumId: Medium %s not found\n", medName);
1853  return 0;
1854 }
string GetString(xmlDocPtr xml_doc, string node_path)
TObjArray fMedNames
Names of geant volumes as C++ chars.
Definition: TGeant3.h:1181
void TGeant3::Mixture ( Int_t &  kmat,
const char *  name,
Float_t *  a,
Float_t *  z,
Double_t  dens,
Int_t  nlmat,
Float_t *  wmat 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 2746 of file TGeant3.cxx.

2748 {
2749  //
2750  // Defines mixture OR COMPOUND IMAT as composed by
2751  // THE BASIC NLMAT materials defined by arrays A,Z and WMAT
2752  //
2753  // If NLMAT > 0 then wmat contains the proportion by
2754  // weights of each basic material in the mixture.
2755  //
2756  // If nlmat < 0 then WMAT contains the number of atoms
2757  // of a given kind into the molecule of the COMPOUND
2758  // In this case, WMAT in output is changed to relative
2759  // weights.
2760  //
2761 
2762  Float_t* fa = CreateFloatArray(a, TMath::Abs(nlmat));
2763  Float_t* fz = CreateFloatArray(z, TMath::Abs(nlmat));
2764  Float_t* fwmat = CreateFloatArray(wmat, TMath::Abs(nlmat));
2765 
2766  G3Mixture(kmat, name, fa, fz, dens, nlmat, fwmat);
2767  Int_t i;
2768  for (i=0; i<TMath::Abs(nlmat); i++) {
2769  a[i] = fa[i]; z[i] = fz[i]; wmat[i] = fwmat[i];
2770  }
2771 
2772  delete [] fa;
2773  delete [] fz;
2774  delete [] fwmat;
2775 }
Float_t * CreateFloatArray(Float_t *array, Int_t size) const
Definition: TGeant3.cxx:6383
void G3Mixture(Int_t &kmat, const char *name, Float_t *a, Float_t *z, Double_t dens, Int_t nlmat, Float_t *wmat)
Definition: TGeant3.cxx:2713
double z
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
Definition: pointer.h:1124
void TGeant3::Mixture ( Int_t &  kmat,
const char *  name,
Double_t *  a,
Double_t *  z,
Double_t  dens,
Int_t  nlmat,
Double_t *  wmat 
)
virtual

Reimplemented in TGeant3TGeo.

Definition at line 2778 of file TGeant3.cxx.

2780 {
2781  //
2782  // Defines mixture OR COMPOUND IMAT as composed by
2783  // THE BASIC NLMAT materials defined by arrays A,Z and WMAT
2784  //
2785  // If NLMAT > 0 then wmat contains the proportion by
2786  // weights of each basic material in the mixture.
2787  //
2788  // If nlmat < 0 then WMAT contains the number of atoms
2789  // of a given kind into the molecule of the COMPOUND
2790  // In this case, WMAT in output is changed to relative
2791  // weights.
2792  //
2793 
2794  Float_t* fa = CreateFloatArray(a, TMath::Abs(nlmat));
2795  Float_t* fz = CreateFloatArray(z, TMath::Abs(nlmat));
2796  Float_t* fwmat = CreateFloatArray(wmat, TMath::Abs(nlmat));
2797 
2798  G3Mixture(kmat, name, fa, fz, dens, nlmat, fwmat);
2799  Int_t i;
2800  for (i=0; i<TMath::Abs(nlmat); i++) {
2801  a[i] = fa[i]; z[i] = fz[i]; wmat[i] = fwmat[i];
2802  }
2803 
2804  delete [] fa;
2805  delete [] fz;
2806  delete [] fwmat;
2807 }
Float_t * CreateFloatArray(Float_t *array, Int_t size) const
Definition: TGeant3.cxx:6383
void G3Mixture(Int_t &kmat, const char *name, Float_t *a, Float_t *z, Double_t dens, Int_t nlmat, Float_t *wmat)
Definition: TGeant3.cxx:2713
double z
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
Definition: pointer.h:1124
Int_t TGeant3::NextKmat ( ) const
protected
Int_t TGeant3::NextVolUp ( Text_t *  name,
Int_t &  copy 
)

Definition at line 1309 of file TGeant3.cxx.

1310 {
1311  //
1312  // Geometry iterator for moving upward in the geometry tree
1313  // Return next volume up
1314  //
1315  fNextVol--;
1316  Int_t i, gname;
1317  if(fNextVol>=0) {
1318  gname=fGcvolu->names[fNextVol];
1320  i=fGcvolu->lvolum[fNextVol];
1321  name = fVolNames[i-1];
1322  if(gname == fZiq[fGclink->jvolum+i]) return i;
1323  else printf("GeomTree: Volume %s not found in bank\n",name);
1324  }
1325  return 0;
1326 }
Gcvolu_t * fGcvolu
GCVDMA common structure.
Definition: TGeant3.h:1157
Int_t number[15]
Definition: TGeant3.h:287
char(* fVolNames)[5]
GCJUMP common structure.
Definition: TGeant3.h:1180
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t names[15]
Definition: TGeant3.h:286
Int_t lvolum[15]
Definition: TGeant3.h:288
Int_t fNextVol
Definition: TGeant3.h:1137
T copy(T const &v)
Int_t * fZiq
Definition: TGeant3.h:1140
Int_t TGeant3::NofVolDaughters ( const char *  volName) const

Definition at line 1866 of file TGeant3.cxx.

1867 {
1868 // Return number of daughters of the volume specified by volName
1869 // According to A. Morsch' G3toRoot class
1870 // ---
1871 
1872  Int_t idvol = VolId(volName);
1873 
1874  Int_t jvo = fZlq[fGclink->jvolum-idvol];
1875  Int_t nin = Int_t(fZq[jvo+3]);
1876  return nin;
1877 }
Float_t * fZq
Good Old LQ of Zebra.
Definition: TGeant3.h:1142
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t * fZlq
Good Old IQ of Zebra.
Definition: TGeant3.h:1141
Int_t VolId(const Text_t *name) const
Definition: TGeant3.cxx:1828
Int_t TGeant3::NofVolumes ( ) const

Definition at line 1857 of file TGeant3.cxx.

1858 {
1859  //
1860  // Return total number of volumes in the geometry
1861  //
1862  return fGcnum->nvolum;
1863 }
Gcnum_t * fGcnum
GCTPOL common structure.
Definition: TGeant3.h:1152
Int_t nvolum
Definition: TGeant3.h:317
Int_t TGeant3::NSecondaries ( ) const

Definition at line 2375 of file TGeant3.cxx.

2376 {
2377  //
2378  // Number of secondary particles generated in the current step
2379  //
2380  return fGcking->ngkine;
2381 }
Gcking_t * fGcking
GCPHLT common structure.
Definition: TGeant3.h:1163
Int_t ngkine
Definition: TGeant3.h:185
TGeant3& TGeant3::operator= ( const TGeant3 )
inlineprotected

Definition at line 1210 of file TGeant3.h.

1210 {return *this;}
Double_t TGeant3::ParticleCharge ( Int_t  pdg) const
virtual

Definition at line 2154 of file TGeant3.cxx.

2155 {
2156 // Return G3 particle charge (in e)
2157 // ---
2158 
2159  char name[20];
2160  Int_t itrtyp;
2161  Float_t mass, charge, tlife;
2162  Gfpart(pdg,name, itrtyp, mass, charge, tlife);
2163 
2164  return charge;
2165 }
virtual void Gfpart(Int_t ipart, char *name, Int_t &itrtyp, Float_t &amass, Float_t &charge, Float_t &tlife) const
Definition: TGeant3.cxx:3266
TString TGeant3::ParticleClass ( TMCParticleType  particleType) const
protected

Definition at line 6183 of file TGeant3.cxx.

6184 {
6185 //
6186 // Returns particle class name (used in TDatabasePDG) for
6187 // the specified MCParticleType
6188 // ---
6189 
6190  // CHECK
6191  switch (particleType) {
6192  case kPTGamma: return TString("Photon");
6193  case kPTElectron: return TString("Lepton");
6194  case kPTNeutron: return TString("Hadron");
6195  case kPTHadron: return TString("Hadron");
6196  case kPTMuon: return TString("Lepton");
6197  case kPTGeantino: return TString("Special");
6198  case kPTIon: return TString("Ion");
6199  case kPTOpticalPhoton: return TString("Photon");
6200  default: return TString("Unknown");
6201  }
6202 }
Double_t TGeant3::ParticleLifeTime ( Int_t  pdg) const
virtual

Definition at line 2168 of file TGeant3.cxx.

2169 {
2170 // Return G3 particle life time
2171 // ---
2172 
2173  char name[20];
2174  Int_t itrtyp;
2175  Float_t mass, charge, tlife;
2176  Gfpart(pdg, name, itrtyp, mass, charge, tlife);
2177 
2178  return tlife;
2179 }
virtual void Gfpart(Int_t ipart, char *name, Int_t &itrtyp, Float_t &amass, Float_t &charge, Float_t &tlife) const
Definition: TGeant3.cxx:3266
Double_t TGeant3::ParticleMass ( Int_t  pdg) const
virtual

Definition at line 2140 of file TGeant3.cxx.

2141 {
2142 // Return G3 particle mass
2143 // ---
2144 
2145  char name[20];
2146  Int_t itrtyp;
2147  Float_t mass, charge, tlife;
2148  Gfpart(pdg,name, itrtyp, mass, charge, tlife);
2149 
2150  return mass;
2151 }
virtual void Gfpart(Int_t ipart, char *name, Int_t &itrtyp, Float_t &amass, Float_t &charge, Float_t &tlife) const
Definition: TGeant3.cxx:3266
TMCParticleType TGeant3::ParticleMCType ( Int_t  pdg) const
virtual

Definition at line 2182 of file TGeant3.cxx.

2183 {
2184 // Return MC particle type
2185 // ---
2186 
2187  char name[20];
2188  Int_t itrtyp;
2189  Float_t mass, charge, tlife;
2190  Gfpart(pdg,name, itrtyp, mass, charge, tlife);
2191 
2192  return ParticleType(itrtyp);
2193 }
TMCParticleType ParticleType(Int_t itrtyp) const
Definition: TGeant3.cxx:6163
virtual void Gfpart(Int_t ipart, char *name, Int_t &itrtyp, Float_t &amass, Float_t &charge, Float_t &tlife) const
Definition: TGeant3.cxx:3266
TString TGeant3::ParticleName ( Int_t  pdg) const
virtual

Definition at line 2125 of file TGeant3.cxx.

2126 {
2127 // Return G3 particle name
2128 // ---
2129 
2130  char name[21];
2131  Int_t itrtyp;
2132  Float_t amass, charge, tlife;
2133  Gfpart(pdg, name, itrtyp,amass, charge, tlife);
2134  name[20] = '\0';
2135 
2136  return TString(name);
2137 }
virtual void Gfpart(Int_t ipart, char *name, Int_t &itrtyp, Float_t &amass, Float_t &charge, Float_t &tlife) const
Definition: TGeant3.cxx:3266
TMCParticleType TGeant3::ParticleType ( Int_t  itrtyp) const
protected

Definition at line 6163 of file TGeant3.cxx.

6164 {
6165 //
6166 // Returns MCParticleType for the specified G3 transport method code
6167 // ---
6168 
6169  switch (itrtyp) {
6170  case 1: return kPTGamma;
6171  case 2: return kPTElectron;
6172  case 3: return kPTNeutron;
6173  case 4: return kPTHadron;
6174  case 5: return kPTMuon;
6175  case 6: return kPTGeantino;
6176  case 7: return kPTOpticalPhoton;
6177  case 8: return kPTIon;
6178  default: return kPTUndefined;
6179  }
6180 }
Int_t TGeant3::PDGFromId ( Int_t  pdg) const

Definition at line 1487 of file TGeant3.cxx.

1488 {
1489  //
1490  // Return PDG code and pseudo ENDF code from Geant3 code
1491  //
1492  if(id>0 && id<fNPDGCodes) return fPDGCode[id];
1493  else return -1;
1494 }
TArrayI fPDGCode
Definition: TGeant3.h:1186
Int_t fNPDGCodes
Definition: TGeant3.h:1184
void TGeant3::ProcessEvent ( )
virtual

Definition at line 6292 of file TGeant3.cxx.

6293 {
6294  //
6295  // Process one event
6296  //
6297  Gtrigi();
6298  Gtrigc();
6299  Gtrig();
6300 }
virtual void Gtrigi()
Definition: TGeant3.cxx:3194
virtual void Gtrig()
Definition: TGeant3.cxx:3171
virtual void Gtrigc()
Definition: TGeant3.cxx:3185
Bool_t TGeant3::ProcessRun ( Int_t  nevent)
virtual

Definition at line 6255 of file TGeant3.cxx.

6256 {
6257  //
6258  // Process the run and return true if run has finished successfully,
6259  // return false in other cases (run aborted by user)
6260 
6261  Int_t todo = TMath::Abs(nevent);
6262  for (Int_t i=0; i<todo; i++) {
6263  // Process one run (one run = one event)
6264  fGcflag->idevt = i;
6265  fGcflag->ievent = i+1;
6266  if (fStopRun) break;
6267  fApplication->BeginEvent();
6268  if (fStopRun) break;
6269  ProcessEvent();
6270  if (fStopRun) break;
6271  fApplication->FinishEvent();
6272  if (fStopRun) break;
6273  }
6274 
6275  if (fStopRun) printf(" **** Run stopped ***\n");
6276 
6277  Bool_t returnValue = !fStopRun;
6278  fStopRun = kFALSE;
6279 #ifdef STATISTICS
6280  printf("count_gmedia= %8d\n",count_gmedia);
6281  printf("count_gtmedi= %8d\n",count_gtmedi);
6282  printf("count_ginvol= %8d\n",count_ginvol);
6283  printf("count_gtnext= %8d\n",count_gtnext);
6284  stattree->AutoSave();
6285  statfile->Close();
6286  printf("Statistics tree saved.\n");
6287 #endif
6288  return returnValue;
6289 }
Int_t count_gtnext
Definition: TGeant3.cxx:1077
Gcflag_t * fGcflag
GCKINE common structure.
Definition: TGeant3.h:1159
virtual void ProcessEvent()
Definition: TGeant3.cxx:6292
Int_t ievent
Definition: TGeant3.h:152
Int_t count_gmedia
Definition: TGeant3.cxx:1075
Int_t count_gtmedi
Definition: TGeant3.cxx:1076
Int_t count_ginvol
Definition: TGeant3.cxx:1074
Bool_t fStopRun
Definition: TGeant3.h:1191
Int_t idevt
Definition: TGeant3.h:149
TMCProcess TGeant3::ProdProcess ( Int_t  isec) const

Definition at line 2393 of file TGeant3.cxx.

2394 {
2395  //
2396  // Name of the process that has produced the secondary particles
2397  // in the current step
2398 
2399  // Modified: to make use of GCKING/KCASE variable for determining the production
2400  // mechanism of the secondaries. The old method was to pick the first
2401  // active process from the current step's list of active processes
2402  // that had the capability of generating secondaries. This occasionally
2403  // picked the wrong secondary production mechanism.
2404 
2405  Int_t imech=0;
2406 
2407  if ( fGcking->ngkine <= 0 ) return kPNoProcess;
2408 
2409  // Secondaries generated, determine production mechanism hollerith
2410  for (Int_t km = 0; km < MAXMEC; ++km) {
2411  if ( fGcking->kcase == fGctrak->namec[km] ) {
2412  imech = km;
2413  break;
2414  }
2415  }
2416 
2417  TMCProcess vmcmech = G3toVMC(imech+1);
2418  if ( vmcmech == kPNoProcess ) {
2419  // failure to find matching process
2420  printf(
2421  "* TGeant3::ProdProcess secondaries present,but no matching process!* \n");
2422  }
2423 
2424  return vmcmech;
2425 }
#define MAXMEC
Definition: TGeant3.h:239
Gcking_t * fGcking
GCPHLT common structure.
Definition: TGeant3.h:1163
static const double km
Definition: Units.h:72
Int_t kcase
Definition: TGeant3.h:184
TMCProcess G3toVMC(Int_t iproc) const
Definition: TGeant3.cxx:2456
Int_t ngkine
Definition: TGeant3.h:185
Int_t namec[MAXMEC]
Definition: TGeant3.h:253
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
virtual Float_t* TGeant3::Q ( ) const
inlinevirtual

Definition at line 832 of file TGeant3.h.

832 {return fZq;}
Float_t * fZq
Good Old LQ of Zebra.
Definition: TGeant3.h:1142
virtual Quest_t* TGeant3::Quest ( ) const
inlinevirtual

Definition at line 807 of file TGeant3.h.

807 {return fQuest;}
Quest_t * fQuest
Good Old Q of Zebra.
Definition: TGeant3.h:1144
Bool_t TGeant3::SecondariesAreOrdered ( ) const
inline

Definition at line 705 of file TGeant3.h.

705 {return kTRUE;}
void TGeant3::SetABAN ( Int_t  par = 1)
virtual

Definition at line 4813 of file TGeant3.cxx.

4814 {
4815  //
4816  // par = 1 particles will be stopped according to their residual
4817  // range if they are not in a sensitive material and are
4818  // far enough from the boundary
4819  // 0 particles are transported normally
4820  //
4821  fGcphys->dphys1 = par;
4822  SetBit(kABAN);
4823 }
Gcphys_t * fGcphys
GCTMED common structure.
Definition: TGeant3.h:1161
Float_t dphys1
Definition: TGeant3.h:447
void TGeant3::SetANNI ( Int_t  par = 1)
virtual

Definition at line 4827 of file TGeant3.cxx.

4828 {
4829  //
4830  // To control positron annihilation.
4831  // par =0 no annihilation
4832  // =1 annihilation. Decays processed.
4833  // =2 annihilation. No decay products stored.
4834  //
4835  fGcphys->ianni = par;
4836 }
Gcphys_t * fGcphys
GCTMED common structure.
Definition: TGeant3.h:1161
Int_t ianni
Definition: TGeant3.h:423
void TGeant3::SetAUTO ( Int_t  par = 1)
virtual

Definition at line 4840 of file TGeant3.cxx.

4841 {
4842  //
4843  // To control automatic calculation of tracking medium parameters:
4844  // par =0 no automatic calculation;
4845  // =1 automatic calculation.
4846  //
4847  fGctrak->igauto = par;
4848  SetBit(kAUTO);
4849 }
Int_t igauto
Definition: TGeant3.h:269
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
void TGeant3::SetBOMB ( Float_t  bomb = 1)
virtual

Definition at line 4853 of file TGeant3.cxx.

4854 {
4855  //
4856  // BOOM : Exploding factor for volumes position
4857  //
4858  // To 'explode' the detector. If BOOM is positive (values smaller
4859  // than 1. are suggested, but any value is possible)
4860  // all the volumes are shifted by a distance
4861  // proportional to BOOM along the direction between their center
4862  // and the origin of the MARS; the volumes which are symmetric
4863  // with respect to this origin are simply not shown.
4864  // BOOM equal to 0 resets the normal mode.
4865  // A negative (greater than -1.) value of
4866  // BOOM will cause an 'implosion'; for even lower values of BOOM
4867  // the volumes' positions will be reflected respect to the origin.
4868  // This command can be useful to improve the 3D effect for very
4869  // complex detectors. The following commands will make explode the
4870  // detector:
4871  //
4872 }
void TGeant3::SetBorderSurface ( const char *  name,
const char *  vol1Name,
int  vol1CopyNo,
const char *  vol2Name,
int  vol2CopyNo,
const char *  opSurfaceName 
)
virtual

Definition at line 3544 of file TGeant3.cxx.

3548 {
3549  Warning("SetBorderSurface",
3550  Form("Called for border surface %s. Not applicable in Geant3 - setting is ignored.", name));
3551 }
void TGeant3::SetBREM ( Int_t  par = 1)
virtual

Definition at line 4875 of file TGeant3.cxx.

4876 {
4877  //
4878  // To control bremsstrahlung.
4879  // par =0 no bremsstrahlung
4880  // =1 bremsstrahlung. Photon processed.
4881  // =2 bremsstrahlung. No photon stored.
4882  //
4883  fGcphys->ibrem = par;
4884 }
Gcphys_t * fGcphys
GCTMED common structure.
Definition: TGeant3.h:1161
Int_t ibrem
Definition: TGeant3.h:428
void TGeant3::SetCerenkov ( Int_t  itmed,
Int_t  npckov,
Float_t *  ppckov,
Float_t *  absco,
Float_t *  effic,
Float_t *  rindex 
)
virtual

Definition at line 3479 of file TGeant3.cxx.

3481 {
3482  //
3483  // Stores the tables for UV photon tracking in medium ITMED
3484  // Please note that it is the user's responsibility to
3485  // provide all the coefficients:
3486  //
3487  //
3488  // ITMED Tracking medium number
3489  // NPCKOV Number of bins of each table
3490  // PPCKOV Value of photon momentum (in GeV)
3491  // ABSCO Absorption coefficients
3492  // dielectric: absorption length in cm
3493  // metals : absorption fraction (0<=x<=1)
3494  // EFFIC Detection efficiency for UV photons
3495  // RINDEX Refraction index (if=0 metal)
3496  //
3497  g3sckov(itmed,npckov,ppckov,absco,effic,rindex);
3498 }
#define g3sckov
Definition: TGeant3.cxx:557
void TGeant3::SetCerenkov ( Int_t  itmed,
Int_t  npckov,
Double_t *  ppckov,
Double_t *  absco,
Double_t *  effic,
Double_t *  rindex 
)
virtual

Definition at line 3501 of file TGeant3.cxx.

3503 {
3504  //
3505  // Stores the tables for UV photon tracking in medium ITMED
3506  // Please note that it is the user's responsibility to
3507  // provide all the coefficients:
3508  //
3509  //
3510  // ITMED Tracking medium number
3511  // NPCKOV Number of bins of each table
3512  // PPCKOV Value of photon momentum (in GeV)
3513  // ABSCO Absorption coefficients
3514  // dielectric: absorption length in cm
3515  // metals : absorption fraction (0<=x<=1)
3516  // EFFIC Detection efficiency for UV photons
3517  // RINDEX Refraction index (if=0 metal)
3518  //
3519 
3520  Float_t* fppckov = CreateFloatArray(ppckov, npckov);
3521  Float_t* fabsco = CreateFloatArray(absco, npckov);
3522  Float_t* feffic = CreateFloatArray(effic, npckov);
3523  Float_t* frindex = CreateFloatArray(rindex, npckov);
3524 
3525  SetCerenkov(itmed, npckov, fppckov, fabsco, feffic, frindex);
3526 
3527  delete [] fppckov;
3528  delete [] fabsco;
3529  delete [] feffic;
3530  delete [] frindex;
3531 }
Float_t * CreateFloatArray(Float_t *array, Int_t size) const
Definition: TGeant3.cxx:6383
virtual void SetCerenkov(Int_t itmed, Int_t npckov, Float_t *ppckov, Float_t *absco, Float_t *effic, Float_t *rindex)
Definition: TGeant3.cxx:3479
void TGeant3::SetCKOV ( Int_t  par = 1)
virtual

Definition at line 4888 of file TGeant3.cxx.

4889 {
4890  //
4891  // To control Cerenkov production
4892  // par =0 no Cerenkov;
4893  // =1 Cerenkov;
4894  // =2 Cerenkov with primary stopped at each step.
4895  //
4896  fGctlit->itckov = par;
4897 }
Gctlit_t * fGctlit
GCOPTI common structure.
Definition: TGeant3.h:1155
Int_t itckov
Definition: TGeant3.h:493
void TGeant3::SetClipBox ( const char *  name,
Double_t  xmin = -9999,
Double_t  xmax = 0,
Double_t  ymin = -9999,
Double_t  ymax = 0,
Double_t  zmin = -9999,
Double_t  zmax = 0 
)
virtual

Definition at line 4901 of file TGeant3.cxx.

4903 {
4904  //
4905  // The hidden line removal technique is necessary to visualize properly
4906  // very complex detectors. At the same time, it can be useful to visualize
4907  // the inner elements of a detector in detail. This function allows
4908  // subtractions (via boolean operation) of BOX shape from any part of
4909  // the detector, therefore showing its inner contents.
4910  // If "*" is given as the name of the
4911  // volume to be clipped, all volumes are clipped by the given box.
4912  // A volume can be clipped at most twice.
4913  // if a volume is explicitly clipped twice,
4914  // the "*" will not act on it anymore. Giving "." as the name
4915  // of the volume to be clipped will reset the clipping.
4916  // Parameters
4917  // NAME Name of volume to be clipped
4918  // +
4919  // XMIN Lower limit of the Shape X coordinate
4920  // XMAX Upper limit of the Shape X coordinate
4921  // YMIN Lower limit of the Shape Y coordinate
4922  // YMAX Upper limit of the Shape Y coordinate
4923  // ZMIN Lower limit of the Shape Z coordinate
4924  // ZMAX Upper limit of the Shape Z coordinate
4925  //
4926  // This function performs a boolean subtraction between the volume
4927  // NAME and a box placed in the MARS according the values of the given
4928  // coordinates.
4929 
4930 }
void TGeant3::SetClose ( Int_t  iclose,
Float_t *  pf,
Float_t  dstrt,
Float_t *  w1,
Float_t *  w2,
Float_t *  p1,
Float_t *  p2,
Float_t *  p3,
Float_t *  cl 
)
virtual

Definition at line 4998 of file TGeant3.cxx.

5001 {
5002  fGcmore->iclose = iclose;
5003  fGcmore->pfinal[0] = pf[0];
5004  fGcmore->pfinal[1] = pf[1];
5005  fGcmore->pfinal[2] = pf[2];
5006  fGcmore->dstrt = dstrt;
5007  fGcmore->wire1[0] = w1[0];
5008  fGcmore->wire1[1] = w1[1];
5009  fGcmore->wire1[2] = w1[2];
5010  fGcmore->wire2[0] = w2[0];
5011  fGcmore->wire2[1] = w2[1];
5012  fGcmore->wire2[2] = w2[2];
5013  fGcmore->p1[0] = p1[0];
5014  fGcmore->p1[1] = p1[1];
5015  fGcmore->p1[2] = p1[2];
5016  fGcmore->p2[0] = p2[0];
5017  fGcmore->p2[1] = p2[1];
5018  fGcmore->p2[2] = p2[2];
5019  fGcmore->p3[0] = p3[0];
5020  fGcmore->p3[1] = p3[1];
5021  fGcmore->p3[2] = p3[2];
5022  fGcmore->cleng[0] = clen[0];
5023  fGcmore->cleng[1] = clen[1];
5024  fGcmore->cleng[2] = clen[2];
5025 }
Int_t iclose
Definition: TGeant3.h:352
Float_t pfinal[3]
Definition: TGeant3.h:353
Float_t p2[3]
Definition: TGeant3.h:358
Float_t p3[3]
Definition: TGeant3.h:359
Float_t p1[3]
Definition: TGeant3.h:357
Float_t wire2[3]
Definition: TGeant3.h:356
Float_t cleng[3]
Definition: TGeant3.h:360
Gcmore_t * fGcmore
GCCUTS common structure.
Definition: TGeant3.h:1148
Float_t wire1[3]
Definition: TGeant3.h:355
Float_t dstrt
Definition: TGeant3.h:354
void TGeant3::SetColors ( )
virtual

Reimplemented in TGeant3TGeo.

Definition at line 6303 of file TGeant3.cxx.

6304 {
6305  //
6306  // Set the colors for all the volumes
6307  // this is done sequentially for all volumes
6308  // based on the number of their medium
6309  //
6310 
6311  Int_t kv, icol;
6312  Int_t jvolum=fGclink->jvolum;
6313  //Int_t jtmed=fGclink->jtmed;
6314  //Int_t jmate=fGclink->jmate;
6315  Int_t nvolum=fGcnum->nvolum;
6316  char name[5];
6317  //
6318  // Now for all the volumes
6319  for(kv=1;kv<=nvolum;kv++) {
6320  // Get the tracking medium
6321  Int_t itm=Int_t (fZq[fZlq[jvolum-kv]+4]);
6322  // Get the material
6323  //Int_t ima=Int_t (fZq[fZlq[jtmed-itm]+6]);
6324  // Get z
6325  //Float_t z=fZq[fZlq[jmate-ima]+7];
6326  // Find color number
6327  //icol = Int_t(z)%6+2;
6328  //icol = 17+Int_t(z*150./92.);
6329  //icol = kv%6+2;
6330  icol = itm%6+2;
6331  strncpy(name,(char*)&fZiq[jvolum+kv],4);
6332  name[4]='\0';
6333  Gsatt(name,"COLO",icol);
6334  }
6335 }
virtual void Gsatt(const char *name, const char *att, Int_t val)
Definition: TGeant3.cxx:4397
Gcnum_t * fGcnum
GCTPOL common structure.
Definition: TGeant3.h:1152
Float_t * fZq
Good Old LQ of Zebra.
Definition: TGeant3.h:1142
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t * fZlq
Good Old IQ of Zebra.
Definition: TGeant3.h:1141
Int_t nvolum
Definition: TGeant3.h:317
Int_t * fZiq
Definition: TGeant3.h:1140
void TGeant3::SetCOMP ( Int_t  par = 1)
virtual

Definition at line 4933 of file TGeant3.cxx.

4934 {
4935  //
4936  // To control Compton scattering
4937  // par =0 no Compton
4938  // =1 Compton. Electron processed.
4939  // =2 Compton. No electron stored.
4940  //
4941  //
4942  fGcphys->icomp = par;
4943 }
Gcphys_t * fGcphys
GCTMED common structure.
Definition: TGeant3.h:1161
Int_t icomp
Definition: TGeant3.h:403
Bool_t TGeant3::SetCut ( const char *  cutName,
Double_t  cutValue 
)

Definition at line 1940 of file TGeant3.cxx.

1941 {
1942  //
1943  // Set transport cuts for particles
1944  //
1945  Bool_t success = kTRUE;
1946 
1947  if(!strcmp(cutName,"CUTGAM"))
1948  fGccuts->cutgam=cutValue;
1949  else if(!strcmp(cutName,"CUTELE"))
1950  fGccuts->cutele=cutValue;
1951  else if(!strcmp(cutName,"CUTNEU"))
1952  fGccuts->cutneu=cutValue;
1953  else if(!strcmp(cutName,"CUTHAD"))
1954  fGccuts->cuthad=cutValue;
1955  else if(!strcmp(cutName,"CUTMUO"))
1956  fGccuts->cutmuo=cutValue;
1957  else if(!strcmp(cutName,"BCUTE"))
1958  fGccuts->bcute=cutValue;
1959  else if(!strcmp(cutName,"BCUTM"))
1960  fGccuts->bcutm=cutValue;
1961  else if(!strcmp(cutName,"DCUTE"))
1962  fGccuts->dcute=cutValue;
1963  else if(!strcmp(cutName,"DCUTM"))
1964  fGccuts->dcutm=cutValue;
1965  else if(!strcmp(cutName,"PPCUTM"))
1966  fGccuts->ppcutm=cutValue;
1967  else if(!strcmp(cutName,"TOFMAX"))
1968  fGccuts->tofmax=cutValue;
1969  else {
1970  Warning("SetCut","Cut %s not implemented\n",cutName);
1971  success = kFALSE;
1972  }
1973 
1974  return success;
1975 }
Gccuts_t * fGccuts
GCLINK common structure.
Definition: TGeant3.h:1147
Float_t cutneu
Definition: TGeant3.h:335
Float_t cuthad
Definition: TGeant3.h:336
Float_t cutmuo
Definition: TGeant3.h:337
Float_t tofmax
Definition: TGeant3.h:343
Float_t cutgam
Definition: TGeant3.h:333
Float_t bcutm
Definition: TGeant3.h:339
Float_t dcutm
Definition: TGeant3.h:341
Float_t dcute
Definition: TGeant3.h:340
Float_t bcute
Definition: TGeant3.h:338
Float_t ppcutm
Definition: TGeant3.h:342
Float_t cutele
Definition: TGeant3.h:334
void TGeant3::SetCUTS ( Float_t  cutgam,
Float_t  cutele,
Float_t  cutneu,
Float_t  cuthad,
Float_t  cutmuo,
Float_t  bcute,
Float_t  bcutm,
Float_t  dcute,
Float_t  dcutm,
Float_t  ppcutm,
Float_t  tofmax,
Float_t *  gcuts 
)
virtual

Definition at line 4948 of file TGeant3.cxx.

4952 {
4953  //
4954  // CUTGAM Cut for gammas D=0.001
4955  // CUTELE Cut for electrons D=0.001
4956  // CUTHAD Cut for charged hadrons D=0.01
4957  // CUTNEU Cut for neutral hadrons D=0.01
4958  // CUTMUO Cut for muons D=0.01
4959  // BCUTE Cut for electron brems. D=-1.
4960  // BCUTM Cut for muon brems. D=-1.
4961  // DCUTE Cut for electron delta-rays D=-1.
4962  // DCUTM Cut for muon delta-rays D=-1.
4963  // PPCUTM Cut for e+e- pairs by muons D=0.01
4964  // TOFMAX Time of flight cut D=1.E+10
4965  //
4966  // If the default values (-1.) for BCUTE ,BCUTM ,DCUTE ,DCUTM
4967  // are not modified, they will be set to CUTGAM,CUTGAM,CUTELE,CUTELE
4968  // respectively.
4969  // If one of the parameters from CUTGAM to PPCUTM included
4970  // is modified, cross-sections and energy loss tables must be
4971  // recomputed via the function Gphysi.
4972  //
4973  fGccuts->cutgam = cutgam;
4974  fGccuts->cutele = cutele;
4975  fGccuts->cutneu = cutneu;
4976  fGccuts->cuthad = cuthad;
4977  fGccuts->cutmuo = cutmuo;
4978  fGccuts->bcute = bcute;
4979  fGccuts->bcutm = bcutm;
4980  fGccuts->dcute = dcute;
4981  fGccuts->dcutm = dcutm;
4982  fGccuts->ppcutm = ppcutm;
4983  fGccuts->tofmax = tofmax;
4984  fGccuts->gcuts[0] = gcuts[0];
4985  fGccuts->gcuts[1] = gcuts[1];
4986  fGccuts->gcuts[2] = gcuts[2];
4987  fGccuts->gcuts[3] = gcuts[3];
4988  fGccuts->gcuts[4] = gcuts[4];
4989 }
Gccuts_t * fGccuts
GCLINK common structure.
Definition: TGeant3.h:1147
Float_t cutneu
Definition: TGeant3.h:335
Float_t gcuts[5]
Definition: TGeant3.h:344
Float_t cuthad
Definition: TGeant3.h:336
Float_t cutmuo
Definition: TGeant3.h:337
Float_t tofmax
Definition: TGeant3.h:343
Float_t cutgam
Definition: TGeant3.h:333
Float_t bcutm
Definition: TGeant3.h:339
Float_t dcutm
Definition: TGeant3.h:341
Float_t dcute
Definition: TGeant3.h:340
Float_t bcute
Definition: TGeant3.h:338
Float_t ppcutm
Definition: TGeant3.h:342
Float_t cutele
Definition: TGeant3.h:334
void TGeant3::SetDCAY ( Int_t  par = 1)
virtual

Definition at line 5044 of file TGeant3.cxx.

5045 {
5046  //
5047  // To control Decay mechanism.
5048  // par =0 no decays.
5049  // =1 Decays. secondaries processed.
5050  // =2 Decays. No secondaries stored.
5051  //
5052  fGcphys->idcay = par;
5053 }
Int_t idcay
Definition: TGeant3.h:443
Gcphys_t * fGcphys
GCTMED common structure.
Definition: TGeant3.h:1161
void TGeant3::SetDEBU ( Int_t  emin = 1,
Int_t  emax = 999,
Int_t  emod = 1 
)
virtual

Definition at line 5057 of file TGeant3.cxx.

5058 {
5059  //
5060  // Set the debug flag and frequency
5061  // Selected debug output will be printed from
5062  // event emin to even emax each emod event
5063  //
5064  fGcflag->idemin = emin;
5065  fGcflag->idemax = emax;
5066  fGcflag->itest = emod;
5067  SetBit(kDEBU);
5068 }
Gcflag_t * fGcflag
GCKINE common structure.
Definition: TGeant3.h:1159
Int_t idemax
Definition: TGeant3.h:146
Int_t itest
Definition: TGeant3.h:147
Int_t idemin
Definition: TGeant3.h:145
Bool_t TGeant3::SetDecayMode ( Int_t  pdg,
Float_t  bratio[6],
Int_t  mode[6][3] 
)
virtual

Definition at line 5301 of file TGeant3.cxx.

5302 {
5303  //
5304  // Set user decay modes by calling Gsdk
5305  //
5306  if ( pdg == 0 ) {
5307  printf("Cannot define decay mode for particle with PDG=0");
5308  return false;
5309  }
5310 
5311  if ( IdFromPDG(pdg) < 0 ) {
5312  printf("Particle %d not in geant\n",pdg);
5313  return false;
5314  }
5315 
5316  SetUserDecay(pdg);
5317 
5318  Int_t g3mode[6];
5319  Int_t id1,id2,id3;
5320  for (Int_t k1=0; k1<6; k1++) g3mode[k1]=0;
5321  for (Int_t k=0; k<6; k++) {
5322 
5323  if(mode[k][0]!=0) {
5324  id1= IdFromPDG(mode[k][0]);
5325  if ( id1 < 0 ) {
5326  printf("Particle %d not in geant\n",mode[k][0]);
5327  return false;
5328  }
5329  }
5330  else id1=0;
5331 
5332  if(mode[k][1]!=0) {
5333  id2= IdFromPDG(mode[k][1]);
5334  if ( id2 < 0 ) {
5335  printf("Particle %d not in geant\n",mode[k][1]);
5336  return false;
5337  }
5338  }
5339  else id2=0;
5340 
5341  if(mode[k][2]!=0) {
5342  id3= IdFromPDG(mode[k][2]);
5343  if ( id3 < 0 ) {
5344  printf("Particle %d not in geant\n",mode[k][1]);
5345  return false;
5346  }
5347  }
5348  else id3=0;
5349  g3mode[k]=id1 + id2* 100+ id3 * 10000 ;
5350 
5351  }
5352  Gsdk(IdFromPDG(pdg), bratio, g3mode);
5353  return kTRUE;
5354 }
Int_t IdFromPDG(Int_t pdg) const
Definition: TGeant3.cxx:1476
virtual void SetUserDecay(Int_t ipart)
Definition: TGeant3.cxx:5276
virtual void Gsdk(Int_t ipart, Float_t *bratio, Int_t *mode)
Definition: TGeant3.cxx:3345
void TGeant3::SetDRAY ( Int_t  par = 1)
virtual

Definition at line 5072 of file TGeant3.cxx.

5073 {
5074  //
5075  // To control delta rays mechanism.
5076  // par =0 no delta rays.
5077  // =1 Delta rays. secondaries processed.
5078  // =2 Delta rays. No secondaries stored.
5079  //
5080  fGcphys->idray = par;
5081 }
Gcphys_t * fGcphys
GCTMED common structure.
Definition: TGeant3.h:1161
Int_t idray
Definition: TGeant3.h:418
void TGeant3::SetECut ( Float_t  gcalpha)
virtual

Definition at line 4993 of file TGeant3.cxx.

4994 {
4995  fGcmore->gcalpha = gcalpha;
4996 }
Gcmore_t * fGcmore
GCCUTS common structure.
Definition: TGeant3.h:1148
Float_t gcalpha
Definition: TGeant3.h:351
void TGeant3::SetERAN ( Float_t  ekmin = 1.e-5,
Float_t  ekmax = 1.e4,
Int_t  nekbin = 90 
)
virtual

Definition at line 5084 of file TGeant3.cxx.

5085 {
5086  //
5087  // To control cross section tabulations
5088  // ekmin = minimum kinetic energy in GeV
5089  // ekmax = maximum kinetic energy in GeV
5090  // nekbin = number of logarithmic bins (<200)
5091  //
5092  fGcmulo->ekmin = ekmin;
5093  fGcmulo->ekmax = ekmax;
5094  fGcmulo->nekbin = nekbin;
5095  SetBit(kERAN);
5096 }
Float_t ekmin
Definition: TGeant3.h:372
Int_t nekbin
Definition: TGeant3.h:374
Float_t ekmax
Definition: TGeant3.h:373
Gcmulo_t * fGcmulo
GCMORE common structure.
Definition: TGeant3.h:1149
void TGeant3::SetHADR ( Int_t  par = 1)
virtual

Definition at line 5099 of file TGeant3.cxx.

5100 {
5101  //
5102  // To control hadronic interactions.
5103  // par =0 no hadronic interactions.
5104  // =1 Hadronic interactions. secondaries processed.
5105  // =2 Hadronic interactions. No secondaries stored.
5106  //
5107  fGcphys->ihadr = par;
5108 }
Gcphys_t * fGcphys
GCTMED common structure.
Definition: TGeant3.h:1161
Int_t ihadr
Definition: TGeant3.h:433
void TGeant3::SetKINE ( Int_t  kine,
Float_t  xk1 = 0,
Float_t  xk2 = 0,
Float_t  xk3 = 0,
Float_t  xk4 = 0,
Float_t  xk5 = 0,
Float_t  xk6 = 0,
Float_t  xk7 = 0,
Float_t  xk8 = 0,
Float_t  xk9 = 0,
Float_t  xk10 = 0 
)
virtual

Definition at line 5111 of file TGeant3.cxx.

5114 {
5115  //
5116  // Set the variables in /GCFLAG/ IKINE, PKINE(10)
5117  // Their meaning is user defined
5118  //
5119  fGckine->ikine = kine;
5120  fGckine->pkine[0] = xk1;
5121  fGckine->pkine[1] = xk2;
5122  fGckine->pkine[2] = xk3;
5123  fGckine->pkine[3] = xk4;
5124  fGckine->pkine[4] = xk5;
5125  fGckine->pkine[5] = xk6;
5126  fGckine->pkine[6] = xk7;
5127  fGckine->pkine[7] = xk8;
5128  fGckine->pkine[8] = xk9;
5129  fGckine->pkine[9] = xk10;
5130 }
Float_t pkine[10]
Definition: TGeant3.h:164
Int_t ikine
Definition: TGeant3.h:163
Gckine_t * fGckine
GCVOLU common structure.
Definition: TGeant3.h:1158
void TGeant3::SetLOSS ( Int_t  par = 2)
virtual

Definition at line 5133 of file TGeant3.cxx.

5134 {
5135  //
5136  // To control energy loss.
5137  // par =0 no energy loss;
5138  // =1 restricted energy loss fluctuations;
5139  // =2 complete energy loss fluctuations;
5140  // =3 same as 1;
5141  // =4 no energy loss fluctuations.
5142  // If the value ILOSS is changed, then cross-sections and energy loss
5143  // tables must be recomputed via the command 'PHYSI'.
5144  //
5145  fGcphys->iloss = par;
5146 }
Int_t iloss
Definition: TGeant3.h:448
Gcphys_t * fGcphys
GCTMED common structure.
Definition: TGeant3.h:1161
void TGeant3::SetMaterialProperty ( Int_t  itmed,
const char *  propertyName,
Int_t  np,
Double_t *  pp,
Double_t *  values 
)
virtual

Definition at line 3563 of file TGeant3.cxx.

3566 {
3567  Warning("SetMaterialProperty",
3568  Form("Called for material ID %5d. Not applicable in Geant3 - setting is ignored.", itmed));
3569 }
void TGeant3::SetMaterialProperty ( Int_t  itmed,
const char *  propertyName,
Double_t  value 
)
virtual

Definition at line 3572 of file TGeant3.cxx.

3575 {
3576  Warning("SetMaterialProperty",
3577  Form("Called for material ID %5d. Not applicable in Geant3 - setting is ignored.", itmed));
3578 }
void TGeant3::SetMaterialProperty ( const char *  surfaceName,
const char *  propertyName,
Int_t  np,
Double_t *  pp,
Double_t *  values 
)
virtual

Definition at line 3581 of file TGeant3.cxx.

3584  {
3585  Warning("SetMaterialProperty",
3586  Form("Called for material surface %s. Not applicable in Geant3 - setting is ignored.", surfaceName));
3587 }
void TGeant3::SetMaxNStep ( Int_t  maxnstp)

Definition at line 2585 of file TGeant3.cxx.

2586 {
2587  //
2588  // Set the maximum number of steps till the particle is in the current medium
2589  //
2590  fGctrak->maxnst=maxnstp;
2591 }
Int_t maxnst
Definition: TGeant3.h:255
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
void TGeant3::SetMaxStep ( Double_t  maxstep)

Definition at line 2576 of file TGeant3.cxx.

2577 {
2578  //
2579  // Set the maximum step allowed till the particle is in the current medium
2580  //
2581  fGctmed->stemax=maxstep;
2582 }
Float_t stemax
Definition: TGeant3.h:227
Gctmed_t * fGctmed
GCFLAG common structure.
Definition: TGeant3.h:1160
void TGeant3::SetMULS ( Int_t  par = 1)
virtual

Definition at line 5150 of file TGeant3.cxx.

5151 {
5152  //
5153  // To control multiple scattering.
5154  // par =0 no multiple scattering.
5155  // =1 Moliere or Coulomb scattering.
5156  // =2 Moliere or Coulomb scattering.
5157  // =3 Gaussian scattering.
5158  //
5159  fGcphys->imuls = par;
5160 }
Int_t imuls
Definition: TGeant3.h:453
Gcphys_t * fGcphys
GCTMED common structure.
Definition: TGeant3.h:1161
void TGeant3::SetMUNU ( Int_t  par = 1)
virtual

Definition at line 5164 of file TGeant3.cxx.

5165 {
5166  //
5167  // To control muon nuclear interactions.
5168  // par =0 no muon-nuclear interactions.
5169  // =1 Nuclear interactions. Secondaries processed.
5170  // =2 Nuclear interactions. Secondaries not processed.
5171  //
5172  fGcphys->imunu = par;
5173 }
Gcphys_t * fGcphys
GCTMED common structure.
Definition: TGeant3.h:1161
Int_t imunu
Definition: TGeant3.h:438
void TGeant3::SetOPTI ( Int_t  par = 2)
virtual

Definition at line 5176 of file TGeant3.cxx.

5177 {
5178  //
5179  // This flag controls the tracking optimization performed via the
5180  // GSORD routine:
5181  // 1 no optimization at all; GSORD calls disabled;
5182  // 0 no optimization; only user calls to GSORD kept;
5183  // 1 all non-GSORDered volumes are ordered along the best axis;
5184  // 2 all volumes are ordered along the best axis.
5185  //
5186  fGcopti->ioptim = par;
5187  SetBit(kOPTI);
5188 }
Int_t ioptim
Definition: TGeant3.h:482
Gcopti_t * fGcopti
GCSETS common structure.
Definition: TGeant3.h:1154
void TGeant3::SetPAIR ( Int_t  par = 1)
virtual

Definition at line 5191 of file TGeant3.cxx.

5192 {
5193  //
5194  // To control pair production mechanism.
5195  // par =0 no pair production.
5196  // =1 Pair production. secondaries processed.
5197  // =2 Pair production. No secondaries stored.
5198  //
5199  fGcphys->ipair = par;
5200 }
Gcphys_t * fGcphys
GCTMED common structure.
Definition: TGeant3.h:1161
Int_t ipair
Definition: TGeant3.h:398
void TGeant3::SetPFIS ( Int_t  par = 1)
virtual

Definition at line 5204 of file TGeant3.cxx.

5205 {
5206  //
5207  // To control photo fission mechanism.
5208  // par =0 no photo fission.
5209  // =1 Photo fission. secondaries processed.
5210  // =2 Photo fission. No secondaries stored.
5211  //
5212  fGcphys->ipfis = par;
5213 }
Gcphys_t * fGcphys
GCTMED common structure.
Definition: TGeant3.h:1161
Int_t ipfis
Definition: TGeant3.h:413
void TGeant3::SetPHOT ( Int_t  par = 1)
virtual

Definition at line 5216 of file TGeant3.cxx.

5217 {
5218  //
5219  // To control Photo effect.
5220  // par =0 no photo electric effect.
5221  // =1 Photo effect. Electron processed.
5222  // =2 Photo effect. No electron stored.
5223  //
5224  fGcphys->iphot = par;
5225 }
Gcphys_t * fGcphys
GCTMED common structure.
Definition: TGeant3.h:1161
Int_t iphot
Definition: TGeant3.h:408
Bool_t TGeant3::SetProcess ( const char *  flagName,
Int_t  flagValue 
)

Definition at line 1978 of file TGeant3.cxx.

1979 {
1980  //
1981  // Set thresholds for different processes
1982  //
1983  Bool_t success = kTRUE;
1984 
1985  if(!strcmp(flagName,"PAIR"))
1986  fGcphys->ipair=flagValue;
1987  else if(!strcmp(flagName,"COMP"))
1988  fGcphys->icomp=flagValue;
1989  else if(!strcmp(flagName,"PHOT"))
1990  fGcphys->iphot=flagValue;
1991  else if(!strcmp(flagName,"PFIS"))
1992  fGcphys->ipfis=flagValue;
1993  else if(!strcmp(flagName,"DRAY"))
1994  fGcphys->idray=flagValue;
1995  else if(!strcmp(flagName,"ANNI"))
1996  fGcphys->ianni=flagValue;
1997  else if(!strcmp(flagName,"BREM"))
1998  fGcphys->ibrem=flagValue;
1999  else if(!strcmp(flagName,"HADR"))
2000  fGcphys->ihadr=flagValue;
2001  else if(!strcmp(flagName,"MUNU"))
2002  fGcphys->imunu=flagValue;
2003  else if(!strcmp(flagName,"DCAY"))
2004  fGcphys->idcay=flagValue;
2005  else if(!strcmp(flagName,"LOSS"))
2006  fGcphys->iloss=flagValue;
2007  else if(!strcmp(flagName,"MULS"))
2008  fGcphys->imuls=flagValue;
2009  else if(!strcmp(flagName,"RAYL"))
2010  fGcphys->irayl=flagValue;
2011  else if(!strcmp(flagName,"STRA"))
2012  fGcphlt->istra=flagValue;
2013  else if(!strcmp(flagName,"SYNC"))
2014  fGcphlt->isync=flagValue;
2015  else if(!strcmp(flagName,"CKOV"))
2016  fGctlit->itckov = flagValue;
2017  else {
2018  Warning("SetFlag","Flag %s not implemented\n",flagName);
2019  success = kFALSE;
2020  }
2021 
2022  return success;
2023 }
Int_t idcay
Definition: TGeant3.h:443
Gcphlt_t * fGcphlt
GCPHYS common structure.
Definition: TGeant3.h:1162
Gctlit_t * fGctlit
GCOPTI common structure.
Definition: TGeant3.h:1155
Int_t iloss
Definition: TGeant3.h:448
Int_t imuls
Definition: TGeant3.h:453
Gcphys_t * fGcphys
GCTMED common structure.
Definition: TGeant3.h:1161
Int_t icomp
Definition: TGeant3.h:403
Int_t iphot
Definition: TGeant3.h:408
Int_t itckov
Definition: TGeant3.h:493
Int_t ianni
Definition: TGeant3.h:423
Int_t istra
Definition: TGeant3.h:476
Int_t ihadr
Definition: TGeant3.h:433
Int_t ibrem
Definition: TGeant3.h:428
Int_t idray
Definition: TGeant3.h:418
Int_t ipair
Definition: TGeant3.h:398
Int_t imunu
Definition: TGeant3.h:438
Int_t irayl
Definition: TGeant3.h:458
Int_t ipfis
Definition: TGeant3.h:413
Int_t isync
Definition: TGeant3.h:475
void TGeant3::SetRAYL ( Int_t  par = 1)
virtual

Definition at line 5228 of file TGeant3.cxx.

5229 {
5230  //
5231  // To control Rayleigh scattering.
5232  // par =0 no Rayleigh scattering.
5233  // =1 Rayleigh.
5234  //
5235  fGcphys->irayl = par;
5236 }
Gcphys_t * fGcphys
GCTMED common structure.
Definition: TGeant3.h:1161
Int_t irayl
Definition: TGeant3.h:458
void TGeant3::SetRootGeometry ( )
virtual

Reimplemented in TGeant3TGeo.

Definition at line 2981 of file TGeant3.cxx.

2982 {
2983 // Notify Geant3 about use of TGeo geometry.
2984 // The materials and tracking medias will be imported from
2985 // TGeo at FinishGeometry().
2986 
2987  Fatal("SetRootGeometry",
2988  "TGeant3 does not support Root geometry");
2989 
2990  fImportRootGeometry = kTRUE;
2991 }
Bool_t fImportRootGeometry
Definition: TGeant3.h:1188
void TGeant3::SetSkinSurface ( const char *  name,
const char *  volName,
const char *  opSurfaceName 
)
virtual

Definition at line 3554 of file TGeant3.cxx.

3557 {
3558  Warning("SetSkinSurface",
3559  Form("Called for skin surface %s. Not applicable in Geant3 - setting is ignored.", name));
3560 }
void TGeant3::SetSkipNeutrinos ( Bool_t  flag)
inline

Definition at line 714 of file TGeant3.h.

714 {fSkipNeutrinos = flag;}
Bool_t fSkipNeutrinos
Definition: TGeant3.h:1192
void TGeant3::SetSTRA ( Int_t  par = 0)
virtual

Definition at line 5239 of file TGeant3.cxx.

5240 {
5241  //
5242  // To control energy loss fluctuations
5243  // with the Photo-Absorption Ionization model.
5244  // par =0 no Straggling.
5245  // =1 Straggling yes => no Delta rays.
5246  //
5247  fGcphlt->istra = par;
5248 }
Gcphlt_t * fGcphlt
GCPHYS common structure.
Definition: TGeant3.h:1162
Int_t istra
Definition: TGeant3.h:476
void TGeant3::SetSWIT ( Int_t  sw,
Int_t  val = 1 
)
virtual

Definition at line 5251 of file TGeant3.cxx.

5252 {
5253  //
5254  // sw Switch number
5255  // val New switch value
5256  //
5257  // Change one element of array ISWIT(10) in /GCFLAG/
5258  //
5259  if (sw <= 0 || sw > 10) return;
5260  fGcflag->iswit[sw-1] = val;
5261  SetBit(kSWIT);
5262 }
Gcflag_t * fGcflag
GCKINE common structure.
Definition: TGeant3.h:1159
Int_t iswit[10]
Definition: TGeant3.h:153
void TGeant3::SetTrack ( Int_t  done,
Int_t  parent,
Int_t  pdg,
Float_t *  pmom,
Float_t *  vpos,
Float_t *  polar,
Float_t  tof,
TMCProcess  mech,
Int_t &  ntr,
Float_t  weight,
Int_t  is 
)

Definition at line 6338 of file TGeant3.cxx.

6341 {
6342  //
6343  // Load a track on the stack
6344  //
6345  // done 0 if the track has to be transported
6346  // 1 if not
6347  // parent identifier of the parent track. -1 for a primary
6348  // pdg particle code
6349  // pmom momentum GeV/c
6350  // vpos position
6351  // polar polarization
6352  // tof time of flight in seconds
6353  // mecha production mechanism
6354  // ntr on output the number of the track stored
6355  //
6356 
6357  // const Float_t tlife=0;
6358 
6359  //
6360  // Here we get the static mass
6361  // For MC is ok, but a more sophisticated method could be necessary
6362  // if the calculated mass is required
6363  // also, this method is potentially dangerous if the mass
6364  // used in the MC is not the same of the PDG database
6365  //
6366  Float_t mass = TDatabasePDG::Instance()->GetParticle(pdg)->Mass();
6367  Float_t e=TMath::Sqrt(mass*mass+pmom[0]*pmom[0]+
6368  pmom[1]*pmom[1]+pmom[2]*pmom[2]);
6369 
6370 // printf("Loading mass %f ene %f No %d ip %d parent %d done %d "
6371 // "pos %f %f %f mom %f %f %f kS %d m \n",
6372 // mass,e,fNtrack,pdg,parent,done,vpos[0],vpos[1],vpos[2],
6373 // pmom[0],pmom[1],pmom[2],kS);
6374 
6375 
6376  GetStack()->PushTrack(done, parent, pdg, pmom[0], pmom[1], pmom[2], e,
6377  vpos[0],vpos[1],vpos[2],tof,polar[0],polar[1],polar[2],
6378  mech, ntr, weight, is);
6379 }
const double e
weight
Definition: test.py:257
void TGeant3::SetTRIG ( Int_t  nevents = 1)
virtual

Definition at line 5266 of file TGeant3.cxx.

5267 {
5268  //
5269  // Set number of events to be run
5270  //
5271  fGcflag->nevent = nevents;
5272  SetBit(kTRIG);
5273 }
Gcflag_t * fGcflag
GCKINE common structure.
Definition: TGeant3.h:1159
Int_t nevent
Definition: TGeant3.h:155
void TGeant3::SetUserDecay ( Int_t  ipart)
virtual

Definition at line 5276 of file TGeant3.cxx.

5277 {
5278  //
5279  // Force the decays of particles to be done with Pythia
5280  // and not with the Geant routines.
5281  // just kill pointers doing mzdrop
5282  //
5283  Int_t ipart = IdFromPDG(pdg);
5284  if(ipart<0) {
5285  printf("Particle %d not in geant\n",pdg);
5286  return;
5287  }
5288  Int_t jpart=fGclink->jpart;
5289  Int_t jpa=fZlq[jpart-ipart];
5290  //
5291  if(jpart && jpa) {
5292  Int_t jpa1=fZlq[jpa-1];
5293  if(jpa1)
5294  mzdrop(fGcbank->ixcons,jpa1,PASSCHARD(" ") PASSCHARL(" "));
5295  Int_t jpa2=fZlq[jpa-2];
5296  if(jpa2)
5297  mzdrop(fGcbank->ixcons,jpa2,PASSCHARD(" ") PASSCHARL(" "));
5298  }
5299 }
#define PASSCHARL(string)
Definition: TCallf77.h:12
Gcbank_t * fGcbank
QUEST common structure.
Definition: TGeant3.h:1145
#define mzdrop
Definition: TGeant3.cxx:601
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t * fZlq
Good Old IQ of Zebra.
Definition: TGeant3.h:1141
Int_t IdFromPDG(Int_t pdg) const
Definition: TGeant3.cxx:1476
Int_t ixcons
Definition: TGeant3.h:106
#define PASSCHARD(string)
Definition: TCallf77.h:11
void TGeant3::SetUserParameters ( Bool_t  isUserParameters)
virtual

Definition at line 2994 of file TGeant3.cxx.

2995 {
2996 // Activate the parameters defined in tracking media
2997 // (DEEMAX, STMIN, STEMAX), which are, be default, ignored.
2998 
2999  SetAUTO(!isUserParameters);
3000 }
virtual void SetAUTO(Int_t par=1)
Definition: TGeant3.cxx:4840
Bool_t TGeant3::SkipNeutrinos ( )
inline

Definition at line 715 of file TGeant3.h.

715 {return fSkipNeutrinos;}
Bool_t fSkipNeutrinos
Definition: TGeant3.h:1192
Int_t TGeant3::StepProcesses ( TArrayI &  proc) const

Definition at line 2428 of file TGeant3.cxx.

2429 {
2430  //
2431  // Return processes active in the current step
2432  //
2433  Int_t i;
2434  Int_t nproc=Gctrak()->nmec;
2435 
2436  // Set no active process if there are no processes
2437  if (nproc==0) {
2438  proc.Set(1);
2439  proc[0] = kPNull;
2440  return 1;
2441  }
2442 
2443  //
2444  proc.Set(nproc);
2445  Int_t nvproc=0;
2446  //
2447  for (i=0; i<nproc; ++i)
2448  if((proc[nvproc]=G3toVMC(Gctrak()->lmec[i]))!=kPNoProcess) nvproc++;
2449  //
2450  proc.Set(nvproc);
2451  //
2452  return nvproc;
2453 }
virtual Gctrak_t * Gctrak() const
Definition: TGeant3.h:829
Int_t nmec
Definition: TGeant3.h:251
TMCProcess G3toVMC(Int_t iproc) const
Definition: TGeant3.cxx:2456
void TGeant3::StopEvent ( )

Definition at line 2546 of file TGeant3.cxx.

2547 {
2548  //
2549  // Stop simulation of the current event and skip to the next
2550  //
2551  fGcflag->ieotri=1;
2552 }
Gcflag_t * fGcflag
GCKINE common structure.
Definition: TGeant3.h:1159
Int_t ieotri
Definition: TGeant3.h:151
void TGeant3::StopRun ( )

Definition at line 2555 of file TGeant3.cxx.

2556 {
2557  //
2558  // Stop simulation of the current event and set the abort run flag to true
2559  //
2560 
2561  StopTrack();
2562  StopEvent();
2563  fStopRun = kTRUE;
2564 }
void StopTrack()
Definition: TGeant3.cxx:2537
Bool_t fStopRun
Definition: TGeant3.h:1191
void StopEvent()
Definition: TGeant3.cxx:2546
void TGeant3::StopTrack ( )

Definition at line 2537 of file TGeant3.cxx.

2538 {
2539  //
2540  // Stop the transport of the current particle and skip to the next
2541  //
2542  fGctrak->istop=1;
2543 }
Int_t istop
Definition: TGeant3.h:268
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
Double_t TGeant3::TrackCharge ( ) const

Definition at line 2276 of file TGeant3.cxx.

2277 {
2278  //
2279  // Return charge of the track currently transported
2280  //
2281  return fGckine->charge;
2282 }
Float_t charge
Definition: TGeant3.h:172
Gckine_t * fGckine
GCVOLU common structure.
Definition: TGeant3.h:1158
Double_t TGeant3::TrackLength ( ) const

Definition at line 2312 of file TGeant3.cxx.

2313 {
2314  //
2315  // Return the length of the current track from its origin
2316  //
2317  return fGctrak->sleng;
2318 }
Float_t sleng
Definition: TGeant3.h:259
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
Double_t TGeant3::TrackMass ( ) const

Definition at line 2285 of file TGeant3.cxx.

2286 {
2287  //
2288  // Return the mass of the track currently transported
2289  //
2290  return fGckine->amass;
2291 }
Float_t amass
Definition: TGeant3.h:171
Gckine_t * fGckine
GCVOLU common structure.
Definition: TGeant3.h:1158
void TGeant3::TrackMomentum ( TLorentzVector &  xyz) const

Definition at line 2247 of file TGeant3.cxx.

2248 {
2249  //
2250  // Return the direction and the momentum (GeV/c) of the track
2251  // currently being transported
2252  //
2253  Double_t ptot=fGctrak->vect[6];
2254  xyz[0]=fGctrak->vect[3]*ptot;
2255  xyz[1]=fGctrak->vect[4]*ptot;
2256  xyz[2]=fGctrak->vect[5]*ptot;
2257  xyz[3]=fGctrak->getot;
2258 }
Float_t vect[7]
Definition: TGeant3.h:247
Float_t getot
Definition: TGeant3.h:248
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
void TGeant3::TrackMomentum ( Double_t &  px,
Double_t &  py,
Double_t &  pz,
Double_t &  etot 
) const

Definition at line 2261 of file TGeant3.cxx.

2263 {
2264  //
2265  // Return the direction and the momentum (GeV/c) of the track
2266  // currently being transported
2267  //
2268  Double_t ptot=fGctrak->vect[6];
2269  px =fGctrak->vect[3]*ptot;
2270  py =fGctrak->vect[4]*ptot;
2271  pz =fGctrak->vect[5]*ptot;
2272  etot=fGctrak->getot;
2273 }
Float_t vect[7]
Definition: TGeant3.h:247
Float_t getot
Definition: TGeant3.h:248
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
Int_t TGeant3::TrackPid ( ) const

Definition at line 2294 of file TGeant3.cxx.

2295 {
2296  //
2297  // Return the id of the particle transported
2298  //
2299  return PDGFromId(fGckine->ipart);
2300 }
Int_t PDGFromId(Int_t pdg) const
Definition: TGeant3.cxx:1487
Int_t ipart
Definition: TGeant3.h:168
Gckine_t * fGckine
GCVOLU common structure.
Definition: TGeant3.h:1158
void TGeant3::TrackPosition ( TLorentzVector &  xyz) const

Definition at line 2213 of file TGeant3.cxx.

2214 {
2215  //
2216  // Return the current position in the master reference frame of the
2217  // track being transported
2218  //
2219  xyz[0]=fGctrak->vect[0];
2220  xyz[1]=fGctrak->vect[1];
2221  xyz[2]=fGctrak->vect[2];
2222  xyz[3]=fGctrak->tofg;
2223 }
Float_t vect[7]
Definition: TGeant3.h:247
Float_t tofg
Definition: TGeant3.h:263
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
void TGeant3::TrackPosition ( Double_t &  x,
Double_t &  y,
Double_t &  z 
) const

Definition at line 2226 of file TGeant3.cxx.

2227 {
2228  //
2229  // Return the current position in the master reference frame of the
2230  // track being transported
2231  //
2232  x=fGctrak->vect[0];
2233  y=fGctrak->vect[1];
2234  z=fGctrak->vect[2];
2235 }
double y
Float_t vect[7]
Definition: TGeant3.h:247
double z
list x
Definition: train.py:276
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
Double_t TGeant3::TrackStep ( ) const

Definition at line 2303 of file TGeant3.cxx.

2304 {
2305  //
2306  // Return the length in centimeters of the current step
2307  //
2308  return fGctrak->step;
2309 }
Float_t step
Definition: TGeant3.h:260
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
Double_t TGeant3::TrackTime ( ) const

Definition at line 2238 of file TGeant3.cxx.

2239 {
2240  //
2241  // Return the current time of flight of the track being transported
2242  //
2243  return fGctrak->tofg;
2244 }
Float_t tofg
Definition: TGeant3.h:263
Gctrak_t * fGctrak
GCKIN3 common structure.
Definition: TGeant3.h:1166
Int_t TGeant3::TransportMethod ( TMCParticleType  particleType) const
protected

Definition at line 6143 of file TGeant3.cxx.

6144 {
6145 //
6146 // Returns G3 transport method code for the specified MCParticleType
6147 // ---
6148 
6149  switch (particleType) {
6150  case kPTGamma: return 1;
6151  case kPTElectron: return 2;
6152  case kPTNeutron: return 3;
6153  case kPTHadron: return 4;
6154  case kPTMuon: return 5;
6155  case kPTGeantino: return 6;
6156  case kPTOpticalPhoton: return 7;
6157  case kPTIon: return 8;
6158  default: return -1;
6159  }
6160 }
virtual Trcom3_t* TGeant3::Trcom3 ( ) const
inlinevirtual

Definition at line 840 of file TGeant3.h.

840 {return fTrcom3;}
Trcom3_t * fTrcom3
ERWORK common structure.
Definition: TGeant3.h:1127
void TGeant3::Trscsd ( Float_t *  pc,
Float_t *  rc,
Float_t *  pd,
Float_t *  rd,
Float_t *  h,
Float_t  ch,
Int_t  ierr,
Float_t  spu,
Float_t *  dj,
Float_t *  dk 
)
virtual

Definition at line 5546 of file TGeant3.cxx.

5546  {
5547 
5548 // SUBROUTINE TRSCSD(PC,RC,PD,RD,H,CH,IERR,SPU,DJ,DK)
5549 // ******************************************************************
5550 // *** TRANSFORMS ERROR MATRIX
5551 // FROM SC VARIABLES (1/P,LAMBDA,PHI,YT,ZT)
5552 // TO VARIABLES (1/P,V',W',V,W)
5553 //
5554 // Authors: A. Haas and W. Wittek
5555 // *** PC(3) 1/P,LAMBDA,PHI INPUT
5556 // PD(3) 1/P,V',W' OUTPUT
5557 // H(3) MAGNETIC FIELD INPUT
5558 // RC(15) ERROR MATRIX IN SC VARIABLES INPUT (TRIANGLE)
5559 // RD(15) ERROR MATRIX IN 1/P,V',W',V,W OUTPUT (TRIANGLE)
5560 // CH CHARGE OF PARTICLE INPUT
5561 // CHARGE AND MAGNETIC FIELD ARE NEEDED
5562 // FOR CORRELATION TERMS (V',YT),(V',ZT),(W',YT),(W',ZT)
5563 // THESE CORRELATION TERMS APPEAR BECAUSE RC IS ASSUMED
5564 // TO BE THE ERROR MATRIX FOR FIXED S (PATH LENGTH)
5565 // AND RD FOR FIXED U
5566 // DJ(3) UNIT VECTOR IN V-DIRECTION
5567 // DK(3) UNIT VECTOR IN W-DIRECTION OF DETECTOR SYSTEM
5568 //
5569 // IERR = 1 PARTICLE MOVES PERPENDICULAR TO U-AXIS
5570 // ( V',W' ARE NOT DEFINED )
5571 // SPU SIGN OF U-COMPONENT OF PARTICLE MOMENTUM OUTPUT
5572 // ******************************************************************
5573  printf("%d\n",ierr);
5574  trscsd(pc,rc,pd,rd,h,ch,ierr,spu,dj,dk);
5575 }
#define trscsd
Definition: TGeant3.cxx:610
h
training ###############################
Definition: train_cnn.py:186
void TGeant3::Trscsp ( Float_t *  ps,
Float_t *  rs,
Float_t *  pc,
Float_t *  rc,
Float_t *  h,
Float_t *  ch,
Int_t *  ierr,
Float_t *  spx 
)
virtual

Definition at line 5605 of file TGeant3.cxx.

5605  {
5606 // ******************************************************************
5607 // SUBROUTINE TRSCSP(PC,RC,PS,RS,H,CH,IERR,SPX)
5608 //
5609 // *** TRANSFORMS ERROR MATRIX
5610 // FROM SC VARIABLES (1/P,LAMBDA,PHI,YT,ZT)
5611 // TO SPLINE VARIABLES (1/P,Y',Z',Y,Z)
5612 //
5613 // Authors: A. Haas and W. Wittek
5614 //
5615 //
5616 // *** PC(3) 1/P,LAMBDA,PHI INPUT
5617 // PS(3) 1/P,Y',Z' OUTPUT
5618 // H(3) MAGNETIC FIELD INPUT
5619 // RC(15) ERROR MATRIX IN SC VARIABLES INPUT (TRIANGLE)
5620 // RS(15) ERROR MATRIX IN SPLINE VARIABLES OUTPUT (TRIANGLE)
5621 // CH CHARGE OF PARTICLE INPUT
5622 // CHARGE AND MAGNETIC FIELD ARE NEEDED
5623 // FOR CORRELATION TERMS (Y',YT),(Y',ZT),(Z',YT),(Z',ZT)
5624 // THESE CORRELATION TERMS APPEAR BECAUSE RC IS ASSUMED
5625 // TO BE THE ERROR MATRIX FOR FIXED S (PATH LENGTH)
5626 // AND RS FOR FIXED X
5627 //
5628 // IERR = 1 PARTICLE MOVES PERPENDICULAR TO X-AXIS
5629 // ( Y',Z' ARE NOT DEFINED )
5630 // SPX SIGN OF X-COMPONENT OF PARTICLE MOMENTUM OUTPUT
5631 // ******************************************************************
5632  trscsp(pc,rc,ps,rs,h,ch,ierr,spx);
5633 }
static const double ps
Definition: Units.h:103
#define trscsp
Definition: TGeant3.cxx:608
h
training ###############################
Definition: train_cnn.py:186
void TGeant3::Trsdsc ( Float_t *  pd,
Float_t *  rd,
Float_t *  pc,
Float_t *  rc,
Float_t *  h,
Float_t *  ch,
Int_t *  ierr,
Float_t *  spu,
Float_t *  dj,
Float_t *  dk 
)
virtual

Definition at line 5577 of file TGeant3.cxx.

5577  {
5578 // ******************************************************************
5579 // SUBROUTINE TRSDSC(PD,RD,PC,RC,H,CH,IERR,SPU,DJ,DK)
5580 //
5581 // *** TRANSFORMS ERROR MATRIX
5582 // FROM VARIABLES (1/P,V',W',V,W)
5583 // TO SC VARIABLES (1/P,LAMBDA,PHI,YT,ZT)
5584 // Authors: A. Haas and W. Wittek
5585 // *** PD(3) 1/P,V',W' INPUT
5586 // PC(3) 1/P,LAMBDA,PHI OUTPUT
5587 // H(3) MAGNETIC FIELD INPUT
5588 // RD(15) ERROR MATRIX IN 1/P,V',W',V,W INPUT (TRIANGLE)
5589 // RC(15) ERROR MATRIX IN SC VARIABLES OUTPUT (TRIANGLE)
5590 // CH CHARGE OF PARTICLE INPUT
5591 // CHARGE AND MAGNETIC FIELD ARE NEEDED
5592 // FOR CORRELATION TERMS (LAMBDA,V),(LAMBDA,W),(PHI,V),(PHI,W)
5593 // THESE CORRELATION TERMS APPEAR BECAUSE RC IS ASSUMED
5594 // TO BE THE ERROR MATRIX FOR FIXED S (PATH LENGTH)
5595 // AND RD FOR FIXED U
5596 // DJ(3) UNIT VECTOR IN V-DIRECTION
5597 // DK(3) UNIT VECTOR IN W-DIRECTION OF DETECTOR SYSTEM
5598 //
5599 // IERR NOT USED
5600 // SPU SIGN OF U-COMPONENT OF PARTICLE MOMENTUM INPUT
5601 // ******************************************************************
5602  trsdsc(pd,rd,pc,rc,h,ch,ierr,spu,dj,dk);
5603 }
#define trsdsc
Definition: TGeant3.cxx:611
h
training ###############################
Definition: train_cnn.py:186
void TGeant3::Trspsc ( Float_t *  ps,
Float_t *  rs,
Float_t *  pc,
Float_t *  rc,
Float_t *  h,
Float_t *  ch,
Int_t *  ierr,
Float_t *  spx 
)
virtual

Definition at line 5635 of file TGeant3.cxx.

5635  {
5636 
5637 // ******************************************************************
5638 // SUBROUTINE TRSPSC(PS,RS,PC,RC,H,CH,IERR,SPX)
5639 //
5640 // *** TRANSFORMS ERROR MATRIX
5641 // FROM SPLINE VARIABLES (1/P,Y',Z',Y,Z)
5642 // TO SC VARIABLES (1/P,LAMBDA,PHI,YT,ZT)
5643 //
5644 // Authors: A. Haas and W. Wittek
5645 //
5646 //
5647 // *** PS(3) 1/P,Y',Z' INPUT
5648 // PC(3) 1/P,LAMBDA,PHI OUTPUT
5649 // H(3) MAGNETIC FIELD INPUT
5650 // RS(15) ERROR MATRIX IN SPLINE VARIABLES INPUT (TRIANGLE)
5651 // RC(15) ERROR MATRIX IN SC VARIABLES OUTPUT (TRIANGLE)
5652 // CH CHARGE OF PARTICLE INPUT
5653 // CHARGE AND MAGNETIC FIELD ARE NEEDED
5654 // FOR CORRELATION TERMS (LAMBDA,Y),(LAMBDA,Z),(PHI,Y),(PHI,Z)
5655 // THESE CORRELATION TERMS APPEAR BECAUSE RC IS ASSUMED
5656 // TO BE THE ERROR MATRIX FOR FIXED S (PATH LENGTH)
5657 // AND RS FOR FIXED X
5658 //
5659 // IERR NOT USED
5660 // SPX SIGN OF X-COMPONENT OF PARTICLE MOMENTUM INPUT
5661 //
5662 // ******************************************************************
5663 
5664  trspsc(ps,rs,pc,rc,h,ch,ierr,spx);
5665 
5666 }
static const double ps
Definition: Units.h:103
#define trspsc
Definition: TGeant3.cxx:609
h
training ###############################
Definition: train_cnn.py:186
void TGeant3::Vname ( const char *  name,
char *  vname 
)
virtual

Definition at line 5357 of file TGeant3.cxx.

5358 {
5359  //
5360  // convert name to upper case. Make vname at least 4 chars
5361  //
5362  Int_t l = strlen(name);
5363  Int_t i;
5364  l = l < 4 ? l : 4;
5365  for (i=0;i<l;i++) vname[i] = toupper(name[i]);
5366  for (i=l;i<4;i++) vname[i] = ' ';
5367  vname[4] = 0;
5368 }
Int_t TGeant3::VolDaughterCopyNo ( const char *  volName,
Int_t  i 
) const

Definition at line 1898 of file TGeant3.cxx.

1899 {
1900 // Return the copyNo of i-th daughters of the volume specified by volName
1901 // According to A. Morsch' G3toRoot class
1902 // ---
1903 
1904  Int_t idvol = VolId(volName);
1905 
1906  Int_t jvo = fZlq[fGclink->jvolum-idvol];
1907  Int_t nin=i+1;
1908  Int_t jin = fZlq[jvo-nin];
1909 
1910  return Int_t(fZq[jin +3]);
1911 }
Float_t * fZq
Good Old LQ of Zebra.
Definition: TGeant3.h:1142
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t * fZlq
Good Old IQ of Zebra.
Definition: TGeant3.h:1141
Int_t VolId(const Text_t *name) const
Definition: TGeant3.cxx:1828
const char * TGeant3::VolDaughterName ( const char *  volName,
Int_t  i 
) const

Definition at line 1880 of file TGeant3.cxx.

1881 {
1882 // Return the name of i-th daughters of the volume specified by volName
1883 // According to A. Morsch' G3toRoot class
1884 // ---
1885 
1886  Int_t idvol = VolId(volName);
1887 
1888  Int_t jvo = fZlq[fGclink->jvolum-idvol];
1889  Int_t nin=i+1;
1890  Int_t jin = fZlq[jvo-nin];
1891  Int_t idvold = Int_t(fZq[jin+2]);;
1892 
1893  return VolName(idvold);
1894 }
Float_t * fZq
Good Old LQ of Zebra.
Definition: TGeant3.h:1142
const char * VolName(Int_t id) const
Definition: TGeant3.cxx:1928
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t * fZlq
Good Old IQ of Zebra.
Definition: TGeant3.h:1141
Int_t VolId(const Text_t *name) const
Definition: TGeant3.cxx:1828
Int_t TGeant3::VolId ( const Text_t *  name) const

Definition at line 1828 of file TGeant3.cxx.

1829 {
1830  //
1831  // Return the unique numeric identifier for volume name
1832  //
1833  Int_t gname,i;
1834  strncpy((char *) &gname, name, 4);
1835  for(i=1; i<=fGcnum->nvolum; i++)
1836  if(gname == fZiq[fGclink->jvolum+i]) return i;
1837  printf("VolId: Volume %s not found\n",name);
1838  return 0;
1839 }
Gcnum_t * fGcnum
GCTPOL common structure.
Definition: TGeant3.h:1152
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t nvolum
Definition: TGeant3.h:317
Int_t * fZiq
Definition: TGeant3.h:1140
Int_t TGeant3::VolId2Mate ( Int_t  id) const

Definition at line 1914 of file TGeant3.cxx.

1915 {
1916  //
1917  // Return material number for a given volume id
1918  //
1919  if(id<1 || id > fGcnum->nvolum || fGclink->jvolum<=0)
1920  return 0;
1921  else {
1922  Int_t jvo = fZlq[fGclink->jvolum-id];
1923  return Int_t(fZq[jvo+4]);
1924  }
1925 }
Gcnum_t * fGcnum
GCTPOL common structure.
Definition: TGeant3.h:1152
Float_t * fZq
Good Old LQ of Zebra.
Definition: TGeant3.h:1142
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t * fZlq
Good Old IQ of Zebra.
Definition: TGeant3.h:1141
Int_t nvolum
Definition: TGeant3.h:317
const char * TGeant3::VolName ( Int_t  id) const

Definition at line 1928 of file TGeant3.cxx.

1929 {
1930  //
1931  // Return the volume name given the volume identifier
1932  //
1933  if(id<1 || id > fGcnum->nvolum || fGclink->jvolum<=0)
1934  return fVolNames[fGcnum->nvolum];
1935  else
1936  return fVolNames[id-1];
1937 }
Gcnum_t * fGcnum
GCTPOL common structure.
Definition: TGeant3.h:1152
char(* fVolNames)[5]
GCJUMP common structure.
Definition: TGeant3.h:1180
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t nvolum
Definition: TGeant3.h:317
void TGeant3::WriteEuclid ( const char *  filnam,
const char *  topvol,
Int_t  number,
Int_t  nlevel 
)
virtual

Definition at line 5670 of file TGeant3.cxx.

5672 {
5673  //
5674  //
5675  // ******************************************************************
5676  // * *
5677  // * Write out the geometry of the detector in EUCLID file format *
5678  // * *
5679  // * filnam : will be with the extension .euc *
5680  // * topvol : volume name of the starting node *
5681  // * number : copy number of topvol (relevant for gsposp) *
5682  // * nlevel : number of levels in the tree structure *
5683  // * to be written out, starting from topvol *
5684  // * *
5685  // * Author : M. Maire *
5686  // * *
5687  // ******************************************************************
5688  //
5689  // File filnam.tme is written out with the definitions of tracking
5690  // medias and materials.
5691  // As to restore original numbers for materials and medias, program
5692  // searches in the file euc_medi.dat and comparing main parameters of
5693  // the mat. defined inside geant and the one in file recognizes them
5694  // and is able to take number from file. If for any material or medium,
5695  // this procedure fails, ordering starts from 1.
5696  // Arrays IOTMED and IOMATE are used for this procedure
5697  //
5698  const char kShape[][5]={"BOX ","TRD1","TRD2","TRAP","TUBE","TUBS","CONE",
5699  "CONS","SPHE","PARA","PGON","PCON","ELTU","HYPE",
5700  "GTRA","CTUB"};
5701  Int_t i, end, itm, irm, jrm, k, nmed;
5702  Int_t imxtmed=0;
5703  Int_t imxmate=0;
5704  FILE *lun;
5705  char *filext, *filetme;
5706  char natmed[21], namate[21];
5707  char natmedc[21], namatec[21];
5708  char key[5], name[5], mother[5], konly[5];
5709  char card[133];
5710  Int_t iadvol, iadtmd, iadrot, nwtot, iret;
5711  Int_t mlevel, numbr, natt, numed, nin, ndata;
5712  Int_t iname, ivo, ish, jvo, nvstak, ivstak;
5713  Int_t jdiv, ivin, in, jin, jvin, irot;
5714  Int_t jtm, imat, jma, flag=0, imatc;
5715  Float_t az, dens, radl, absl, a, step, x, y, z;
5716  Int_t npar, ndvmx, left;
5717  Float_t zc, densc, radlc, abslc, c0, tmaxfd;
5718  Int_t nparc, numb;
5719  Int_t iomate[100], iotmed[100];
5720  Float_t par[100], att[20], ubuf[50];
5721  Float_t *qws;
5722  Int_t *iws;
5723  Int_t level, ndiv, iaxe;
5724  Int_t itmedc, nmatc, isvolc, ifieldc, nwbufc, isvol, nmat, ifield, nwbuf;
5725  Float_t fieldmc, tmaxfdc, stemaxc, deemaxc, epsilc, stminc, fieldm;
5726  Float_t tmaxf, stemax, deemax, epsil, stmin;
5727  const char *k10000="!\n%s\n!\n";
5728  //Open the input file
5729  end=strlen(filnam);
5730  for(i=0;i<end;i++) if(filnam[i]=='.') {
5731  end=i;
5732  break;
5733  }
5734  filext=new char[end+5];
5735  filetme=new char[end+5];
5736  strncpy(filext,filnam,end);
5737  strncpy(filetme,filnam,end);
5738  //
5739  // *** The output filnam name will be with extension '.euc'
5740  strcpy(&filext[end],".euc");
5741  strcpy(&filetme[end],".tme");
5742  lun=fopen(filext,"w");
5743  //
5744  // *** Initialization of the working space
5745  iadvol=fGcnum->nvolum;
5746  iadtmd=iadvol+fGcnum->nvolum;
5747  iadrot=iadtmd+fGcnum->ntmed;
5748  if(fGclink->jrotm) {
5749  fGcnum->nrotm=fZiq[fGclink->jrotm-2];
5750  } else {
5751  fGcnum->nrotm=0;
5752  }
5753  nwtot=iadrot+fGcnum->nrotm;
5754  qws = new float[nwtot+1];
5755  for (i=0;i<nwtot+1;i++) qws[i]=0;
5756  iws = (Int_t*) qws;
5757  mlevel=nlevel;
5758  if(nlevel==0) mlevel=20;
5759  //
5760  // *** find the top volume and put it in the stack
5761  numbr = number>0 ? number : 1;
5762  Gfpara(topvol,numbr,1,npar,natt,par,att);
5763  if(npar <= 0) {
5764  printf(" *** GWEUCL *** top volume : %s number : %3d can not be "
5765  "a valid root\n", topvol, numbr);
5766  return;
5767  }
5768  //
5769  // *** authorized shape ?
5770  strncpy((char *)&iname, topvol, 4);
5771  ivo=0;
5772  for(i=1; i<=fGcnum->nvolum; i++) if(fZiq[fGclink->jvolum+i]==iname) {
5773  ivo=i;
5774  break;
5775  }
5776  jvo = fZlq[fGclink->jvolum-ivo];
5777  ish = Int_t (fZq[jvo+2]);
5778  if(ish > 12) {
5779  printf(" *** GWEUCL *** top volume : %s number : %3d can not be "
5780  "a valid root\n",topvol, numbr);
5781  }
5782  //
5783  level = 1;
5784  nvstak = 1;
5785  iws[nvstak] = ivo;
5786  iws[iadvol+ivo] = level;
5787  ivstak = 0;
5788  //
5789  //*** flag all volumes and fill the stack
5790  //
5791  L10:
5792  //
5793  // pick the next volume in stack
5794  ivstak += 1;
5795  ivo = TMath::Abs(iws[ivstak]);
5796  jvo = fZlq[fGclink->jvolum - ivo];
5797  //
5798  // flag the tracking medium
5799  numed = Int_t (fZq[jvo + 4]);
5800  iws[iadtmd + numed] = 1;
5801  //
5802  // get the daughters ...
5803  level = iws[iadvol+ivo];
5804  if (level < mlevel) {
5805  level += 1;
5806  nin = Int_t (fZq[jvo + 3]);
5807  //
5808  // from division ...
5809  if (nin < 0) {
5810  jdiv = fZlq[jvo - 1];
5811  ivin = Int_t (fZq[jdiv + 2]);
5812  nvstak += 1;
5813  iws[nvstak] = -ivin;
5814  iws[iadvol+ivin] = level;
5815  //
5816  // from position ...
5817  } else if (nin > 0) {
5818  for(in=1; in<=nin; in++) {
5819  jin = fZlq[jvo - in];
5820  ivin = Int_t (fZq[jin + 2 ]);
5821  jvin = fZlq[fGclink->jvolum - ivin];
5822  ish = Int_t (fZq[jvin + 2]);
5823  // authorized shape ?
5824  if (ish <= 12) {
5825  // not yet flagged ?
5826  if (iws[iadvol+ivin]==0) {
5827  nvstak += 1;
5828  iws[nvstak] = ivin;
5829  iws[iadvol+ivin] = level;
5830  }
5831  // flag the rotation matrix
5832  irot = Int_t ( fZq[jin + 4 ]);
5833  if (irot > 0) iws[iadrot+irot] = 1;
5834  }
5835  }
5836  }
5837  }
5838  //
5839  // next volume in stack ?
5840  if (ivstak < nvstak) goto L10;
5841  //
5842  // *** restore original material and media numbers
5843  // file euc_medi.dat is needed to compare materials and medias
5844  //
5845  FILE* luncor=fopen("euc_medi.dat","r");
5846  //
5847  if(luncor) {
5848  for(itm=1; itm<=fGcnum->ntmed; itm++) {
5849  if (iws[iadtmd+itm] > 0) {
5850  jtm = fZlq[fGclink->jtmed-itm];
5851  strncpy(natmed,(char *)&fZiq[jtm+1],20);
5852  imat = Int_t (fZq[jtm+6]);
5853  jma = fZlq[fGclink->jmate-imat];
5854  if (jma <= 0) {
5855  printf(" *** GWEUCL *** material not defined for tracking medium "
5856  "%5i %s\n",itm,natmed);
5857  flag=1;
5858  } else {
5859  strncpy(namate,(char *)&fZiq[jma+1],20);
5860  }
5861  //*
5862  //** find the material original number
5863  rewind(luncor);
5864  L23:
5865  iret=fscanf(luncor,"%4s,%130s",key,card);
5866  if(iret<=0) goto L26;
5867  flag=0;
5868  if(!strcmp(key,"MATE")) {
5869  sscanf(card,"%d %s %f %f %f %f %f %d",&imatc,namatec,&az,&zc,
5870  &densc,&radlc,&abslc,&nparc);
5871  Gfmate(imat,namate,a,z,dens,radl,absl,par,npar);
5872  if(!strcmp(namatec,namate)) {
5873  if(az==a && zc==z && densc==dens && radlc==radl
5874  && abslc==absl && nparc==nparc) {
5875  iomate[imat]=imatc;
5876  flag=1;
5877  printf("*** GWEUCL *** material : %3d '%s' restored as %3d\n",
5878  imat,namate,imatc);
5879  } else {
5880  printf("*** GWEUCL *** different definitions for material: %s\n",
5881  namate);
5882  }
5883  }
5884  }
5885  if(strcmp(key,"END") && !flag) goto L23;
5886  if (!flag) {
5887  printf("*** GWEUCL *** cannot restore original number for "
5888  "material: %s\n",namate);
5889  }
5890  //*
5891  //*
5892  //*** restore original tracking medium number
5893  rewind(luncor);
5894  L24:
5895  iret=fscanf(luncor,"%4s,%130s",key,card);
5896  if(iret<=0) goto L26;
5897  flag=0;
5898  if (!strcmp(key,"TMED")) {
5899  sscanf(card,"%d %s %d %d %d %f %f %f %f %f %f %d\n",
5900  &itmedc,natmedc,&nmatc,&isvolc,&ifieldc,&fieldmc,
5901  &tmaxfdc,&stemaxc,&deemaxc,&epsilc,&stminc,&nwbufc);
5902  Gftmed(itm,natmed,nmat,isvol,ifield,fieldm,tmaxf,stemax,deemax,
5903  epsil,stmin,ubuf,&nwbuf);
5904  if(!strcmp(natmedc,natmed)) {
5905  if (iomate[nmat]==nmatc && nwbuf==nwbufc) {
5906  iotmed[itm]=itmedc;
5907  flag=1;
5908  printf("*** GWEUCL *** medium : %3d '%20s' restored as %3d\n",
5909  itm,natmed,itmedc);
5910  } else {
5911  printf("*** GWEUCL *** different definitions for tracking "
5912  "medium: %s\n",natmed);
5913  }
5914  }
5915  }
5916  if(strcmp(key,"END") && !flag) goto L24;
5917  if(!flag) {
5918  printf("cannot restore original number for medium : %s\n",natmed);
5919  goto L27;
5920  }
5921  }
5922  }
5923  goto L29;
5924  //*
5925  }
5926  L26: printf("*** GWEUCL *** cannot read the data file\n");
5927  L27: flag=2;
5928  L29: if(luncor) fclose (luncor);
5929  //
5930  //
5931  // *** write down the tracking medium definition
5932  //
5933  strcpy(card,"! Tracking medium");
5934  fprintf(lun,k10000,card);
5935  //
5936  for(itm=1;itm<=fGcnum->ntmed;itm++) {
5937  if (iws[iadtmd+itm]>0) {
5938  jtm = fZlq[fGclink->jtmed-itm];
5939  strncpy(natmed,(char *)&fZiq[jtm+1],20);
5940  natmed[20]='\0';
5941  imat = Int_t (fZq[jtm+6]);
5942  jma = fZlq[fGclink->jmate-imat];
5943  //* order media from one, if comparing with database failed
5944  if (flag==2) {
5945  iotmed[itm]=++imxtmed;
5946  iomate[imat]=++imxmate;
5947  }
5948  //*
5949  if(jma<=0) {
5950  strcpy(namate," ");
5951  printf(" *** GWEUCL *** material not defined for tracking "
5952  "medium %5d %s\n", itm,natmed);
5953  } else {
5954  strncpy(namate,(char *)&fZiq[jma+1],20);
5955  namate[20]='\0';
5956  }
5957  fprintf(lun,"TMED %3d '%20s' %3d '%20s'\n",iotmed[itm],natmed,
5958  iomate[imat],namate);
5959  }
5960  }
5961  //*
5962  //* *** write down the rotation matrix
5963  //*
5964  strcpy(card,"! Reperes");
5965  fprintf(lun,k10000,card);
5966  //
5967  for(irm=1;irm<=fGcnum->nrotm;irm++) {
5968  if (iws[iadrot+irm]>0) {
5969  jrm = fZlq[fGclink->jrotm-irm];
5970  fprintf(lun,"ROTM %3d",irm);
5971  for(k=11;k<=16;k++) fprintf(lun," %8.3f",fZq[jrm+k]);
5972  fprintf(lun,"\n");
5973  }
5974  }
5975  //*
5976  //* *** write down the volume definition
5977  //*
5978  strcpy(card,"! Volumes");
5979  fprintf(lun,k10000,card);
5980  //*
5981  for(ivstak=1;ivstak<=nvstak;ivstak++) {
5982  ivo = iws[ivstak];
5983  if (ivo>0) {
5984  strncpy(name,(char *)&fZiq[fGclink->jvolum+ivo],4);
5985  name[4]='\0';
5986  jvo = fZlq[fGclink->jvolum-ivo];
5987  ish = Int_t (fZq[jvo+2]);
5988  nmed = Int_t (fZq[jvo+4]);
5989  npar = Int_t (fZq[jvo+5]);
5990  if (npar>0) {
5991  if (ivstak>1) for(i=0;i<npar;i++) par[i]=fZq[jvo+7+i];
5992  Gckpar (ish,npar,par);
5993  fprintf(lun,"VOLU '%4s' '%4s' %3d %3d\n",name,kShape[ish-1],
5994  iotmed[nmed],npar);
5995  for(i=0;i<(npar-1)/6+1;i++) {
5996  fprintf(lun," ");
5997  left=npar-i*6;
5998  for(k=0;k<(left<6?left:6);k++) fprintf(lun," %11.5f",par[i*6+k]);
5999  fprintf(lun,"\n");
6000  }
6001  } else {
6002  fprintf(lun,"VOLU '%4s' '%4s' %3d %3d\n",name,kShape[ish-1],
6003  iotmed[nmed],npar);
6004  }
6005  }
6006  }
6007  //*
6008  //* *** write down the division of volumes
6009  //*
6010  fprintf(lun,k10000,"! Divisions");
6011  for(ivstak=1;ivstak<=nvstak;ivstak++) {
6012  ivo = TMath::Abs(iws[ivstak]);
6013  jvo = fZlq[fGclink->jvolum-ivo];
6014  ish = Int_t (fZq[jvo+2]);
6015  nin = Int_t (fZq[jvo+3]);
6016  //* this volume is divided ...
6017  if (nin<0) {
6018  jdiv = fZlq[jvo-1];
6019  iaxe = Int_t ( fZq[jdiv+1]);
6020  ivin = Int_t ( fZq[jdiv+2]);
6021  ndiv = Int_t ( fZq[jdiv+3]);
6022  c0 = fZq[jdiv+4];
6023  step = fZq[jdiv+5];
6024  jvin = fZlq[fGclink->jvolum-ivin];
6025  nmed = Int_t ( fZq[jvin+4]);
6026  strncpy(mother,(char *)&fZiq[fGclink->jvolum+ivo ],4);
6027  mother[4]='\0';
6028  strncpy(name,(char *)&fZiq[fGclink->jvolum+ivin],4);
6029  name[4]='\0';
6030  if ((step<=0.)||(ish>=11)) {
6031  //* volume with negative parameter or gsposp or pgon ...
6032  fprintf(lun,"DIVN '%4s' '%4s' %3d %3d\n",name,mother,ndiv,iaxe);
6033  } else if ((ndiv<=0)||(ish==10)) {
6034  //* volume with negative parameter or gsposp or para ...
6035  ndvmx = TMath::Abs(ndiv);
6036  fprintf(lun,"DIVT '%4s' '%4s' %11.5f %3d %3d %3d\n",
6037  name,mother,step,iaxe,iotmed[nmed],ndvmx);
6038  } else {
6039  //* normal volume : all kind of division are equivalent
6040  fprintf(lun,"DVT2 '%4s' '%4s' %11.5f %3d %11.5f %3d %3d\n",
6041  name,mother,step,iaxe,c0,iotmed[nmed],ndiv);
6042  }
6043  }
6044  }
6045  //*
6046  //* *** write down the the positionnement of volumes
6047  //*
6048  fprintf(lun,k10000,"! Positionnements\n");
6049  //
6050  for(ivstak = 1;ivstak<=nvstak;ivstak++) {
6051  ivo = TMath::Abs(iws[ivstak]);
6052  strncpy(mother,(char*)&fZiq[fGclink->jvolum+ivo ],4);
6053  mother[4]='\0';
6054  jvo = fZlq[fGclink->jvolum-ivo];
6055  nin = Int_t( fZq[jvo+3]);
6056  //* this volume has daughters ...
6057  if (nin>0) {
6058  for (in=1;in<=nin;in++) {
6059  jin = fZlq[jvo-in];
6060  ivin = Int_t (fZq[jin +2]);
6061  numb = Int_t (fZq[jin +3]);
6062  irot = Int_t (fZq[jin +4]);
6063  x = fZq[jin +5];
6064  y = fZq[jin +6];
6065  z = fZq[jin +7];
6066  strcpy(konly,"ONLY");
6067  if (fZq[jin+8]!=1.) strcpy(konly,"MANY");
6068  strncpy(name,(char*)&fZiq[fGclink->jvolum+ivin],4);
6069  name[4]='\0';
6070  jvin = fZlq[fGclink->jvolum-ivin];
6071  ish = Int_t (fZq[jvin+2]);
6072  //* gspos or gsposp ?
6073  ndata = fZiq[jin-1];
6074  if (ndata==8) {
6075  fprintf(lun,"POSI '%4s' %4d '%4s' %11.5f %11.5f %11.5f %3d '%4s'\n",
6076  name,numb,mother,x,y,z,irot,konly);
6077  } else {
6078  npar = Int_t (fZq[jin+9]);
6079  for(i=0;i<npar;i++) par[i]=fZq[jin+10+i];
6080  Gckpar (ish,npar,par);
6081  fprintf(lun,"POSP '%4s' %4d '%4s' %11.5f %11.5f %11.5f %3d '%4s' %3d\n",
6082  name,numb,mother,x,y,z,irot,konly,npar);
6083  fprintf(lun," ");
6084  for(i=0;i<npar;i++) fprintf(lun," %11.5f",par[i]);
6085  fprintf(lun,"\n");
6086  }
6087  }
6088  }
6089  }
6090  //*
6091  fprintf(lun,"END\n");
6092  fclose(lun);
6093  //*
6094  //****** write down the materials and medias *****
6095  //*
6096  lun=fopen(filetme,"w");
6097  //*
6098  for(itm=1;itm<=fGcnum->ntmed;itm++) {
6099  if (iws[iadtmd+itm]>0) {
6100  jtm = fZlq[fGclink->jtmed-itm];
6101  strncpy(natmed,(char*)&fZiq[jtm+1],4);
6102  imat = Int_t (fZq[jtm+6]);
6103  jma = Int_t (fZlq[fGclink->jmate-imat]);
6104  //* material
6105  Gfmate (imat,namate,a,z,dens,radl,absl,par,npar);
6106  fprintf(lun,"MATE %4d '%20s'%11.5E %11.5E %11.5E %11.5E %11.5E %3d\n",
6107  iomate[imat],namate,a,z,dens,radl,absl,npar);
6108  //*
6109  if (npar>0) {
6110  fprintf(lun," ");
6111  for(i=0;i<npar;i++) fprintf(lun," %11.5f",par[i]);
6112  fprintf(lun,"\n");
6113  }
6114  //* medium
6115  Gftmed(itm,natmed,nmat,isvol,ifield,fieldm,tmaxfd,stemax,deemax,
6116  epsil,stmin,par,&npar);
6117  fprintf(lun,"TMED %4d '%20s' %3d %1d %3d %11.5f %11.5f %11.5f "
6118  "%11.5f %11.5f %11.5f %3d\n",
6119  iotmed[itm],natmed,iomate[nmat],isvol,ifield,
6120  fieldm,tmaxfd,stemax,deemax,epsil,stmin,npar);
6121  //*
6122  if (npar>0) {
6123  fprintf(lun," ");
6124  for(i=0;i<npar;i++) fprintf(lun," %11.5f",par[i]);
6125  fprintf(lun,"\n");
6126  }
6127 
6128  }
6129  }
6130  fprintf(lun,"END\n");
6131  fclose(lun);
6132  printf(" *** GWEUCL *** file: %s is now written out\n",filext);
6133  printf(" *** GWEUCL *** file: %s is now written out\n",filetme);
6134  // Clean up
6135  delete [] filext;
6136  delete [] filetme;
6137  delete [] qws;
6138  iws=0;
6139  return;
6140 }
Gcnum_t * fGcnum
GCTPOL common structure.
Definition: TGeant3.h:1152
Float_t * fZq
Good Old LQ of Zebra.
Definition: TGeant3.h:1142
double y
virtual void Gfmate(Int_t imat, char *name, Float_t &a, Float_t &z, Float_t &dens, Float_t &radl, Float_t &absl, Float_t *ubuf, Int_t &nbuf)
Definition: TGeant3.cxx:3227
Gclink_t * fGclink
GCBANK common structure.
Definition: TGeant3.h:1146
Int_t * fZlq
Good Old IQ of Zebra.
Definition: TGeant3.h:1141
double z
Int_t nvolum
Definition: TGeant3.h:317
Int_t nrotm
Definition: TGeant3.h:318
virtual void Gftmed(Int_t numed, char *name, Int_t &nmat, Int_t &isvol, Int_t &ifield, Float_t &fieldm, Float_t &tmaxfd, Float_t &stemax, Float_t &deemax, Float_t &epsil, Float_t &stmin, Float_t *buf=0, Int_t *nbuf=0)
Definition: TGeant3.cxx:3281
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
Definition: pointer.h:1124
constexpr auto const & left(const_AssnsIter< L, R, D, Dir > const &a, const_AssnsIter< L, R, D, Dir > const &b)
Definition: AssnsIter.h:96
Int_t ntmed
Definition: TGeant3.h:319
list x
Definition: train.py:276
end
Definition: test.py:8
virtual void Gckpar(Int_t ish, Int_t npar, Float_t *par)
Definition: TGeant3.cxx:4502
virtual void Gfpara(const char *name, Int_t number, Int_t intext, Int_t &npar, Int_t &natt, Float_t *par, Float_t *att)
Definition: TGeant3.cxx:4491
Int_t * fZiq
Definition: TGeant3.h:1140
Double_t TGeant3::Xsec ( char *  reac,
Double_t  energy,
Int_t  part,
Int_t  mate 
)

Definition at line 2197 of file TGeant3.cxx.

2199 {
2200  //
2201  // Calculate X-sections -- dummy for the moment
2202  //
2203  if(!strcmp(reac,"PHOT"))
2204  {
2205  if(part!=22) {
2206  Error("Xsec","Can calculate photoelectric only for photons\n");
2207  }
2208  }
2209  return 0;
2210 }

Member Data Documentation

Eroptc_t* TGeant3::fEroptc

EROPTS common structure.

Definition at line 1125 of file TGeant3.h.

Eropts_t* TGeant3::fEropts

ERTRIO1 common structure.

Definition at line 1124 of file TGeant3.h.

Ertrio_t* TGeant3::fErtrio

Definition at line 1122 of file TGeant3.h.

Ertrio1_t* TGeant3::fErtrio1

ERTRIO common structure.

Definition at line 1123 of file TGeant3.h.

Erwork_t* TGeant3::fErwork

EROPTC common structure.

Definition at line 1126 of file TGeant3.h.

Gcbank_t* TGeant3::fGcbank
protected

QUEST common structure.

Definition at line 1145 of file TGeant3.h.

Gcchan_t* TGeant3::fGcchan
protected

GCTRAK common structure.

Definition at line 1167 of file TGeant3.h.

Gccuts_t* TGeant3::fGccuts
protected

GCLINK common structure.

Definition at line 1147 of file TGeant3.h.

Gcflag_t* TGeant3::fGcflag
protected

GCKINE common structure.

Definition at line 1159 of file TGeant3.h.

Gcjump_t* TGeant3::fGcjump
protected

GCONSX common structure.

Definition at line 1173 of file TGeant3.h.

Gckin2_t* TGeant3::fGckin2
protected

GCKING common structure.

Definition at line 1164 of file TGeant3.h.

Gckin3_t* TGeant3::fGckin3
protected

GCKIN2 common structure.

Definition at line 1165 of file TGeant3.h.

Gckine_t* TGeant3::fGckine
protected

GCVOLU common structure.

Definition at line 1158 of file TGeant3.h.

Gcking_t* TGeant3::fGcking
protected

GCPHLT common structure.

Definition at line 1163 of file TGeant3.h.

Gclink_t* TGeant3::fGclink
protected

GCBANK common structure.

Definition at line 1146 of file TGeant3.h.

Gcmate_t* TGeant3::fGcmate
protected

GCMULO common structure.

Definition at line 1150 of file TGeant3.h.

Gcmore_t* TGeant3::fGcmore
protected

GCCUTS common structure.

Definition at line 1148 of file TGeant3.h.

Gcmulo_t* TGeant3::fGcmulo
protected

GCMORE common structure.

Definition at line 1149 of file TGeant3.h.

Gcnum_t* TGeant3::fGcnum
protected

GCTPOL common structure.

Definition at line 1152 of file TGeant3.h.

Gconst_t* TGeant3::fGconst
protected

GCCHAN common structure.

Definition at line 1171 of file TGeant3.h.

Gconsx_t* TGeant3::fGconsx
protected

GCONST common structure.

Definition at line 1172 of file TGeant3.h.

Gcopti_t* TGeant3::fGcopti
protected

GCSETS common structure.

Definition at line 1154 of file TGeant3.h.

Gcphlt_t* TGeant3::fGcphlt
protected

GCPHYS common structure.

Definition at line 1162 of file TGeant3.h.

Gcphys_t* TGeant3::fGcphys
protected

GCTMED common structure.

Definition at line 1161 of file TGeant3.h.

Gcsets_t* TGeant3::fGcsets
protected

GCNUM common structure.

Definition at line 1153 of file TGeant3.h.

Gctlit_t* TGeant3::fGctlit
protected

GCOPTI common structure.

Definition at line 1155 of file TGeant3.h.

Gctmed_t* TGeant3::fGctmed
protected

GCFLAG common structure.

Definition at line 1160 of file TGeant3.h.

Gctpol_t* TGeant3::fGctpol
protected

GCMATE common structure.

Definition at line 1151 of file TGeant3.h.

Gctrak_t* TGeant3::fGctrak
protected

GCKIN3 common structure.

Definition at line 1166 of file TGeant3.h.

Gcvdma_t* TGeant3::fGcvdma
protected

GCTLIT common structure.

Definition at line 1156 of file TGeant3.h.

Gcvolu_t* TGeant3::fGcvolu
protected

GCVDMA common structure.

Definition at line 1157 of file TGeant3.h.

Bool_t TGeant3::fImportRootGeometry
protected

Definition at line 1188 of file TGeant3.h.

TGeoMCGeometry* TGeant3::fMCGeo
protected

Definition at line 1187 of file TGeant3.h.

TObjArray TGeant3::fMedNames
protected

Names of geant volumes as C++ chars.

Definition at line 1181 of file TGeant3.h.

Int_t TGeant3::fNextVol
protected

Definition at line 1137 of file TGeant3.h.

Int_t TGeant3::fNG3Particles
protected

Names of geant medias as TObjString.

Definition at line 1183 of file TGeant3.h.

Int_t TGeant3::fNPDGCodes
protected

Definition at line 1184 of file TGeant3.h.

char TGeant3::fPath[512]
protected

Definition at line 1138 of file TGeant3.h.

TArrayI TGeant3::fPDGCode
protected

Definition at line 1186 of file TGeant3.h.

Quest_t* TGeant3::fQuest
protected

Good Old Q of Zebra.

Definition at line 1144 of file TGeant3.h.

Bool_t TGeant3::fSkipNeutrinos
protected

Definition at line 1192 of file TGeant3.h.

Bool_t TGeant3::fStopRun
protected

Definition at line 1191 of file TGeant3.h.

Trcom3_t* TGeant3::fTrcom3

ERWORK common structure.

Definition at line 1127 of file TGeant3.h.

char(* TGeant3::fVolNames)[5]
protected

GCJUMP common structure.

Definition at line 1180 of file TGeant3.h.

Int_t* TGeant3::fZiq
protected

Definition at line 1140 of file TGeant3.h.

Int_t* TGeant3::fZlq
protected

Good Old IQ of Zebra.

Definition at line 1141 of file TGeant3.h.

Float_t* TGeant3::fZq
protected

Good Old LQ of Zebra.

Definition at line 1142 of file TGeant3.h.


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