Geant4  10.01.p01
UBox Class Reference

#include <UBox.hh>

+ Inheritance diagram for UBox:
+ Collaboration diagram for UBox:

Public Member Functions

 UBox ()
 
 UBox (const std::string &name, double dx, double dy, double dz)
 
virtual ~UBox ()
 
 UBox (const UBox &rhs)
 
UBoxoperator= (const UBox &rhs)
 
void Set (double dx, double dy, double dz)
 
void Set (const UVector3 &vec)
 
double GetXHalfLength () const
 
double GetYHalfLength () const
 
double GetZHalfLength () const
 
void SetXHalfLength (double dx)
 
void SetYHalfLength (double dy)
 
void SetZHalfLength (double dz)
 
EnumInside Inside (const UVector3 &aPoint) const
 
double SafetyFromInside (const UVector3 &aPoint, bool aAccurate=false) const
 
double SafetyFromOutside (const UVector3 &aPoint, bool aAccurate=false) const
 
double DistanceToIn (const UVector3 &aPoint, const UVector3 &aDirection, double aPstep=UUtils::kInfinity) const
 
double DistanceToOut (const UVector3 &aPoint, const UVector3 &aDirection, UVector3 &aNormalVector, bool &aConvex, double aPstep=UUtils::kInfinity) const
 
bool Normal (const UVector3 &aPoint, UVector3 &aNormal) const
 
void Extent (UVector3 &aMin, UVector3 &aMax) const
 
double Capacity ()
 
double SurfaceArea ()
 
VUSolidClone () const
 
UGeometryType GetEntityType () const
 
void ComputeBBox (UBBox *, bool)
 
void GetParametersList (int, double *aArray) const
 
UVector3 GetPointOnSurface () const
 
std::ostream & StreamInfo (std::ostream &os) const
 
- Public Member Functions inherited from VUSolid
 VUSolid ()
 
 VUSolid (const std::string &name)
 
virtual ~VUSolid ()
 
double GetCarTolerance () const
 
double GetRadTolerance () const
 
double GetAngTolerance () const
 
void SetCarTolerance (double eps)
 
void SetRadTolerance (double eps)
 
void SetAngTolerance (double eps)
 
virtual void ExtentAxis (EAxisType aAxis, double &aMin, double &aMax) const
 
const std::string & GetName () const
 
void SetName (const std::string &aName)
 
virtual void SamplePointsInside (int, UVector3 *) const
 
virtual void SamplePointsOnSurface (int, UVector3 *) const
 
virtual void SamplePointsOnEdge (int, UVector3 *) const
 
double EstimateCubicVolume (int nStat, double epsilon) const
 
double EstimateSurfaceArea (int nStat, double ell) const
 

Private Attributes

double fDx
 
double fDy
 
double fDz
 
double fCubicVolume
 
double fSurfaceArea
 

Additional Inherited Members

- Public Types inherited from VUSolid
enum  EnumInside { eInside =0, eSurface =1, eOutside =2 }
 
enum  EAxisType { eXaxis =0, eYaxis =1, eZaxis =2 }
 
- Static Public Member Functions inherited from VUSolid
static double Tolerance ()
 
- Static Protected Attributes inherited from VUSolid
static double fgTolerance = 1.0E-9
 
static double frTolerance = 1.0E-9
 
static double faTolerance = 1.0E-9
 

Detailed Description

Definition at line 33 of file UBox.hh.

Constructor & Destructor Documentation

UBox::UBox ( )
inline

Definition at line 37 of file UBox.hh.

Referenced by Clone().

+ Here is the caller graph for this function:

UBox::UBox ( const std::string &  name,
double  dx,
double  dy,
double  dz 
)

Definition at line 23 of file UBox.cc.

References UUtils::Exception(), FatalErrorInArguments, VUSolid::fgTolerance, and VUSolid::GetName().

+ Here is the call graph for this function:

UBox::~UBox ( )
virtual

Definition at line 57 of file UBox.cc.

UBox::UBox ( const UBox rhs)

Definition at line 63 of file UBox.cc.

Member Function Documentation

double UBox::Capacity ( )
inlinevirtual

Implements VUSolid.

Definition at line 126 of file UBox.hh.

References fCubicVolume, fDx, fDy, and fDz.

VUSolid * UBox::Clone ( ) const
virtual

Implements VUSolid.

Definition at line 550 of file UBox.cc.

References UBox().

+ Here is the call graph for this function:

void UBox::ComputeBBox ( UBBox ,
bool   
)
inlinevirtual

Implements VUSolid.

Definition at line 88 of file UBox.hh.

double UBox::DistanceToIn ( const UVector3 aPoint,
const UVector3 aDirection,
double  aPstep = UUtils::kInfinity 
) const
virtual

Implements VUSolid.

Definition at line 117 of file UBox.cc.

References fDx, fDy, fDz, VUSolid::fgTolerance, UUtils::kInfinity, UVector3::x, UVector3::y, and UVector3::z.

Referenced by UVoxelizer::DistanceToFirst(), UVCSGfaceted::DistanceToIn(), UGenericTrap::DistanceToIn(), and UPolycone::DistanceToIn().

+ Here is the caller graph for this function:

double UBox::DistanceToOut ( const UVector3 aPoint,
const UVector3 aDirection,
UVector3 aNormalVector,
bool &  aConvex,
double  aPstep = UUtils::kInfinity 
) const
virtual

Implements VUSolid.

Definition at line 215 of file UBox.cc.

References fDx, fDy, fDz, VUSolid::fgTolerance, UUtils::kInfinity, UVector3::Set(), UUtils::Sign(), UVector3::x, UVector3::y, and UVector3::z.

+ Here is the call graph for this function:

void UBox::Extent ( UVector3 aMin,
UVector3 aMax 
) const
virtual

Implements VUSolid.

Definition at line 397 of file UBox.cc.

References fDx, fDy, fDz, UVector3::x, UVector3::y, and UVector3::z.

UGeometryType UBox::GetEntityType ( ) const
virtual

Implements VUSolid.

Definition at line 545 of file UBox.cc.

void UBox::GetParametersList ( int  ,
double *  aArray 
) const
inlinevirtual

Implements VUSolid.

Definition at line 91 of file UBox.hh.

References GetXHalfLength(), GetYHalfLength(), and GetZHalfLength().

+ Here is the call graph for this function:

UVector3 UBox::GetPointOnSurface ( ) const
virtual

Implements VUSolid.

Definition at line 415 of file UBox.cc.

References fDx, fDy, fDz, and UUtils::Random().

+ Here is the call graph for this function:

double UBox::GetXHalfLength ( ) const
inline

Definition at line 113 of file UBox.hh.

References fDx.

Referenced by GetParametersList(), and G4UBox::GetXHalfLength().

+ Here is the caller graph for this function:

double UBox::GetYHalfLength ( ) const
inline

Definition at line 117 of file UBox.hh.

References fDy.

Referenced by GetParametersList(), and G4UBox::GetYHalfLength().

+ Here is the caller graph for this function:

double UBox::GetZHalfLength ( ) const
inline

Definition at line 121 of file UBox.hh.

References fDz.

Referenced by UPolycone::DistanceToIn(), GetParametersList(), G4UBox::GetZHalfLength(), UVCSGfaceted::InitVoxels(), and UPolycone::Inside().

+ Here is the caller graph for this function:

VUSolid::EnumInside UBox::Inside ( const UVector3 aPoint) const
virtual

Implements VUSolid.

Definition at line 97 of file UBox.cc.

References VUSolid::eInside, VUSolid::eOutside, VUSolid::eSurface, fDx, fDy, fDz, VUSolid::fgTolerance, UVector3::x, UVector3::y, and UVector3::z.

Referenced by UGenericTrap::Inside(), and UPolycone::Inside().

+ Here is the caller graph for this function:

bool UBox::Normal ( const UVector3 aPoint,
UVector3 aNormal 
) const
virtual

Implements VUSolid.

Definition at line 328 of file UBox.cc.

References fDx, fDy, fDz, VUSolid::fgTolerance, UVector3::Set(), UUtils::Sign(), UVector3::x, UVector3::y, and UVector3::z.

+ Here is the call graph for this function:

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

Definition at line 72 of file UBox.cc.

References fCubicVolume, fDx, fDy, fDz, and fSurfaceArea.

double UBox::SafetyFromInside ( const UVector3 aPoint,
bool  aAccurate = false 
) const
virtual

Implements VUSolid.

Definition at line 276 of file UBox.cc.

References fDx, fDy, fDz, G4INCL::Math::max(), UVector3::x, UVector3::y, and UVector3::z.

+ Here is the call graph for this function:

double UBox::SafetyFromOutside ( const UVector3 aPoint,
bool  aAccurate = false 
) const
virtual

Implements VUSolid.

Definition at line 292 of file UBox.cc.

References fDx, fDy, fDz, UVector3::x, UVector3::y, and UVector3::z.

Referenced by UVCSGfaceted::SafetyFromOutside(), and UGenericTrap::SafetyFromOutside().

+ Here is the caller graph for this function:

void UBox::Set ( double  dx,
double  dy,
double  dz 
)

Definition at line 43 of file UBox.cc.

References fDx, fDy, and fDz.

Referenced by UPolycone::Init(), and UVCSGfaceted::InitVoxels().

+ Here is the caller graph for this function:

void UBox::Set ( const UVector3 vec)

Definition at line 50 of file UBox.cc.

References fDx, fDy, fDz, UVector3::x, UVector3::y, and UVector3::z.

void UBox::SetXHalfLength ( double  dx)

Definition at line 485 of file UBox.cc.

References UUtils::Exception(), FatalErrorInArguments, fCubicVolume, fDx, VUSolid::fgTolerance, fSurfaceArea, and VUSolid::GetName().

Referenced by G4UBox::SetXHalfLength().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void UBox::SetYHalfLength ( double  dy)

Definition at line 505 of file UBox.cc.

References UUtils::Exception(), FatalErrorInArguments, fCubicVolume, fDy, VUSolid::fgTolerance, fSurfaceArea, and VUSolid::GetName().

Referenced by G4UBox::SetYHalfLength().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void UBox::SetZHalfLength ( double  dz)

Definition at line 525 of file UBox.cc.

References UUtils::Exception(), FatalErrorInArguments, fCubicVolume, fDz, VUSolid::fgTolerance, fSurfaceArea, and VUSolid::GetName().

Referenced by G4UBox::SetZHalfLength().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

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

Implements VUSolid.

Definition at line 468 of file UBox.cc.

References fDx, fDy, fDz, and VUSolid::GetName().

+ Here is the call graph for this function:

double UBox::SurfaceArea ( )
inlinevirtual

Implements VUSolid.

Definition at line 139 of file UBox.hh.

References fDx, fDy, fDz, and fSurfaceArea.

Member Data Documentation

double UBox::fCubicVolume
private

Definition at line 107 of file UBox.hh.

Referenced by Capacity(), operator=(), SetXHalfLength(), SetYHalfLength(), and SetZHalfLength().

double UBox::fSurfaceArea
private

Definition at line 108 of file UBox.hh.

Referenced by operator=(), SetXHalfLength(), SetYHalfLength(), SetZHalfLength(), and SurfaceArea().


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