From the first law of thermodynamics we have
- Failed to parse (Conversion error. Server ("https://wikimedia.org/api/rest_") reported: "Cannot get mml. Server problem."): {\displaystyle \left.\delta Q\right.=dU+pdV}
the heat capacity is given by

At constant volume

where U is the internal energy, T is the temperature, and V is the volume.
At constant pressure

where p is the pressure.