Closed simonerossoni1996 closed 10 months ago
Hey @simonerossoni1996,
thanks for your improvement.
If I see it correctly this PR is not based on the current CRPropa master. Can you rebase it on the current master and resolve the merge conflicts (or maybe prepare a new PR based on the current master).
The current version is not able to compile due to some conflicts from the newer features as the "tagOrigin".
This PR introduces changes to the SourceDirectedEmission() module.
The SourceDirectedEmission() module samples a random vector from the von Mises-Fischer distribution defined by a mean direction and a concentration parameter. This vector is then used for the injection of the candidate. The sampling was done as in http://people.csail.mit.edu/jstraub/download/straub2017vonMisesFisherInference.pdf .
Given the presence of a function for random sampling from a von Mises-Fischer distribution (in Random.cpp), the sampling procedure was modified. Some functions in the module are no longer needed.
Thanks to @avvliet for help with the changes and with the PR.