<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Windows-1252">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div class="elementToProof"><span style="font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">Hi Paul,</span></div>
<div><span style="font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);"><br>
</span></div>
<div class="elementToProof"><span style="font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">I computed the 3D Smagorinsky coefficient by accounting for the buoyancy last winter.
I attach the files mom_calc_smag_3d.F, mom_diagnostics_init.F, MOM_COMMON_OPTIONS.h and CPP_OPTIONS.h. In CPP_OPTIONS.h, I defined a flag to include or not the buoyancy in the calculation of the 3D Smagorinsky coefficient.</span></div>
<div><span style="font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);"><br>
</span></div>
<div><span style="font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">I hope it helps.</span></div>
<div><span style="font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);"><br>
</span></div>
<div><span style="font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">Cheers,</span></div>
<div><span style="font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);"><br>
</span></div>
<div class="elementToProof"><span style="font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">Sandy</span></div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>De :</b> MITgcm-support <mitgcm-support-bounces@mitgcm.org> de la part de Burns, Paul <P.Burns2@exeter.ac.uk><br>
<b>Envoyé :</b> vendredi 8 décembre 2023 08:34<br>
<b>À :</b> mitgcm-support@mitgcm.org <mitgcm-support@mitgcm.org><br>
<b>Objet :</b> Re: [MITgcm-support] Vertical diffusion for non-hydrostatic ocean model with a stretched grid</font>
<div> </div>
</div>
<style type="text/css" style="display:none">
<!--
p
{margin-top:0;
margin-bottom:0}
-->
</style>
<div dir="ltr">
<table border="0" cellspacing="0" cellpadding="0" align="left" width="100%">
<tbody>
<tr>
<td style="background:#ff0000; padding:5pt 2pt 5pt 2pt"></td>
<td width="100%" cellpadding="7px 6px 7px 15px" style="background:#ffe0e0; padding:5pt 4pt 5pt 12pt; word-wrap:break-word">
<div style="color:#000000"><span style="color:#000000; font-weight:bold">ATTENTION :</span>
<span style="color:#000000; font-size:10.0pt">Ce courriel provient d'une source externe. Assurez-vous que cette dernière est sûre avant d'ouvrir une pièce jointe ou de cliquer sur un lien. Dans le doute, signalez le message.
</span></div>
</td>
</tr>
</tbody>
</table>
<br>
<div>
<div class="x_elementToProof" style="font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Hi Martin,</div>
<div class="x_elementToProof" style="font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div class="x_elementToProof" style="font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Ok that is great. I'll have a go and get back to you. </div>
<div class="x_elementToProof" style="font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div class="x_elementToProof" style="font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Many thanks,</div>
<div class="x_elementToProof" style="font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Paul</div>
<div class="x_elementToProof" style="font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div id="x_Signature">
<div><span style="font-family:Calibri,sans-serif; font-size:14.6667px; color:rgb(12,100,192); background-color:rgb(255,255,255)"><u> </u></span></div>
<div><span style="font-family:Calibri,sans-serif; font-size:14.6667px; color:rgb(23,78,134); background-color:rgb(255,255,255)">Dr Paul Burns MInstP FRMetS</span></div>
<div><span style="font-family:Calibri,sans-serif; font-size:14.6667px; color:rgb(23,78,134)">Associate Research Fellow</span></div>
<div><span style="font-family:Calibri,sans-serif; font-size:14.6667px; color:rgb(23,78,134)">& </span></div>
<div><span style="font-family:Calibri,Helvetica,sans-serif; font-size:11pt; color:rgb(23,78,134)">Senior Scientist</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<span style="font-size:11pt; color:rgb(23,78,134)">Atmospheric Processes and Parametrisation (APP)</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<span style="font-size:11pt; color:rgb(23,78,134)">Met Office</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<span style="font-size:11pt; color:rgb(23,78,134)">Exeter</span></div>
</div>
<div id="x_appendonsend"></div>
<hr tabindex="-1" style="display:inline-block; width:98%">
<div id="x_divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" color="#000000" style="font-size:11pt"><b>From:</b> MITgcm-support <mitgcm-support-bounces@mitgcm.org> on behalf of Martin Losch <Martin.Losch@awi.de><br>
<b>Sent:</b> 08 December 2023 12:46<br>
<b>To:</b> MITgcm Support <mitgcm-support@mitgcm.org><br>
<b>Subject:</b> Re: [MITgcm-support] Vertical diffusion for non-hydrostatic ocean model with a stretched grid</font>
<div> </div>
</div>
<div style="line-break:after-white-space">
<div style="background-color:#FFEB9C; width:100%; border-style:solid; border-color:#9C6500; border-width:1pt; padding:2pt; font-size:10pt; line-height:12pt; font-family:'Calibri'; color:Black; text-align:left">
<span style="color:#9C6500; font-weight:bold">CAUTION:</span> This email originated from outside of the organisation. Do not click links or open attachments unless you recognise the sender and know the content is safe.</div>
<br>
<div>Hi Paul,
<div><br>
</div>
<div>if you need that functionality, it should be relatively easy for you to add:</div>
<div>- in the header file “DYNVARS.h”, there’s already the global sigmaRfield, just need to change/remove the CPP-flags</div>
<div>- velocities are available via DYNVARS.h, too, so that it should be straightforward to compute N2/dVdz from that, similarly to what’s done in pkg/ggl90/ggl90_calc.F</div>
<div><br>
</div>
<div>Martin</div>
<div>
<div><br>
<blockquote type="cite">
<div>On 8. Dec 2023, at 12:55, Burns, Paul <P.Burns2@exeter.ac.uk> wrote:</div>
<br class="x_x_Apple-interchange-newline">
<div>
<div style="margin-top:0px; margin-bottom:0px; font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<span style="font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">Ok that's easier then. I believe the Richardson number function could be added to the code where the Smagorinsky viscosity is computed at some
k-level in</span></div>
<div class="x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
<br>
</div>
<div style="margin-top:0px; margin-bottom:0px; font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<span style="font-family:Menlo; font-size:11px">mom_calc_smag_3d.F</span></div>
<div style="margin-top:0px; margin-bottom:0px; font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<span style="font-family:Menlo; font-size:11px"><br>
</span></div>
<div style="margin-top:0px; margin-bottom:0px; font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<br>
</div>
<div style="margin-top:0px; margin-bottom:0px; font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<span style="font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif">Many thanks,</span></div>
<div style="margin-top:0px; margin-bottom:0px; font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<span style="font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif">Paul</span></div>
<div class="x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
<br>
</div>
<div id="x_x_Signature" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<div><span style="font-family:Calibri,sans-serif; font-size:14.6667px; color:rgb(12,100,192); background-color:rgb(255,255,255)"><u> </u></span></div>
<div><span style="font-family:Calibri,sans-serif; font-size:14.6667px; color:rgb(23,78,134); background-color:rgb(255,255,255)">Dr Paul Burns MInstP FRMetS</span></div>
<div><span style="font-family:Calibri,sans-serif; font-size:14.6667px; color:rgb(23,78,134)">Associate Research Fellow</span></div>
<div><span style="font-family:Calibri,sans-serif; font-size:14.6667px; color:rgb(23,78,134)">& </span></div>
<div><span style="font-family:Calibri,Helvetica,sans-serif; font-size:11pt; color:rgb(23,78,134)">Senior Scientist</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt"><span style="font-size:11pt; color:rgb(23,78,134)">Atmospheric Processes and Parametrisation (APP)</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt"><span style="font-size:11pt; color:rgb(23,78,134)">Met Office</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt"><span style="font-size:11pt; color:rgb(23,78,134)">Exeter</span></div>
</div>
<div id="x_x_appendonsend" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
</div>
<hr tabindex="-1" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; display:inline-block; width:1025.078125px">
<span style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; float:none; display:inline!important"></span>
<div id="x_x_divRplyFwdMsg" dir="ltr" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<font face="Calibri, sans-serif" style="font-size:11pt"><b>From:</b><span class="x_x_Apple-converted-space"> </span>MITgcm-support <<a href="mailto:mitgcm-support-bounces@mitgcm.org">mitgcm-support-bounces@mitgcm.org</a>> on behalf of Martin Losch <<a href="mailto:Martin.Losch@awi.de">Martin.Losch@awi.de</a>><br>
<b>Sent:</b><span class="x_x_Apple-converted-space"> </span>08 December 2023 10:49<br>
<b>To:</b><span class="x_x_Apple-converted-space"> </span>MITgcm Support <<a href="mailto:mitgcm-support@mitgcm.org">mitgcm-support@mitgcm.org</a>><br>
<b>Subject:</b><span class="x_x_Apple-converted-space"> </span>Re: [MITgcm-support] Vertical diffusion for non-hydrostatic ocean model with a stretched grid</font>
<div> </div>
</div>
<div style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; line-break:after-white-space">
<div style="background-color:rgb(255,235,156); width:1046px; border-style:solid; border-color:rgb(156,101,0); border-width:1pt; padding:2pt; font-size:10pt; line-height:12pt; font-family:Calibri; text-align:left">
<span style="color:rgb(156,101,0); font-weight:bold">CAUTION:</span><span class="x_x_Apple-converted-space"> </span>This email originated from outside of the organisation. Do not click links or open attachments unless you recognise the sender and know the content
is safe.</div>
<br>
<div>There are plenty of places, where Ri-numbers are computed, e.g. in pkg/ggl90/ggl90_calc.F, or even full routines, e.g. pkg/pp81/pp81_ri_number.F (although when that was written the vertical gradient of density SigmaRw as not availalbe).
<div><br>
</div>
<div>In which routine would you need the Ri-number exactly?</div>
<div><br>
</div>
<div>Martin<br id="x_x_x_lineBreakAtBeginningOfMessage">
<div><br>
<blockquote type="cite">
<div>On 8. Dec 2023, at 11:20, Burns, Paul <P.Burns2@exeter.ac.uk> wrote:</div>
<br class="x_x_x_Apple-interchange-newline">
<div>
<div class="x_x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
Hi Martin,</div>
<div class="x_x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
<br>
</div>
<div class="x_x_x_elementToProof" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<span style="font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">A quick message to thank you for your help with this. I've found the fortran file where<span class="x_x_x_Apple-converted-space"> </span></span><span style="letter-spacing:normal; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt; font-weight:400">smag3D_coeff</span></div>
<div class="x_x_x_elementToProof" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; text-align:left; margin:0px; background-color:rgb(255,255,255)">
<span style="letter-spacing:normal; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt; font-weight:400">(and smag3Ddiff_coeff) are used to compute the viscosity (diffusivity), so hopefully I can work through
the code and compare that with a relevant paper about using the Smagorinsky-Lilly model in the ocean to figure out what the values of<span class="x_x_x_Apple-converted-space"> </span></span><span style="letter-spacing:normal; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:16px; font-weight:400; background-color:rgb(255,255,255)">smag3D_coeff</span><span style="letter-spacing:normal; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt; font-weight:400"> and<span class="x_x_x_Apple-converted-space"> </span></span><span style="letter-spacing:normal; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:16px; font-weight:400; background-color:rgb(255,255,255)">smag3Ddiff_coeff</span><span style="letter-spacing:normal; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt; font-weight:400"> should
be in MITgcm. </span></div>
<div class="x_x_x_elementToProof" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; text-align:left; margin:0px; background-color:rgb(255,255,255)">
<span style="letter-spacing:normal; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt; font-weight:400"><br>
</span></div>
<div class="x_x_x_elementToProof" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; text-align:left; margin:0px; background-color:rgb(255,255,255)">
<span style="letter-spacing:normal; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt; font-weight:400">It might be useful to add a Richardson number function to the existing 3D Smagorinsky model in MITgcm
to try and account for buoyancy effects, but not sure how tricky that will be. Mathematically it's straightforward. I'd need to pass relevant variables to calculate a local Richardson number and I'd need to first find a reasonable Richardson number function
for the ocean. Not sure if anyone has tried this already?</span></div>
<div class="x_x_x_elementToProof" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; text-align:left; margin:0px; background-color:rgb(255,255,255)">
<span style="letter-spacing:normal; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt; font-weight:400"><br>
</span></div>
<div class="x_x_x_elementToProof" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; text-align:left; margin:0px; background-color:rgb(255,255,255)">
<span style="letter-spacing:normal; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt; font-weight:400">Cheers,</span></div>
<div class="x_x_x_elementToProof" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; text-align:left; margin:0px; background-color:rgb(255,255,255)">
<span style="letter-spacing:normal; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt; font-weight:400">Paul</span></div>
<div class="x_x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
<br>
</div>
<div id="x_x_x_Signature" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<div><span style="font-family:Calibri,sans-serif; font-size:14.6667px; color:rgb(12,100,192); background-color:rgb(255,255,255)"><u> </u></span></div>
<div><span style="font-family:Calibri,sans-serif; font-size:14.6667px; color:rgb(23,78,134); background-color:rgb(255,255,255)">Dr Paul Burns MInstP FRMetS</span></div>
<div><span style="font-family:Calibri,sans-serif; font-size:14.6667px; color:rgb(23,78,134)">Associate Research Fellow</span></div>
<div><span style="font-family:Calibri,sans-serif; font-size:14.6667px; color:rgb(23,78,134)">& </span></div>
<div><span style="font-family:Calibri,Helvetica,sans-serif; font-size:11pt; color:rgb(23,78,134)">Senior Scientist</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt"><span style="font-size:11pt; color:rgb(23,78,134)">Atmospheric Processes and Parametrisation (APP)</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt"><span style="font-size:11pt; color:rgb(23,78,134)">Met Office</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt"><span style="font-size:11pt; color:rgb(23,78,134)">Exeter</span></div>
</div>
<div id="x_x_x_appendonsend" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
</div>
<hr tabindex="-1" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; display:inline-block; width:1025.078125px">
<span style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; float:none; display:inline!important"></span>
<div id="x_x_x_divRplyFwdMsg" dir="ltr" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<font face="Calibri, sans-serif" style="font-size:11pt"><b>From:</b><span class="x_x_x_Apple-converted-space"> </span>MITgcm-support <<a href="mailto:mitgcm-support-bounces@mitgcm.org">mitgcm-support-bounces@mitgcm.org</a>> on behalf of Martin Losch <<a href="mailto:Martin.Losch@awi.de">Martin.Losch@awi.de</a>><br>
<b>Sent:</b><span class="x_x_x_Apple-converted-space"> </span>01 December 2023 06:51<br>
<b>To:</b><span class="x_x_x_Apple-converted-space"> </span>MITgcm Support <<a href="mailto:mitgcm-support@mitgcm.org">mitgcm-support@mitgcm.org</a>><br>
<b>Subject:</b><span class="x_x_x_Apple-converted-space"> </span>Re: [MITgcm-support] Vertical diffusion for non-hydrostatic ocean model with a stretched grid</font>
<div> </div>
</div>
<div style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; line-break:after-white-space">
<div style="background-color:rgb(255,235,156); width:1046px; border-style:solid; border-color:rgb(156,101,0); border-width:1pt; padding:2pt; font-size:10pt; line-height:12pt; font-family:Calibri; text-align:left">
<span style="color:rgb(156,101,0); font-weight:bold">CAUTION:</span><span class="x_x_x_Apple-converted-space"> </span>This email originated from outside of the organisation. Do not click links or open attachments unless you recognise the sender and know the
content is safe.</div>
<br>
<div>Hi Paul,
<div><br>
</div>
<div>I have no experience with the Smag3D code and don’t have any suggestions for setting the coefficients, but this is what I do to find code:</div>
<div><br>
</div>
<div>Compile the experiment that uses the code (here: tutorial_deep_convection), in fact, just the genmake2 and make depend steps are enough, then you have all necessary code in the build directory and you can grep for useSmag3D (or ALLOW_SMAG_3D). This gives
me:</div>
<div>
<div style="margin:0px; font-style:normal; font-variant-caps:normal; font-stretch:normal; font-size:11px; line-height:normal; font-family:Menlo; font-size-adjust:none; font-kerning:auto; font-variant-alternates:normal; font-variant-ligatures:normal; font-variant-numeric:normal; font-variant-east-asian:normal; font-feature-settings:normal">
<span style="font-variant-ligatures:no-common-ligatures">>> grep -i useSmag3D *.F</span></div>
<div style="margin:0px; font-style:normal; font-variant-caps:normal; font-stretch:normal; font-size:11px; line-height:normal; font-family:Menlo; font-size-adjust:none; font-kerning:auto; font-variant-alternates:normal; font-variant-ligatures:normal; font-variant-numeric:normal; font-variant-east-asian:normal; font-feature-settings:normal">
<span style="font-variant-ligatures:no-common-ligatures">calc_gw.F: IF ( useSmag3D .AND. k.GT.1 ) THEN</span></div>
<div style="margin:0px; font-style:normal; font-variant-caps:normal; font-stretch:normal; font-size:11px; line-height:normal; font-family:Menlo; font-size-adjust:none; font-kerning:auto; font-variant-alternates:normal; font-variant-ligatures:normal; font-variant-numeric:normal; font-variant-east-asian:normal; font-feature-settings:normal">
<span style="font-variant-ligatures:no-common-ligatures">config_check.F: IF ( useSmag3D ) THEN</span></div>
<div style="margin:0px; font-style:normal; font-variant-caps:normal; font-stretch:normal; font-size:11px; line-height:normal; font-family:Menlo; font-size-adjust:none; font-kerning:auto; font-variant-alternates:normal; font-variant-ligatures:normal; font-variant-numeric:normal; font-variant-east-asian:normal; font-feature-settings:normal">
<span style="font-variant-ligatures:no-common-ligatures">config_check.F: & 'Cannot set useSmag3D=TRUE when compiled with'</span></div>
<div style="margin:0px; font-style:normal; font-variant-caps:normal; font-stretch:normal; font-size:11px; line-height:normal; font-family:Menlo; font-size-adjust:none; font-kerning:auto; font-variant-alternates:normal; font-variant-ligatures:normal; font-variant-numeric:normal; font-variant-east-asian:normal; font-feature-settings:normal">
<span style="font-variant-ligatures:no-common-ligatures">config_check.F: & useSmag3D .AND. useCDscheme ) THEN</span></div>
<div style="margin:0px; font-style:normal; font-variant-caps:normal; font-stretch:normal; font-size:11px; line-height:normal; font-family:Menlo; font-size-adjust:none; font-kerning:auto; font-variant-alternates:normal; font-variant-ligatures:normal; font-variant-numeric:normal; font-variant-east-asian:normal; font-feature-settings:normal">
<span style="font-variant-ligatures:no-common-ligatures">config_check.F: IF ( useSmag3D .AND.</span></div>
<div style="margin:0px; font-style:normal; font-variant-caps:normal; font-stretch:normal; font-size:11px; line-height:normal; font-family:Menlo; font-size-adjust:none; font-kerning:auto; font-variant-alternates:normal; font-variant-ligatures:normal; font-variant-numeric:normal; font-variant-east-asian:normal; font-feature-settings:normal">
<span style="font-variant-ligatures:no-common-ligatures">config_summary.F: CALL WRITE_0D_L( useSmag3D, INDEX_NONE,</span></div>
<div style="margin:0px; font-style:normal; font-variant-caps:normal; font-stretch:normal; font-size:11px; line-height:normal; font-family:Menlo; font-size-adjust:none; font-kerning:auto; font-variant-alternates:normal; font-variant-ligatures:normal; font-variant-numeric:normal; font-variant-east-asian:normal; font-feature-settings:normal">
<span style="font-variant-ligatures:no-common-ligatures">config_summary.F: & 'useSmag3D =', ' /* Use isotropic 3-D Smagorinsky viscosity */')</span></div>
<div style="margin:0px; font-style:normal; font-variant-caps:normal; font-stretch:normal; font-size:11px; line-height:normal; font-family:Menlo; font-size-adjust:none; font-kerning:auto; font-variant-alternates:normal; font-variant-ligatures:normal; font-variant-numeric:normal; font-variant-east-asian:normal; font-feature-settings:normal">
<span style="font-variant-ligatures:no-common-ligatures">config_summary.F: IF ( useSmag3D )</span></div>
<div style="margin:0px; font-style:normal; font-variant-caps:normal; font-stretch:normal; font-size:11px; line-height:normal; font-family:Menlo; font-size-adjust:none; font-kerning:auto; font-variant-alternates:normal; font-variant-ligatures:normal; font-variant-numeric:normal; font-variant-east-asian:normal; font-feature-settings:normal">
<span style="font-variant-ligatures:no-common-ligatures">dynamics.F: IF ( useSmag3D ) THEN</span></div>
<div style="margin:0px; font-style:normal; font-variant-caps:normal; font-stretch:normal; font-size:11px; line-height:normal; font-family:Menlo; font-size-adjust:none; font-kerning:auto; font-variant-alternates:normal; font-variant-ligatures:normal; font-variant-numeric:normal; font-variant-east-asian:normal; font-feature-settings:normal">
<span style="font-variant-ligatures:no-common-ligatures">dynamics.F: IF ( useSmag3D ) THEN</span></div>
<div style="margin:0px; font-style:normal; font-variant-caps:normal; font-stretch:normal; font-size:11px; line-height:normal; font-family:Menlo; font-size-adjust:none; font-kerning:auto; font-variant-alternates:normal; font-variant-ligatures:normal; font-variant-numeric:normal; font-variant-east-asian:normal; font-feature-settings:normal">
<span style="font-variant-ligatures:no-common-ligatures">ini_parms.F: & viscC2leith, viscC4leith, smag3D_coeff, useSmag3D,</span></div>
<div style="margin:0px; font-style:normal; font-variant-caps:normal; font-stretch:normal; font-size:11px; line-height:normal; font-family:Menlo; font-size-adjust:none; font-kerning:auto; font-variant-alternates:normal; font-variant-ligatures:normal; font-variant-numeric:normal; font-variant-east-asian:normal; font-feature-settings:normal">
<span style="font-variant-ligatures:no-common-ligatures">ini_parms.F: IF ( smag3D_diffCoeff.NE.zeroRL .AND. .NOT.useSmag3D ) THEN</span></div>
<div style="margin:0px; font-style:normal; font-variant-caps:normal; font-stretch:normal; font-size:11px; line-height:normal; font-family:Menlo; font-size-adjust:none; font-kerning:auto; font-variant-alternates:normal; font-variant-ligatures:normal; font-variant-numeric:normal; font-variant-east-asian:normal; font-feature-settings:normal">
<span style="font-variant-ligatures:no-common-ligatures">ini_parms.F: & 'will not use "smag3D_diffCoeff" without useSmag3D'</span></div>
<div style="margin:0px; font-style:normal; font-variant-caps:normal; font-stretch:normal; font-size:11px; line-height:normal; font-family:Menlo; font-size-adjust:none; font-kerning:auto; font-variant-alternates:normal; font-variant-ligatures:normal; font-variant-numeric:normal; font-variant-east-asian:normal; font-feature-settings:normal">
<span style="font-variant-ligatures:no-common-ligatures">set_defaults.F: useSmag3D = .FALSE.</span></div>
<div style="margin:0px; font-style:normal; font-variant-caps:normal; font-stretch:normal; font-size:11px; line-height:normal; font-family:Menlo; font-size-adjust:none; font-kerning:auto; font-variant-alternates:normal; font-variant-ligatures:normal; font-variant-numeric:normal; font-variant-east-asian:normal; font-feature-settings:normal">
<span style="font-variant-ligatures:no-common-ligatures">set_parms.F: useSmag3D = momViscosity .AND. useSmag3D</span></div>
<div><br>
</div>
<div>You can probably figure out yourself, that the files starting with “ini_” or “config_”, “set_defaults/params.F” are only initialisation, and that calc_gw.F and dynamics.F are more interesting to you. In these files you’ll see that with this flag=Ture,
specific routines (e.g., MOM_W_SMAG_3D, MOM_CALC_3D_STRAIN, ...) are called which (probably) contain most of the code. Most of the time in MITgcm, a routine lives in a file with the same name (e.g., mom_w_smag_3d.F, if not you’d have to grep for it again).
This routine is linked from the source directory (pkg/mom_common).</div>
<div><br>
</div>
<div>Martin</div>
<div><br>
<blockquote type="cite">
<div>On 30. Nov 2023, at 20:07, Burns, Paul <P.Burns2@exeter.ac.uk> wrote:</div>
<br class="x_x_x_x_Apple-interchange-newline">
<div>
<div class="x_x_x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
Hi,</div>
<div class="x_x_x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
<br>
</div>
<div class="x_x_x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
I've only recently come back to some work I started about a year ago about regional modelling in the Arctic ocean, having been distracted by a change of jobs. I received some useful advice from Jean-Michel about the two types of Smagorinsky scheme available
in MITgcm. I was advised to look at tutorial_deep_convection for details of the parameters that need setting when using the 3D Smagorinsky scheme (i.e., required with useSmag3D=.TRUE.), however, the documentation in that tutorial is very limited and it isn't
clear what values should be chosen for: </div>
<div class="x_x_x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
<br>
</div>
<div class="x_x_x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
smag3D_coeff</div>
<div class="x_x_x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
smag3Ddiff_coeff</div>
<div class="x_x_x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
<br>
</div>
<div class="x_x_x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
I would be grateful is someone could give some advice about how to choose values for these parameters. </div>
<div class="x_x_x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
<br>
</div>
<div class="x_x_x_x_elementToProof" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<span style="font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">Also, it might be useful to look at the source code for the 3D Smagorinsky scheme (</span><span style="letter-spacing:normal; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:16px; font-weight:400; background-color:rgb(255,255,255)">useSmag3D=.TRUE.)</span><span style="font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">,
but I am not sure where it is located?</span></div>
<div class="x_x_x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
<br>
</div>
<div class="x_x_x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
<br>
</div>
<div class="x_x_x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
Many thanks,</div>
<div class="x_x_x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
Paul</div>
<div class="x_x_x_x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif; font-size:12pt">
<br>
</div>
<div id="x_x_x_x_Signature" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<div><span style="font-family:Calibri,sans-serif; font-size:14.6667px; color:rgb(12,100,192); background-color:rgb(255,255,255)"><u> </u></span></div>
<div><span style="font-family:Calibri,sans-serif; font-size:14.6667px; color:rgb(23,78,134); background-color:rgb(255,255,255)">Dr Paul Burns MInstP FRMetS</span></div>
<div><span style="font-family:Calibri,sans-serif; font-size:14.6667px; color:rgb(23,78,134)">Associate Research Fellow</span></div>
<div><span style="font-family:Calibri,sans-serif; font-size:14.6667px; color:rgb(23,78,134)">& </span></div>
<div><span style="font-family:Calibri,Helvetica,sans-serif; font-size:11pt; color:rgb(23,78,134)">Senior Scientist</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt"><span style="font-size:11pt; color:rgb(23,78,134)">Atmospheric Processes and Parametrisation (APP)</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt"><span style="font-size:11pt; color:rgb(23,78,134)">Met Office</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt"><span style="font-size:11pt; color:rgb(23,78,134)">Exeter</span></div>
</div>
<div id="x_x_x_x_appendonsend" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
</div>
<hr tabindex="-1" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; display:inline-block; width:429.234375px">
<span style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; float:none; display:inline!important"></span>
<div id="x_x_x_x_divRplyFwdMsg" dir="ltr" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<font face="Calibri, sans-serif" style="font-size:11pt"><b>From:</b><span class="x_x_x_x_Apple-converted-space"> </span>Burns, Paul <<a href="mailto:P.Burns2@exeter.ac.uk">P.Burns2@exeter.ac.uk</a>><br>
<b>Sent:</b><span class="x_x_x_x_Apple-converted-space"> </span>02 February 2023 11:44<br>
<b>To:</b><span class="x_x_x_x_Apple-converted-space"> </span><a href="mailto:MITgcm-support@mitgcm.org">MITgcm-support@mitgcm.org</a><span class="x_x_x_x_Apple-converted-space"> </span><<a href="mailto:MITgcm-support@mitgcm.org">MITgcm-support@mitgcm.org</a>><br>
<b>Subject:</b><span class="x_x_x_x_Apple-converted-space"> </span>Re: [MITgcm-support] Vertical diffusion for non-hydrostatic ocean model with a stretched grid</font>
<div> </div>
</div>
<div dir="ltr" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<div class="x_x_x_x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; background-color:rgb(255,255,255)">
Hi Jean-Michel,</div>
<div class="x_x_x_x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; background-color:rgb(255,255,255)">
<br>
</div>
<div class="x_x_x_x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; background-color:rgb(255,255,255)">
Many thanks for your quick and clear response.</div>
<div class="x_x_x_x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; background-color:rgb(255,255,255)">
<br>
</div>
<div class="x_x_x_x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; background-color:rgb(255,255,255)">
I agree that I should try option 2), which appears to calculate both the viscosity and diffusivity for the tracers (simply by using a constant Prandtl number)? Yes, the Smagorinsky model essentially parameterises subgrid mixing by using the resolved shear
and grid resolution, and so does not explicitly account for stratification. I hope that my very fine vertical grid resolves most buoyancy-driven (and mechanical) mixing. </div>
<div class="x_x_x_x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; background-color:rgb(255,255,255)">
<br>
</div>
<div class="x_x_x_x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; background-color:rgb(255,255,255)">
MITgcm does have a TKE 1.5-order closure scheme (i.e., package ggl90), however, it seems only suitable for hydrostatic simulations, when the mixing length in the scheme doesn't need to be limited to the grid resolution. This at least is my understanding from
the paper by Blanke and Delecluse (1993).</div>
<div class="x_x_x_x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; background-color:rgb(255,255,255)">
<br>
</div>
<div class="x_x_x_x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; background-color:rgb(255,255,255)">
My grid is certainly not isotropic, but I have no bottom topography so the grid cells are at least aligned with the horizontal. I am not sure what errors my grid may introduce when using the Smagorinsky scheme? I guess I can test the results using the Smagorinsky
scheme against simply specifying a profile of viscosity and diffusivity using the relevant Reynolds number (i.e. setting <span class="x_x_x_x_x_ContentPasted0" style="font-size:12pt; background-color:rgb(255,255,255); display:inline!important">viscArNr).</span></div>
<div class="x_x_x_x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; background-color:rgb(255,255,255)">
<br>
</div>
<div class="x_x_x_x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; background-color:rgb(255,255,255)">
<br>
</div>
<div class="x_x_x_x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; background-color:rgb(255,255,255)">
Cheers,</div>
<div class="x_x_x_x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; background-color:rgb(255,255,255)">
Paul</div>
<div class="x_x_x_x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; background-color:rgb(255,255,255)">
<br>
</div>
<div class="x_x_x_x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; background-color:rgb(255,255,255)">
<br>
</div>
<div class="x_x_x_x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; background-color:rgb(255,255,255)">
<br>
</div>
<div class="x_x_x_x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; background-color:rgb(255,255,255)">
<br>
</div>
<div class="x_x_x_x_x_elementToProof">
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt"><br>
</div>
<div id="x_x_x_x_x_Signature">
<div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
<div style="margin:0px; font-size:15px; color:rgb(32,31,30); text-align:start; background-color:rgb(255,255,255)">
<div style="margin:0px; font-size:11pt; font-family:Calibri,sans-serif"><span style="color:rgb(12,100,192)"><u> </u></span></div>
<div style="margin:0px; font-size:11pt; font-family:Calibri,sans-serif"><span style="margin:0px; color:rgb(31,78,121)">Dr Paul Burns MInstP FRMetS</span></div>
<div style="margin:0px; font-size:11pt; font-family:Calibri,sans-serif"><span style="margin:0px; color:rgb(31,78,121)">Research Fellow</span></div>
<div style="margin:0px; font-size:11pt; font-family:Calibri,sans-serif"><span style="margin:0px; color:rgb(31,78,121)">Geophysical and Astrophysical Fluid Dynamics Group</span></div>
<div style="margin:0px; font-size:11pt; font-family:Calibri,sans-serif"><span style="margin:0px; color:rgb(31,78,121)">Department of Mathematics</span></div>
<div style="margin:0px; font-size:11pt; font-family:Calibri,sans-serif"><span style="margin:0px; color:rgb(31,78,121)">Harrison Building</span></div>
<div style="margin:0px; font-size:11pt; font-family:Calibri,sans-serif"><span style="margin:0px; color:rgb(31,78,121)">University of Exeter</span></div>
</div>
<br>
</div>
</div>
</div>
</div>
<div id="x_x_x_x_x_appendonsend"></div>
<hr tabindex="-1" style="display:inline-block; width:429.234375px">
<div id="x_x_x_x_x_divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt"><b>From:</b><span class="x_x_x_x_Apple-converted-space"> </span>MITgcm-support <<a href="mailto:mitgcm-support-bounces@mitgcm.org">mitgcm-support-bounces@mitgcm.org</a>>
on behalf of Jean-Michel Campin <<a href="mailto:jmc@mit.edu">jmc@mit.edu</a>><br>
<b>Sent:</b><span class="x_x_x_x_Apple-converted-space"> </span>01 February 2023 15:25<br>
<b>To:</b><span class="x_x_x_x_Apple-converted-space"> </span><a href="mailto:mitgcm-support@mitgcm.org">mitgcm-support@mitgcm.org</a><span class="x_x_x_x_Apple-converted-space"> </span><<a href="mailto:mitgcm-support@mitgcm.org">mitgcm-support@mitgcm.org</a>><br>
<b>Subject:</b><span class="x_x_x_x_Apple-converted-space"> </span>Re: [MITgcm-support] Vertical diffusion for non-hydrostatic ocean model with a stretched grid</font>
<div> </div>
</div>
<div class="x_x_x_x_x_BodyFragment"><font size="2"><span style="font-size:11pt">
<div class="x_x_x_x_x_PlainText">CAUTION: This email originated from outside of the organisation. Do not click links or open attachments unless you recognise the sender and know the content is safe.<br>
<br>
<br>
Hi Paul,<br>
<br>
There is some confusion about Smagorinsky in MITgcm since we have 2 implementations:<br>
1) a Smagorinsky like horizontal viscosity that is function of horizontal shear,<br>
with the choice of harmonic (viscC2smag) or bi-harmonic (viscC4smag) viscosity.<br>
2) a simple 3-D Smagorinsky harmonic viscosity that work best when the grid is<br>
near isotropic (mostly for Non-Hydrostatic simulation) and does not acount for<br>
stratification.<br>
Need ALLOW_SMAG_3D_DIFFUSIVITY to be defined and uses run-time parameter:<br>
useSmag3D = .TRUE., with smag3D_coeff,<br>
see experiment: tutorial_deep_convection, with input.smag3d/data<br>
<br>
You may want to try this second implementation.<br>
Alternatively, you could always set a vertical profile of (background)<br>
vertical viscosity using Nr values to set vector "viscArNr" in main parameter<br>
input file "data" (note that the fist value corresponds to the very top,<br>
i.e., surface, vertical index k=1, and has no effect).<br>
<br>
Cheers,<br>
Jean-Michel<br>
<br>
On Wed, Feb 01, 2023 at 12:55:22PM +0000, Burns, Paul wrote:<br>
> Hi,<br>
><br>
> I was hoping that someone could give me some advice about the best way to define the vertical viscosity (and diffusivity) in MITgcm for a non-hydrostatic model using a stretched vertical grid. I've used a stretched vertical grid to resolve very small features
of interest (~0.2 m) in the upper ocean and to keep the simulation practical.<br>
><br>
> The viscosity should vary with the grid resolution (e.g., Smagorinsky, 1993), however, the MITgcm documentation says that the Smagorinsky scheme isn't implemented in the vertical. So would a reasonable approach be to compute a vertical profile of viscosities
using a vertical Reynolds number and use that to set viscArNr?<br>
><br>
><br>
> Many thanks,<br>
> Paul<br>
><br>
><br>
><br>
><br>
> Dr Paul Burns MInstP FRMetS<br>
><br>
> Research Fellow<br>
><br>
> Geophysical and Astrophysical Fluid Dynamics Group<br>
><br>
> Department of Mathematics<br>
><br>
> Harrison Building<br>
><br>
> University of Exeter<br>
><br>
<br>
> _______________________________________________<br>
> MITgcm-support mailing list<br>
><span class="x_x_x_x_Apple-converted-space"> </span><a href="mailto:MITgcm-support@mitgcm.org">MITgcm-support@mitgcm.org</a><br>
><span class="x_x_x_x_Apple-converted-space"> </span><a href="http://mailman.mitgcm.org/mailman/listinfo/mitgcm-support" originalsrc="http://mailman.mitgcm.org/mailman/listinfo/mitgcm-support" shash="LCTsMxKB7tqyL3Lo7n1baS8lyYiNibzA3N1retXucgdU2rqqSdxFHsuJzm4IfMopfHkRRsIXyUtZiPBt/CGpzAD4it2twLn9PFZCZ5G135xmd7xrJZ0r/VLydjJFnWkof4i4jlo72O+ZBjqqF2LRriAvjWCsh2HvvvCv9/a+9dY=" originalsrc="http://mailman.mitgcm.org/mailman/listinfo/mitgcm-support" shash="cTioXSVm4tKo798OYa4+6c8Ccp5X5hORLgEgTwtnJiqHvvs2LNdjl4OIPKA8Cc58ojCVYSKcErPKO1viE2mRAhcf/V1vkwY6leG8M/96kGwgK30oazl6RF2hkAha9eEfegUHIMdEJQxC5WWBTbd05CxzAFaWYYNU0hsOSRIY0a0=">https://eur03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fmailman.mitgcm.org%2Fmailman%2Flistinfo%2Fmitgcm-support&data=05%7C01%7Cp.burns2%40exeter.ac.uk%7Cc5f922888565484cca2d08db04689db2%7C912a5d77fb984eeeaf321334d8f04a53%7C0%7C0%7C638108619586622927%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=lIiEnoR5jjVDjN6nbhJqucfgF1b8zQyyxo0%2F9ryH%2F%2Bw%3D&reserved=0</a><br>
<br>
_______________________________________________<br>
MITgcm-support mailing list<br>
<a href="mailto:MITgcm-support@mitgcm.org">MITgcm-support@mitgcm.org</a><br>
<a href="http://mailman.mitgcm.org/mailman/listinfo/mitgcm-support" originalsrc="http://mailman.mitgcm.org/mailman/listinfo/mitgcm-support" shash="eKbEmaaaVm19svRe7RdzgxDvRySWwRu4CpE2qYwe77fbqZbXDmm2XpGkJe7bNVxFsmX6HCzW56bHVaA+wcTLqruUR3MyGwEMhzCyGh20c3cXLsrpjUEfVgSu8vwn90JB7PLKB2g7EQZ0nodBSjUAfDbLPwZifz1EP6AHnvvjNus=" originalsrc="http://mailman.mitgcm.org/mailman/listinfo/mitgcm-support" shash="cTioXSVm4tKo798OYa4+6c8Ccp5X5hORLgEgTwtnJiqHvvs2LNdjl4OIPKA8Cc58ojCVYSKcErPKO1viE2mRAhcf/V1vkwY6leG8M/96kGwgK30oazl6RF2hkAha9eEfegUHIMdEJQxC5WWBTbd05CxzAFaWYYNU0hsOSRIY0a0=">https://eur03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fmailman.mitgcm.org%2Fmailman%2Flistinfo%2Fmitgcm-support&data=05%7C01%7Cp.burns2%40exeter.ac.uk%7Cc5f922888565484cca2d08db04689db2%7C912a5d77fb984eeeaf321334d8f04a53%7C0%7C0%7C638108619586622927%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=lIiEnoR5jjVDjN6nbhJqucfgF1b8zQyyxo0%2F9ryH%2F%2Bw%3D&reserved=0</a><br>
</div>
</span></font></div>
</div>
<span style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; float:none; display:inline!important">_______________________________________________</span><br style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<span style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; float:none; display:inline!important">MITgcm-support
mailing list</span><br style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<a href="mailto:MITgcm-support@mitgcm.org" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px">MITgcm-support@mitgcm.org</a><br style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<a href="http://mailman.mitgcm.org/mailman/listinfo/mitgcm-support" originalsrc="http://mailman.mitgcm.org/mailman/listinfo/mitgcm-support" shash="eKbEmaaaVm19svRe7RdzgxDvRySWwRu4CpE2qYwe77fbqZbXDmm2XpGkJe7bNVxFsmX6HCzW56bHVaA+wcTLqruUR3MyGwEMhzCyGh20c3cXLsrpjUEfVgSu8vwn90JB7PLKB2g7EQZ0nodBSjUAfDbLPwZifz1EP6AHnvvjNus=" originalsrc="http://mailman.mitgcm.org/mailman/listinfo/mitgcm-support" shash="cTioXSVm4tKo798OYa4+6c8Ccp5X5hORLgEgTwtnJiqHvvs2LNdjl4OIPKA8Cc58ojCVYSKcErPKO1viE2mRAhcf/V1vkwY6leG8M/96kGwgK30oazl6RF2hkAha9eEfegUHIMdEJQxC5WWBTbd05CxzAFaWYYNU0hsOSRIY0a0=" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px">http://mailman.mitgcm.org/mailman/listinfo/mitgcm-support</a></div>
</blockquote>
</div>
<br>
</div>
</div>
</div>
<span style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; float:none; display:inline!important">_______________________________________________</span><br style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<span style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; float:none; display:inline!important">MITgcm-support
mailing list</span><br style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<a href="mailto:MITgcm-support@mitgcm.org" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px">MITgcm-support@mitgcm.org</a><br style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<a href="http://mailman.mitgcm.org/mailman/listinfo/mitgcm-support" originalsrc="http://mailman.mitgcm.org/mailman/listinfo/mitgcm-support" shash="eKbEmaaaVm19svRe7RdzgxDvRySWwRu4CpE2qYwe77fbqZbXDmm2XpGkJe7bNVxFsmX6HCzW56bHVaA+wcTLqruUR3MyGwEMhzCyGh20c3cXLsrpjUEfVgSu8vwn90JB7PLKB2g7EQZ0nodBSjUAfDbLPwZifz1EP6AHnvvjNus=" originalsrc="http://mailman.mitgcm.org/mailman/listinfo/mitgcm-support" shash="cTioXSVm4tKo798OYa4+6c8Ccp5X5hORLgEgTwtnJiqHvvs2LNdjl4OIPKA8Cc58ojCVYSKcErPKO1viE2mRAhcf/V1vkwY6leG8M/96kGwgK30oazl6RF2hkAha9eEfegUHIMdEJQxC5WWBTbd05CxzAFaWYYNU0hsOSRIY0a0=" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px">http://mailman.mitgcm.org/mailman/listinfo/mitgcm-support</a></div>
</blockquote>
</div>
<br>
</div>
</div>
</div>
<span style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; float:none; display:inline!important">_______________________________________________</span><br style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<span style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; float:none; display:inline!important">MITgcm-support
mailing list</span><br style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<a href="mailto:MITgcm-support@mitgcm.org" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; orphans:auto; text-align:start; text-indent:0px; text-transform:none; white-space:normal; widows:auto; word-spacing:0px">MITgcm-support@mitgcm.org</a><br style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<a href="http://mailman.mitgcm.org/mailman/listinfo/mitgcm-support" originalsrc="http://mailman.mitgcm.org/mailman/listinfo/mitgcm-support" shash="eKbEmaaaVm19svRe7RdzgxDvRySWwRu4CpE2qYwe77fbqZbXDmm2XpGkJe7bNVxFsmX6HCzW56bHVaA+wcTLqruUR3MyGwEMhzCyGh20c3cXLsrpjUEfVgSu8vwn90JB7PLKB2g7EQZ0nodBSjUAfDbLPwZifz1EP6AHnvvjNus=" style="font-family:Helvetica; font-size:12px; font-style:normal; font-variant-caps:normal; font-weight:400; letter-spacing:normal; orphans:auto; text-align:start; text-indent:0px; text-transform:none; white-space:normal; widows:auto; word-spacing:0px">http://mailman.mitgcm.org/mailman/listinfo/mitgcm-support</a></div>
</blockquote>
</div>
<br>
</div>
</div>
</div>
</div>
</div>
</body>
</html>