Repository navigation
Conversation
… rings This fixes a problem in the uniform InteractionSampler and adds a unit test. - The BC jump, the collision multiplicity per crossing and the collision time came from RandomRing buffers filled once in init() and never refilled. - The multiplicities therefore repeated every 1000 occupied crossings, and triple collisions were missing at small mu. - These quantities are now drawn from gRandom on each use, with the same distributions. - FixedSkipBC_InteractionSampler and NonUniformMuInteractionSampler use the same time draw. - The new test compares the crossing multiplicities with Poisson at mu 0.05 and 0.3 and checks that they show no period of 1000. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This replaces the rejection loop for the zero-truncated Poisson draw and adds a unit test. - The number of collisions in an occupied crossing was drawn with gRandom->Poisson(mu) until it was not zero. - This needs about 1/mu calls, i.e. about 500 calls per crossing at Pb-Pb rates. - The new drawZeroTruncatedPoisson() inverts the cumulative distribution with one uniform number per call. - Above mu = 30 it keeps the Poisson draw, where a zero is negligible and exp(-mu) would underflow. - InteractionSampler and NonUniformMuInteractionSampler both use it. - init() now stops with a fatal error for a non-positive mu. - The new test checks the frequencies, mean and variance of the draw for mu from 2e-4 to 100. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Increase randomicity and control speed by drawing from inverted distribution.
https://its.cern.ch/jira/browse/O2-7330
Assisted by Claude Code.