-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Implement rapidity-based DeltaR calculations in TLorentzVector #7087
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
Conversation
|
Can one of the admins verify this patch? |
|
Hi, I guess this should also be implemented in VectorUtil -- this is a work-in-progress until I push another commit. Sorry for not sending it all at once! MLB |
|
Hi Matt Than you for your contribution! If you have time, it would be nice to add also this also for the Genvector package for the Cheers Lorenzo |
|
I've added this functionality now also to ROOT::Math::GenVector, it gives the same results as the other implementation and fastjet::pseudojet. I'm not sure if this is exactly how you wanted it implemented, so please let me know if you have further comments -- I've tried to keep everything as consistent as possible between the two sets of changes. I have un-marked the PR as a work-in-progress. |
|
Hi @lmoneta, this is just a ping in case you didn't see the other message -- there is obviously no rush, though. |
|
@phsft-bot build! |
|
Starting build on |
|
Build failed on ROOT-fedora31/noimt. |
|
Build failed on ROOT-performance-centos8-multicore/default. Errors:
Failing tests: |
|
Build failed on mac11.0/cxx17. Errors:
Failing tests: |
lmoneta
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In the case of VectorUtil we need two different functions:
DeltaR( v1,v2) for Eta
DeltaRapidityPhi (v1,v2) for Rapidity.
The reason is that we can call DeltaR also for 3D objects and if it is implemented in term of rapidity , it will not compile. You can see this from the failing error from the integration builds.
Can you please add this change ?
Thank you for this contribution !
Lorenzo
|
Hi @lmoneta, that makes sense -- I have just pushed some more changes. Thanks for the review! MLB |
|
Thank you for the changes. They look good now. If you don't have time doing this, I can do it later, after merging this PR. |
|
@phsft-bot build! |
|
Starting build on |
|
Build failed on mac11.0/cxx17. Failing tests: |
|
Hi @lmoneta, I don't have time to implement this test at the moment, but I will add it to my list to revisit in the future, in case I get there before you do. Thanks once again for reviewing this PR! |
|
Build failed on windows10/cxx14. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A test will then be added as a separate PR. Thank you @mattleblanc for this contribution!
Hello,
At the moment, the
ROOT::TLorentzVectorclass uses a pseudorapidity-based calculation for the commonly-used DeltaR distance between vectors. For massive objects, such as jets, the rapidity should often be used instead. I have implemented a small switch within theTLorentzVector::DeltaRfunction to allow users to make this calculation with the vector's rapidity, instead of pseudorapidity. This has a default value ofkFALSE, which means that the current behaviour will be the default one.I have cross-checked this new functionality with the
fastjet::pseudojet::delta_Rimplementation and an internal ATLAS one, which all give the same results when performing the rapidity-based calculation.Please let me know if I have violated any contribution guidelines, and I will update this PR accordingly!
🍻 Matt