Public Member Functions |
Static Public Member Functions |
Protected Member Functions |
Protected Attributes |
Friends
Vector3 Class Reference Three-dimensional specialisation of Vector. More...
Inheritance diagram for Vector3:
Collaboration diagram for Vector3:
Detailed DescriptionThree-dimensional specialisation of Vector. Definition at line 26 of file Vector3.hh. Constructor & Destructor Documentation
Definition at line 35 of file Vector3.hh. Referenced by Vector3::mkX(), Vector3::mkY(), and Vector3::mkZ(). : Vector<3>() { }
Definition at line 38 of file Vector3.hh. References Vector3::setX(), Vector3::setY(), and Vector3::setZ(). Definition at line 44 of file Vector3.hh. References Vector< N >::get(), Vector3::setX(), Vector3::setY(), and Vector3::setZ().
Definition at line 50 of file Vector3.hh. References Vector3::setX(), Vector3::setY(), and Vector3::setZ().
Definition at line 56 of file Vector3.hh. { } Member Function DocumentationDefinition at line 81 of file Vector3.hh. References Vector3::dot(), Rivet::fuzzyEquals(), and Vector3::unit(). Referenced by FourVector::angle(), and Rivet::angle(). { const double localDotOther = unit().dot(v.unit()); if (fuzzyEquals(localDotOther, 1.0)) return 0.0; else if (fuzzyEquals(localDotOther, -1.0)) return M_PI; return acos(localDotOther); }
Angle subtended by the vector's projection in x-y and the x-axis. Definition at line 123 of file Vector3.hh. References Rivet::isZero(), Rivet::mapAngle(), Vector< 3 >::mod2(), Vector3::x(), and Vector3::y(). Referenced by FourVector::azimuthalAngle(), Rivet::azimuthalAngle(), Rivet::deltaPhi(), Rivet::deltaR(), Vector3::phi(), and DISKinematics::project(). { // If this is a null vector, return zero rather than let atan2 set an error state if (Rivet::isZero(mod2())) return 0.0; // Calculate the arctan and return in the requested range const double value = atan2( y(), x() ); return mapAngle(value, mapping); } Definition at line 75 of file Vector3.hh. References Vector< N >::_vec, and Vector< 3 >::_vec. Referenced by Thrust::_calcThrust(), D0_1996_S3214044::_fourJetAnalysis(), CDF_1997_S3541940::_psi(), CDF_1996_S3349578::_psi(), D0_1996_S3214044::_threeJetAnalysis(), MC_ZZINC::analyze(), MC_WWINC::analyze(), and Rivet::cross(). Definition at line 71 of file Vector3.hh. References Vector< 3 >::_vec, and Vector< N >::_vec. Referenced by Rivet::_calcT(), CDF_1996_S3349578::_fiveJetAnalysis(), CDF_1996_S3349578::_fourJetAnalysis(), D0_1996_S3214044::_fourJetAnalysis(), CDF_1997_S3541940::_psi(), CDF_1996_S3349578::_psi(), CDF_1996_S3349578::_threeJetAnalysis(), D0_1996_S3214044::_threeJetAnalysis(), OPAL_1993_S2692198::analyze(), SLD_2004_S5693039::analyze(), SLD_1999_S3743934::analyze(), CDF_1997_S3541940::analyze(), ATLAS_2012_I1082009::analyze(), MC_ZZINC::analyze(), MC_WWINC::analyze(), Vector3::angle(), Rivet::dot(), and FoxWolframMoments::project(). { return _vec.dot(v._vec); }
Synonym for pseudorapidity. Definition at line 156 of file Vector3.hh. References Vector3::pseudorapidity(). Referenced by FourVector::eta(), and Rivet::eta(). { return pseudorapidity(); }
Definition at line 33 of file VectorN.hh. { if (index >= N) { throw std::runtime_error("Tried to access an invalid vector index."); } else { return _vec(index); } }
Definition at line 126 of file VectorN.hh. { if (index >= N) { throw std::runtime_error("Tried to access an invalid vector index."); } else { return _vec(index); } }
Check for nullness, allowing for numerical precision. Definition at line 67 of file VectorN.hh. Referenced by Vector3::unit(). { for (size_t i=0; i < N; ++i) { if (! Rivet::isZero(_vec[i], tolerance) ) return false; } return true; } Definition at line 59 of file Vector3.hh. References Vector3::Vector3(). Referenced by DISKinematics::project(), and LorentzTransform::setBoost(). { return Vector3(1,0,0); } Definition at line 60 of file Vector3.hh. References Vector3::Vector3(). Referenced by DISKinematics::project(). { return Vector3(0,1,0); } Definition at line 61 of file Vector3.hh. References Vector3::Vector3(). Referenced by DISKinematics::project(). { return Vector3(0,0,1); }
Calculate the modulus of a vector. . Definition at line 87 of file VectorN.hh. Referenced by Vector3::unit(). { const double norm = mod2(); assert(norm >= 0); return sqrt(norm); }
Calculate the modulus-squared of a vector. . Definition at line 76 of file VectorN.hh. Referenced by Vector3::azimuthalAngle().
Definition at line 104 of file VectorN.hh. { return _vec != a._vec; }
Definition at line 161 of file Vector3.hh. References Vector< 3 >::_vec, Vector< N >::_vec, and Vector3::multiply. Definition at line 171 of file Vector3.hh. References Vector< 3 >::_vec, Vector< N >::_vec, and Vector3::add.
Invert the vector. Reimplemented from Vector< 3 >. Definition at line 181 of file Vector3.hh. References Vector< N >::_vec, and Vector< 3 >::_vec. Definition at line 176 of file Vector3.hh. References Vector< 3 >::_vec, Vector< N >::_vec, and Vector3::subtract.
Definition at line 166 of file Vector3.hh. References Vector< 3 >::_vec, Vector< N >::_vec, and Vector3::multiply.
Definition at line 108 of file VectorN.hh. { return _vec < a._vec; }
Definition at line 112 of file VectorN.hh. { return _vec <= a._vec; }
Definition at line 100 of file VectorN.hh. { return _vec == a._vec; }
Definition at line 116 of file VectorN.hh. { return _vec > a._vec; }
Definition at line 120 of file VectorN.hh. { return _vec >= a._vec; }
Direct access to vector elements by index. Definition at line 42 of file VectorN.hh. { return get(index); }
Direct access to vector elements by index. Definition at line 47 of file VectorN.hh. { return get(index); }
Synonym for polarRadius. Definition at line 113 of file Vector3.hh. References Vector3::polarRadius(). Referenced by FourVector::perp(), and Rivet::perp(). { return polarRadius(); }
Synonym for polarRadius2. Definition at line 99 of file Vector3.hh. References Vector3::polarRadius2(). Referenced by FourVector::perp2(), and Rivet::perp2(). { return polarRadius2(); }
Synonym for azimuthalAngle. Definition at line 133 of file Vector3.hh. References Vector3::azimuthalAngle(). Referenced by FourVector::phi(), and Rivet::phi(). { return azimuthalAngle(mapping); }
Angle subtended by the vector and the z-axis. Definition at line 138 of file Vector3.hh. References Rivet::mapAngle0ToPi(), Vector3::polarRadius(), and Vector3::z(). Referenced by FourVector::polarAngle(), Rivet::polarAngle(), Vector3::pseudorapidity(), and Vector3::theta(). { // Get number beween [0,PI] const double polarangle = atan2(polarRadius(), z()); return mapAngle0ToPi(polarangle); }
Definition at line 108 of file Vector3.hh. References Vector3::polarRadius2(). Referenced by Vector3::perp(), Vector3::polarAngle(), FourVector::polarRadius(), Rivet::polarRadius(), and Vector3::rho(). { return sqrt(polarRadius2()); }
Definition at line 94 of file Vector3.hh. References Vector3::x(), and Vector3::y(). Referenced by Vector3::perp2(), Vector3::polarRadius(), FourVector::polarRadius2(), Rivet::polarRadius2(), FourMomentum::pT2(), FourMomentum::pt2(), and Vector3::rho2().
Purely geometric approximation to rapidity; exact for massless particles and in the central region. Definition at line 151 of file Vector3.hh. References Vector3::polarAngle(). Referenced by Rivet::deltaEta(), Rivet::deltaR(), Vector3::eta(), FourVector::pseudorapidity(), and Rivet::pseudorapidity(). { return -std::log(tan( 0.5 * polarAngle() )); }
Synonym for polarRadius. Definition at line 118 of file Vector3.hh. References Vector3::polarRadius(). Referenced by FourVector::rho(), and Rivet::rho(). { return polarRadius(); }
Synonym for polarRadius2. Definition at line 104 of file Vector3.hh. References Vector3::polarRadius2(). Referenced by FourVector::rho2(), and Rivet::rho2(). { return polarRadius2(); } Set indexed value. Definition at line 52 of file VectorN.hh. { if (index >= N) { throw std::runtime_error("Tried to access an invalid vector index."); } else { _vec[index] = value; } return *this; } Definition at line 67 of file Vector3.hh. References Vector3::x(). Referenced by Vector3::Vector3(). { set(0, x); return *this; } Definition at line 68 of file Vector3.hh. References Vector3::y(). Referenced by Vector3::Vector3(). { set(1, y); return *this; } Definition at line 69 of file Vector3.hh. References Vector3::z(). Referenced by CMS_2011_S8957746::analyze(), CMS_2013_I1209721::analyze(), MissingMomentum::project(), and Vector3::Vector3(). { set(2, z); return *this; }
Synonym for polarAngle. Definition at line 145 of file Vector3.hh. References Vector3::polarAngle(). Referenced by ALEPH_1996_S3196992::analyze(), FourVector::theta(), and Rivet::theta(). { return polarAngle(); }
Definition at line 88 of file Vector3.hh. References Vector< 3 >::isZero(), and Vector< 3 >::mod(). Referenced by Rivet::_calcS(), Rivet::_calcT(), Thrust::_calcThrust(), CDF_1996_S3349578::_fiveJetAnalysis(), CDF_1996_S3349578::_fourJetAnalysis(), CDF_1997_S3541940::_psi(), CDF_1996_S3349578::_psi(), CDF_1996_S3349578::_threeJetAnalysis(), OPAL_1993_S2692198::analyze(), CDF_1997_S3541940::analyze(), ATLAS_2012_I1082009::analyze(), DELPHI_1996_S3430090::analyze(), Vector3::angle(), LorentzTransform::boost(), Matrix3::Matrix3(), MissingMomentum::project(), and Matrix3::setAsRotation().
Definition at line 64 of file Vector3.hh. Referenced by FParameter::_calcFParameter(), Rivet::_calcS(), Spherocity::_calcSpherocity(), Thrust::_calcThrust(), MC_WPOL::analyze(), Vector3::azimuthalAngle(), Vector3::polarRadius2(), and Vector3::setX(). { return get(0); }
Definition at line 65 of file Vector3.hh. Referenced by FParameter::_calcFParameter(), Rivet::_calcS(), Spherocity::_calcSpherocity(), MC_WPOL::analyze(), Vector3::azimuthalAngle(), ATLAS_2011_I944826::getPerpFlightDistance(), Vector3::polarRadius2(), and Vector3::setY(). { return get(1); }
Definition at line 66 of file Vector3.hh. Referenced by Thrust::_calcThrust(), Vector3::polarAngle(), and Vector3::setZ(). { return get(2); } Friends And Related Function DocumentationReferenced by Vector3::operator+=().
Definition at line 28 of file Vector3.hh. Referenced by Vector3::operator*=(), and Vector3::operator/=(). Definition at line 227 of file Vector3.hh. Referenced by Vector3::operator-=(). { Vector3 result; result._vec = a._vec - b._vec; return result; } Member Data Documentation
Vector. Definition at line 135 of file VectorN.hh. Referenced by Vector3::cross(), Vector3::dot(), Vector3::operator*=(), Vector3::operator+=(), Vector3::operator-(), Vector3::operator-=(), and Vector3::operator/=(). The documentation for this class was generated from the following file: Generated on Thu Feb 6 2014 17:38:57 for The Rivet MC analysis system by 1.7.6.1 |