Hi all,
I met some problem and confusion for the bustr/bvstr units.
In the ROMS code: Modules/mod_forces.F:
! Bottom momentum stresses. !
! !
! bustr Kinematic bottom momentum flux (bottom stress) in !
! the XI-direction (m2/s2) at horizontal U-points. !
! bvstr Kinematic bottom momentum flux (bottom stress) in !
! ETA-direction (m2/s2) at horizontal V-points. !
It tells the unit is m2/s2.
But in the var_info.dat file it said the uiit is N/m2.
My understanding of this inconsistency is that, ROMS did a scale transformation by a function FUNCTION nf_fwrite2d, making the scale equates -rho for scale transformation, so we will get N/m^2 for bvstr/bustr in the outputfile directly, named " bottom U-momentum stress". I guess ROMS did this for convenience.
! Write out bottom U-momentum stress.
!
IF (Hout(idUbms,ng)) THEN
scale=-rho0
gtype=gfactor*u2dvar
status=nf_fwrite2d(ng, iNLM, HIS(ng)%ncid, HIS(ng)%Vid(idUbms), &
& HIS(ng)%Rindex, gtype, &
& LBi, UBi, LBj, UBj, scale, &
& GRID(ng) % umask_io, &
& FORCES(ng) % bustr)
IF (status.ne.nf90_noerr) THEN
IF (Master) THEN
WRITE (stdout,10) TRIM(Vname(1,idUbms)), HIS(ng)%Rindex
END IF
exit_flag=3
ioerror=status
RETURN
END IF
END IF
MODULE nf_fwrite2d_mod
!
!svn $Id: nf_fwrite2d.F 585 2012-01-03 18:44:28Z arango $
!================================================== Hernan G. Arango ===
! Copyright (c) 2002-2012 The ROMS/TOMS Group !
! Licensed under a MIT/X style license !
! See License_ROMS.txt !
!=======================================================================
! !
! This function writes out a generic floating point 2D array into an !
! output NetCDF file. !
! !
! On Input: !
! !
! ng Nested grid number. !
! model Calling model identifier. !
! ncid NetCDF file ID. !
! ncvarid NetCDF variable ID. !
! tindex NetCDF time record index to write. !
! gtype Grid type. If negative, only write water points. !
! LBi I-dimension Lower bound. !
! UBi I-dimension Upper bound. !
! LBj J-dimension Lower bound. !
! UBj J-dimension Upper bound. !
! Amask land/Sea mask, if any (real). !
! Ascl Factor to scale field before writing (real). !
! A Field to write out (real). !
! SetFillVal Logical switch to set fill value in land areas !
! (optional). !
! !
! On Output: !
! !
! nf_fwrite Error flag (integer).
But for the ROMS coding calculating itself, bustr/bvstr units are still the same m2/s2,and its value remain the one before scale/unit transformation and remain same units m2/s2 for its subroutine and biological module and sediment module.
This could better explain in the following code calculation tke and bustr in the mod_mixing.F
tke(i,j,0,nnew)=MAX(cmu_fac3*0.5_r8* &
& SQRT((bustr(i,j)+bustr(i+1,j))**2+ &
& (bvstr(i,j)+bvstr(i,j+1))**2), &
& gls_Kmin(ng))
So units between bvstr, tke, gls_Kmin should be consistent:m2/s2
Is this same from your understanding?
What I am doing now will need the value of bvstr/bustr for some extended subroutine, so hopefully have a better understanding of value.
Thanks for your answer.
bustr bvstr units confusion
-
- Posts: 17
- Joined: Mon Sep 08, 2014 4:17 pm
- Location: Hohai University
Re: bustr bvstr units confusion
Yes, internally ROMS carries the surface and bottom stresses (sustr, bustr, etc.) in kinematic units of stress divided by reference density (parameter rho0 in ROMS), which is then units of m2/s2.
This is clear in set_vbc.F for simple bottom drag formulae such as quadratic:
Here the components of velocity (u,v) are being averaged to the u-point on the staggered grid (as is the drag coefficient, which can be spatially varying and is notionally defined at the rho-point position on the staggered grid) before computing the velocity magnitude (cff2), then bustr is the velocity magnitude times drag coefficient times u-component of velocity.
bustr has units m2/s2 and is defined on the u-point of the grid.
Similarly, bvstr will be defined at the v-points grid.
The magnitude of the vector [bustr,bvstr] is the familiar "u-star" in fluid dynamics, being the bottom stress divided by rho0.
If you wish to use bottom stress in a parameterization of, say, particulate matter resuspension rate or a settlement criterion for larvae, then you need to calculate the stress magnitude by averaging to a common location on the staggered grid (most rationally the rho-points) and work with that. e.g.:
Here, TauB will be at rho-point (i,j) in units of Pascal = Newton/m2.
This is clear in set_vbc.F for simple bottom drag formulae such as quadratic:
Code: Select all
# elif defined UV_QDRAG
!
! Set quadratic bottom stress.
!
DO j=Jstr,Jend
DO i=IstrU,Iend
cff1=0.25_r8*(v(i ,j ,1,nrhs)+ &
& v(i ,j+1,1,nrhs)+ &
& v(i-1,j ,1,nrhs)+ &
& v(i-1,j+1,1,nrhs))
cff2=SQRT(u(i,j,1,nrhs)*u(i,j,1,nrhs)+cff1*cff1)
bustr(i,j)=0.5_r8*(rdrag2(i-1,j)+rdrag2(i,j))* &
& u(i,j,1,nrhs)*cff2
bustr has units m2/s2 and is defined on the u-point of the grid.
Similarly, bvstr will be defined at the v-points grid.
The magnitude of the vector [bustr,bvstr] is the familiar "u-star" in fluid dynamics, being the bottom stress divided by rho0.
If you wish to use bottom stress in a parameterization of, say, particulate matter resuspension rate or a settlement criterion for larvae, then you need to calculate the stress magnitude by averaging to a common location on the staggered grid (most rationally the rho-points) and work with that. e.g.:
Code: Select all
TauB=rho0*SQRT((0.5_r8*(bustr(i,j)+bustr(i+1,j)))**2+ &
& (0.5_r8*(bvstr(i,j)+bvstr(i,j+1)))**2)
John Wilkin: DMCS Rutgers University
71 Dudley Rd, New Brunswick, NJ 08901-8521, USA. ph: 609-630-0559 jwilkin@rutgers.edu
71 Dudley Rd, New Brunswick, NJ 08901-8521, USA. ph: 609-630-0559 jwilkin@rutgers.edu