Skip to content

Instantly share code, notes, and snippets.

View ChristopherMayes's full-sized avatar

Christopher Mayes ChristopherMayes

View GitHub Profile
@ChristopherMayes
ChristopherMayes / benchmarking_ran_gauss.md
Last active March 12, 2026 00:57
`ran_gauss` Benchmark — Gaussian RNG for bmad-ecosystem

ran_gauss Benchmark — Gaussian RNG for bmad-ecosystem

Standalone benchmark comparing five implementations of the ran_gauss Gaussian random number generator used in bmad-ecosystem radiation tracking.

Versions compared

Version Description
Original Upstream code. ran_gauss_vector calls ran_gauss_scalar per element; each scalar call goes through ran_uniform → ran_uniform_scalar → pointer_to_ran_state.
Clean Structural optimizations only: resolve pointer_to_ran_state once, batch Box-Muller pairs in the vector path. No inlined RNG — still calls ran_uniform_vector.
@ChristopherMayes
ChristopherMayes / JuliaSpaceCharge.ipynb
Last active August 22, 2026 06:46
Julia Space Charge
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.