Skip to content

Commit

Permalink
One small victory for monadic thinking.
Browse files Browse the repository at this point in the history
  • Loading branch information
timmah committed Jun 10, 2011
1 parent b076175 commit 199e76a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion basic/src/Source.hs
Expand Up @@ -20,7 +20,7 @@ genParticlesInCells :: Mesh m => m -> RNG -> [(CellIdx,Int)] ->
FP -> -- ^ e'
[Particle]
genParticlesInCells msh rng nPerCell a e' =
join $ map (genParticlesInCell msh rng a e') nPerCell
nPerCell >>= (genParticlesInCell msh rng a e')

-- | generate a given number of particles in one cell
genParticlesInCell :: Mesh m => m -> RNG ->
Expand Down

0 comments on commit 199e76a

Please sign in to comment.