-
Notifications
You must be signed in to change notification settings - Fork 26
Description
Possible tanDip bug
Hi all,
I have found a potential issue with tanDip going negative for downstream going track segments in EventNtuple, and would appreciate some guidance on how to proceed, since I use this parameter for a selection cut in an ongoing analysis.
As I understand it, tanDip = pz/pt per intersection. Therefore, if I apply a mask according to p_z > 0 per segment I should not see any negative tanDip values since it is signed by the z-momentum.
However, when I plot tanDip for downstream going track segments at the tracker entrance, I see negative peaks in both CeEndpoint and CosmicCRY nts datasets:
Additionally, if I calculate tanDip from the track segment momentum vector, I see something which looks much more sensible:
It was suggested that tanDip might be calculated at the stopping target and then broadcast to all segments, but I don't think that's what's happening. For one thing, if I simply print out the arrays for a single track I see tanDip changing over z-position and momentum:
trksegs.mom.fCoordinates.fZ: [[-23.8, -9.8, -9.8, -10.0, 30.4, 49.7, 49.5, 54.1, 54.9, 55.5]]
trksegs.pos.fCoordinates.fZ: [[-4122.2, -4350.5, -4350.5, -4359.2, -3922.2, -2679.8, -2381.0, -1631.1, 10.1, 1639.1]]
trksegpars_lh.tanDip: [[0.6, 0.5, 0.3, -0.2, 0.6, 0.6, 0.6, -0.1, -0.1, -0.1]]
I had a look at the code, and it all looks reasonable to me, although there is a subtlety where tanDip is calculated at trksegspars_lh.t0, here, which is not the same thing as trksegs.time.
trksegs.time: [[709.2, 714.0, 714.0, 714.3, 728.9, 739.4, 741.5, 746.4, 756.8, 767.0]]
trksegpars_lh.t0: [[757.5, 758.9, 773.4, 648.1, 756.9, 756.7, 756.8, 567.7, 567.7, 549.9]]
I understand that tanDip is marked as "deprecated", but it is still used as one of the "standard" track cuts, so I would appreciate some guidance on what to do here. Should I just calculate tanDip by hand from the momentum vector, or is there something I'm missing about this parameter.
Thanks,
Sam