CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Pre-Processing (https://www.cfd-online.com/Forums/openfoam-pre-processing/)
-   -   Problem with Rosin Rammler (https://www.cfd-online.com/Forums/openfoam-pre-processing/116077-problem-rosin-rammler.html)

Chrisi1984 April 12, 2013 09:19

Problem with Rosin Rammler
 
Hi all,

I want to use a RosinRammler pdf for my parcels.

In the the source code I found the following:

Quote:

Foam::scalar Foam::distributionModels::RosinRammler::sample() const
{
scalar K = 1.0 - exp(-pow((maxValue_ - minValue_)/d_, n_));
scalar y = rndGen_.sample01<scalar>();
scalar x = minValue_ + d_*::pow(-log(1.0 - y*K), 1.0/n_);
return x;
}
I tried to implement exactly that in excel to calculate the values for minValue, maxValue, d and n for my desired distribution.

I callculated K and with that later the x value. For y I take a list of 100 values from 0 to 1.

Then I thought for y= 0.5 I should get the value for dv50 of my destribution. The same I did with y= 0.9 for dv90.

But the distribution in FOAM later on does not correspond to my excel values.

What is the error that I do?

Thanks for you help in advance.

Kind regards

Chrisi

raptorishungry February 24, 2021 11:53

Hi Chrisi, did you figure this out?


All times are GMT -4. The time now is 22:36.