CMS 3D CMS Logo

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

#include <OptOPlateSplitter.h>

Inheritance diagram for OptOPlateSplitter:
OpticalObject

Public Member Functions

void constructSolidShape () override
 
void detailedDeviatesLightRay (LightRay &lightray) override
 
void detailedTraversesLightRay (LightRay &lightray) override
 
void fastDeviatesLightRay (LightRay &lightray) override
 
void fastTraversesLightRay (LightRay &lightray) override
 
 OptOPlateSplitter ()
 
 OptOPlateSplitter (OpticalObject *parent, const ALIstring &type, const ALIstring &name, const ALIbool copy_data)
 
 ~OptOPlateSplitter () override
 
- Public Member Functions inherited from OpticalObject
void addCoordinateEntryToList (Entry *entry)
 
void addExtraEntryToList (Entry *entry)
 
void addExtraEntryValueOriginalOriginalToList (ALIdouble entry_value)
 
void addExtraEntryValueOriginalToList (ALIdouble entry_value)
 
void addExtraEntryValueToList (ALIdouble entry_value)
 
double addPii (double val)
 
double approxTo0 (double val)
 
CLHEP::HepRotation buildRmFromEntryValuesOriginalOriginal ()
 
const CLHEP::Hep3Vector & centreGlob () const
 
const CLHEP::Hep3Vector & centreGlobal () const
 
const CLHEP::Hep3Vector & centreGlobOriginal () const
 
const CLHEP::Hep3Vector & centreGlobOriginalOriginal () const
 
const CLHEP::Hep3Vector centreLocal () const
 
int checkMatrixEquations (double angleX, double angleY, double angleZ, CLHEP::HepRotation *rot=nullptr)
 
void construct ()
 
void constructFromOptAligInfo (const OpticalAlignInfo &oaInfo)
 
virtual void constructMaterial ()
 
const std::vector< Entry * > & CoordinateEntryList () const
 
void createComponentOptOsFromOptAlignInfo ()
 
virtual void defaultBehaviour (LightRay &lightray, Measurement &meas)
 
double diff2pi (double ang1, double ang2)
 
void displaceCentreGlob (const XYZcoor coor, const ALIdouble disp)
 
void displaceCentreGlob (const CLHEP::Hep3Vector &dispVec)
 
void displaceCentreGlobOriginal (const XYZcoor coor, const ALIdouble disp)
 
void displaceCentreGlobOriginal (const CLHEP::Hep3Vector &dispVec)
 
void displaceCentreGlobOriginalOriginal (const XYZcoor coor, const ALIdouble disp)
 
void displaceCentreGlobOriginalOriginal (const CLHEP::Hep3Vector &dispVec)
 
void displaceExtraEntry (const ALIuint entryNo, const ALIdouble disp)
 
void displaceExtraEntryOriginal (const ALIuint entryNo, const ALIdouble disp)
 
void displaceExtraEntryOriginalOriginal (const ALIuint entryNo, const ALIdouble disp)
 
void displaceRmGlobAroundGlobal (OpticalObject *opto1stRotated, const XYZcoor coor, const ALIdouble disp)
 
void displaceRmGlobAroundLocal (OpticalObject *opto1stRotated, const XYZcoor coor, const ALIdouble disp)
 
void displaceRmGlobOriginal (const OpticalObject *opto1stRotated, const XYZcoor coor, const ALIdouble disp)
 
void displaceRmGlobOriginalOriginal (const OpticalObject *opto1stRotated, const XYZcoor coor, const ALIdouble disp)
 
bool eq2ang (double ang1, double ang2)
 
const std::vector< Entry * > & ExtraEntryList () const
 
const ALIint extraEntryNo (const ALIstring &entry_name) const
 
std::vector< ALIdouble > & ExtraEntryValueList ()
 
const std::vector< ALIdouble > & ExtraEntryValueOriginalList ()
 
const std::vector< ALIdouble > & ExtraEntryValueOriginalOriginalList ()
 
virtual void fillIguana ()
 
virtual void fillVRML ()
 
const ALIdouble findExtraEntryValue (const ALIstring &eename) const
 
const ALIbool findExtraEntryValueIfExists (const ALIstring &eename, ALIdouble &value) const
 
const ALIdouble findExtraEntryValueMustExist (const ALIstring &eename) const
 
const ALIuint getCmsswID () const
 
std::vector< ALIstringgetCoordinateFromOptAlignParam (const OpticalAlignParam &oaParam)
 
CLHEP::Hep3Vector getDisplacementInLocalCoordinates (const XYZcoor coor, const ALIdouble disp)
 
const double getEntryCentre (const XYZcoor coor) const
 
const double getEntryCentre (const ALIstring &coor) const
 
const double getEntryRMangle (const XYZcoor coor) const
 
const double getEntryRMangle (const ALIstring &coor) const
 
std::vector< double > getLocalRotationAngles (const std::vector< Entry * > &entries) const
 
CocoaMaterialElementarygetMaterial () const
 
ALIPlane getPlate (const ALIbool forwardPlate, const ALIbool applyWedge)
 
std::vector< double > getRotationAnglesFromMatrix (CLHEP::HepRotation &rmLocal, const std::vector< Entry * > &entries) const
 
std::vector< double > getRotationAnglesInOptOFrame (const OpticalObject *optoAncestor, const std::vector< Entry * > &entries) const
 
CocoaSolidShapegetSolidShape () const
 
CLHEP::Hep3Vector getZAxis ()
 
const ALIuint ID () const
 
const ALIstring longName () const
 
virtual void makeMeasurement (LightRay &lightray, Measurement &meas)
 
Measurementmeas ()
 
const ALIstringname () const
 
 OpticalObject ()
 
 OpticalObject (OpticalObject *parent, const ALIstring &type, const ALIstring &name, const ALIbool copy_data)
 
const OpticalObjectparent () const
 
virtual void participateInMeasurement (LightRay &lightray, Measurement &meas, const ALIstring &behav)
 
void propagateGlobalRMOriginalOriginalChangeToChildren (const CLHEP::HepRotation &rmorioriold, const CLHEP::HepRotation &rmoriorinew)
 
void resetGlobalCoordinates ()
 
void resetOriginalOriginalCoordinates ()
 
const CLHEP::HepRotation & rmGlob () const
 
const CLHEP::HepRotation & rmGlobOriginal () const
 
const CLHEP::HepRotation & rmGlobOriginalOriginal () const
 
const CLHEP::HepRotation rmLocal () const
 
void setCmsswID (ALIuint id)
 
void setExtraEntryValue (const ALIuint entryNo, const ALIdouble disp)
 
void setGlobalCoordinates ()
 
void setGlobalRMOriginalOriginal (const CLHEP::HepRotation &rmoriori)
 
void setID (ALIuint id)
 
void setMeas (Measurement *meas)
 set current measurement More...
 
void setOriginalEntryValues ()
 
void setRmGlobal (const CLHEP::HepRotation &rm)
 
void setRmGlobalOriginal (const CLHEP::HepRotation &rm)
 
void setType (const ALIstring &type)
 
const ALIstring shortName () const
 
const ALIstringtype () const
 
virtual void userDefinedBehaviour (LightRay &lightray, Measurement &meas, const ALIstring &behav)
 
virtual ~OpticalObject ()
 

Additional Inherited Members

- Protected Member Functions inherited from OpticalObject
virtual void fillExtraEntry (std::vector< ALIstring > &wordlist)
 
- Protected Attributes inherited from OpticalObject
CocoaMaterialElementarytheMaterial
 
CocoaSolidShapetheSolidShape
 
ALIint verbose
 

Detailed Description

Definition at line 18 of file OptOPlateSplitter.h.

Constructor & Destructor Documentation

OptOPlateSplitter::OptOPlateSplitter ( )
inline

Definition at line 21 of file OptOPlateSplitter.h.

21 {};
OptOPlateSplitter::OptOPlateSplitter ( OpticalObject parent,
const ALIstring type,
const ALIstring name,
const ALIbool  copy_data 
)
inline

Definition at line 22 of file OptOPlateSplitter.h.

23  : OpticalObject(parent, type, name, copy_data){};
const ALIstring & name() const
Definition: OpticalObject.h:58
OptOPlateSplitter::~OptOPlateSplitter ( )
inlineoverride

Definition at line 24 of file OptOPlateSplitter.h.

24 {};

Member Function Documentation

void OptOPlateSplitter::constructSolidShape ( )
overridevirtual

Reimplemented from OpticalObject.

Definition at line 150 of file OptOPlateSplitter.cc.

References GlobalOptionMgr::getGlobalOptionValue(), GlobalOptionMgr::getInstance(), and visualization-live-secondInstance_cfg::m.

150  {
151  ALIdouble go;
153  gomgr->getGlobalOptionValue("VisScale", go);
154 
156  "Box", go * 5. * cm / m, go * 5. * cm / m, go * 1. * cm / m); //COCOA internal units are meters
157 }
long double ALIdouble
Definition: CocoaGlobals.h:11
CocoaSolidShape * theSolidShape
static GlobalOptionMgr * getInstance()
int getGlobalOptionValue(const ALIstring &sstr, ALIdouble &val)
--— Search a string in theGlobalOptions and return 1 if found
void OptOPlateSplitter::detailedDeviatesLightRay ( LightRay lightray)
overridevirtual

Reimplemented from OpticalObject.

Definition at line 26 of file OptOPlateSplitter.cc.

References gather_cfg::cout, ALIUtils::debug, ALIUtils::dump3v(), LightRay::dumpData(), mergeVDriftHistosByStation::name, and LightRay::reflect().

26  {
27  if (ALIUtils::debug >= 2)
28  std::cout << "LR: DETAILED REFLECTION IN PLATE SPLITTER " << name() << std::endl;
29  if (ALIUtils::debug >= 3)
30  ALIUtils::dump3v(centreGlob(), " centre Global RF ");
31 
32  //---------- Get forward plate
33  ALIPlane plate = getPlate(true, true);
34  //---------- Reflect
35  lightray.reflect(plate);
36  if (ALIUtils::debug >= 2) {
37  std::cout << "Reflected in plate" << std::endl;
38  lightray.dumpData(" ");
39  }
40 }
static ALIint debug
Definition: ALIUtils.h:34
static void dump3v(const CLHEP::Hep3Vector &vec, const std::string &msg)
Definition: ALIUtils.cc:58
const CLHEP::Hep3Vector & centreGlob() const
Definition: OpticalObject.h:75
ALIPlane getPlate(const ALIbool forwardPlate, const ALIbool applyWedge)
void dumpData(const ALIstring &str) const
Definition: LightRay.cc:374
tuple cout
Definition: gather_cfg.py:144
const ALIstring & name() const
Definition: OpticalObject.h:58
void reflect(const ALIPlane &plane)
Definition: LightRay.cc:138
void OptOPlateSplitter::detailedTraversesLightRay ( LightRay lightray)
overridevirtual

Reimplemented from OpticalObject.

Definition at line 50 of file OptOPlateSplitter.cc.

References gather_cfg::cout, ALIUtils::debug, LightRay::dumpData(), mergeVDriftHistosByStation::name, and LightRay::refract().

50  {
51  if (ALIUtils::debug >= 2)
52  std::cout << "LR: DETAILED TRAVERSE IN PLATE SPLITTER " << name() << std::endl;
53 
54  //---------- Get forward plate
55  ALIPlane plate = getPlate(true, true);
56  //---------- If width is 0, just keep the same point
57  ALIdouble width = findExtraEntryValue("width");
58  if (width == 0) {
59  if (ALIUtils::debug >= 3)
60  lightray.dumpData("Traversed with 0 width");
61  return;
62  }
63 
64  //---------- Refract while entering splitter
65  ALIdouble refra_ind1 = 1.;
66  ALIdouble refra_ind2 = findExtraEntryValue("refra_ind");
67  lightray.refract(plate, refra_ind1, refra_ind2);
68  if (ALIUtils::debug >= 2) {
69  lightray.dumpData("Refracted in first plate");
70  }
71 
72  //---------- Get backward plate
73  plate = getPlate(false, true);
74  //---------- Refract while exiting splitter
75  lightray.refract(plate, refra_ind2, refra_ind1);
76  if (ALIUtils::debug >= 2) {
77  lightray.dumpData("Refracted in first plate");
78  }
79 }
long double ALIdouble
Definition: CocoaGlobals.h:11
void refract(const ALIPlane &plate, const ALIdouble refra_ind1, const ALIdouble refra_ind2)
Definition: LightRay.cc:157
static ALIint debug
Definition: ALIUtils.h:34
const ALIdouble findExtraEntryValue(const ALIstring &eename) const
ALIPlane getPlate(const ALIbool forwardPlate, const ALIbool applyWedge)
void dumpData(const ALIstring &str) const
Definition: LightRay.cc:374
tuple cout
Definition: gather_cfg.py:144
const ALIstring & name() const
Definition: OpticalObject.h:58
void OptOPlateSplitter::fastDeviatesLightRay ( LightRay lightray)
overridevirtual

Reimplemented from OpticalObject.

Definition at line 88 of file OptOPlateSplitter.cc.

References gather_cfg::cout, ALIUtils::debug, LightRay::dumpData(), mergeVDriftHistosByStation::name, LightRay::reflect(), and LightRay::shiftAndDeviateWhileTraversing().

88  {
89  if (ALIUtils::debug >= 2)
90  std::cout << "LR: REFLECTION IN PLATE SPLITTER " << name() << std::endl;
91 
92  //---------- Get forward plate
93  ALIPlane plate = getPlate(true, false);
94  //---------- Reflect in plate (including intersection with it)
95  lightray.reflect(plate);
96  if (ALIUtils::debug >= 2) {
97  lightray.dumpData("Reflected in plate");
98  }
99  //---------- Deviate Lightray
100  lightray.shiftAndDeviateWhileTraversing(this, 'R');
101  if (ALIUtils::debug >= 2) {
102  lightray.dumpData("Deviated ");
103  }
104 }
void shiftAndDeviateWhileTraversing(const OpticalObject *opto, char behav)
Definition: LightRay.cc:235
static ALIint debug
Definition: ALIUtils.h:34
ALIPlane getPlate(const ALIbool forwardPlate, const ALIbool applyWedge)
void dumpData(const ALIstring &str) const
Definition: LightRay.cc:374
tuple cout
Definition: gather_cfg.py:144
const ALIstring & name() const
Definition: OpticalObject.h:58
void reflect(const ALIPlane &plane)
Definition: LightRay.cc:138
void OptOPlateSplitter::fastTraversesLightRay ( LightRay lightray)
overridevirtual

Reimplemented from OpticalObject.

Definition at line 115 of file OptOPlateSplitter.cc.

References gather_cfg::cout, ALIUtils::debug, LightRay::dumpData(), LightRay::intersect(), mergeVDriftHistosByStation::name, and LightRay::shiftAndDeviateWhileTraversing().

115  {
116  if (ALIUtils::debug >= 2)
117  std::cout << "LR: TRAVERSE PLATE SPLITTER " << name() << std::endl;
118 
119  //---------- Get backward plate
120  ALIPlane plate = getPlate(false, false);
121  lightray.intersect(plate);
122  if (ALIUtils::debug >= 2) {
123  lightray.dumpData("Intersected with plate");
124  }
125  //---------- Shift and Deviate
126  lightray.shiftAndDeviateWhileTraversing(this, 'T');
127  if (ALIUtils::debug >= 2) {
128  lightray.dumpData("Shifted and Deviated");
129  }
130 }
void shiftAndDeviateWhileTraversing(const OpticalObject *opto, char behav)
Definition: LightRay.cc:235
static ALIint debug
Definition: ALIUtils.h:34
void intersect(const ALIPlane &plane)
Definition: LightRay.cc:93
ALIPlane getPlate(const ALIbool forwardPlate, const ALIbool applyWedge)
void dumpData(const ALIstring &str) const
Definition: LightRay.cc:374
tuple cout
Definition: gather_cfg.py:144
const ALIstring & name() const
Definition: OpticalObject.h:58