# Error in variance

I've been exploring techniques in statistical physics, specifically applying them to spin ices. I'm in the canonical ensemble. By using the fluctuation dissipation theorem you can extract useful properties from the variance in energy and magnetization such as the heat capacity (constant V) and magnetic susceptibility respectively.

I've included the formulas I'm using below: \begin{align} C_V & = \frac{\partial\langle E \rangle}{\partial T} \\ & = -\frac{\beta}{T} \frac{\partial\langle E \rangle}{\partial\beta} \\ & = \frac{\beta}{T} \frac{\partial^2\ln Z}{\partial\beta^2} \\ & = \frac{\beta}{T} \frac{\partial}{\partial\beta}\left(\frac{1}{Z} \frac{\partial Z}{\partial\beta}\right) \\ & = \frac{\beta}{T} \left[\frac{1}{Z} \frac{\partial^2Z}{\partial\beta^2} - \frac{1}{Z^2} \left(\frac{\partial Z}{\partial\beta}\right)^2\right] \\ & = \frac{\beta}{T} \left[\langle E^2 \rangle - \langle E \rangle^2\right], \\ \chi & = \frac{\partial\langle M \rangle}{\partial H} \\ & = \beta \left[\langle M^2 \rangle - \langle M \rangle^2\right]. \end{align}

Now for my question, is there another computable statistical property which acts as the error for the variance? Such that I can get errors for the heat capacity and susceptibility.

• Hi @Jonathan. The inability to embed might have been a new user restriction? In any event, once you can embed, the official stackexchange imgur method is preferred (see here), but for formulas Latex-style formatting (implemented via MathJax) is even more preferred. – user10851 Apr 21 '13 at 19:35
• Hi there. When I posted it said it couldn't reach imgur. Guess it was just a glitch. Out of curiosity did you write out the latex yourself, or did you convert the image automatically somehow? I'm quite new to Latex, only started learning it this week. I will use it from now on. – Uzer Apr 21 '13 at 19:43
• That was all on my own. Soon enough, you'll be a natural at it too :) I don't know of any full image-to-tex converters (someone somewhere has no doubt tried to code one), but for single symbols this is a great resource for beginners. – user10851 Apr 21 '13 at 19:47

Since the energy $E$ is a random value, you can define another random variable

$c_V=(E-<E>)^2$

such that the heat capacity is the mean value of this quantity:

$C_V=<c_V>$

Now we can identificate the mean variance of $c_V$ with the variance of $C_V$, we have:

$<\Delta c_V>=\Delta C_V= \sqrt(<E^4>-<E>^4)$

we can compute $<E^4>$ with the formula:

$<E^n>=(-1)^n\frac{1}{Z}\frac{\partial^n}{\partial \beta^n}Z=(-1)^n\frac{1}{Z}\frac{\partial^n}{\partial \beta^n}e^{\ln Z}$

$\frac{\partial}{\partial \beta}\ln Z=-<E>$

after expressing all the values in terms of derivative with respect of the temperature of the mean energy. You will obtain an estimation for the error of variance from derivatives of the mean energy with respect to temperature.

Turns out there are two methods that I have found out... there many be others:

1) Repeat the simulation n times with different initial conditions and use the usual statistic techniques to calculate the mean and error of the variance quantities.

2) Bootstrapping, sub sample the data as follows: Randomly choose N frames from M frames, where M > n N [n defined below]. Calculate quantities in the set N. Repeat n times Calculate statistical variances among the n sets of calculations.

Source: Dr Peter Olmsted @ Leeds University