Expression of the specific heat capacity in statistical mechanics from the thermodynamical definition The specific heat capacity as I recall from thermodynamics(and as Wikipedia defines it) is defined as
$$C_v= \frac{1}{M}\frac{dQ}{dT}$$
$C_v$ is specific heat capacity at constant volume, M is the mass
In statistical mechanics, after deriving the Boltzmann-Gibbs probability measure, the canonical partition function Z and defining the Helmholtz free energy, they start proving the thermodynamic relations from these equations. At some point the following equation is used, which I like to know how to obtain, it must be a thermodynamical thing, since they are not proving it
$$C_v= \left.\frac{\partial \langle H \rangle}{\partial T}\right|_{V,N}= \left.\frac{\partial U}{\partial T}\right|_{V,N} $$
H is the Hamiltonian of the system, and usually they put =E, where E is the energy, I think that they are not using U, to distinguish it from the thermodynamical internal energy, since when constructing the theory we don't know beforehand if they coincide, then we prove they do
I am not familiar with the second one, can it be proved using thermodynamics? How does one get from the first one to the second one?
 A: $c_v=\frac{1}{M}\frac{dQ}{dT}$ is an informal definition of heat capacity per unit of mass called specific heat capacity. Your statistic mechanical text defines heat capacity for the whole object, not per unit of mass. Usually "specific" version are written with lower case. I'll do this.
$$c_v=\frac{1}{M}\frac{dQ}{dT}$$
$Q$ is not a state function, $dQ$ is not a differential, you can't write something like $dQ$. You can only talk of $\delta Q$ for a certain transformation. Transformations that matter to define heat capacity are transformations at constant volume.
The first principle says : $dU=\delta Q+\delta W$. Strictly speaking, a transformation at constant volume cannot do work on a system: you can't do work on a gas without touching the piston. More generally, if no external variable the system's Hamiltonian depends on (here it is $V$ but it could be other variables) are allowed to change, the work is $\delta W=0$ by definition. Hence, any transformation at constant volume is such that $dU=\delta Q$.
Finally, you can define heat capacity as (here, you have state functions only and you don't need to say for what transformation.):
$$C_v=\frac{\partial U}{\partial T}|V$$
And the "per unit of mass" specific version:
$$c_v=\frac{1}{M}\frac{\partial U}{\partial T}|V$$
$\langle H\rangle=U$ by definition. The Hamiltonian is the energy (it's named "Hamiltonian" to say it's a function depending on the micro-state, while energy usually refers to a single numerical value). For example, you can say the micro-canonical ensemble is the set of micro states whose Hamiltonian (=energy) is equal to a certain value $U$. $U$ is the average if the energy is not precesily fixed (as in the canonical ensemble for example).
