Skip to content

Review: Foam::distributionModels

  • Some member models could be refactored by using C++11 #include <random>, e.g.:
    • Foam::distributionModels::RosinRammler -> std::weibull_distribution
    • Foam::distributionModels::exponential -> std::exponential_distribution (although the latter does not provide any mechanism to min/max the support)
    • Foam::distributionModels::uniform -> std::uniform_real_distribution
    • Foam::distributionModels::normal -> std::normal_distribution
  • Namespace content could be chucked outside the Lagrangian context to enable users/developers to generate random variates sampled from a chosen distribution. Maybe into Random.H?