[MITgcm-support] user-defined diagnostic filled with zeros
Jean-Michel Campin
jmc at ocean.mit.edu
Wed Aug 5 15:37:24 EDT 2015
Hi Alexandre,
I don't see any problem in the modifications you describe here.
Are you sure that the CPP-option "CAR_DISS" is #define in your DIC_OPTIONS.h
(since in the default option file, i.e, pkg/dic/DIC_OPTIONS.h, it is #undef) ?
Might be safer to move the call to DIAGNOSTICS_FILL you added
just after the ENDIF following CALCITE_SATURATION, within the
#ifdef CAR_DISS ... #endif bloc
so that this new diagnostics would be filled up only when CAR_DISS is defined.
Cheers,
Jean-Michel
On Wed, Aug 05, 2015 at 07:58:34PM +0200, Alexandre Pohl wrote:
> Dear all,
>
> I am using a coupled configuration of the MITgcm with the pkg/DIC and pkg/diagnostics enabled. I would like to add a new diagnostic to the permanent set of diagnostics of the model: 'omegaC' (computed in 'dic/calcite_saturation.F').
>
> I followed the instructions from the guidebook (http://mitgcm.org/public/r2_manual/latest/online_documents/node269.html):
>
> 1] First, I define the new diagnostic in 'dic_diagnostics_init.F' :
>
> diagName = 'OMEGAC '
> diagTitle = 'Calcite Omega '
> diagUnits = 'dimensionless '
> diagCode = 'SMRP MR '
> CALL DIAGNOSTICS_ADDTOLIST( diagNum,
> I diagName, diagCode, diagUnits, diagTitle, 0, myThid )
>
> 2] Then, I call the 'DIAGNOSTICS_FILL' routine in 'dic_biotic_forcing.F'.
>
> CALL DIAGNOSTICS_FILL(SURC ,'DICTFLX ',0,1 ,2,bi,bj,myThid) <==== one of pkg/DIC default diagnostics
> CALL DIAGNOSTICS_FILL(omegaC ,'OMEGAC ',0,Nr,1,bi,bj,myThid) <==== my new diag
> #ifdef ALLOW_O2
> CALL DIAGNOSTICS_FILL(SURO ,'DICOFLX ',0,1 ,2,bi,bj,myThid) <==== another pkg/DIC default diagnostic
>
> Compilation succeeds, the model runs and diagnostics are successfully written in the model output mdsio files. The problem is that the newly added diagnostic, OMEGAC, is filled with zeros. I guess that it has something to do with either 'diagCode' from step 1 (which I set to 'SMRP MR ' like for DICBIOA, which seemed to be correct after Table 7.1: http://mitgcm.org/public/r2_manual/latest/online_documents/node268.html), or with the bibjFlg from step 2 (which I set to 1 because omegaC is not modified in 'dic_biotic_forcing.F', following instructions given at the top of the same page).
>
> Could anyone tell me what I am doing wrong?
>
> Thanks!
> Alexandre
>
>
> _______________________________________________
> MITgcm-support mailing list
> MITgcm-support at mitgcm.org
> http://mitgcm.org/mailman/listinfo/mitgcm-support
More information about the MITgcm-support
mailing list