Skip to content

Commit

Permalink
TPC: Renaming variables
Browse files Browse the repository at this point in the history
  • Loading branch information
matthias-kleiner committed Aug 7, 2024
1 parent 39b66da commit 0ed5f63
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Detectors/TPC/simulation/src/Digitizer.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ void Digitizer::setMeanLumiDistortionsDerivative(float meanLumi)

void Digitizer::recalculateDistortions()
{
if (!mSpaceCharge || !mSpaceCharge) {
if (!mSpaceCharge || !mSpaceChargeDer) {
LOGP(info, "Average or derivative distortions not set");
return;
}
Expand Down
8 changes: 4 additions & 4 deletions Detectors/TPC/spacecharge/src/SpaceCharge.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -748,7 +748,7 @@ void SpaceCharge<DataT>::calcGlobalDistCorrIterative(const DistCorrInterpolator<
initContainer(mGlobalCorrdRPhi[side], true);
}

const auto& scScale = (type == Type::Distortions) ? scSCale->mInterpolatorGlobalCorr[side] : scSCale->mInterpolatorGlobalDist[side];
const auto& scSCaleInterpolator = (type == Type::Distortions) ? scSCale->mInterpolatorGlobalCorr[side] : scSCale->mInterpolatorGlobalDist[side];

#pragma omp parallel for num_threads(sNThreads)
for (unsigned int iPhi = 0; iPhi < mParamGrid.NPhiVertices; ++iPhi) {
Expand Down Expand Up @@ -802,13 +802,13 @@ void SpaceCharge<DataT>::calcGlobalDistCorrIterative(const DistCorrInterpolator<
// interpolate global correction at new point and calculate position of global correction
corrdR = globCorr.evaldR(zCurrPos, rCurrPos, phiCurrPos);
if (scSCale && scale != 0) {
corrdR += scale * scScale.evaldR(zCurrPos, rCurrPos, phiCurrPos);
corrdR += scale * scSCaleInterpolator.evaldR(zCurrPos, rCurrPos, phiCurrPos);
}
const DataT rNewPos = rCurrPos + corrdR;

DataT corrPhi = 0;
if (scSCale && scale != 0) {
corrPhi = scale * scScale.evaldRPhi(zCurrPos, rCurrPos, phiCurrPos);
corrPhi = scale * scSCaleInterpolator.evaldRPhi(zCurrPos, rCurrPos, phiCurrPos);
}
corrPhi += globCorr.evaldRPhi(zCurrPos, rCurrPos, phiCurrPos);
corrPhi /= rCurrPos;
Expand All @@ -818,7 +818,7 @@ void SpaceCharge<DataT>::calcGlobalDistCorrIterative(const DistCorrInterpolator<

corrdZ = globCorr.evaldZ(zCurrPos, rCurrPos, phiCurrPos);
if (scSCale && scale != 0) {
corrdZ += scale * scScale.evaldZ(zCurrPos, rCurrPos, phiCurrPos);
corrdZ += scale * scSCaleInterpolator.evaldZ(zCurrPos, rCurrPos, phiCurrPos);
}
const DataT zNewPos = zCurrPos + corrdZ;

Expand Down

0 comments on commit 0ed5f63

Please sign in to comment.