CMS 3D CMS Logo

RigidBodyAlignmentParameters4D.cc
Go to the documentation of this file.
1 
9 
16 
17 // This class's header
19 
20 //__________________________________________________________________________________________________
22  const AlignableDetOrUnitPtr &alidet) const {
23  const Alignable *ali = this->alignable(); // Alignable of these parameters
24 
25  if (ali == alidet) { // same alignable => same frame
26  return SegmentAlignmentDerivatives4D()(tsos);
27  } else { // different alignable => transform into correct frame
28  const AlgebraicMatrix deriv = SegmentAlignmentDerivatives4D()(tsos);
30  return ftfd.frameToFrameDerivative(alidet, ali).T() * deriv;
31  }
32 }
33 
34 //__________________________________________________________________________________________________
36  const AlgebraicSymMatrix &covMatrix) const {
38  new RigidBodyAlignmentParameters4D(alignable(), parameters, covMatrix, selector());
39 
40  if (userVariables())
42  rbap->setValid(isValid());
43 
44  return rbap;
45 }
46 
47 //__________________________________________________________________________________________________
49  const AlgebraicVector &parameters, const AlgebraicSymMatrix &covMatrix) const {
51  alignable(), expandVector(parameters, selector()), expandSymMatrix(covMatrix, selector()), selector());
52 
53  if (userVariables())
55  rbap->setValid(isValid());
56 
57  return rbap;
58 }
59 
60 //__________________________________________________________________________________________________
RigidBodyAlignmentParameters4D * clone(const AlgebraicVector &parameters, const AlgebraicSymMatrix &covMatrix) const override
Clone all parameters (for update of parameters)
AlgebraicSymMatrix expandSymMatrix(const AlgebraicSymMatrix &m, const std::vector< bool > &sel) const
const std::vector< bool > & selector(void) const
Get alignment parameter selector vector.
int type() const override
tell type (AlignmentParametersFactory::ParametersType - but no circular dependency) ...
AlignmentUserVariables * userVariables(void) const
Get pointer to user variables.
CLHEP::HepMatrix AlgebraicMatrix
void setValid(bool v)
Set validity flag.
Alignable * alignable(void) const
Get pointer to corresponding alignable.
AlgebraicMatrix frameToFrameDerivative(const Alignable *object, const Alignable *composedObject) const
CLHEP::HepVector AlgebraicVector
AlgebraicVector expandVector(const AlgebraicVector &m, const std::vector< bool > &sel) const
void setUserVariables(AlignmentUserVariables *auv)
Set pointer to user variables.
RigidBodyAlignmentParameters4D * cloneFromSelected(const AlgebraicVector &parameters, const AlgebraicSymMatrix &covMatrix) const override
Clone selected parameters (for update of parameters)
bool isValid(void) const
Get validity flag.
CLHEP::HepSymMatrix AlgebraicSymMatrix
AlgebraicMatrix derivatives(const TrajectoryStateOnSurface &tsos, const AlignableDetOrUnitPtr &) const override
Get all derivatives.
RigidBodyAlignmentParameters4D(Alignable *alignable, bool calcMis)