@@ -28,6 +28,12 @@ namespace impactx::distribution
2828 * bijective correspondence between vMF distributions and mean
2929 * (polarization) vectors.
3030 *
31+ * The algorithm used here is a simplification of the algorithm described in:
32+ * C. Pinzon and K. Jung, "Fast Python sampler of the von Mises Fisher distribution", in the special
33+ * case of the 2-sphere. Additional references used include:
34+ * K. V. Mardia and P. E. Jupp, Directional Statistics, Wiley, 1999
35+ * S. Kang and H-S. Oh, "Novel sampling method for the von Mises-Fisher distribution", Stat.
36+ * and Comput. 34, 106 (2024), https://doi.org/10.1007/s11222-024-10419-3
3137 * Return sampling from a vMF distribution.
3238 *
3339 * @param mux,muy,muz components of a unit vector specifying the mean direction
@@ -101,6 +107,9 @@ namespace impactx::distribution
101107 amrex::ParticleReal c = std::cos (2_prt*pi*x1);
102108 amrex::ParticleReal s = std::sin (2_prt*pi*x1);
103109 amrex::ParticleReal t;
110+ // The form of the function below is obtained from eq (30) of:
111+ // D. Frisch and U. D. Hanebeck, "Deterministic Von Mises-Fisher Sampling on the Sphere Using
112+ // Fibonacci Lattices", IEEE, 2023, DOI: 10.1109/SDF-MFI59545.2023.10361396
104113 if (m_kappa > 0 ) {
105114 t = 1_prt + std::log1p (x2 * std::expm1 (-2 *m_kappa))/m_kappa;
106115 } else {
0 commit comments