[MITgcm-support] Confusion about Anelastic Option

Jean-Michel Campin jmc at mit.edu
Wed Feb 17 00:36:43 EST 2021


Hi Gage,

Sorry for not answering earlier but thank you for asking about these density profiles
since, indeed, there is not much documentation about this.

In general:
a) setting "rhoRefFile= ..." is the only way to turn on anelastic formualation and it's only used for that;
   the anelastic reference density profile is then loaded into a vector "rho1Ref".
   Note that at the very top, the model assumes that the density ratio is = 1, which is equivalent
   to anelastic reference density  = rhoConst.
b) tRef and sRef are used to initialize the model 3-D Potential Temperature and Salinity/Water-vapour field,
   unless a 3-D file is provided.
c) and depending on the EOS, tRef and sRef are used for various vertical profile calculation.

With Linear EOS, tRef and sRef have no "real" effects (but do affect machine truncation error), 
even though the density anomaly is computed  from the differences: (Theta - tRef) and (Salt - rRef).

With other EOS, tRef & sRef are used to compute a density profile "rhoRef", which can be used
in different places, e.g., to get a more accurate pressure input into the EOS (pRef4EOS) or
to get a stratification profile for solving internal gravity waves implicitly (using 3-D solver).
Since it's not for a single purpose, it was more convenient to always write out the small 
file "RhoRef.data/meta" (even when rhoRef was not used) rather than to write it only when  
rhoRef was used. But I think we can agree that with Linear EOS, RhoRef.data/meta are useless.

In your case, if you want to compare (a) anelastic simulation with (b) simple boussinesq simulation,
the simple way to do this would be:
for (a): to provide a density profile via "rhoRefFile= ..."  and rhoConst (for the very top).
and for (b): to provide just "rhoConst= ...".

Cheers,
Jean-Michel

On Fri, Jan 29, 2021 at 05:21:37PM +0000, Walters, Gage S. wrote:
> Hello all,
> 
> 
> 
> I have been trying to do a comparison between a simulation with and without the anelastic formulation and was wondering if someone could clarify a few things.
> 
> 
> 
> Looking through the documentation, one implements the anelastic option via rhoRefFile. The deep_anelastic example has this implementation:
> 
> 
> 
> # Continuous equation parameters
> 
> #-note: rhoRefFile is used to turn on the anelastic formulation
> 
> &PARM01
> 
> rhoRefFile='rhoLin_x2.bin',
> 
> tRefFile='TRefFile.bin',
> 
> .
> 
> .
> 
> rhoConst=1000.,
> 
> .
> 
> .
> 
> eosType='LINEAR',
> 
> 
> 
> In this example 'rhoLin_x2.bin' has variable density with depth, whereas 'TRefFile.bin' is a constant temperature profile. If the reference temperature is constant and my EOS is constant, then the 'RhoRef.data' and 'RhoRef.meta' are constant. In fact when you run the example those two files report a density of 999.8 when rhoConst is 1000 and a rhoRefFile is given.
> 
> 
> 
> Reading the Fortran code in the MITgcm/model/src/set_ref_state.F file, all rhoRefFile does is set rhoFacC and rhoFacF. I realize that this then scales the density in the adv equations. However, I am confused why this does not change the rho reference of the output. I see that it doesn't do that in the code, so maybe I am misunderstanding the difference between the reference density set from the EOS and the reference density file I give the code.
> 
> 
> 
> Is it not fair to do a comparison where
> 
> 
> 
> 1.       I vary the reference temperature with depth (salinity constant) and use the linear EOS to get my density versus depth.
> 
> 2.       Use that same density versus depth output from RhoRef.data as my rhoRefFile.bin and turn off my EOS.
> 
> 
> 
> Or in the second option do I still need to give it the varying temperature profile AND the varying rhoRefFile.bin.
> 
> 
> 
> Some explanation would be greatly appreciated.
> 
> 
> 
> All the best,
> 
> Gage
> 

> _______________________________________________
> MITgcm-support mailing list
> MITgcm-support at mitgcm.org
> http://mailman.mitgcm.org/mailman/listinfo/mitgcm-support



More information about the MITgcm-support mailing list