In my version of NEMO 4.6 I noticed the following line in NEMOGCM/src/OCE/SBC/sbcflx.F90:
zmod = 0.5_wp * SQRT( ztx * ztx + zty * zty ) * tmask(ji,jj,1)
where ztx and zty are the zonal and meridional wind-stress components.
Shouldn’t the wind-stress magnitude simply be SQRT(ztx² + zty²) (masked by tmask)? What is the rationale behind the global 0.5_wp prefactor?
Could anyone confirm whether this is an intended behavior or if it might be an oversight?
In all NEMO versions < 5.0, the wind stress along the i direction is computed at U point and the wind stress along the j direction is computed at V point.
Which means that the 2 stress components have to be computed at a common location, i.e. T point, before being combined to calculate the wind stress module.
NEMO 4.6 does not exist on the official NEMO server.
Your piece of code looks like NEMO 3.6 where we have:
ztx = utau(ji-1,jj ) + utau(ji,jj)
zty = vtau(ji ,jj-1) + vtau(ji,jj)
zmod = 0.5 * SQRT( ztx * ztx + zty * zty )
Where we can see a nice bug as it should be
ztx = 0.5 * ( utau(ji-1,jj ) + utau(ji,jj) )
zty = 0.5 * ( vtau(ji ,jj-1) + vtau(ji,jj) )
zmod = SQRT( ztx * ztx + zty * zty )
or
ztx = utau(ji-1,jj ) + utau(ji,jj)
zty = vtau(ji ,jj-1) + vtau(ji,jj)
zmod = 0.25 * SQRT( ztx * ztx + zty * zty )
You will find an even better version in version 4.0 and 4.2:
! Note the use of 0.5*(2-umask) in order to unmask the stress along coastlines
ztx = ( utau(ji-1,jj ) + utau(ji,jj) ) * 0.5_wp * ( 2._wp - MIN( umask(ji-1,jj ,1), umask(ji,jj,1) ) )
zty = ( vtau(ji ,jj-1) + vtau(ji,jj) ) * 0.5_wp * ( 2._wp - MIN( vmask(ji ,jj-1,1), vmask(ji,jj,1) ) )
zmod = SQRT( ztx * ztx + zty * zty ) * tmask(ji,jj,1)
Note that from version 5.0, the wind stress component are computed at T point, which means that we directly compute:
zmod = SQRT( utau(ji,jj) * utau(ji,jj) + vtau(ji,jj) * vtau(ji,jj) ) * smask0(ji,jj)
taum(ji,jj) = zmod
1 Like