From f0a12938c7ea13b48c341610b8da052937dc46c3 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 8 Apr 2024 20:43:42 +0000 Subject: [PATCH] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- macros/REST_Axion_XMMAngleEffCSV.C | 4 +--- .../boundary/Boundaries_test_interactive.C | 12 ++++-------- src/TRestAxionMagneticField.cxx | 12 +++++------- src/TRestAxionOpticsMirror.cxx | 4 ++-- 4 files changed, 12 insertions(+), 20 deletions(-) diff --git a/macros/REST_Axion_XMMAngleEffCSV.C b/macros/REST_Axion_XMMAngleEffCSV.C index 81576f20..a95795d1 100644 --- a/macros/REST_Axion_XMMAngleEffCSV.C +++ b/macros/REST_Axion_XMMAngleEffCSV.C @@ -47,9 +47,7 @@ Int_t REST_Axion_XMMAngleEffCSV( Int_t obsID = run->GetAnalysisTree()->GetObservableID("optics_efficiency"); if (obsID == -1) { - RESTError << "No observable \"" - << "optics_efficiency" - << "\" in file " << files[n] << RESTendl; + RESTError << "No observable \"" << "optics_efficiency" << "\" in file " << files[n] << RESTendl; continue; } Double_t eff = 0; diff --git a/pipeline/metadata/magneticField/boundary/Boundaries_test_interactive.C b/pipeline/metadata/magneticField/boundary/Boundaries_test_interactive.C index 17b4739a..1dda767a 100644 --- a/pipeline/metadata/magneticField/boundary/Boundaries_test_interactive.C +++ b/pipeline/metadata/magneticField/boundary/Boundaries_test_interactive.C @@ -60,8 +60,7 @@ void PrintVolumeBoundaries(Int_t volume_ID, TVector3 position, TVector3 directio if (volume_ID == 0) { myfile << "Initial position : (" << position.X() << ", " << position.Y() << ", " << position.Z() - << ")" - << "\n"; + << ")" << "\n"; myfile << "Direction : (" << direction.X() << ", " << direction.Y() << ", " << direction.Z() << ")" << "\n\n"; } @@ -69,8 +68,7 @@ void PrintVolumeBoundaries(Int_t volume_ID, TVector3 position, TVector3 directio myfile << "Number of volume boundary points found : " << boundaries.size() << "\n"; for (int i = 0; i < boundaries.size(); i++) myfile << "boundaries[" << i << "] = (" << boundaries[i].X() << ", " << boundaries[i].Y() << ", " - << boundaries[i].Z() << ")" - << "\n"; + << boundaries[i].Z() << ")" << "\n"; myfile << "\n\n"; } @@ -84,8 +82,6 @@ void PrintFieldBoundaries(std::vector fieldboundaries) { myfile << "Number of field boundary points found : " << fieldboundaries.size() << "\n"; for (int i = 0; i < fieldboundaries.size(); i++) myfile << "fieldboundaries[" << i << "] = (" << fieldboundaries[i].X() << ", " - << fieldboundaries[i].Y() << ", " << fieldboundaries[i].Z() << ")" - << "\n"; - myfile << "---------------------------------" - << "\n"; + << fieldboundaries[i].Y() << ", " << fieldboundaries[i].Z() << ")" << "\n"; + myfile << "---------------------------------" << "\n"; } diff --git a/src/TRestAxionMagneticField.cxx b/src/TRestAxionMagneticField.cxx index 763819de..23deb52e 100644 --- a/src/TRestAxionMagneticField.cxx +++ b/src/TRestAxionMagneticField.cxx @@ -751,13 +751,11 @@ void TRestAxionMagneticField::LoadMagneticFieldData(MagneticFieldVolume& mVol, RESTWarning << "nX: " << nX << " nY: " << nY << " nZ: " << nZ << RESTendl; RESTWarning << "WARNING: field[nX][nY][nZ] element not equal to initial value (0, 0, 0) !!" << RESTendl; - RESTWarning << "It has value: " - << "mVol.field[" << nX << "][" << nY << "][" << nZ << "] = (" + RESTWarning << "It has value: " << "mVol.field[" << nX << "][" << nY << "][" << nZ << "] = (" << mVol.field[nX][nY][nZ].X() << " , " << mVol.field[nX][nY][nZ].Y() << " , " << mVol.field[nX][nY][nZ].Z() << ")" << RESTendl; - RESTWarning << "Values to write: " - << "Bx: " << data[n][3] << " By: " << data[n][4] << " Bz: " << data[n][5] << RESTendl - << RESTendl; + RESTWarning << "Values to write: " << "Bx: " << data[n][3] << " By: " << data[n][4] + << " Bz: " << data[n][5] << RESTendl << RESTendl; this->SetError("There was a problem assigning the field matrix!"); if (GetVerboseLevel() >= TRestStringOutput::REST_Verbose_Level::REST_Extreme) GetChar(); @@ -1532,8 +1530,8 @@ void TRestAxionMagneticField::PrintMetadata() { RESTMetadata << "* Volume " << p << " centered at (" << centerX << "," << centerY << "," << centerZ << ") mm" << RESTendl; RESTMetadata << " - Grid mesh element size. X: " << fMeshSize[p].X() << "mm " - << " Y: " << fMeshSize[p].Y() << "mm " - << " Z: " << fMeshSize[p].Z() << "mm " << RESTendl; + << " Y: " << fMeshSize[p].Y() << "mm " << " Z: " << fMeshSize[p].Z() << "mm " + << RESTendl; RESTMetadata << " - Offset field [T] : (" << fConstantField[p].X() << ", " << fConstantField[p].Y() << ", " << fConstantField[p].Z() << ")" << RESTendl; RESTMetadata << " - File loaded : " << fFileNames[p] << RESTendl; diff --git a/src/TRestAxionOpticsMirror.cxx b/src/TRestAxionOpticsMirror.cxx index 2ca01c51..ee17be1a 100644 --- a/src/TRestAxionOpticsMirror.cxx +++ b/src/TRestAxionOpticsMirror.cxx @@ -397,7 +397,7 @@ Double_t TRestAxionOpticsMirror::GetReflectivity(const Double_t angle, const Dou } Int_t lowAngBin = (Int_t)((ang) / 0.01); - Double_t deltaAng = (ang - (Double_t)(lowAngBin)*0.01) / 0.01; // between 0 and 1 + Double_t deltaAng = (ang - (Double_t)(lowAngBin) * 0.01) / 0.01; // between 0 and 1 Double_t REnLowAngLow = fReflectivityTable[lowEnBin][lowAngBin]; Double_t REnLowAngHi = fReflectivityTable[lowEnBin][lowAngBin + 1]; @@ -449,7 +449,7 @@ Double_t TRestAxionOpticsMirror::GetTransmission(const Double_t angle, const Dou } Int_t lowAngBin = (Int_t)((ang) / 0.01); - Double_t deltaAng = (ang - (Double_t)(lowAngBin)*0.01) / 0.01; // between 0 and 1 + Double_t deltaAng = (ang - (Double_t)(lowAngBin) * 0.01) / 0.01; // between 0 and 1 Double_t REnLowAngLow = fTransmissionTable[lowEnBin][lowAngBin]; Double_t REnLowAngHi = fTransmissionTable[lowEnBin][lowAngBin + 1];