[MITgcm-support] Initial Wind on Cubed Sphere

Jean-Michel Campin jmc at ocean.mit.edu
Tue May 1 13:33:50 EDT 2012


Chris,

This is a good question (I did not look to this script for some time,
need to remember how things are done) and should be documented at the
top ofuvLatLon2cube.m.
"spv" is an optional argument (but it's unfortunate that it's before cosalpha,sinalpha, 
which you may want to specify without providing "spv") for an exclusion-value 
(or "special value") that could be found in the input uFld,vFld over dead region 
(e.g., continent when processing oceanic velocity). 
And when "spv" is specified, the interpolation discard these "dead regions" 
and, at the end, put back "spv" over these regions.
So if you specify a value for "spv" that is not present anywhere neither in
uFld nor in vFld, then it will have no effect on the result.

Cheers,
Jean-Michel

On Tue, May 01, 2012 at 04:28:43PM +0100, Chris Watkins wrote:
> Hi Jean-Michel,
> 
> Thank you for such a quick response. I was looking at
> utils/matlab/cs_grid/uvLatLon2cube.m. It asks for spv as one of its input.
> Can you tell me what spv is?
> 
> Thanks again,
> 
> Chris
> 
> On 1 May 2012 16:11, Jean-Michel Campin <jmc at ocean.mit.edu> wrote:
> 
> > Hi Chris,
> >
> > Depending on the wind field, you may try one of the 2 methods:
> > 1) general method (similar to what is done within matlab script
> >  utils/matlab/cs_grid/uvLatLon2cube.m): your can define your wind field
> >  on a lat-lon grid and then use uvLatLon2cube.m to interpolate + rotate
> >  to CS-grid direction + put the uVel,vVel on to C-grid location;
> > Or, you can skip the interpolation stage and define your wind field
> >  on the CS-grid, at the grid-cell center location and then just do
> >  the rotation + the move to C-grid location.
> > 2) specific method for non-divergent wind-field (this is a special case
> >  which is not uncommon): From the analytical expression of the wind,
> >  you can derive an analytical expression of the horizontal stream-function.
> >  Then you evaluate the stream-function on the CS-grid at the grid-cell
> > corner
> >  (position XG,YG) and from there you can compute directly the wind
> >  at the C-grid location (this ensure that uVel,vVel field is non
> > divergent).
> >  There are few matlab scripts that uses this 2nd method (e.g., in
> >  MITgcm_contrib/dyncore_ASP/mat_scripts ) and also some fortran code
> >  (e.g., verification/advect_cs/code/ini_vel.F or
> >   verification/code/solid-body.cs-32x32x1/code/ini_vel.F).
> >
> > Cheers,
> > Jean-Michel
> >
> > On Tue, May 01, 2012 at 02:34:45PM +0100, Chris Watkins wrote:
> > > I am trying to set up an initial wind field using the file ini_vel.f on a
> > > cubed sphere. I know analytically what the meridional and zonal winds
> > > should be on a latitude-longitude grid. Can anyone help me understand
> > what
> > > adjustments I need to make to these values to make them into the uVel and
> > > vVel variables.
> > >
> > > I originally set uVel to the zonal wind and vVel to the meridional wind
> > but
> > > the output for U & V  for timestep 0 does not match.
> > >
> > > --
> > > Chris Watkins
> >
> > > _______________________________________________
> > > MITgcm-support mailing list
> > > MITgcm-support at mitgcm.org
> > > http://mitgcm.org/mailman/listinfo/mitgcm-support
> >
> >
> > _______________________________________________
> > MITgcm-support mailing list
> > MITgcm-support at mitgcm.org
> > http://mitgcm.org/mailman/listinfo/mitgcm-support
> >
> 
> 
> 
> -- 
> Chris Watkins
> 
> G+ GPlus.to/ChrisWatkins <http://gplus.to/ChrisWatkins>

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




More information about the MITgcm-support mailing list