Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions ALICE3/TableProducer/OTF/onTheFlyRichPid.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
<<<<<<< Updated upstream
=======
#include "CommonConstants/MathConstants.h"
>>>>>>> Stashed changes
>>>>>>> Stashed changes
#include "CommonConstants/PhysicsConstants.h"
#include "CommonUtils/NameConf.h"
#include "DataFormatsCalibration/MeanVertexObject.h"
Expand Down Expand Up @@ -73,7 +73,7 @@
#include <utility>
#include <vector>

using namespace o2;
using namespace o2;
using namespace o2::framework;
using namespace o2::constants::math;

Expand Down Expand Up @@ -510,7 +510,7 @@
/// \param n the refractive index of the considered sector
/// \param angle the output angle (passed by reference)
/// \return true if particle is above the threshold and enough photons, false otherwise
bool CherenkovAngle(const float momentum, const float mass, const float n, float& angle)

Check failure on line 513 in ALICE3/TableProducer/OTF/onTheFlyRichPid.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
{
if (momentum > mass / std::sqrt(n * n - 1.0)) { // Check if particle is above the threshold
// Calculate angle
Expand Down Expand Up @@ -543,13 +543,13 @@

/// returns angular resolution for considered track eta
/// \param eta the pseudorapidity of the tarck (assuming primary vertex at origin)
float AngularResolution(float eta)

Check failure on line 546 in ALICE3/TableProducer/OTF/onTheFlyRichPid.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
{
// Vectors for sampling (USE ANALYTICAL EXTRAPOLATION FOR BETTER RESULTS)
static constexpr float etaSampling[] = {-2.000000, -1.909740, -1.731184, -1.552999, -1.375325, -1.198342, -1.022276, -0.847390, -0.673976, -0.502324, -0.332683, -0.165221, 0.000000, 0.165221, 0.332683, 0.502324, 0.673976, 0.847390, 1.022276, 1.198342, 1.375325, 1.552999, 1.731184, 1.909740, 2.000000};

Check failure on line 549 in ALICE3/TableProducer/OTF/onTheFlyRichPid.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/constexpr-constant]

Use UpperCamelCase for names of constexpr constants. Names of special constants may be prefixed with "k".
static constexpr float resRingSamplingWithAbsWalls[] = {0.0009165, 0.000977, 0.001098, 0.001198, 0.001301, 0.001370, 0.001465, 0.001492, 0.001498, 0.001480, 0.001406, 0.001315, 0.001241, 0.001325, 0.001424, 0.001474, 0.001480, 0.001487, 0.001484, 0.001404, 0.001273, 0.001197, 0.001062, 0.000965, 0.0009165};

Check failure on line 550 in ALICE3/TableProducer/OTF/onTheFlyRichPid.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/constexpr-constant]

Use UpperCamelCase for names of constexpr constants. Names of special constants may be prefixed with "k".
static constexpr float resRingSamplingWithoutAbsWalls[] = {0.0009165, 0.000977, 0.001095, 0.001198, 0.001300, 0.001369, 0.001468, 0.001523, 0.001501, 0.001426, 0.001299, 0.001167, 0.001092, 0.001179, 0.001308, 0.001407, 0.001491, 0.001508, 0.001488, 0.001404, 0.001273, 0.001196, 0.001061, 0.000965, 0.0009165};

Check failure on line 551 in ALICE3/TableProducer/OTF/onTheFlyRichPid.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/constexpr-constant]

Use UpperCamelCase for names of constexpr constants. Names of special constants may be prefixed with "k".
static constexpr int sizeResVector = sizeof(etaSampling) / sizeof(etaSampling[0]);

Check failure on line 552 in ALICE3/TableProducer/OTF/onTheFlyRichPid.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/constexpr-constant]

Use UpperCamelCase for names of constexpr constants. Names of special constants may be prefixed with "k".
// Use binary search to find the lower and upper indices
const int lowerIndex = std::lower_bound(etaSampling, etaSampling + sizeResVector, eta) - etaSampling - 1;
const int upperIndex = lowerIndex + 1;
Expand Down Expand Up @@ -634,7 +634,7 @@
// const float ze = thicknessRad / (2. * zP);
const float az = zP * cosThetaCherenkov - xP * sinThetaCherenkov * cosPhi;
const float e3z = std::sqrt(az * az + (nGas / n) * (nGas / n) - 1.);
const float Z = thicknessGas;

Check failure on line 637 in ALICE3/TableProducer/OTF/onTheFlyRichPid.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
const float alpha = e3z / az;
const float etac = e3z * n * n;
const float k = thicknessRad / (2. * Z);
Expand Down Expand Up @@ -685,7 +685,7 @@
// Fraction of photons in rings (to account loss close to sector boundary in projective geometry)
const float sinThetaCherenkovSquared = sinThetaCherenkov * sinThetaCherenkov;
const float radius = (thicknessRad / 2.0) * std::tan(thetaCherenkov) + thicknessGas * std::tan(std::asin((n / nGas) * sinThetaCherenkov));
const float N0 = 24. * thicknessRad / 2.; // photons for N = 1.03 at saturation ( 24/2 factor per radiator cm )

Check failure on line 688 in ALICE3/TableProducer/OTF/onTheFlyRichPid.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
const float sinAngle = std::sin(std::acos(1. / 1.03));
const float sinAngleSquared = sinAngle * sinAngle;
const float multiplicitySpectrumFactor = sinThetaCherenkovSquared / sinAngleSquared; // scale multiplicity w.r.t. N = 1.03 at saturation
Expand Down Expand Up @@ -838,8 +838,8 @@
float nSigmaBarrelRich[kNspecies] = {kErrorValue, kErrorValue, kErrorValue, kErrorValue, kErrorValue};
bool signalBarrelRich[kNspecies] = {false, false, false, false, false};
float deltaThetaBarrelRich[kNspecies]; //, nSigmaBarrelRich[kNspecies];
static constexpr int lpdgArray[kNspecies] = {kElectron, kMuonMinus, kPiPlus, kKPlus, kProton};

Check failure on line 841 in ALICE3/TableProducer/OTF/onTheFlyRichPid.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/constexpr-constant]

Use UpperCamelCase for names of constexpr constants. Names of special constants may be prefixed with "k".
static constexpr float masses[kNspecies] = {o2::track::pid_constants::sMasses[o2::track::PID::Electron],

Check failure on line 842 in ALICE3/TableProducer/OTF/onTheFlyRichPid.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/constexpr-constant]

Use UpperCamelCase for names of constexpr constants. Names of special constants may be prefixed with "k".
o2::track::pid_constants::sMasses[o2::track::PID::Muon],
o2::track::pid_constants::sMasses[o2::track::PID::Pion],
o2::track::pid_constants::sMasses[o2::track::PID::Kaon],
Expand Down
Loading