Coupling of m3-m2 initial conditions

Discussion of how to use ROMS on different regional and basin scale applications.

Moderators: arango, robertson

Post Reply
Message
Author
stef
Posts: 48
Joined: Tue Mar 13, 2007 6:38 pm
Location: Independent researcher
Contact:

Coupling of m3-m2 initial conditions

#1 Post by stef » Sat Mar 31, 2007 3:52 pm

My configuration is a flow-channel with open boundaries in north/south and closed walles in the east and west. I want to have velocity boundary conditions identical to velocity initial conditions. All of these conditions are analytically defined.

If I want inflow from the north with u=w=0 and a vertical profile for v that has only negative values in the entire watercolumn, then I have to integrate that profile vertically and devide by depth to get the corresponding m2 condition on that boundary, right?

If I want this boundary condition to be initial condition in the entire domain, I have to do the same thing in the entire domain?

How do you integrate the velocity? Do you have to do a discrete integration (e.g. trapezoidal rule) in analytical.f90 or is there some subroutine I can call?

User avatar
kate
Posts: 3678
Joined: Wed Jul 02, 2003 5:29 pm
Location: IMS/UAF, USA

#2 Post by kate » Mon Apr 02, 2007 7:39 pm

The version of ROMS I have (one of the 3.0 beta series) has main3d call ini_fields at the start of the first timestep. This routine does the vertical average for you, setting ubar, vbar accordingly. You should see if ROMS is doing this for you already.

stef
Posts: 48
Joined: Tue Mar 13, 2007 6:38 pm
Location: Independent researcher
Contact:

#3 Post by stef » Mon Apr 02, 2007 9:08 pm

Thanks Kate,

In my version (2.2) there is only one possibility to define 3d velocity initial conditions analytically: ANA_INITIAL. If I define it, I have to insert analytical initial fields for BOTH m2 and m3 velocities (and tracers). That's why I don't think that there is a call to any routine that calculates m2 solely with the m3 profile, because it would then "overrule" my analytically defined m2.
I'm looking forward to get the new version!

--stefan

User avatar
kate
Posts: 3678
Joined: Wed Jul 02, 2003 5:29 pm
Location: IMS/UAF, USA

#4 Post by kate » Mon Apr 02, 2007 10:59 pm

There is code in ROMS to do the vertical integral, though. Look in some place like step3d_uv.F for something like this:

! Replace INTERIOR POINTS incorrect vertical mean with more accurate
! barotropic component, vbar=DV_avg1/(D*om_v). Recall that, D=CF(:,0).

User avatar
m.hadfield
Posts: 516
Joined: Tue Jul 01, 2003 4:12 am
Location: NIWA

#5 Post by m.hadfield » Tue Apr 03, 2007 8:47 pm

To the best of my recollection, all recent ROMS versions, including 2.2, do exactly what Stef thinks they wouldn't do, i.e. overrule the initial M2 fields with new ones calculated from M3.

stef
Posts: 48
Joined: Tue Mar 13, 2007 6:38 pm
Location: Independent researcher
Contact:

#6 Post by stef » Wed Apr 04, 2007 8:57 am

Hi!
Hmm, that's interesting. When I define m2 to be zero and define a m3 profile, e.g. u=w=0 and v=v(z), with all values negative from zeta down to the bottom (so vbar should be negative), the entry in the history files for the first calculated baroclinic timestep (NHIS=2) containes a vertical v profile similar to the one I defined, exept that it is translated along the y-axis in a way that its vertical integral yields (almost) exactly zero. Vbar is also almost exactly zero at this time. Then I thought about the mode-splitting and came to the conclusion that the model starts to evolve zeta, ubar and vbar with the defined fs and m2 initial conditions. After the barotropic timesteps, it adjusts the defined m3 profile accoding to the ubar and vbar result from the barotropic timesteps. Kate indicated the corresponding part of the code in her previous post.

However, I don't know how this plays together with the boundary conditions. At the moment I have a channel with inflow in north, outflow in south and closed walls in east and west. Every variable at the inflow is clamped, and everything in the south is gradient, but I have noticed the same m2-m3 initial behaviour with many other choices for boundary conditions.

--stefan

User avatar
m.hadfield
Posts: 516
Joined: Tue Jul 01, 2003 4:12 am
Location: NIWA

#7 Post by m.hadfield » Wed Apr 04, 2007 9:15 pm

Yes, something like that :oops:

nganju
Posts: 82
Joined: Mon Aug 16, 2004 8:47 pm
Location: U.S. Geological Survey, Woods Hole
Contact:

#8 Post by nganju » Mon Apr 09, 2007 6:06 pm

i ran a similar configuration, instead of clamping the inflow at the north and gradient for the outflow in the south, I clamped the outflow in the south, and gradient for the inflow at the north. This worked well for me, and gave me the correct inflow at the north once it reached steady-state...

stef
Posts: 48
Joined: Tue Mar 13, 2007 6:38 pm
Location: Independent researcher
Contact:

#9 Post by stef » Tue Apr 10, 2007 3:53 pm

I'm going to try that as soon as I can. My most stable setup so far is: Everything clamped in north, m3, m2 and tracer clamped in south, with free surface radiation.

Post Reply