Question: C++, Putt, emacs Particle Size Distribution Simulation 1. Generate and analyze a Gaussian particle size distribution. (a) Use the Gaussian random number generator to generate

C++, Putt, emacs

Particle Size Distribution Simulation

1. Generate and analyze a Gaussian particle size distribution.

(a) Use the Gaussian random number generator to generate 100 particle diameters with a mean of 50 m and a standard deviation of 5 m. Store the generated particles sizes in a vector. Reject any unphysical sizes.

(b) Write a function to return the average particle size.

(c) Write a function to return the standard deviation of the particles sizes.

2. Create number frequency histogram of the distribution.

(a) Determine how many size ranges (bins) you will use for your histogram and what their widths will be.

(b) Create a vector to store the number of particles in a bin.

(c) Normalize the data by dividing the number of particles in each bin by the total number of particles to get the fraction of particles in each bin. Store these values in a vector.

(d) Normalize the particle fractions in each bin by dividing each fraction by the bin width. This is the normalized histogram.

3. Plot the normalized data as a histogram.

Please and Thank You

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!