Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Common] Fix matching to MC for daughters interacting with material #9391

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

fgrosa
Copy link
Collaborator

@fgrosa fgrosa commented Jan 19, 2025

Together with @mfaggin we realised that whenever a daughter particle (i.e. pion or kaon from a D0 decay) interacts with the material, the particle id changes and in particular another particle with same pdg of the original one is produced by GEANT, and it is set as daughter of the original mother. This can happen several times, due to several interactions with material.
When this happens, getMatchedMCRec does not match correctly the signals, since the track can be associated to the particle from material and not the original daughter:

[INFO]    pdg code 421
[INFO]        - daughter PDG -321 | idx 58356
[INFO]             - grandDaughter PDG 1000120250 | idx 58518
[INFO]             - grandDaughter PDG 11 | idx 58519
[INFO]        - daughter PDG 211 | idx 58357
[INFO]             - grandDaughter PDG 1000120260 | idx 58514
[INFO]             - grandDaughter PDG 211 | idx 58515
[INFO]             - grandDaughter PDG 11 | idx 58516
[INFO]             ++++  track found! 4963 | idxDaug 58356
[INFO]             ++++  track found! 4981 | idxDaug 58515
[INFO]    idx matched reco particle:   -1

To overcome this issue, I added a functionality similar to the one added by @Luca610 for the decays into muons, with the only difference that it searches the mothers iteratively, since multiple interactions might have happen.

The effect is anyway very small (< 1%) in case global tracks are required, since often if the particle interacts with material, there are two track segments reconstructed (only one of the two having hits in the ITS IB, i.e. the one produced by decay itself) or only a track for the particle produced by the material that has no ITS IB hit most of the times.
However, if no global track requirement is applied to the daughters (which might be in case of non-HF decays) the fraction is very high (in the case of the D0, about 25% of the D0 have at least a daughter that interacted with material), so the fraction of non matched signals becomes also very high.

@vkucera could you please have a look to check if it's good for you? If it's the case, I would ask @ddobrigk to merge this so that I will include it in the HF code. Thanks!

@fgrosa fgrosa requested review from alibuild, jgrosseo, iarsene, ktf, ddobrigk and a team as code owners January 19, 2025 09:36
@github-actions github-actions bot changed the title Fix matching to MC for daughters interacting with material [Common] Fix matching to MC for daughters interacting with material Jan 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging this pull request may close these issues.

1 participant