Explain the transfer of thermal energy occurring in each situation?