<div dir="ltr">Thank you very much Ian,<div>Ivana</div><div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Mar 11, 2021 at 11:01 AM Fenty, Ian G (US 329C) <<a href="mailto:ian.fenty@jpl.nasa.gov">ian.fenty@jpl.nasa.gov</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi Ivana,<br>
<br>
>> I want to calculate the potential density relative to the surface using ECCO output (THETA and SALT fields....) and "density.m" function from gcmfaces, where "p" is the depth of tracer points, do I specify pref=0, and the potential density is given by rhop, as: [rhop,rhpis,rhor] = density(t(:),s(:),p(:),pref(:));<br>
<br>
That's what I would do. You do have some choices about what to use for pressure. You could directly convert model z depth to pressure in decibars or you could use the latitude-dependent pressure (e.g., the matlab seawater package 'sw_pres' from <a href="https://urldefense.com/v3/__http://globec.whoi.edu/globec-dir/CTDSoftware/SeaWater/__;!!Mih3wA!TM8nqsHsQgnfBzc5NYAL0p0QD2Gb0fHO7dBKqHXt1gf4lZAIhVnANq9fFXxvGZ-KXw$" rel="noreferrer" target="_blank">https://urldefense.com/v3/__http://globec.whoi.edu/globec-dir/CTDSoftware/SeaWater/__;!!Mih3wA!TM8nqsHsQgnfBzc5NYAL0p0QD2Gb0fHO7dBKqHXt1gf4lZAIhVnANq9fFXxvGZ-KXw$</a> ).<br>
<br>
In case you are not aware, there is a Matlab representation of the JMD95 eos here:<br>
<a href="https://urldefense.com/v3/__https://github.com/MITgcm/MITgcm/blob/master/utils/matlab/densjmd95.m__;!!Mih3wA!TM8nqsHsQgnfBzc5NYAL0p0QD2Gb0fHO7dBKqHXt1gf4lZAIhVnANq9fFXz13p2vfw$" rel="noreferrer" target="_blank">https://urldefense.com/v3/__https://github.com/MITgcm/MITgcm/blob/master/utils/matlab/densjmd95.m__;!!Mih3wA!TM8nqsHsQgnfBzc5NYAL0p0QD2Gb0fHO7dBKqHXt1gf4lZAIhVnANq9fFXz13p2vfw$</a> <br>
<br>
<br>
>> If following Iudicone et al. (2008), I want to estimate the equation of evolution of the locally referenced potential density defined at a reference pressure chosen as the local pressure pr, I get that by multiplying the temperature tendency equation by alpha, salt tendency equation by beta, and combine them. In doing so, is this a correct way to obtain alpha?<br>
>> alpha=sw_alpha(s(:),t(:),p(:),'ptmp'),<br>
>>where again s is obtained from the SALT fields, t from THETA and p is the depth of the tracer points.<br>
<br>
Yes, that is what I would do. Again, you could choose a different eos to calculate alpha. The eos used in the seawater package 'sw_alpha' routine seems to be same JMD: <a href="https://urldefense.com/v3/__https://www.mathworks.com/matlabcentral/mlc-downloads/downloads/submissions/47595/versions/12/previews/mixing_library/private1/seawater/sw_aonb.m/index.html?access_key=__;!!Mih3wA!TM8nqsHsQgnfBzc5NYAL0p0QD2Gb0fHO7dBKqHXt1gf4lZAIhVnANq9fFXzecweOEA$" rel="noreferrer" target="_blank">https://urldefense.com/v3/__https://www.mathworks.com/matlabcentral/mlc-downloads/downloads/submissions/47595/versions/12/previews/mixing_library/private1/seawater/sw_aonb.m/index.html?access_key=__;!!Mih3wA!TM8nqsHsQgnfBzc5NYAL0p0QD2Gb0fHO7dBKqHXt1gf4lZAIhVnANq9fFXzecweOEA$</a> <br>
<br>
-Ian<br>
<br>
<br>
<br>
_______________________________________________<br>
ecco-support mailing list<br>
<a href="mailto:ecco-support@mit.edu" target="_blank">ecco-support@mit.edu</a><br>
<a href="https://urldefense.com/v3/__http://mailman.mit.edu/mailman/listinfo/ecco-support__;!!Mih3wA!TM8nqsHsQgnfBzc5NYAL0p0QD2Gb0fHO7dBKqHXt1gf4lZAIhVnANq9fFXz3JRfbQw$" rel="noreferrer" target="_blank">https://urldefense.com/v3/__http://mailman.mit.edu/mailman/listinfo/ecco-support__;!!Mih3wA!TM8nqsHsQgnfBzc5NYAL0p0QD2Gb0fHO7dBKqHXt1gf4lZAIhVnANq9fFXz3JRfbQw$</a> <br>
</blockquote></div>