# Where does the relation $u=h_f-RT+(c_p-R)(T-T_0)$ come from?

I'm working on a college project for a subject called Motorcycle Engineering, and in this project I'm supposed to do some reverse engineering on a MATLAB program to model the engine of the motorcycle. In this program I just came across the following expression: $$u=h_f-RT+(c_p-R)(T-T_0)$$ where $u$ is the specific internal energy, $h_f$ is the enthalpy of formation per unit mol, $c_p$ is the constant pressure specific heat, $T$ is the temperature, $T_0$ is the room temperature and $R$ is the gas constant.

Does anybody know where does it come from?

-