-
Notifications
You must be signed in to change notification settings - Fork 3
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
Add PhaseSpacePoint definition #51
Conversation
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.
Thank you for this!
This is not a full review of the changes, but some first obvious comments from my side.
Can you explain, why the unit tests for Julia v1.6 and v1.7 fail, but the others not? Looks a bit like an API change for @test_throws
.
Yeah I'm pretty sure that's what it is... I think the matching to a regex is new. I can just wrap it in a check about the Julia version, but are we sure we need to support 1.6 and 1.7 anyways? Especially when the now stable version is 1.10 already. |
87006a8
to
6f7cb5e
Compare
6f7cb5e
to
e7f6f90
Compare
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.
I like the implementation, here are some comments from my side.
Furthermore, we should think about some custom Base.show
methods for these nested types.
Julia v1.6 is the defacto LTS, but you are right, the tests for v1.7 to v1.9 are somewhat arbitrary. However, I am fine with the exclusion of some tests, if there is an API change of lack of support in the respective Julia version. Therefore, there is no need to drop the support in the current status, but we should keep an eye on that. Regarding the support of Julia v1.10, you are right, of course. There should be an issue opened on its inclusion 😉 |
aa50ca9
to
5a5f855
Compare
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.
Just some minor issues. Can be merged if resolved.
Co-authored-by: Uwe Hernandez Acosta <[email protected]>
Btw: we must not set assignees on pull requests, because it breaks the gitlab bot somehow 🤷♂️ |
Oh you're right, I completely forgot |
6327fef
to
c62aa75
Compare
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.
Since there is no open issue for this one, I am happy to merge!
With this PR, we adopt the phase space points from #51 for the probability and cross section interface. Further changes: we drop the support of different phase space definitions for the in- and out-phase space.⚠️ This is based on https://github.com/AntonReinhard/QEDprocesses.jl/tree/phase_space_point and should be rebased to `dev` and considered for merging *after* #51 is merged. --------- Co-authored-by: Anton Reinhard <[email protected]> Co-authored-by: Uwe Hernandez Acosta <[email protected]>
Proposal to fix issue #46
This branch is currently based on PR #39 and should be merged after it.
This is a draft for now, but I think it is a good compromise from the discussion in issue #46. The definition is type stable, allows some nice overloads for
is_fermion
and so on for theParticleStateful
objects, and takes care of preventing illegal objects in the constructors.Creating particles is straightforward and disallows illegal configurations (electron with polarization or photon with spin):
Creating
PhaseSpacePoint
s is similarly simple and prevents illegal configurations, e.g. incoming particles in the outgoing list, but is still reasonably fast and does not need allocations. One PhaseSpacePoint for a 2 to 2 process is 944B in memory.Suggestions welcome