[MITgcm-support] MDSWRITEFIELD, diagnostic package , interface elevation

Martin Losch Martin.Losch at awi.de
Wed Dec 27 06:05:31 EST 2006


Riema,

sorry for the multiple emails:

On 27 Dec 2006, at 04:53, Riema Rachmayani wrote:
> by the way, i've seen diagnostic package you've told me...specially  
> diagnostic_main_init.F and diagnostic_out.F, but i dont know how to  
> modify the routines, i do not familiar with the syntax/code/ 
> variables, for example i'd like to write out OBWu profiles at each  
> time step in an output file. Can you give me the steps?? what  
> routines i should modify??
The diagnostics package is really nice for all sorts of diagnostics.  
The diagnostics_main_init.F contains a list of the diagnostics that  
are available for the main code. Each package has a  
$pkg_diagnostics_init.F (e.g. exf_diagnostics_init.F) which does the  
same for the individual package. Unfortunately, obcs does not have  
such a file. You could try to create your own obcs_diagnostics_init.F  
by analogy from a $pkg_diagnostics_init.F Then you'll also have to  
create a obcs_diagnostics_fill.F which actually assigns value to the  
diagnostics values. However, I don't know if this works for the xz/ 
yz-2d fields of the obcs package.

Alternatively you could modify the file obcs_diags.F which is called  
from do_the_model_io.F to include you "diagnostics" (this means  
bypassing the diagnostics-pkg altogether, and I am not sure I should  
recommend that). This is my suggestion for a quick HACK:
In obcs_diags.F you could replace a line like
         CALL PLOT_FIELD_YZRL( OBWu, 'OBWu' , Nr, myIter, mythid )
which plots output to stdout by
           WRITE(suff,'(I10.10)') myIter
           CALL WRITE_FLD_YZ_RL( 'OBCWu.',suff,OBWu,myIter,myThid)
(see write_state.F for examples of "regular" 2D and 3D fields). You  
can then hardwire the output frequency to "every timestep" by  
commenting the if-statement:
>       IF (
>      &  DIFFERENT_MULTIPLE(dumpFreq,myCurrentTime,deltaTClock)
>      &  .AND. OBCSprintDiags
>      & ) THEN
Again, all of this is a hack and I do not recommened it for general use.


> what variable for D (total depth)=H (bathymetri depth)+ eta  
> (elevation) in MITgcm??
>
> do you know about Eta output file in internal wave verification??  
> it shows free surface elevation or interface elevation??
Eta is the "surface pressure anomaly", that is for z-coordinates  
(internal wave experiment) is the surface elevation relative to z=0.  
So, if you want the total depth of the water column, add Eta to the  
abs(bathymetry).

Martin




More information about the MITgcm-support mailing list