This shows you the differences between two versions of the page.

Next revision | Previous revision | ||

cs190c:sample_ideal_gas_discussion [2008/03/19 20:00] seh created |
cs190c:sample_ideal_gas_discussion [2008/03/24 01:10] (current) |
||
---|---|---|---|

Line 7: | Line 7: | ||

The average system energy and total energy were plotted versus N. The plot below includes predicted system energy (yellow) based on the model discussed below. | The average system energy and total energy were plotted versus N. The plot below includes predicted system energy (yellow) based on the model discussed below. | ||

- | {{ project:project3_sample_discussion_energies.png?250 |}} | + | {{ cs190c:project3_sample_discussion_energies.png?250 |}} |

The plot shows an overall trend for system energy to approach total energy for larger values of N. The table below shows the approximate difference between total energy and system energy for a few values of N: | The plot shows an overall trend for system energy to approach total energy for larger values of N. The table below shows the approximate difference between total energy and system energy for a few values of N: | ||

Line 16: | Line 16: | ||

Looking at the data and the relationship between total and system energy, one can conclude that a reasonable model for the relationship here is that totalEnergy - systemEnergy ≈ 1000/N (or systemEnergy ≈ totalEnergy - 1000/N). For comparison, the values predicted by this model were plotted against a new set of observed values; the resulting plot shows a strong linear correlation. | Looking at the data and the relationship between total and system energy, one can conclude that a reasonable model for the relationship here is that totalEnergy - systemEnergy ≈ 1000/N (or systemEnergy ≈ totalEnergy - 1000/N). For comparison, the values predicted by this model were plotted against a new set of observed values; the resulting plot shows a strong linear correlation. | ||

- | {{ project:project3_sample_discussion_correlation.png?250 |Correlation between observed and predicted values}} | + | {{ cs190c:project3_sample_discussion_correlation.png?250 |Correlation between observed and predicted values}} |

The pylab.corrcoef() function was used to compute a linear correlation of 0.997. | The pylab.corrcoef() function was used to compute a linear correlation of 0.997. | ||

Line 27: | Line 27: | ||

The choice of initial velocities at about +1.4 (sqrt(2*totalEnergy/N)=√2) can explain both of these; velocities closer to 1.4 were more accessible, resulting in the slight right-skewness for values lower than 1.4 and the higher than expected number of velocities around 3. | The choice of initial velocities at about +1.4 (sqrt(2*totalEnergy/N)=√2) can explain both of these; velocities closer to 1.4 were more accessible, resulting in the slight right-skewness for values lower than 1.4 and the higher than expected number of velocities around 3. | ||

- | {{ project:project3_sample_discussion_velocities.png?250 |}} | + | {{ cs190c:project3_sample_discussion_velocities.png?250 |}} |

Line 36: | Line 36: | ||

The demon energy reached as high as about 12.5 during the simulation with N=500, totalEnergy=500, and steps=3000, but this occurred only for a single observation; in contrast, about 50% of energy observations were below roughly 1.3. Given this, the observed average demon energy (i.e., 500-systemEnergy) of about two is not surprising. | The demon energy reached as high as about 12.5 during the simulation with N=500, totalEnergy=500, and steps=3000, but this occurred only for a single observation; in contrast, about 50% of energy observations were below roughly 1.3. Given this, the observed average demon energy (i.e., 500-systemEnergy) of about two is not surprising. | ||

- | {{ project:project3_sample_discussion_demonenergy.png?250 |}} | + | {{ cs190c:project3_sample_discussion_demonenergy.png?250 |}} |