stop_macro.F90 1.39 KB
 kbk committed Mar 01, 2006 1 !$Id: stop_macro.F90,v 1.6 2006-03-01 15:54:08 kbk Exp$ gotm committed May 02, 2002 2 3 4 5 #include "cppdefs.h" !----------------------------------------------------------------------- !BOP ! hb committed Mar 01, 2006 6 ! !ROUTINE: stop_macro - terminates the macro loop \label{sec-stop-macro} gotm committed May 02, 2002 7 8 9 10 11 12 ! ! !INTERFACE: subroutine stop_macro ! ! !DESCRIPTION: ! hb committed Mar 01, 2006 13 14 15 16 17 18 ! This routine should be called from {\tt m3d} at the end of each macro ! time step in order to copy the vertically interated and temporally ! averaged transports to old values {\tt Uinto} and {\tt Vinto}, and ! to reinitialise the transports {\tt Uint} and {\tt Vint} ! to zero. ! gotm committed May 02, 2002 19 ! !USES: kbk committed Apr 07, 2003 20 use variables_2d, only: Uint,Uinto,Vint,Vinto gotm committed May 02, 2002 21 22 23 24 25 26 27 28 IMPLICIT NONE ! ! !INPUT PARAMETERS: ! ! !INPUT/OUTPUT PARAMETERS: ! ! !OUTPUT PARAMETERS: ! kbk committed Mar 01, 2006 29 30 31 ! !REVISION HISTORY: ! Original author(s): Hans Burchard & Karsten Bolding ! gotm committed May 02, 2002 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 ! !LOCAL VARIABLES: !EOP !----------------------------------------------------------------------- !BOC #ifdef DEBUG integer, save :: Ncall = 0 Ncall = Ncall+1 write(debug,*) 'stop_macro() # ',Ncall #endif Uinto=Uint Uint= _ZERO_ Vinto=Vint Vint= _ZERO_ #ifdef DEBUG write(debug,*) 'Leaving stop_macro()' write(debug,*) #endif return end subroutine stop_macro !EOC !----------------------------------------------------------------------- ! Copyright (C) 2001 - Hans Burchard and Karsten Bolding ! !-----------------------------------------------------------------------