11 #include <framework/datastore/RelationsObject.h>
12 #include <framework/logging/Logger.h>
15 #include <TLorentzVector.h>
67 for (
int i = 0; i < 3; i++)
85 B2ERROR(
"Invalid EigenVector number (n = " << i <<
"). You can set only 3 eigenvectors.");
98 B2ERROR(
"Invalid EigenVector number (n = " << i <<
"). You can set only 3 eigenvectors.");
110 if (order < 0 || order > 9)
111 B2ERROR(
"Invalid Fox-Wolfram moment order (n = " << order <<
"). The order must be in the [0,9] range.");
131 if (thrustAxis.Mag() < 1.E-10)
132 B2WARNING(
"The thrust axis you are trying to set has magnitude numerically compatible with 0.");
142 if (spherocityAxis.Mag() < 1.E-10)
143 B2WARNING(
"The spherocity axis you are trying to set has magnitude numerically compatible with 0.");
154 if (order < 0 || order > 9)
155 B2ERROR(
"Invalid harmonic moment order. It must be in the [0,9] range.");
167 if (order < 0 || order > 9)
168 B2ERROR(
"Invalid harmonic moment order. It must be in the [0,9] range.");
180 if (order < 0 || order > 9)
181 B2ERROR(
"Invalid Cleo cone order. It must be in the [0,9] range.");
193 if (order < 0 || order > 9)
194 B2ERROR(
"Invalid Cleo cone order. It must be in the [0,9] range.");
257 if (i < 0 || i > 2) {
258 B2ERROR(
"Invalid Eigenvalue number (n = " << i <<
"). There are only 3 eigenvalues...");
259 return std::numeric_limits<float>::quiet_NaN();
272 if (i < 0 || i > 2) {
273 B2ERROR(
"Invalid Eigenvalue number (n = " << i <<
"). There are only 3 eigenvalues...");
274 return TVector3(std::numeric_limits<float>::quiet_NaN(), std::numeric_limits<float>::quiet_NaN(),
275 std::numeric_limits<float>::quiet_NaN());
289 if (order < 0 || order > 9) {
290 B2ERROR(
"Invalid Fox-Wolfram moment order. It must be in the [0,9] range.");
291 return std::numeric_limits<float>::quiet_NaN();
303 if (order < 0 || order > 9) {
304 B2ERROR(
"Invalid harmonic moment order. It must be in the [0,9] range.");
305 return std::numeric_limits<float>::quiet_NaN();
317 if (order < 0 || order > 9) {
318 B2ERROR(
"Invalid harmonic moment order. The order must be in the [0,9] range.");
319 return std::numeric_limits<float>::quiet_NaN();
332 if (order < 0 || order > 9) {
333 B2ERROR(
"Invalid CLEO cone order. The order must be in the [0,9] range.");
334 return std::numeric_limits<float>::quiet_NaN();
346 if (order < 0 || order > 9) {
347 B2ERROR(
"Invalid CLEO cone order. The order must be in the [0,9] range.");
348 return std::numeric_limits<float>::quiet_NaN();
Class for collecting the basic objects related to the event shape.
float getSphericityEigenvalue(short i) const
Returns the i-th sphericity matrix eigenvalue.
TLorentzVector getForwardHemisphere4Momentum() const
Returns the 4-momentum of the forward hemisphere, as defined by the thrust axis.
float getCleoConeThrust(short order) const
Returns the Cleo cone of a given order, calculated respect to the thrust axis.
TVector3 m_spherocityAxis
Spherocity axis.
float m_cleoConesCollision[10]
Cleo cones up to order 9, calculated respect to the collision axis.
TLorentzVector m_backwardHemisphere4Momentum
Total 4-momentum of the particles in the backward hemisphere.
void setSpherocityAxis(TVector3 spherocityAxis)
Sets the spherocity axis, normalizing it.
void setThrustAxis(TVector3 thrustAxis)
Sets the thrust axis, normalizing it.
TVector3 m_thrustAxis
Thrust axis.
void setSphericityEigenvalue(short i, float eigenvalue)
Sets the i-th sphericity eigenvalue.
float getThrust() const
Returns the thrust.
TVector3 getThrustAxis() const
Returns the thrust axis (normalized).
TVector3 getSpherocityAxis() const
Returns the spherocity axis (normalized).
EventShapeContainer()
Default constructor, resets the sphericity matrix.
void setThrust(float thrust)
Sets the thrust of the event.
float getFWMoment(short order) const
Returns the Fox-Wolfram moment of a given order.
void setFWMoment(short order, float moment)
Sets the Fox-Wolfram (FW) moment of order n.
float m_harmonicMomentsCollision[10]
Harmonic moments up to order 9, calculated respect to the collision axis.
void setHarmonicMomentThrust(short order, float moment)
Sets the harmonic moment of order n, calculated using the thrust axis.
float m_thrust
Thrust value.
void setSphericityEigenvector(short i, TVector3 eigenvector)
Sets the i-th sphericity eigenvector.
float getHarmonicMomentThrust(short order) const
Returns the harmonic moment of a given order, calculated respect to the thrust axis.
TVector3 getSphericityEigenvector(short i) const
Returns the i-th sphericity matrix eigenvector.
void setCleoConeThrust(short order, float moment)
Sets the Cleo cone of order n, calculated using the thrust axis.
void setBackwardHemisphere4Momentum(TLorentzVector mom)
Sets the 4-momentum of the backward hemisphere, as defined by the thrust axis.
TVector3 m_sphericityEigenvector[3]
Sphericity tensor eigenvectors.
void setCleoConeCollision(short order, float moment)
Sets the Cleo cone of order n, calculated using the collision axis.
float getCleoConeCollision(short order) const
Returns the Cleo cone of a given order, calculated respect to the beam axis.
void setHarmonicMomentCollision(short order, float moment)
Sets the harmonic moment of order n, calculated using the collision axis.
TLorentzVector getBackwardHemisphere4Momentum() const
Return the 4-momentum of the backward hemisphere, as defined by the thrust axis.
TLorentzVector m_forwardHemisphere4Momentum
Total 4-momentum of the particles in the forward hemisphere.
float getHarmonicMomentCollision(short order) const
Returns the harmonic moment of a given order, calculated respect to the beam axis.
float m_sphericityEigenvalue[3]
Sphericity tensor eigenvalues.
void setForwardHemisphere4Momentum(TLorentzVector mom)
Sets the 4-momentum of the forward hemisphere, as defined by the thrust axis.
float m_cleoConesThrust[10]
Cleo cones up to order 9, calculated respect to the thrust axis.
float m_foxWolframMoments[10]
Fox Wolfram moments up to order 9.
float m_harmonicMomentsThrust[10]
Harmonic moments up to order 9, calculated respect to the thrust axis.
Defines interface for accessing relations of objects in StoreArray.
ClassDef(RelationsInterface, 0)
defines interface for accessing relations of objects in StoreArray.
Abstract base class for different kinds of events.