What is thermal energy?

Thermal energy is the energy of motion of the atoms or molecules within a quantity of matter. Thus it is the energy associated with the temperature of matter.