CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Public Attributes | Private Attributes
MagVolume6Faces Class Reference

#include <MagVolume6Faces.h>

Inheritance diagram for MagVolume6Faces:
MagVolume GloballyPositioned< float > MagneticField

Public Member Functions

virtual const std::vector
< VolumeSide > & 
faces () const
 Access to volume faces. More...
 
virtual bool inside (const GlobalPoint &gp, double tolerance=0.) const
 
 MagVolume6Faces (const PositionType &pos, const RotationType &rot, DDSolidShape shape, const std::vector< VolumeSide > &faces, const MagneticFieldProvider< float > *mfp, double sf=1.)
 
- Public Member Functions inherited from MagVolume
LocalVector fieldInTesla (const LocalPoint &lp) const
 
GlobalVector fieldInTesla (const GlobalPoint &lp) const
 
virtual bool inside (const LocalPoint &lp, double tolerance=0.) const
 
virtual ::GlobalVector inTesla (const ::GlobalPoint &gp) const
 
bool isIron () const
 Temporary hack to pass information on material. Will eventually be replaced! More...
 
 MagVolume (const PositionType &pos, const RotationType &rot, DDSolidShape shape, const MagneticFieldProvider< float > *mfp, double sf=1.)
 
void ownsFieldProvider (bool o)
 
const MagneticFieldProvider
< float > * 
provider () const
 
void setIsIron (bool iron)
 
DDSolidShape shapeType () const
 
virtual ~MagVolume ()
 
- Public Member Functions inherited from GloballyPositioned< float >
float eta () const
 
 GloballyPositioned ()
 
 GloballyPositioned (const PositionType &pos, const RotationType &rot)
 
void move (const GlobalVector &displacement)
 
float phi () const
 
const PositionTypeposition () const
 
void rotate (const RotationType &rotation)
 
const RotationTyperotation () const
 
GlobalPoint toGlobal (const LocalPoint &lp) const
 
Point3DBase< U, GlobalTagtoGlobal (const Point3DBase< U, LocalTag > &lp) const
 
GlobalVector toGlobal (const LocalVector &lv) const
 
Vector3DBase< U, GlobalTagtoGlobal (const Vector3DBase< U, LocalTag > &lv) const
 
LocalPoint toLocal (const GlobalPoint &gp) const
 
Point3DBase< U, LocalTagtoLocal (const Point3DBase< U, GlobalTag > &gp) const
 
LocalVector toLocal (const GlobalVector &gv) const
 
Vector3DBase< U, LocalTagtoLocal (const Vector3DBase< U, GlobalTag > &gv) const
 
virtual ~GloballyPositioned ()
 
- Public Member Functions inherited from MagneticField
virtual MagneticFieldclone () const
 
GlobalVector inInverseGeV (const GlobalPoint &gp) const
 Field value ad specified global point, in 1/Gev. More...
 
GlobalVector inKGauss (const GlobalPoint &gp) const
 Field value ad specified global point, in KGauss. More...
 
virtual GlobalVector inTesla (const GlobalPoint &gp) const =0
 Field value ad specified global point, in Tesla. More...
 
virtual GlobalVector inTeslaUnchecked (const GlobalPoint &gp) const
 
virtual bool isDefined (const GlobalPoint &gp) const
 True if the point is within the region where the concrete field. More...
 
 MagneticField ()
 
int nominalValue () const
 The nominal field value for this map in kGauss. More...
 
virtual ~MagneticField ()
 

Public Attributes

char copyno
 
short volumeNo
 

Private Attributes

std::vector< VolumeSidetheFaces
 

Additional Inherited Members

- Public Types inherited from MagVolume
typedef GloballyPositioned< float > Base
 
typedef GloballyPositioned
< float >::GlobalPoint 
GlobalPoint
 
typedef GloballyPositioned
< float >::GlobalVector 
GlobalVector
 
typedef GloballyPositioned
< float >::LocalPoint 
LocalPoint
 
typedef GloballyPositioned
< float >::LocalVector 
LocalVector
 
- Public Types inherited from GloballyPositioned< float >
typedef Point3DBase< float,
GlobalTag
GlobalPoint
 
typedef Vector3DBase< float,
GlobalTag
GlobalVector
 
typedef Point3DBase< float,
LocalTag
LocalPoint
 
typedef Vector3DBase< float,
LocalTag
LocalVector
 
typedef Point3DBase< float,
GlobalTag
PositionType
 
typedef TkRotation< float > RotationType
 
typedef float Scalar
 
- Static Public Member Functions inherited from GloballyPositioned< float >
static float iniEta ()
 
static float iniPhi ()
 

Detailed Description

A MagVolume defined by a number of sides (surfaces) NOTE that despite the name the sides can be less (or more) than 6!!!

inside() is implemented by checking that the given point is on the correct side of each of the surfaces sides.

Date:
2013/05/03 20:03:24
Revision:
1.6
Author
T. Todorov, N. Amapane

Definition at line 29 of file MagVolume6Faces.h.

Constructor & Destructor Documentation

MagVolume6Faces::MagVolume6Faces ( const PositionType pos,
const RotationType rot,
DDSolidShape  shape,
const std::vector< VolumeSide > &  faces,
const MagneticFieldProvider< float > *  mfp,
double  sf = 1. 
)

Definition at line 3 of file MagVolume6Faces.cc.

9  : MagVolume(pos,rot,shape,mfp,sf), volumeNo(0), copyno(0), theFaces(faces)
10 {}
virtual const std::vector< VolumeSide > & faces() const
Access to volume faces.
MagVolume(const PositionType &pos, const RotationType &rot, DDSolidShape shape, const MagneticFieldProvider< float > *mfp, double sf=1.)
Definition: MagVolume.h:23
std::vector< VolumeSide > theFaces

Member Function Documentation

virtual const std::vector<VolumeSide>& MagVolume6Faces::faces ( ) const
inlinevirtual

Access to volume faces.

Implements MagVolume.

Definition at line 41 of file MagVolume6Faces.h.

References theFaces.

41 {return theFaces;}
std::vector< VolumeSide > theFaces
bool MagVolume6Faces::inside ( const GlobalPoint gp,
double  tolerance = 0. 
) const
virtual

Implements MagVolume.

Definition at line 12 of file MagVolume6Faces.cc.

References i, SurfaceOrientation::onSurface, and theFaces.

13 {
14 
15  // check if the point is on the correct side of all delimiting surfaces
16  for (std::vector<VolumeSide>::const_iterator i=theFaces.begin(); i!=theFaces.end(); ++i) {
17  Surface::Side side = i->surface().side( gp, tolerance);
18  if ( side != i->surfaceSide() && side != SurfaceOrientation::onSurface) return false;
19  }
20  return true;
21 }
int i
Definition: DBlmapReader.cc:9
std::vector< VolumeSide > theFaces

Member Data Documentation

char MagVolume6Faces::copyno

Definition at line 45 of file MagVolume6Faces.h.

std::vector<VolumeSide> MagVolume6Faces::theFaces
private

Definition at line 50 of file MagVolume6Faces.h.

Referenced by faces(), and inside().

short MagVolume6Faces::volumeNo

Definition at line 44 of file MagVolume6Faces.h.