Calculation of final temperature in a heat transfer process