merc_calc() finished

finished coding merc_calc() and tested