We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent bbb5e94 commit b0129edCopy full SHA for b0129ed
1 file changed
DataFormats/Detectors/TPC/include/DataFormatsTPC/VDriftCorrFact.h
@@ -47,11 +47,10 @@ struct VDriftCorrFact {
47
float normVDrift = newVRef;
48
if (newVRef == 0.f) {
49
normVDrift = refVDrift * corrFact;
50
- if ((tp == 0) || (refTP == 0)) {
51
- newVRef = normVDrift; // no T/P scaling applied
52
- } else {
+ newVRef = normVDrift;
+ if ((tp > 0) && (refTP > 0)) {
53
// linear scaling based on relative change of T/P
54
- newVRef = normVDrift * (1 + (tp - refTP) / refTP);
+ normVDrift *= refTP / tp;
55
refTP = tp; // update reference T/P
56
}
57
0 commit comments