CMS 3D CMS Logo

List of all members | Public Member Functions | Private Member Functions | Private Attributes
AlignableMuon Class Reference

Constructor of the full muon geometry. More...

#include <AlignableMuon.h>

Inheritance diagram for AlignableMuon:
AlignableComposite Alignable

Public Member Functions

 AlignableMuon (const DTGeometry *, const CSCGeometry *)
 Constructor from geometries. More...
 
const align::Alignablescomponents () const final
 Return all components. More...
 
AlignmentErrorsExtendedcscAlignmentErrorsExtended ()
 Get CSC alignment errors sorted by DetId. More...
 
AlignmentscscAlignments ()
 Get CSC alignments sorted by DetId. More...
 
align::Alignables CSCChambers ()
 
align::Alignables CSCEndcaps ()
 
align::Alignables CSCLayers ()
 
align::Alignables CSCRings ()
 
align::Alignables CSCStations ()
 
AlignmentErrorsExtendeddtAlignmentErrorsExtended ()
 Get DT alignment errors sorted by DetId. More...
 
AlignmentsdtAlignments ()
 Get DT alignments sorted by DetId. More...
 
align::Alignables DTBarrel ()
 
align::Alignables DTChambers ()
 
align::Alignables DTLayers ()
 Methods to return specific of components. More...
 
align::Alignables DTStations ()
 
align::Alignables DTSuperLayers ()
 
align::Alignables DTWheels ()
 
virtual Alignablemother ()
 Alignable tracker has no mother. More...
 
const AlignableObjectIdobjectIdProvider () const
 Return muon alignable object ID provider derived from the muon system geometry. More...
 
void update (const DTGeometry *, const CSCGeometry *)
 
 ~AlignableMuon () override
 Destructor. More...
 
- Public Member Functions inherited from AlignableComposite
void addAlignmentPositionError (const AlignmentPositionError &ape, bool propagateDown) override
 
void addAlignmentPositionErrorFromLocalRotation (const RotationType &rotation, bool propagateDown) override
 
void addAlignmentPositionErrorFromRotation (const RotationType &rotation, bool propagateDown) override
 
void addComponent (Alignable *component) final
 
void addSurfaceDeformation (const SurfaceDeformation *deformation, bool propagateDown) override
 
 AlignableComposite (align::ID id, StructureType aType, const RotationType &rot=RotationType())
 
StructureType alignableObjectId () const override
 Return the alignable type identifier. More...
 
void dump () const override
 Recursive printout of alignable structure. More...
 
void move (const GlobalVector &displacement) override
 Move with respect to the global reference frame. More...
 
virtual void moveComponentLocal (const int i, const LocalVector &localDisplacement)
 Move a single component with respect to the local reference frame. More...
 
virtual void moveComponentsLocal (const LocalVector &localDisplacement)
 Move with respect to the local reference frame. More...
 
void recursiveComponents (Alignables &result) const override
 Provide all components, subcomponents etc. (cf. description in base class) More...
 
void rotateInGlobalFrame (const RotationType &rotation) override
 Rotation interpreted in global reference frame. More...
 
void setAlignmentPositionError (const AlignmentPositionError &ape, bool propagateDown) override
 
void setSurfaceDeformation (const SurfaceDeformation *deformation, bool propagateDown) override
 Set the surface deformation parameters - if (!propagateDown) do not affect daughters. More...
 
int surfaceDeformationIdPairs (std::vector< std::pair< int, SurfaceDeformation * > > &) const override
 Return surface deformations. More...
 
void update (align::ID, StructureType aType, const RotationType &rot=RotationType())
 
 ~AlignableComposite () override
 deleting its components More...
 
- Public Member Functions inherited from Alignable
 Alignable (align::ID, const AlignableSurface &)
 
 Alignable (align::ID, const RotationType &)
 
AlignmentParametersalignmentParameters () const
 Get the AlignmentParameters. More...
 
virtual void cacheTransformation ()
 cache the current position, rotation and other parameters (e.g. surface deformations), also for possible components More...
 
virtual void cacheTransformation (const align::RunNumber &)
 
virtual CompConstraintType compConstraintType () const
 Return the alignable type of contraints wrt. its components. More...
 
const AlignablesdeepComponents () const
 
const GlobalVectordisplacement () const
 Return change of the global position since the creation of the object. More...
 
bool firstCompsWithParams (Alignables &paramComps) const
 
const DetIdgeomDetId () const
 
const PositionTypeglobalPosition () const
 Return the global position of the object. More...
 
const RotationTypeglobalRotation () const
 Return the global orientation of the object. More...
 
align::ID id () const
 Return the ID of Alignable, i.e. DetId of 'first' component GeomDet(Unit). More...
 
bool lastCompsWithParams (Alignables &paramComps) const
 
Alignablemother () const
 Return pointer to container alignable (if any) More...
 
virtual void recenterSurface ()
 Recenter surface object without moving possible components. More...
 
virtual void recursiveComponents (Alignables &result) const =0
 
virtual void restoreCachedTransformation ()
 restore the previously cached transformation, also for possible components More...
 
virtual void restoreCachedTransformation (const align::RunNumber &)
 
virtual void rotateAroundGlobalAxis (const GlobalVector &axis, Scalar radians)
 Rotation around arbitratry global axis. More...
 
virtual void rotateAroundGlobalX (Scalar radians)
 Rotation around global x-axis. More...
 
virtual void rotateAroundGlobalY (Scalar radians)
 Rotation around global y-axis. More...
 
virtual void rotateAroundGlobalZ (Scalar radians)
 Rotation around global z-axis. More...
 
virtual void rotateAroundLocalAxis (const LocalVector &axis, Scalar radians)
 Rotation around arbitratry local axis. More...
 
virtual void rotateAroundLocalX (Scalar radians)
 Rotation around local x-axis. More...
 
virtual void rotateAroundLocalY (Scalar radians)
 Rotation around local y-axis. More...
 
virtual void rotateAroundLocalZ (Scalar radians)
 Rotation around local z-axis. More...
 
virtual void rotateInLocalFrame (const RotationType &rotation)
 Rotation intepreted in the local reference frame. More...
 
const RotationTyperotation () const
 Return change of orientation since the creation of the object. More...
 
void setAlignmentParameters (AlignmentParameters *dap)
 Set the AlignmentParameters. More...
 
void setMother (Alignable *mother)
 Assign mother to alignable. More...
 
void setSurvey (const SurveyDet *)
 Set survey info. More...
 
int size () const
 Return number of direct components. More...
 
const AlignableSurfacesurface () const
 Return the Surface (global position and orientation) of the object. More...
 
AlignmentSurfaceDeformationssurfaceDeformations () const
 Return surface deformations, sorted by DetId. More...
 
const SurveyDetsurvey () const
 Return survey info. More...
 
void update (align::ID, const AlignableSurface &)
 
virtual ~Alignable ()
 Destructor. More...
 

Private Member Functions

AlignmentErrorsExtendedalignmentErrors () const override
 Get alignment errors sorted by DetId. More...
 
Alignmentsalignments () const override
 Get alignments sorted by DetId. More...
 
void buildCSCEndcap (const CSCGeometry *, bool update=false)
 Build muon end caps. More...
 
void buildDTBarrel (const DTGeometry *, bool update=false)
 Build muon barrel. More...
 
RotationType computeOrientation ()
 Get the global orientation (no rotation by default) More...
 
PositionType computePosition ()
 Get the position (centered at 0 by default) More...
 
AlignableSurface computeSurface ()
 Get the Surface. More...
 
void recursiveSetMothers (Alignable *alignable)
 Set mothers recursively. More...
 

Private Attributes

const AlignableObjectId alignableObjectId_
 alignable object ID provider More...
 
std::vector< AlignableCSCChamber * > theCSCChambers
 
std::vector< AlignableCSCEndcap * > theCSCEndcaps
 
std::vector< AlignableCSCRing * > theCSCRings
 
std::vector< AlignableCSCStation * > theCSCStations
 
std::vector< AlignableDTBarrel * > theDTBarrel
 
std::vector< AlignableDTChamber * > theDTChambers
 Containers of separate components. More...
 
std::vector< AlignableDTStation * > theDTStations
 
std::vector< AlignableDTWheel * > theDTWheels
 
align::Alignables theMuonComponents
 

Additional Inherited Members

- Public Types inherited from Alignable
typedef align::Alignables Alignables
 
enum  CompConstraintType { CompConstraintType::NONE, CompConstraintType::POSITION, CompConstraintType::POSITION_Z }
 
typedef align::GlobalVector GlobalVector
 
typedef align::LocalVector LocalVector
 
typedef align::PositionType PositionType
 
typedef align::RotationType RotationType
 
typedef align::Scalar Scalar
 
typedef align::StructureType StructureType
 
- Protected Types inherited from Alignable
template<class T >
using Cache = std::map< align::RunNumber, T >
 
- Protected Member Functions inherited from AlignableComposite
 AlignableComposite (const GeomDet *geomDet)
 Constructor from GeomDet, only for use in AlignableDet. More...
 
void setSurface (const AlignableSurface &s)
 
void update (const GeomDet *geomDet)
 
template<class T >
void update (T)=delete
 
- Protected Member Functions inherited from Alignable
void addDisplacement (const GlobalVector &displacement)
 
void addRotation (const RotationType &rotation)
 
virtual void updateMother (const GlobalVector &shift)
 
- Protected Attributes inherited from AlignableComposite
StructureType theStructureType
 
- Protected Attributes inherited from Alignable
CompConstraintType compConstraintType_ {CompConstraintType::NONE}
 
Cache< GlobalVectordisplacementsCache_
 
Cache< RotationTyperotationsCache_
 
Cache< AlignableSurfacesurfacesCache_
 
GlobalVector theCachedDisplacement
 
RotationType theCachedRotation
 
AlignableSurface theCachedSurface
 
Alignables theDeepComponents
 
DetId theDetId
 
GlobalVector theDisplacement
 
align::ID theId
 
RotationType theRotation
 
AlignableSurface theSurface
 

Detailed Description

Constructor of the full muon geometry.

The alignable muon.

Date
2008/04/25 21:23:15
Revision
1.21
Author
Andre Sznajder - UERJ(Brazil)

Definition at line 33 of file AlignableMuon.h.

Constructor & Destructor Documentation

AlignableMuon::AlignableMuon ( const DTGeometry dtGeometry,
const CSCGeometry cscGeometry 
)

Constructor from geometries.

Definition at line 29 of file AlignableMuon.cc.

References buildCSCEndcap(), buildDTBarrel(), components(), recursiveSetMothers(), and Alignable::theId.

30  : AlignableComposite(0, align::AlignableMuon), // cannot yet set id, use 0
31  alignableObjectId_(nullptr, dtGeometry, cscGeometry) {
32  // Build the muon barrel
33  buildDTBarrel(dtGeometry);
34 
35  // Build the muon end caps
36  buildCSCEndcap(cscGeometry);
37 
38  // Set links to mothers recursively
39  recursiveSetMothers(this);
40 
41  // now can set id as for all composites: id of first component
42  theId = this->components()[0]->id();
43 
44  edm::LogInfo("AlignableMuon") << "Constructing alignable muon objects DONE";
45 }
AlignableComposite()
default constructor hidden
const AlignableObjectId alignableObjectId_
alignable object ID provider
void recursiveSetMothers(Alignable *alignable)
Set mothers recursively.
void buildCSCEndcap(const CSCGeometry *, bool update=false)
Build muon end caps.
const align::Alignables & components() const final
Return all components.
Definition: AlignableMuon.h:46
void buildDTBarrel(const DTGeometry *, bool update=false)
Build muon barrel.
align::ID theId
Definition: Alignable.h:235
AlignableMuon::~AlignableMuon ( )
override

Destructor.

Definition at line 48 of file AlignableMuon.cc.

References theMuonComponents.

48  {
49  for (align::Alignables::iterator iter = theMuonComponents.begin(); iter != theMuonComponents.end(); iter++) {
50  delete *iter;
51  }
52 }
align::Alignables theMuonComponents

Member Function Documentation

AlignmentErrorsExtended * AlignableMuon::alignmentErrors ( void  ) const
overrideprivatevirtual

Get alignment errors sorted by DetId.

Reimplemented from AlignableComposite.

Definition at line 400 of file AlignableMuon.cc.

References AlCaHLTBitMon_QueryRunRegistry::comp, components(), filterCSVwithJSON::copy, mps_fire::i, and AlignmentErrorsExtended::m_alignError.

Referenced by objectIdProvider().

400  {
402  AlignmentErrorsExtended* m_alignmentErrors = new AlignmentErrorsExtended();
403 
404  // Add components recursively
405  for (align::Alignables::iterator i = comp.begin(); i != comp.end(); i++) {
406  AlignmentErrorsExtended* tmpAlignmentErrorsExtended = (*i)->alignmentErrors();
407  std::copy(tmpAlignmentErrorsExtended->m_alignError.begin(),
408  tmpAlignmentErrorsExtended->m_alignError.end(),
409  std::back_inserter(m_alignmentErrors->m_alignError));
410  delete tmpAlignmentErrorsExtended;
411  }
412 
413  // sort by rawId
414  std::sort(m_alignmentErrors->m_alignError.begin(), m_alignmentErrors->m_alignError.end());
415 
416  return m_alignmentErrors;
417 }
std::vector< AlignTransformErrorExtended > m_alignError
const align::Alignables & components() const final
Return all components.
Definition: AlignableMuon.h:46
std::vector< Alignable * > Alignables
Definition: Utilities.h:31
Alignments * AlignableMuon::alignments ( void  ) const
overrideprivatevirtual

Get alignments sorted by DetId.

Reimplemented from AlignableComposite.

Definition at line 384 of file AlignableMuon.cc.

References AlCaHLTBitMon_QueryRunRegistry::comp, components(), filterCSVwithJSON::copy, mps_fire::i, and Alignments::m_align.

Referenced by objectIdProvider().

384  {
386  Alignments* m_alignments = new Alignments();
387  // Add components recursively
388  for (align::Alignables::iterator i = comp.begin(); i != comp.end(); i++) {
389  Alignments* tmpAlignments = (*i)->alignments();
390  std::copy(tmpAlignments->m_align.begin(), tmpAlignments->m_align.end(), std::back_inserter(m_alignments->m_align));
391  delete tmpAlignments;
392  }
393 
394  // sort by rawId
395  std::sort(m_alignments->m_align.begin(), m_alignments->m_align.end());
396 
397  return m_alignments;
398 }
std::vector< AlignTransform > m_align
Definition: Alignments.h:19
const align::Alignables & components() const final
Return all components.
Definition: AlignableMuon.h:46
std::vector< Alignable * > Alignables
Definition: Utilities.h:31
void AlignableMuon::buildCSCEndcap ( const CSCGeometry pCSC,
bool  update = false 
)
private

Build muon end caps.

Definition at line 157 of file AlignableMuon.cc.

References align::AlignableCSCChamber, align::AlignableCSCEndcap, align::AlignableCSCRing, align::AlignableCSCStation, CSCGeometry::chambers(), RecoEcal_EventContent_cff::ec, CSCDetId::endcap(), LogDebug, CSCDetId::ring(), CSCDetId::station(), theCSCChambers, theCSCEndcaps, theCSCRings, theCSCStations, and theMuonComponents.

Referenced by AlignableMuon(), objectIdProvider(), and update().

157  {
158  LogDebug("Position") << "Constructing AlignableCSCBarrel";
159 
160  // Temporary container for stations in a given endcap
161  std::vector<AlignableCSCStation*> tmpCSCStationsInEndcap;
162 
163  // Loop over endcaps ( 1..2 )
164  for (int iec = 1; iec < 3; iec++) {
165  // Temporary container for rings in a given station
166  std::vector<AlignableCSCRing*> tmpCSCRingsInStation;
167 
168  // Loop over stations ( 1..4 )
169  for (int ist = 1; ist < 5; ist++) {
170  // Temporary container for chambers in a given ring
171  std::vector<AlignableCSCChamber*> tmpCSCChambersInRing;
172 
173  // Loop over rings ( 1..4 )
174  for (int iri = 1; iri < 5; iri++) {
175  // Loop over geom CSC Chambers
176  int iChamber{0};
177  const CSCGeometry::ChamberContainer& vc = pCSC->chambers();
178  for (const auto& det : vc) {
179  // Get the CSCDet ID
180  CSCDetId cscId = det->id();
181 
182  // Get chamber, station, ring, layer and endcap labels of the CSC chamber
183  int ec = cscId.endcap();
184  int st = cscId.station();
185  int ri = cscId.ring();
186  //int ch = cscId.chamber();
187 
188  // Select the chambers in a given endcap, station, and ring
189  if (iec == ec && ist == st && iri == ri) {
190  if (update) {
191  // Update the alignable CSC chamber
192  theCSCEndcaps[iec - 1]->station(ist - 1).ring(iri - 1).chamber(iChamber).update(det);
193  } else {
194  AlignableCSCChamber* tmpCSCChamber = new AlignableCSCChamber(det);
195 
196  // Store the alignable CSC chambers
197  tmpCSCChambersInRing.push_back(tmpCSCChamber);
198  }
199 
200  ++iChamber;
201  // End If chamber selection
202  }
203 
204  // End loop over geom CSC chambers
205  }
206 
207  if (!update) {
208  // Not all stations have 4 rings: only add the rings that exist (have chambers associated with them)
209  if (!tmpCSCChambersInRing.empty()) {
210  // Store the alignable CSC chambers
211  theCSCChambers.insert(theCSCChambers.end(), tmpCSCChambersInRing.begin(), tmpCSCChambersInRing.end());
212 
213  // Create the alignable CSC ring with chambers in a given ring
214  AlignableCSCRing* tmpCSCRing = new AlignableCSCRing(tmpCSCChambersInRing);
215 
216  // Store the CSC rings in a given station
217  tmpCSCRingsInStation.push_back(tmpCSCRing);
218 
219  // Clear the temporary vector of chambers in ring
220  tmpCSCChambersInRing.clear();
221 
222  // End if this ring exists
223  }
224  }
225 
226  // End loop over rings
227  }
228 
229  if (!update) {
230  // Create the alignable CSC station with rings in a given station
231  AlignableCSCStation* tmpCSCStation = new AlignableCSCStation(tmpCSCRingsInStation);
232 
233  // Store the alignable CSC rings
234  theCSCRings.insert(theCSCRings.end(), tmpCSCRingsInStation.begin(), tmpCSCRingsInStation.end());
235 
236  // Store the CSC stations in a given endcap
237  tmpCSCStationsInEndcap.push_back(tmpCSCStation);
238 
239  // Clear the temporary vector of rings in station
240  tmpCSCRingsInStation.clear();
241  }
242 
243  // End loop over stations
244  }
245 
246  if (!update) {
247  // Create the alignable CSC endcap
248  AlignableCSCEndcap* tmpEndcap = new AlignableCSCEndcap(tmpCSCStationsInEndcap);
249 
250  // Store the alignable CSC stations
251  theCSCStations.insert(theCSCStations.end(), tmpCSCStationsInEndcap.begin(), tmpCSCStationsInEndcap.end());
252 
253  // Store the alignable CSC endcaps
254  theCSCEndcaps.push_back(tmpEndcap);
255 
256  // Clear the temporary vector of stations in endcap
257  tmpCSCStationsInEndcap.clear();
258  }
259 
260  // End loop over endcaps
261  }
262 
263  if (!update) {
264  // Store the encaps in the muon components
265  theMuonComponents.insert(theMuonComponents.end(), theCSCEndcaps.begin(), theCSCEndcaps.end());
266  }
267 }
#define LogDebug(id)
void update(const DTGeometry *, const CSCGeometry *)
const ChamberContainer & chambers() const
Return a vector of all chambers.
Definition: CSCGeometry.cc:96
std::vector< AlignableCSCEndcap * > theCSCEndcaps
int endcap() const
Definition: CSCDetId.h:85
align::Alignables theMuonComponents
std::vector< AlignableCSCStation * > theCSCStations
int ring() const
Definition: CSCDetId.h:68
std::vector< AlignableCSCRing * > theCSCRings
std::vector< const CSCChamber * > ChamberContainer
Definition: CSCGeometry.h:30
int station() const
Definition: CSCDetId.h:79
std::vector< AlignableCSCChamber * > theCSCChambers
A muon CSC Chamber( an AlignableDet )
void AlignableMuon::buildDTBarrel ( const DTGeometry pDT,
bool  update = false 
)
private

Build muon barrel.

Definition at line 67 of file AlignableMuon.cc.

References align::AlignableDTBarrel, align::AlignableDTChamber, align::AlignableDTStation, align::AlignableDTWheel, DTGeometry::chambers(), LogDebug, DTChamberId::station(), theDTBarrel, theDTChambers, theDTStations, theDTWheels, theMuonComponents, and DTChamberId::wheel().

Referenced by AlignableMuon(), objectIdProvider(), and update().

67  {
68  LogDebug("Position") << "Constructing AlignableDTBarrel";
69 
70  // Temporary container for chambers in a given station and stations in a given wheel
71  std::vector<AlignableDTChamber*> tmpDTChambersInStation;
72  std::vector<AlignableDTStation*> tmpDTStationsInWheel;
73 
74  // Loop over wheels ( -2..2 )
75  for (int iwh = -2; iwh < 3; iwh++) {
76  // Loop over stations ( 1..4 )
77  for (int ist = 1; ist < 5; ist++) {
78  // Loop over geom DT Chambers
79  int iChamber{0};
80  std::vector<const GeomDet*>
81  theSLs; // FIXME: What is this vector meant to be for? Probably redundant since super layers are handled inside of the AlignableDTChamber.
82  for (const auto& det : pDT->chambers()) {
83  // Get the chamber ID
84  DTChamberId chamberId = det->id();
85 
86  // Get wheel,station and sector of the chamber
87  int wh = chamberId.wheel();
88  int st = chamberId.station();
89  //int se = chamberId.sector();
90 
91  // Select the chambers in a given wheel in a given station
92  if (iwh == wh && ist == st) {
93  if (update) {
94  // Update the alignable DT chamber
95  theDTBarrel.back()->wheel(iwh + 2).station(ist - 1).chamber(iChamber).update(det);
96  } else {
97  // Create the alignable DT chamber
98  AlignableDTChamber* tmpDTChamber = new AlignableDTChamber(det);
99 
100  // Store the DT chambers in a given DT Station and Wheel
101  tmpDTChambersInStation.push_back(tmpDTChamber);
102  }
103 
104  ++iChamber;
105  // End chamber selection
106  }
107 
108  // End loop over chambers
109  }
110 
111  if (!update) {
112  // Store the DT chambers
113  theDTChambers.insert(theDTChambers.end(), tmpDTChambersInStation.begin(), tmpDTChambersInStation.end());
114 
115  // Create the alignable DT station with chambers in a given station and wheel
116  AlignableDTStation* tmpDTStation = new AlignableDTStation(tmpDTChambersInStation);
117 
118  // Store the DT stations in a given wheel
119  tmpDTStationsInWheel.push_back(tmpDTStation);
120 
121  // Clear the temporary vector of chambers in a station
122  tmpDTChambersInStation.clear();
123  }
124  // End loop over stations
125  }
126 
127  if (!update) {
128  // Store The DT stations
129  theDTStations.insert(theDTStations.end(), tmpDTStationsInWheel.begin(), tmpDTStationsInWheel.end());
130 
131  // Create the alignable DT wheel
132  AlignableDTWheel* tmpWheel = new AlignableDTWheel(tmpDTStationsInWheel);
133 
134  // Store the DT wheels
135  theDTWheels.push_back(tmpWheel);
136 
137  // Clear temporary vector of stations in a wheel
138  tmpDTStationsInWheel.clear();
139  }
140 
141  // End loop over wheels
142  }
143 
144  if (!update) {
145  // Create the alignable Muon Barrel
146  AlignableDTBarrel* tmpDTBarrel = new AlignableDTBarrel(theDTWheels);
147 
148  // Store the barrel
149  theDTBarrel.push_back(tmpDTBarrel);
150 
151  // Store the barrel in the muon
152  theMuonComponents.push_back(tmpDTBarrel);
153  }
154 }
#define LogDebug(id)
A muon DT Chamber( an AlignableDet )
const std::vector< const DTChamber * > & chambers() const
Return a vector of all Chamber.
Definition: DTGeometry.cc:84
void update(const DTGeometry *, const CSCGeometry *)
align::Alignables theMuonComponents
std::vector< AlignableDTStation * > theDTStations
std::vector< AlignableDTChamber * > theDTChambers
Containers of separate components.
std::vector< AlignableDTBarrel * > theDTBarrel
std::vector< AlignableDTWheel * > theDTWheels
int station() const
Return the station number.
Definition: DTChamberId.h:42
int wheel() const
Return the wheel number.
Definition: DTChamberId.h:39
const align::Alignables& AlignableMuon::components ( ) const
inlinefinalvirtual

Return all components.

Reimplemented from AlignableComposite.

Definition at line 46 of file AlignableMuon.h.

References theMuonComponents.

Referenced by AlignableMuon(), alignmentErrors(), and alignments().

46 { return theMuonComponents; }
align::Alignables theMuonComponents
RotationType AlignableMuon::computeOrientation ( )
private

Get the global orientation (no rotation by default)

Referenced by objectIdProvider().

PositionType AlignableMuon::computePosition ( )
private

Get the position (centered at 0 by default)

Referenced by objectIdProvider().

AlignableSurface AlignableMuon::computeSurface ( )
private

Get the Surface.

Referenced by objectIdProvider().

AlignmentErrorsExtended * AlignableMuon::cscAlignmentErrorsExtended ( void  )

Get CSC alignment errors sorted by DetId.

Definition at line 445 of file AlignableMuon.cc.

References filterCSVwithJSON::copy, CSCEndcaps(), and AlignmentErrorsExtended::m_alignError.

Referenced by MuonAlignment::copyAlignmentToSurvey(), mother(), MisalignedMuonESProducer::produce(), MuonAlignment::saveCSCtoDB(), and MuonAlignmentOutputXML::write().

445  {
446  // Retrieve muon endcaps alignment errors
447  AlignmentErrorsExtended* cscEndCap1Errors = this->CSCEndcaps().front()->alignmentErrors();
448  AlignmentErrorsExtended* cscEndCap2Errors = this->CSCEndcaps().back()->alignmentErrors();
449  AlignmentErrorsExtended* tmpAlignmentErrorsExtended = new AlignmentErrorsExtended();
450 
451  std::copy(cscEndCap1Errors->m_alignError.begin(),
452  cscEndCap1Errors->m_alignError.end(),
453  back_inserter(tmpAlignmentErrorsExtended->m_alignError));
454  std::copy(cscEndCap2Errors->m_alignError.begin(),
455  cscEndCap2Errors->m_alignError.end(),
456  back_inserter(tmpAlignmentErrorsExtended->m_alignError));
457 
458  return tmpAlignmentErrorsExtended;
459 }
align::Alignables CSCEndcaps()
std::vector< AlignTransformErrorExtended > m_alignError
Alignments * AlignableMuon::cscAlignments ( void  )

Get CSC alignments sorted by DetId.

Definition at line 433 of file AlignableMuon.cc.

References filterCSVwithJSON::copy, CSCEndcaps(), and Alignments::m_align.

Referenced by mother(), MisalignedMuonESProducer::produce(), and MuonAlignment::saveCSCtoDB().

433  {
434  // Retrieve muon endcaps alignments
435  Alignments* cscEndCap1 = this->CSCEndcaps().front()->alignments();
436  Alignments* cscEndCap2 = this->CSCEndcaps().back()->alignments();
437  Alignments* tmpAlignments = new Alignments();
438 
439  std::copy(cscEndCap1->m_align.begin(), cscEndCap1->m_align.end(), back_inserter(tmpAlignments->m_align));
440  std::copy(cscEndCap2->m_align.begin(), cscEndCap2->m_align.end(), back_inserter(tmpAlignments->m_align));
441 
442  return tmpAlignments;
443 }
std::vector< AlignTransform > m_align
Definition: Alignments.h:19
align::Alignables CSCEndcaps()
align::Alignables AlignableMuon::CSCChambers ( )

Definition at line 348 of file AlignableMuon.cc.

References filterCSVwithJSON::copy, mps_fire::result, and theCSCChambers.

Referenced by AlignmentParameterSelector::addSelection(), CSCLayers(), MuonAlignmentFromReference::initialize(), mother(), and MuonScenarioBuilder::moveCSCSectors().

348  {
350  copy(theCSCChambers.begin(), theCSCChambers.end(), back_inserter(result));
351  return result;
352 }
std::vector< Alignable * > Alignables
Definition: Utilities.h:31
std::vector< AlignableCSCChamber * > theCSCChambers
align::Alignables AlignableMuon::CSCEndcaps ( )
align::Alignables AlignableMuon::CSCLayers ( )

Definition at line 333 of file AlignableMuon.cc.

References chambers, CSCChambers(), hgcalTopologyTester_cfi::layers, and mps_fire::result.

Referenced by AlignmentParameterSelector::addSelection(), and mother().

333  {
335 
337  for (align::Alignables::const_iterator chamberIter = chambers.begin(); chamberIter != chambers.end(); ++chamberIter) {
338  align::Alignables layers = (*chamberIter)->components();
339  for (align::Alignables::const_iterator layerIter = layers.begin(); layerIter != layers.end(); ++layerIter) {
340  result.push_back(*layerIter);
341  }
342  }
343 
344  return result;
345 }
align::Alignables CSCChambers()
std::vector< Alignable * > Alignables
Definition: Utilities.h:31
static char chambers[264][20]
Definition: ReadPGInfo.cc:243
align::Alignables AlignableMuon::CSCRings ( )

Definition at line 355 of file AlignableMuon.cc.

References filterCSVwithJSON::copy, mps_fire::result, and theCSCRings.

Referenced by AlignmentParameterSelector::addSelection(), and mother().

355  {
357  copy(theCSCRings.begin(), theCSCRings.end(), back_inserter(result));
358  return result;
359 }
std::vector< AlignableCSCRing * > theCSCRings
std::vector< Alignable * > Alignables
Definition: Utilities.h:31
align::Alignables AlignableMuon::CSCStations ( )

Definition at line 362 of file AlignableMuon.cc.

References filterCSVwithJSON::copy, mps_fire::result, and theCSCStations.

Referenced by AlignmentParameterSelector::addSelection(), and mother().

362  {
364  copy(theCSCStations.begin(), theCSCStations.end(), back_inserter(result));
365  return result;
366 }
std::vector< AlignableCSCStation * > theCSCStations
std::vector< Alignable * > Alignables
Definition: Utilities.h:31
AlignmentErrorsExtended * AlignableMuon::dtAlignmentErrorsExtended ( void  )

Get DT alignment errors sorted by DetId.

Definition at line 426 of file AlignableMuon.cc.

References DTBarrel().

Referenced by MuonAlignment::copyAlignmentToSurvey(), mother(), MisalignedMuonESProducer::produce(), MuonAlignment::saveDTtoDB(), and MuonAlignmentOutputXML::write().

426  {
427  // Retrieve muon barrel alignment errors
428  AlignmentErrorsExtended* tmpAlignmentErrorsExtended = this->DTBarrel().front()->alignmentErrors();
429 
430  return tmpAlignmentErrorsExtended;
431 }
align::Alignables DTBarrel()
Alignments * AlignableMuon::dtAlignments ( void  )

Get DT alignments sorted by DetId.

Definition at line 419 of file AlignableMuon.cc.

References DTBarrel().

Referenced by mother(), MisalignedMuonESProducer::produce(), and MuonAlignment::saveDTtoDB().

419  {
420  // Retrieve muon barrel alignments
421  Alignments* tmpAlignments = this->DTBarrel().front()->alignments();
422 
423  return tmpAlignments;
424 }
align::Alignables DTBarrel()
align::Alignables AlignableMuon::DTBarrel ( )
align::Alignables AlignableMuon::DTChambers ( )

Definition at line 305 of file AlignableMuon.cc.

References filterCSVwithJSON::copy, mps_fire::result, and theDTChambers.

Referenced by AlignmentParameterSelector::addSelection(), DTLayers(), DTSuperLayers(), MuonAlignmentFromReference::initialize(), mother(), and MuonScenarioBuilder::moveDTSectors().

305  {
307  copy(theDTChambers.begin(), theDTChambers.end(), back_inserter(result));
308  return result;
309 }
std::vector< AlignableDTChamber * > theDTChambers
Containers of separate components.
std::vector< Alignable * > Alignables
Definition: Utilities.h:31
align::Alignables AlignableMuon::DTLayers ( )

Methods to return specific of components.

Definition at line 270 of file AlignableMuon.cc.

References chambers, DTChambers(), hgcalTopologyTester_cfi::layers, and mps_fire::result.

Referenced by AlignmentParameterSelector::addSelection(), and mother().

270  {
272 
274  for (align::Alignables::const_iterator chamberIter = chambers.begin(); chamberIter != chambers.end(); ++chamberIter) {
275  align::Alignables superlayers = (*chamberIter)->components();
276  for (align::Alignables::const_iterator superlayerIter = superlayers.begin(); superlayerIter != superlayers.end();
277  ++superlayerIter) {
278  align::Alignables layers = (*superlayerIter)->components();
279  for (align::Alignables::const_iterator layerIter = layers.begin(); layerIter != layers.end(); ++layerIter) {
280  result.push_back(*layerIter);
281  }
282  }
283  }
284 
285  return result;
286 }
align::Alignables DTChambers()
std::vector< Alignable * > Alignables
Definition: Utilities.h:31
static char chambers[264][20]
Definition: ReadPGInfo.cc:243
align::Alignables AlignableMuon::DTStations ( )

Definition at line 312 of file AlignableMuon.cc.

References filterCSVwithJSON::copy, mps_fire::result, and theDTStations.

Referenced by AlignmentParameterSelector::addSelection(), and mother().

312  {
314  copy(theDTStations.begin(), theDTStations.end(), back_inserter(result));
315  return result;
316 }
std::vector< AlignableDTStation * > theDTStations
std::vector< Alignable * > Alignables
Definition: Utilities.h:31
align::Alignables AlignableMuon::DTSuperLayers ( )

Definition at line 289 of file AlignableMuon.cc.

References chambers, DTChambers(), and mps_fire::result.

Referenced by AlignmentParameterSelector::addSelection(), and mother().

289  {
291 
293  for (align::Alignables::const_iterator chamberIter = chambers.begin(); chamberIter != chambers.end(); ++chamberIter) {
294  align::Alignables superlayers = (*chamberIter)->components();
295  for (align::Alignables::const_iterator superlayerIter = superlayers.begin(); superlayerIter != superlayers.end();
296  ++superlayerIter) {
297  result.push_back(*superlayerIter);
298  }
299  }
300 
301  return result;
302 }
align::Alignables DTChambers()
std::vector< Alignable * > Alignables
Definition: Utilities.h:31
static char chambers[264][20]
Definition: ReadPGInfo.cc:243
align::Alignables AlignableMuon::DTWheels ( )

Definition at line 319 of file AlignableMuon.cc.

References filterCSVwithJSON::copy, mps_fire::result, and theDTWheels.

Referenced by AlignmentParameterSelector::addSelection(), and mother().

319  {
321  copy(theDTWheels.begin(), theDTWheels.end(), back_inserter(result));
322  return result;
323 }
std::vector< Alignable * > Alignables
Definition: Utilities.h:31
std::vector< AlignableDTWheel * > theDTWheels
virtual Alignable* AlignableMuon::mother ( )
inlinevirtual
const AlignableObjectId& AlignableMuon::objectIdProvider ( ) const
inline

Return muon alignable object ID provider derived from the muon system geometry.

Definition at line 77 of file AlignableMuon.h.

References alignableObjectId_, alignmentErrors(), alignments(), buildCSCEndcap(), buildDTBarrel(), computeOrientation(), computePosition(), computeSurface(), and recursiveSetMothers().

Referenced by MuonAlignmentInputXML::newAlignableMuon(), and MuonAlignmentOutputXML::write().

77 { return alignableObjectId_; }
const AlignableObjectId alignableObjectId_
alignable object ID provider
void AlignableMuon::recursiveSetMothers ( Alignable alignable)
private

Set mothers recursively.

Definition at line 376 of file AlignableMuon.cc.

References Alignable::components().

Referenced by AlignableMuon(), and objectIdProvider().

376  {
377  for (const auto& iter : alignable->components()) {
378  iter->setMother(alignable);
379  recursiveSetMothers(iter);
380  }
381 }
virtual const Alignables & components() const =0
Return vector of all direct components.
void recursiveSetMothers(Alignable *alignable)
Set mothers recursively.
void AlignableMuon::update ( const DTGeometry dtGeometry,
const CSCGeometry cscGeometry 
)

Updater using DTGeometry and CSCGeometry. The given geometries have to match the current ones.

Definition at line 55 of file AlignableMuon.cc.

References buildCSCEndcap(), and buildDTBarrel().

Referenced by progressbar.ProgressBar::__next__(), MatrixUtil.Matrix::__setitem__(), MatrixUtil.Steps::__setitem__(), Vispa.Gui.VispaWidget.VispaWidget::autosize(), Vispa.Views.LineDecayView.LineDecayContainer::createObject(), Vispa.Views.LineDecayView.LineDecayContainer::deselectAllObjects(), Vispa.Gui.VispaWidgetOwner.VispaWidgetOwner::deselectAllWidgets(), Vispa.Gui.VispaWidget.VispaWidget::enableAutosizing(), dqm-mbProfile.Profile::finish(), progressbar.ProgressBar::finish(), Vispa.Gui.MenuWidget.MenuWidget::leaveEvent(), Vispa.Gui.VispaWidgetOwner.VispaWidgetOwner::mouseMoveEvent(), Vispa.Gui.MenuWidget.MenuWidget::mouseMoveEvent(), Vispa.Views.LineDecayView.LineDecayContainer::mouseMoveEvent(), Vispa.Gui.VispaWidgetOwner.VispaWidgetOwner::mouseReleaseEvent(), Vispa.Views.LineDecayView.LineDecayContainer::objectMoved(), MatrixUtil.Steps::overwrite(), Vispa.Views.LineDecayView.LineDecayContainer::removeObject(), Vispa.Gui.ConnectableWidget.ConnectableWidget::removePorts(), Vispa.Gui.FindDialog.FindDialog::reset(), Vispa.Gui.PortConnection.PointToPointConnection::select(), Vispa.Gui.VispaWidget.VispaWidget::select(), Vispa.Views.LineDecayView.LineDecayContainer::select(), Vispa.Gui.VispaWidget.VispaWidget::setText(), Vispa.Gui.VispaWidget.VispaWidget::setTitle(), Vispa.Gui.ZoomableWidget.ZoomableWidget::setZoom(), Vispa.Views.LineDecayView.LineDecayContainer::setZoom(), and Vispa.Gui.PortConnection.PointToPointConnection::updateConnection().

55  {
56  // update the muon barrel
57  buildDTBarrel(dtGeometry, /* update = */ true);
58 
59  // update the muon end caps
60  buildCSCEndcap(cscGeometry, /* update = */ true);
61 
62  edm::LogInfo("Alignment") << "@SUB=AlignableMuon::update"
63  << "Updating alignable muon objects DONE";
64 }
void buildCSCEndcap(const CSCGeometry *, bool update=false)
Build muon end caps.
void buildDTBarrel(const DTGeometry *, bool update=false)
Build muon barrel.

Member Data Documentation

const AlignableObjectId AlignableMuon::alignableObjectId_
private

alignable object ID provider

Definition at line 107 of file AlignableMuon.h.

Referenced by objectIdProvider().

std::vector<AlignableCSCChamber*> AlignableMuon::theCSCChambers
private

Definition at line 115 of file AlignableMuon.h.

Referenced by buildCSCEndcap(), and CSCChambers().

std::vector<AlignableCSCEndcap*> AlignableMuon::theCSCEndcaps
private

Definition at line 118 of file AlignableMuon.h.

Referenced by buildCSCEndcap(), and CSCEndcaps().

std::vector<AlignableCSCRing*> AlignableMuon::theCSCRings
private

Definition at line 117 of file AlignableMuon.h.

Referenced by buildCSCEndcap(), and CSCRings().

std::vector<AlignableCSCStation*> AlignableMuon::theCSCStations
private

Definition at line 116 of file AlignableMuon.h.

Referenced by buildCSCEndcap(), and CSCStations().

std::vector<AlignableDTBarrel*> AlignableMuon::theDTBarrel
private

Definition at line 113 of file AlignableMuon.h.

Referenced by buildDTBarrel(), and DTBarrel().

std::vector<AlignableDTChamber*> AlignableMuon::theDTChambers
private

Containers of separate components.

Definition at line 110 of file AlignableMuon.h.

Referenced by buildDTBarrel(), and DTChambers().

std::vector<AlignableDTStation*> AlignableMuon::theDTStations
private

Definition at line 111 of file AlignableMuon.h.

Referenced by buildDTBarrel(), and DTStations().

std::vector<AlignableDTWheel*> AlignableMuon::theDTWheels
private

Definition at line 112 of file AlignableMuon.h.

Referenced by buildDTBarrel(), and DTWheels().

align::Alignables AlignableMuon::theMuonComponents
private

Definition at line 120 of file AlignableMuon.h.

Referenced by buildCSCEndcap(), buildDTBarrel(), components(), and ~AlignableMuon().