static List <int> DoReaction(IShape shape, int particlesCount, double lambda) { var particles = GenerateInternalParticles(shape, particlesCount); var reaction = new NuclearReaction(shape, particles, lambda); return(reaction.Run()); }
static void BallWithInteractionProbabilities(double absorption, double scattering, double fission) { var ball = new Ball(10); var particles = GenerateInternalParticles(ball, 1000); var reaction = new NuclearReaction(ball, particles, 0.9); reaction.RandomInteractions = new InteractionWithProbabilities(absorption, scattering, fission); var counts = reaction.Run(); }