Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] derivation of thetaot300 and thetaot700 #373

Open
YanchunHe opened this issue Feb 5, 2025 · 1 comment · Fixed by #375
Open

[BUG] derivation of thetaot300 and thetaot700 #373

YanchunHe opened this issue Feb 5, 2025 · 1 comment · Fixed by #375

Comments

@YanchunHe
Copy link
Collaborator

Describe the bug
cite H.Pohlmann

I am trying to compare thetaot300 and thetaot700 for OHC between MPI-ESM1-2-LR and NorESM2-LM. I had expected the values to be similar to the SST data. However, the data from the NorESM2-LM model are mainly between -1 and 3 deg C. Are theses anomalies? Against which mean?

To Reproduce
...

Additional context
cite I.Bethke

I can confirm the problem and suspect a bug in the post-processing that vertically integrates. The code in question is https://github.com/NorESMhub/noresm2cmor/blob/master/source/m_modelsocn.F , lines 1517-1540:

c --- - Average over upper 300 m
        CASE ('dzavg300')
          fldtmp=1e20
          DO j=1,jj
            DO i=1,ii
              IF (fld(i,j,1).NE.1e20) THEN
                fldtmp(i,j,1)= (min(300.,pdepth(i,j),depth_bnds(2,1))
     .                         -min(300.,pdepth(i,j),depth_bnds(1,1)))
     .                         *pbot(i,j)/pdepth(i,j)
                fld(i,j,1)=fld(i,j,1)*fldtmp(i,j,1)
              END IF
              DO k=2,kk
                IF (fld(i,j,k).NE.1e20) THEN
                  fldtmp(i,j,k)= (min(300.,pdepth(i,j),depth_bnds(2,k))
     .                           -min(300.,pdepth(i,j),depth_bnds(1,k)))
     .                           *pbot(i,j)/pdepth(i,j)
                  fld(i,j,k)=fld(i,j,k-1)+fld(i,j,k)*fldtmp(i,j,k)
                  fldtmp(i,j,1)=fldtmp(i,j,1)+fldtmp(i,j,k)
                ENDIF
              ENDDO
              IF (fld(i,j,1).NE.1e20)
     .          fld(i,j,1)=fld(i,j,1)/fldtmp(i,j,1)
            ENDDO
          ENDDO  
! I think
                  fld(i,j,k)=fld(i,j,k-1)+fld(i,j,k)*fldtmp(i,j,k)
! needs to be changed to
                  fld(i,j,1)=fld(i,j,1)+fld(i,j,k)*fldtmp(i,j,k)
@YanchunHe
Copy link
Collaborator Author

@monsieuralok

Could you please retract all thetao300, thetao700 and thetao2000 for all model versions and experiments?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants