/[MITgcm]/MITgcm/pkg/diagnostics/diagnostics_setunits.F
ViewVC logotype

Annotation of /MITgcm/pkg/diagnostics/diagnostics_setunits.F

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.10 - (hide annotations) (download)
Sat Jan 16 22:29:54 2010 UTC (14 years, 5 months ago) by jmc
Branch: MAIN
CVS Tags: HEAD
Changes since 1.9: +1 -1 lines
FILE REMOVED
remove unused S/R (DIAGNOSTICS_ADDTOLIST replaces DIAGNOSTICS_ADD2LIST)

1 jmc 1.10 C $Header: /u/gcmpack/MITgcm/pkg/diagnostics/diagnostics_setunits.F,v 1.9 2008/02/05 15:31:19 jmc Exp $
2 edhill 1.3 C $Name: $
3    
4 edhill 1.4 #include "DIAG_OPTIONS.h"
5    
6 edhill 1.5 C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----|
7     CBOP 0
8     C !ROUTINE: DIAGNOSTICS_SETUNITS
9    
10     C !INTERFACE:
11     SUBROUTINE DIAGNOSTICS_SETUNITS (
12     I myThid,
13 jmc 1.9 I chardiag,
14 edhill 1.5 I diagunits )
15    
16     C !DESCRIPTION:
17     C Wrapper routine to set the units of an active diagnostic
18 jmc 1.9
19 edhill 1.5 C !USES:
20 molod 1.1 implicit none
21 jmc 1.8 #include "EEPARAMS.h"
22 molod 1.1 #include "SIZE.h"
23 jmc 1.6 #include "DIAGNOSTICS_SIZE.h"
24     #include "DIAGNOSTICS.h"
25 molod 1.1
26 edhill 1.5 C !INPUT PARAMETERS:
27 molod 1.1 integer myThid
28 edhill 1.5 character*8 chardiag
29     character*16 diagunits
30     CEOP
31 molod 1.1
32 edhill 1.5 C Local variables
33 molod 1.1 integer n, ndiagnum, ipointer
34    
35 edhill 1.5 C Run through list of active diagnostics to make sure
36     C we are trying to fill a valid diagnostic
37 jmc 1.9
38 molod 1.1 ndiagnum = 0
39     ipointer = 0
40     do n = 1,ndiagt
41 edhill 1.5 if(chardiag.eq.cdiag(n)) then
42     ndiagnum = n
43 jmc 1.7 c ipointer = idiag(n)
44 edhill 1.5 endif
45 molod 1.1 enddo
46     if( ndiagnum.ne.0 .and. ipointer.ne.0 ) then
47 edhill 1.5 udiag(ndiagnum)=diagunits
48 molod 1.1 else
49 edhill 1.5 write(6,1000)chardiag
50 molod 1.1 endif
51 jmc 1.9
52 edhill 1.5 1000 format(' ',' Warning: Trying to set units of diagnostic ',a8,
53     & ' But it is not a valid (or active) name ')
54 molod 1.1
55     return
56     end

  ViewVC Help
Powered by ViewVC 1.1.22