Subroutine CalcCleanup() != Clean up (e.g. via deallocation) mess from Calc routines. character(*), parameter :: this_routine = 'CalcCleanup' if(allocated(MCDet)) deallocate(MCDet) call LogMemDealloc(this_routine, tagMCDet) if (allocated(user_input_seed)) deallocate(user_input_seed) if (allocated(user_input_SftDamp)) deallocate(user_input_SftDamp) End Subroutine CalcCleanup