As the title suggests i have attempted comparing the variance of the position of particles of a sample of matter with the sample's temperature.<br/>
Now firstly we need to clarify the basics:<br/>
1. method for averaging a continuous function:<br/>
$$
M\{f\}(a,b)=\frac{1}{b-a} \int_{a}^{b} f(x) \, dx
$$<br/>
2. method for computing the variance of a continuous function:<br/>
we have $$\tag{*} \sigma^2=\sum_{i=1}^N \frac{(x_i - \bar{x})^2}{N} = (\sum_{i=1}^N \frac{x_i^2}{N}) - \bar{x}^2 $$<br/>
Now notice that $$(\sum_{i=1}^N \frac{x_i^2}{N}) $$<br/>
is the same as the average of the function $f^2(x)$ (assuming $\forall x_i\Rightarrow x_i \in R_f$) so with a bit of substitution and simplification we will have:<br/>
$$\sigma^2\{f\}(a,b)=M\{f^2\}(a,b) - (M\{f\}(a,b))^2$$<br/>
Okay!Now that we have our tools;we can continue to compute the desired variance. Notice the "variance" of the function of position of a moving particle gives us a scalar that indicates that how much the particle -sort of-"wobbles".<br/>
now if we have a sample consisting of 500 water molecules and we have the function of position of each particle with respect to time-and assume they are all moving in a simple harmonic manner (i.e $x(t) = A\cos{\omega t}$)-we can theoretically compute the total energy of the system:<br/>
$$Q = \sum{K} = \frac{1}{2}m_{molecule}\sum_{i=1}^N(\frac{dx_i}{dt})^2 = m_{total}cT = cT\sum m_{molecule}$$
note that the total heat energy of a system can be computed like so:$$Q = mc\Delta T = mc(T_1-T_0)=mc(T_2-0) = mcT_2$$(because the heat energy of a system is zero at zero kelvin)
and let's define the "variance" of a system as follows:<br/>
$$\sigma^2[S]_{0}^{t}= \frac{1}{N}\sum_{i=1}^N \sigma^2\{x_i(t)\}(0,t)$$where $x_i(t)$ is the equation of motion of the i-th particle.<br/>
now if plot the variance of a system against its temperature using a code I wrote [you can see it here.][1]
now it takes about ten minutes to completely render and do all of the needed computations - my code is inefficient and my computer slow:( - and the final plot (the $y$ axis is variance of the system and the x axis is the temperature of the system) and the computed image is like follows:
[![Fig 1][2]][2]
<br/>now if we had more continuous data i suspect it would strangely resemble this figure here.(And I have ran it several times and it was not an accident.)
[![Fig 2][3]][3]
<br/>Now my question is if this connection really exists and if so why? <br/>
[1]: https://github.com/iliavarnasseri1305/heat-simulation-in-a-system
[2]:
[3]: