[Mitgcm-support] RE: about kpp & flt
mitgcm-support at dev.mitgcm.org
mitgcm-support at dev.mitgcm.org
Wed Jul 9 15:44:16 EDT 2003
Jean-Michel, just came across your KPP bug report.
Not sure if this is still relevant?
>> 1) I wonder if in a case where
>> the vertical profile of db/dz shows 2 minimum below dB_dz,
>> e.g., 1 in the mix layer, stratified just below, then very low
>> stratification (< dB_dz) at some depth in the deep ocean,
>> and finally stratified near the bottom ;
>> the first loop might capture the 2nd stratification and not the
>> 1rst one as the comment suggest "the shallowest depth ..."
I agree that this would be a problem.
I suggest replacing with something like:
c Determine mixed layer depth hMix as the shallowest depth at which
c dB/dz exceeds 5.2e-5 s^-2.
work1(i,j) = nzmax(i,j,bi,bj)
DO k = 1, Nr
IF ( work1(i,j) .EQ. nzmax(i,j,bi,bj) .AND.
& k .LT. nzmax(i,j,bi,bj) .AND.
& dbloc(i,j,k) / drC(k+1) .GT. dB_dz )
& work1(i,j) = k
END DO
>> 2) since dBdz1 has to be < dB_dz
>> dB_dz - dBdz1 > 0 ; MAX ( phepsi, dBdz2 - dBdz1 ) > 0
>> so that drF(k)*(dB_dz - dBdz1) /MAX ( phepsi, dBdz2 - dBdz1 )
>> is also > 0 ; rF(k) < 0 so that |zRef(i,j)| < |rF(k)|
>> and this does not seems logical to me.
>>
>> I would expect to find zRef(i,j) = rF(k) - drF(k) * ...
I think Patrick is right about the sign change.
This should be coded using rkFac (or ABS and SIGN)
to make the code robust to rF sign changes.
Dimitris
--
Dimitris Menemenlis menemenlis at jpl.nasa.gov
Jet Propulsion Lab, MS 300-323 tel: 818-354-1656
4800 Oak Grove Dr, Pasadena CA 91109 fax: 818-393-6720
More information about the MITgcm-support
mailing list