Solve the vertical diffusion equation implicitly using the
method of inverting a tridiagonal matrix as described in
Numerical Recipes in Fortran, The art of Scientific Computing,
Second Edition, Press, Teukolsky, Vetterling, Flannery, 1992
pages 42,43.
This routine assumes that the variables are defined at grid points,
and the top and bottom b.c. are flux conditions.
inputs:
z = right hand side terms
nk = number of vertical levels
topbc = top boundary condition
botbc = bottom boundary condition
dcb = vertical mixing coeff at base of cell
tdt = timestep over which do implicit update
kmz = level indicator
mask = land/sea mask
outputs:
z = returned solution
invtri_bmf
DESCRIPTION
Solve the vertical friction equation implicitly using the
method of inverting a tridiagonal matrix as described in
Numerical Recipes in Fortran, The art of Scientific Computing,
Second Edition, Press, Teukolsky, Vetterling, Flannery, 1992
pages 42,43.
This routine assumes that the variables are defined at grid points,
and the top b.c. is a flux condition. The bottom b.c. is assumed
to be a bottom drag which is implemented implicitly, thus allowing
for large values of the bottom drag coefficient.
NOTE: This routine is generally only called when doing the bmf
implicitly in time. The original invtri is used for explicit
bmf.
inputs:
z = right hand side terms
nk = number of vertical levels
topbc = top boundary condition
botbc = time explicit bottom boundary condition (zero in this routine, since bmf is implicit)
gamma = botttom drag factor scaling the u(taup1) contribution to bottom drag
dcb = vertical mixing coeff at base of cell
tdt = timestep over which do implicit update
kmz = level indicator
mask = land/sea mask
outputs:
z = returned solution
iplot
DESCRIPTION
map integer array "iarray" into characters for printing with
format (a1) to provide a contour map of the integer field.
note: max number of unique characters = 80
inputs:
iarray = integer array to be plotted
is = starting index along inner dimension of "iarray"
ie = ending index along inner dimension of "iarray"
js = starting index along outer dimension of "iarray"
je = ending index along outer dimension of "iarray"
output: prints contour map of "iarray"
matrix
DESCRIPTION
matrix is a general two-dimensional array printing routine,
input:
array = the array to be printed
istrt = the 1st element of the 1st dimension to be printed
im = the last element of the 1st dimension to be printed
jstrt = the 1st element of the 2nd dimension to be printed
jm = the last element of the 2nd dimension to be printed
the 2nd dimension is printed in reverse order if both
jstrt and jm are negative
scale = a scaling factor by which array is divided before
printing. (if this is zero, no scaling is done.)
if scale=0, 10 columns are printed across in e format
if scale>0, 20 columns are printed across in f format
output: print "array" as a matrix
write_timestamp
DESCRIPTION
Write the time stamp.
write_chksum_header
DESCRIPTION
Write the checksum header.
write_note
DESCRIPTION
Write a note.
write_warning
DESCRIPTION
Write a warning.
write_line
DESCRIPTION
Write a message.
write_chksum_3d
DESCRIPTION
Write a 3d checksum.
write_chksum_2d
DESCRIPTION
Write a 2d checksum.
write_chksum_2d_int
DESCRIPTION
Write a 2d integer checksum.
check_restart
DESCRIPTION
Write a note regarding the restart setup.
write_summary
DESCRIPTION
Write a summary note.
diagnose_3d
DESCRIPTION
Helper function for diagnosting 3D data using the grid tmask.
diagnose_2d
DESCRIPTION
Helper function for diagnosting 2D data using the grid tmask.
diagnose_2d_int
DESCRIPTION
Helper function for diagnosting 2D data using the grid tmask.
diagnose_3d_int
DESCRIPTION
Helper function for diagnosting 3D data using the grid tmask.