ECCE @ EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
G4Trd Class Reference

#include <geant4/tree/geant4-10.6-release/source/geometry/solids/CSG/include/G4Trd.hh>

+ Inheritance diagram for G4Trd:
+ Collaboration diagram for G4Trd:

Public Member Functions

 G4Trd (const G4String &pName, G4double pdx1, G4double pdx2, G4double pdy1, G4double pdy2, G4double pdz)
 
 ~G4Trd ()
 
G4double GetXHalfLength1 () const
 
G4double GetXHalfLength2 () const
 
G4double GetYHalfLength1 () const
 
G4double GetYHalfLength2 () const
 
G4double GetZHalfLength () const
 
void SetXHalfLength1 (G4double val)
 
void SetXHalfLength2 (G4double val)
 
void SetYHalfLength1 (G4double val)
 
void SetYHalfLength2 (G4double val)
 
void SetZHalfLength (G4double val)
 
void SetAllParameters (G4double pdx1, G4double pdx2, G4double pdy1, G4double pdy2, G4double pdz)
 
G4double GetCubicVolume ()
 
G4double GetSurfaceArea ()
 
void ComputeDimensions (G4VPVParameterisation *p, const G4int n, const G4VPhysicalVolume *pRep)
 
void BoundingLimits (G4ThreeVector &pMin, G4ThreeVector &pMax) const
 
G4bool CalculateExtent (const EAxis pAxis, const G4VoxelLimits &pVoxelLimit, const G4AffineTransform &pTransform, G4double &pMin, G4double &pMax) const
 
EInside Inside (const G4ThreeVector &p) const
 
G4ThreeVector SurfaceNormal (const G4ThreeVector &p) const
 
G4double DistanceToIn (const G4ThreeVector &p, const G4ThreeVector &v) const
 
G4double DistanceToIn (const G4ThreeVector &p) const
 
G4double DistanceToOut (const G4ThreeVector &p, const G4ThreeVector &v, const G4bool calcNorm=false, G4bool *validNorm=nullptr, G4ThreeVector *n=nullptr) const
 
G4double DistanceToOut (const G4ThreeVector &p) const
 
G4GeometryType GetEntityType () const
 
G4ThreeVector GetPointOnSurface () const
 
G4VSolidClone () const
 
std::ostream & StreamInfo (std::ostream &os) const
 
void DescribeYourselfTo (G4VGraphicsScene &scene) const
 
G4PolyhedronCreatePolyhedron () const
 
 G4Trd (__void__ &)
 
 G4Trd (const G4Trd &rhs)
 
G4Trdoperator= (const G4Trd &rhs)
 
- Public Member Functions inherited from G4CSGSolid
 G4CSGSolid (const G4String &pName)
 
virtual ~G4CSGSolid ()
 
virtual G4PolyhedronGetPolyhedron () const
 
 G4CSGSolid (__void__ &)
 
 G4CSGSolid (const G4CSGSolid &rhs)
 
G4CSGSolidoperator= (const G4CSGSolid &rhs)
 
- Public Member Functions inherited from G4VSolid
 G4VSolid (const G4String &name)
 
virtual ~G4VSolid ()
 
G4bool operator== (const G4VSolid &s) const
 
G4String GetName () const
 
void SetName (const G4String &name)
 
G4double GetTolerance () const
 
void DumpInfo () const
 
virtual G4VisExtent GetExtent () const
 
virtual const G4VSolidGetConstituentSolid (G4int no) const
 
virtual G4VSolidGetConstituentSolid (G4int no)
 
virtual const G4DisplacedSolidGetDisplacedSolidPtr () const
 
virtual G4DisplacedSolidGetDisplacedSolidPtr ()
 
 G4VSolid (__void__ &)
 
 G4VSolid (const G4VSolid &rhs)
 
G4VSolidoperator= (const G4VSolid &rhs)
 
G4double EstimateCubicVolume (G4int nStat, G4double epsilon) const
 
G4double EstimateSurfaceArea (G4int nStat, G4double ell) const
 

Private Member Functions

void CheckParameters ()
 
void MakePlanes ()
 
G4ThreeVector ApproxSurfaceNormal (const G4ThreeVector &p) const
 

Private Attributes

G4double halfCarTolerance
 
G4double fDx1
 
G4double fDx2
 
G4double fDy1
 
G4double fDy2
 
G4double fDz
 
struct {
   G4double   a
 
   G4double   b
 
   G4double   c
 
   G4double   d
 
fPlanes [4]
 

Additional Inherited Members

- Protected Member Functions inherited from G4CSGSolid
G4double GetRadiusInRing (G4double rmin, G4double rmax) const
 
- Protected Attributes inherited from G4CSGSolid
G4double fCubicVolume = 0.0
 
G4double fSurfaceArea = 0.0
 
G4bool fRebuildPolyhedron = false
 
G4PolyhedronfpPolyhedron = nullptr
 

Detailed Description

Definition at line 62 of file G4Trd.hh.

View newest version in sPHENIX GitHub at line 62 of file G4Trd.hh

Constructor & Destructor Documentation

G4Trd::G4Trd ( const G4String pName,
G4double  pdx1,
G4double  pdx2,
G4double  pdy1,
G4double  pdy2,
G4double  pdz 
)

Definition at line 54 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 54 of file G4Trd.cc

References CheckParameters(), and MakePlanes().

Referenced by Clone().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

G4Trd::~G4Trd ( )

Definition at line 81 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 81 of file G4Trd.cc

G4Trd::G4Trd ( __void__ &  a)

Definition at line 70 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 70 of file G4Trd.cc

References MakePlanes().

+ Here is the call graph for this function:

G4Trd::G4Trd ( const G4Trd rhs)

Definition at line 89 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 89 of file G4Trd.cc

References fPlanes.

Member Function Documentation

G4ThreeVector G4Trd::ApproxSurfaceNormal ( const G4ThreeVector p) const
private

Definition at line 428 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 428 of file G4Trd.cc

References a, kdfinder::abs(), b, c, d, DBL_MAX, fDz, fPlanes, CLHEP::Hep3Vector::x(), CLHEP::Hep3Vector::y(), and CLHEP::Hep3Vector::z().

Referenced by SurfaceNormal().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void G4Trd::BoundingLimits ( G4ThreeVector pMin,
G4ThreeVector pMax 
) const
virtual

Reimplemented from G4VSolid.

Definition at line 248 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 248 of file G4Trd.cc

References G4VSolid::DumpInfo(), dz, G4Exception(), G4VSolid::GetName(), GetXHalfLength1(), GetXHalfLength2(), GetYHalfLength1(), GetYHalfLength2(), GetZHalfLength(), JustWarning, max, message(), pMax, CLHEP::Hep3Vector::set(), CLHEP::Hep3Vector::x(), xmax, CLHEP::Hep3Vector::y(), ymax, and CLHEP::Hep3Vector::z().

Referenced by CalculateExtent().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

G4bool G4Trd::CalculateExtent ( const EAxis  pAxis,
const G4VoxelLimits pVoxelLimit,
const G4AffineTransform pTransform,
G4double pMin,
G4double pMax 
) const
virtual

Implements G4VSolid.

Definition at line 279 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 279 of file G4Trd.cc

References G4BoundingEnvelope::BoundingBoxVsVoxelLimits(), BoundingLimits(), G4BoundingEnvelope::CalculateExtent(), dz, GetXHalfLength1(), GetXHalfLength2(), GetYHalfLength1(), GetYHalfLength2(), GetZHalfLength(), and pMax.

+ Here is the call graph for this function:

void G4Trd::CheckParameters ( )
private

Definition at line 147 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 147 of file G4Trd.cc

References FatalException, fDx1, fDx2, fDy1, fDy2, fDz, G4Exception(), G4VSolid::GetName(), G4VSolid::kCarTolerance, and message().

Referenced by G4Trd(), and SetAllParameters().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

G4VSolid * G4Trd::Clone ( ) const
virtual

Reimplemented from G4VSolid.

Definition at line 686 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 686 of file G4Trd.cc

References G4Trd().

+ Here is the call graph for this function:

void G4Trd::ComputeDimensions ( G4VPVParameterisation p,
const G4int  n,
const G4VPhysicalVolume pRep 
)
virtual

Reimplemented from G4VSolid.

Definition at line 237 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 237 of file G4Trd.cc

References G4VPVParameterisation::ComputeDimensions().

+ Here is the call graph for this function:

G4Polyhedron * G4Trd::CreatePolyhedron ( ) const
virtual

Reimplemented from G4VSolid.

Definition at line 781 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 781 of file G4Trd.cc

References fDx1, fDx2, fDy1, fDy2, and fDz.

void G4Trd::DescribeYourselfTo ( G4VGraphicsScene scene) const
virtual

Implements G4VSolid.

Definition at line 776 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 776 of file G4Trd.cc

References G4VGraphicsScene::AddSolid().

+ Here is the call graph for this function:

G4double G4Trd::DistanceToIn ( const G4ThreeVector p,
const G4ThreeVector v 
) const
virtual

Implements G4VSolid.

Definition at line 452 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 452 of file G4Trd.cc

References kdfinder::abs(), DBL_MAX, dz, fDz, fPlanes, halfCarTolerance, kInfinity, tmp, CLHEP::Hep3Vector::x(), CLHEP::Hep3Vector::y(), and CLHEP::Hep3Vector::z().

+ Here is the call graph for this function:

G4double G4Trd::DistanceToIn ( const G4ThreeVector p) const
virtual

Implements G4VSolid.

Definition at line 545 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 545 of file G4Trd.cc

References kdfinder::abs(), c, dx, dy, dz, fDz, fPlanes, max, CLHEP::Hep3Vector::x(), CLHEP::Hep3Vector::y(), and CLHEP::Hep3Vector::z().

+ Here is the call graph for this function:

G4double G4Trd::DistanceToOut ( const G4ThreeVector p,
const G4ThreeVector v,
const G4bool  calcNorm = false,
G4bool validNorm = nullptr,
G4ThreeVector n = nullptr 
) const
virtual

Implements G4VSolid.

Definition at line 563 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 563 of file G4Trd.cc

References a, kdfinder::abs(), b, c, DBL_MAX, fDz, fPlanes, halfCarTolerance, CLHEP::Hep3Vector::set(), tmp, CLHEP::Hep3Vector::x(), CLHEP::Hep3Vector::y(), and CLHEP::Hep3Vector::z().

+ Here is the call graph for this function:

G4double G4Trd::DistanceToOut ( const G4ThreeVector p) const
virtual

Implements G4VSolid.

Definition at line 645 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 645 of file G4Trd.cc

References kdfinder::abs(), c, G4VSolid::DumpInfo(), dx, dy, dz, fDz, fPlanes, G4cout, G4endl, G4Exception(), G4VSolid::GetName(), Inside(), JustWarning, kOutside, max, message(), mm, CLHEP::Hep3Vector::x(), CLHEP::Hep3Vector::y(), and CLHEP::Hep3Vector::z().

+ Here is the call graph for this function:

G4double G4Trd::GetCubicVolume ( )
virtual

Reimplemented from G4VSolid.

Definition at line 206 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 206 of file G4Trd.cc

References G4CSGSolid::fCubicVolume, fDx1, fDx2, fDy1, fDy2, and fDz.

G4GeometryType G4Trd::GetEntityType ( ) const
virtual

Implements G4VSolid.

Definition at line 677 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 677 of file G4Trd.cc

G4ThreeVector G4Trd::GetPointOnSurface ( ) const
virtual

Reimplemented from G4VSolid.

Definition at line 718 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 718 of file G4Trd.cc

References fDx1, fDx2, fDy1, fDy2, fDz, G4UniformRand, k, CLHEP::Hep3Vector::mag(), pt, s1, CLHEP::Hep3Vector::set(), G4GeomTools::TriangleAreaNormal(), Acts::UnitConstants::u, and v.

+ Here is the call graph for this function:

G4double G4Trd::GetSurfaceArea ( )
virtual

Reimplemented from G4VSolid.

Definition at line 220 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 220 of file G4Trd.cc

References fDx1, fDx2, fDy1, fDy2, fDz, and G4CSGSolid::fSurfaceArea.

EInside G4Trd::Inside ( const G4ThreeVector p) const
virtual

Implements G4VSolid.

Definition at line 330 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 330 of file G4Trd.cc

References kdfinder::abs(), c, dx, dy, dz, fDz, fPlanes, halfCarTolerance, kInside, kOutside, kSurface, max, CLHEP::Hep3Vector::x(), CLHEP::Hep3Vector::y(), and CLHEP::Hep3Vector::z().

Referenced by DistanceToOut().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void G4Trd::MakePlanes ( )
private

Definition at line 169 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 169 of file G4Trd.cc

References dx, dy, dz, fDx1, fDx2, fDy1, fDy2, fDz, and fPlanes.

Referenced by G4Trd(), and SetAllParameters().

+ Here is the caller graph for this function:

G4Trd & G4Trd::operator= ( const G4Trd rhs)

Definition at line 101 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 101 of file G4Trd.cc

References fDx1, fDx2, fDy1, fDy2, fDz, fPlanes, halfCarTolerance, and G4CSGSolid::operator=().

+ Here is the call graph for this function:

void G4Trd::SetAllParameters ( G4double  pdx1,
G4double  pdx2,
G4double  pdy1,
G4double  pdy2,
G4double  pdz 
)

Definition at line 126 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 126 of file G4Trd.cc

References CheckParameters(), G4CSGSolid::fCubicVolume, fDx1, fDx2, fDy1, fDy2, fDz, G4CSGSolid::fRebuildPolyhedron, G4CSGSolid::fSurfaceArea, and MakePlanes().

Referenced by G4ParameterisationTrdX::ComputeDimensions(), G4ParameterisationTrdY::ComputeDimensions(), and G4ParameterisationTrdZ::ComputeDimensions().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void G4Trd::SetXHalfLength1 ( G4double  val)
inline

Referenced by G4GDMLParameterisation::ComputeDimensions(), and export_G4Trd().

+ Here is the caller graph for this function:

void G4Trd::SetXHalfLength2 ( G4double  val)
inline

Referenced by G4GDMLParameterisation::ComputeDimensions(), and export_G4Trd().

+ Here is the caller graph for this function:

void G4Trd::SetYHalfLength1 ( G4double  val)
inline

Referenced by G4GDMLParameterisation::ComputeDimensions(), and export_G4Trd().

+ Here is the caller graph for this function:

void G4Trd::SetYHalfLength2 ( G4double  val)
inline

Referenced by G4GDMLParameterisation::ComputeDimensions(), and export_G4Trd().

+ Here is the caller graph for this function:

void G4Trd::SetZHalfLength ( G4double  val)
inline

Referenced by G4GDMLParameterisation::ComputeDimensions(), and export_G4Trd().

+ Here is the caller graph for this function:

std::ostream & G4Trd::StreamInfo ( std::ostream &  os) const
virtual

Reimplemented from G4CSGSolid.

Definition at line 695 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 695 of file G4Trd.cc

References fDx1, fDx2, fDy1, fDy2, fDz, G4VSolid::GetName(), and mm.

+ Here is the call graph for this function:

G4ThreeVector G4Trd::SurfaceNormal ( const G4ThreeVector p) const
virtual

Implements G4VSolid.

Definition at line 347 of file G4Trd.cc.

View newest version in sPHENIX GitHub at line 347 of file G4Trd.cc

References kdfinder::abs(), ApproxSurfaceNormal(), G4VSolid::DumpInfo(), dz, fDz, fPlanes, G4cout, G4endl, G4Exception(), G4VSolid::GetName(), halfCarTolerance, JustWarning, message(), mm, CLHEP::Hep3Vector::unit(), CLHEP::Hep3Vector::x(), CLHEP::Hep3Vector::y(), and CLHEP::Hep3Vector::z().

+ Here is the call graph for this function:

Member Data Documentation

G4double G4Trd::a

Definition at line 170 of file G4Trd.hh.

View newest version in sPHENIX GitHub at line 170 of file G4Trd.hh

Referenced by ApproxSurfaceNormal(), and DistanceToOut().

G4double G4Trd::b

Definition at line 170 of file G4Trd.hh.

View newest version in sPHENIX GitHub at line 170 of file G4Trd.hh

Referenced by ApproxSurfaceNormal(), and DistanceToOut().

G4double G4Trd::c

Definition at line 170 of file G4Trd.hh.

View newest version in sPHENIX GitHub at line 170 of file G4Trd.hh

Referenced by ApproxSurfaceNormal(), DistanceToIn(), DistanceToOut(), and Inside().

G4double G4Trd::d

Definition at line 170 of file G4Trd.hh.

View newest version in sPHENIX GitHub at line 170 of file G4Trd.hh

Referenced by ApproxSurfaceNormal().

G4double G4Trd::fDx1
private

Definition at line 169 of file G4Trd.hh.

View newest version in sPHENIX GitHub at line 169 of file G4Trd.hh

Referenced by CheckParameters(), CreatePolyhedron(), GetCubicVolume(), GetPointOnSurface(), GetSurfaceArea(), MakePlanes(), operator=(), SetAllParameters(), and StreamInfo().

G4double G4Trd::fDx2
private

Definition at line 169 of file G4Trd.hh.

View newest version in sPHENIX GitHub at line 169 of file G4Trd.hh

Referenced by CheckParameters(), CreatePolyhedron(), GetCubicVolume(), GetPointOnSurface(), GetSurfaceArea(), MakePlanes(), operator=(), SetAllParameters(), and StreamInfo().

G4double G4Trd::fDy1
private

Definition at line 169 of file G4Trd.hh.

View newest version in sPHENIX GitHub at line 169 of file G4Trd.hh

Referenced by CheckParameters(), CreatePolyhedron(), GetCubicVolume(), GetPointOnSurface(), GetSurfaceArea(), MakePlanes(), operator=(), SetAllParameters(), and StreamInfo().

G4double G4Trd::fDy2
private

Definition at line 169 of file G4Trd.hh.

View newest version in sPHENIX GitHub at line 169 of file G4Trd.hh

Referenced by CheckParameters(), CreatePolyhedron(), GetCubicVolume(), GetPointOnSurface(), GetSurfaceArea(), MakePlanes(), operator=(), SetAllParameters(), and StreamInfo().

G4double G4Trd::halfCarTolerance
private

Definition at line 168 of file G4Trd.hh.

View newest version in sPHENIX GitHub at line 168 of file G4Trd.hh

Referenced by DistanceToIn(), DistanceToOut(), Inside(), operator=(), and SurfaceNormal().


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