CMS 3D CMS Logo

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

#include <ZReflectedMFGrid.h>

Inheritance diagram for ZReflectedMFGrid:
MFGrid MagneticFieldProvider< float >

Public Member Functions

virtual Dimensions dimensions () const
 
virtual LocalPoint fromGridFrame (double a, double b, double c) const
 find grid coordinates for point. For debugging and validation only. More...
 
virtual LocalPoint nodePosition (int i, int j, int k) const
 Position of node in local frame. More...
 
virtual LocalVector nodeValue (int i, int j, int k) const
 Field value at node. More...
 
virtual void toGridFrame (const LocalPoint &p, double &a, double &b, double &c) const
 find grid coordinates for point. For debugging and validation only. More...
 
virtual LocalVector valueInTesla (const LocalPoint &p) const
 Interpolated field value at given point. More...
 
 ZReflectedMFGrid (const GloballyPositioned< float > &vol, MFGrid *sectorGrid)
 
 ~ZReflectedMFGrid ()
 
- Public Member Functions inherited from MFGrid
virtual void dump () const
 
const GloballyPositioned< float > & frame () const
 Local reference frame. More...
 
virtual Indexes index (const LocalPoint &p) const
 
 MFGrid (const GloballyPositioned< float > &vol)
 
virtual ~MFGrid ()
 
- Public Member Functions inherited from MagneticFieldProvider< float >
virtual LocalVectorType derivativeInTeslaPerMeter (const LocalPointType &p, int N) const
 
virtual int hasDerivatives () const
 
virtual LocalVectorType valueInTesla (const LocalPointType &p) const =0
 
virtual ~MagneticFieldProvider ()
 

Private Member Functions

void throwUp (const char *message) const
 

Private Attributes

double theDelta
 
double thePhiMax
 
double thePhiMin
 
MFGridtheSectorGrid
 

Additional Inherited Members

- Public Types inherited from MFGrid
typedef GloballyPositioned
< float >::GlobalPoint 
GlobalPoint
 
typedef GloballyPositioned
< float >::GlobalVector 
GlobalVector
 
typedef GloballyPositioned
< float >::LocalPoint 
LocalPoint
 
typedef GloballyPositioned
< float >::LocalVector 
LocalVector
 
- Public Types inherited from MagneticFieldProvider< float >
typedef Point3DBase< float,
GlobalTag
GlobalPointType
 
typedef Vector3DBase< float,
GlobalTag
GlobalVectorType
 
typedef Point3DBase< float,
LocalTag
LocalPointType
 
typedef Vector3DBase< float,
LocalTag
LocalVectorType
 

Detailed Description

Definition at line 7 of file ZReflectedMFGrid.h.

Constructor & Destructor Documentation

ZReflectedMFGrid::ZReflectedMFGrid ( const GloballyPositioned< float > &  vol,
MFGrid sectorGrid 
)

Definition at line 8 of file ZReflectedMFGrid.cc.

9  :
10  MFGrid(vol), theSectorGrid( sectorGrid)
11 
12 {}
MFGrid(const GloballyPositioned< float > &vol)
Definition: MFGrid.h:39
ZReflectedMFGrid::~ZReflectedMFGrid ( )

Definition at line 14 of file ZReflectedMFGrid.cc.

References theSectorGrid.

15 {
16  delete theSectorGrid;
17 }

Member Function Documentation

Dimensions ZReflectedMFGrid::dimensions ( void  ) const
virtual

Implements MFGrid.

Definition at line 43 of file ZReflectedMFGrid.cc.

References MFGrid::dimensions(), and theSectorGrid.

43 {return theSectorGrid->dimensions();}
virtual Dimensions dimensions() const =0
MFGrid::LocalPoint ZReflectedMFGrid::fromGridFrame ( double  a,
double  b,
double  c 
) const
virtual

find grid coordinates for point. For debugging and validation only.

Implements MFGrid.

Definition at line 37 of file ZReflectedMFGrid.cc.

References throwUp().

38 {
39  throwUp("Not implemented yet");
40  return LocalPoint();
41 }
void throwUp(const char *message) const
GloballyPositioned< float >::LocalPoint LocalPoint
Definition: MFGrid.h:36
MFGrid::LocalPoint ZReflectedMFGrid::nodePosition ( int  i,
int  j,
int  k 
) const
virtual

Position of node in local frame.

Implements MFGrid.

Definition at line 45 of file ZReflectedMFGrid.cc.

References throwUp().

46 {
47  throwUp("Not implemented yet");
48  return LocalPoint();
49 }
void throwUp(const char *message) const
GloballyPositioned< float >::LocalPoint LocalPoint
Definition: MFGrid.h:36
MFGrid::LocalVector ZReflectedMFGrid::nodeValue ( int  i,
int  j,
int  k 
) const
virtual

Field value at node.

Implements MFGrid.

Definition at line 51 of file ZReflectedMFGrid.cc.

References throwUp().

52 {
53  throwUp("Not implemented yet");
54  return LocalVector();
55 }
void throwUp(const char *message) const
GloballyPositioned< float >::LocalVector LocalVector
Definition: MFGrid.h:37
void ZReflectedMFGrid::throwUp ( const char *  message) const
private

Definition at line 27 of file ZReflectedMFGrid.cc.

References gather_cfg::cout.

Referenced by fromGridFrame(), nodePosition(), nodeValue(), and toGridFrame().

28 {
29  std::cout << "Throwing exception " << message << std::endl;
31 }
tuple cout
Definition: gather_cfg.py:121
void ZReflectedMFGrid::toGridFrame ( const LocalPoint p,
double &  a,
double &  b,
double &  c 
) const
virtual

find grid coordinates for point. For debugging and validation only.

Implements MFGrid.

Definition at line 32 of file ZReflectedMFGrid.cc.

References throwUp().

33 {
34  throwUp("Not implemented yet");
35 }
void throwUp(const char *message) const
MFGrid::LocalVector ZReflectedMFGrid::valueInTesla ( const LocalPoint p) const
virtual

Interpolated field value at given point.

Implements MFGrid.

Definition at line 19 of file ZReflectedMFGrid.cc.

References theSectorGrid, and MFGrid::valueInTesla().

20 {
21  // Z reflection of point
22  LocalPoint mirrorp( p.x(), p.y(), -p.z());
23  LocalVector mirrorB = theSectorGrid->valueInTesla( mirrorp);
24  return LocalVector( -mirrorB.x(), -mirrorB.y(), mirrorB.z());
25 }
T y() const
Definition: PV3DBase.h:62
T z() const
Definition: PV3DBase.h:63
virtual LocalVector valueInTesla(const LocalPoint &p) const =0
Interpolated field value at given point.
GloballyPositioned< float >::LocalVector LocalVector
Definition: MFGrid.h:37
T x() const
Definition: PV3DBase.h:61

Member Data Documentation

double ZReflectedMFGrid::theDelta
private

Definition at line 33 of file ZReflectedMFGrid.h.

double ZReflectedMFGrid::thePhiMax
private

Definition at line 31 of file ZReflectedMFGrid.h.

double ZReflectedMFGrid::thePhiMin
private

Definition at line 30 of file ZReflectedMFGrid.h.

MFGrid* ZReflectedMFGrid::theSectorGrid
private

Definition at line 32 of file ZReflectedMFGrid.h.

Referenced by dimensions(), valueInTesla(), and ~ZReflectedMFGrid().