/[MITgcm]/MITgcm/pkg/exf/exf_wind.F
ViewVC logotype

Diff of /MITgcm/pkg/exf/exf_wind.F

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.5 by mlosch, Thu Mar 8 08:42:24 2007 UTC revision 1.6 by mlosch, Thu Mar 8 14:45:07 2007 UTC
# Line 92  c             cdn(umps); ustar can be di Line 92  c             cdn(umps); ustar can be di
92  C-   no need for wind-stress inversion since everything  C-   no need for wind-stress inversion since everything
93  C    (ustar, ... etc ...) is derived directly from wind-stress  C    (ustar, ... etc ...) is derived directly from wind-stress
94    
95            ustmp = ustress(i,j,bi,bj)*ustress(i,j,bi,bj) +            ustmp = 0.5*
96       &         vstress(i,j,bi,bj)*vstress(i,j,bi,bj)       &         (ustress(i,  j,bi,bj)*ustress(i  ,j,bi,bj)
97         &         +ustress(i+1,j,bi,bj)*ustress(i+1,j,bi,bj)
98         &         +vstress(i,j,  bi,bj)*vstress(i,j  ,bi,bj)
99         &         +vstress(i,j+1,bi,bj)*vstress(i,j+1,bi,bj))
100         &         )
101            if ( ustmp .ne. 0. _d 0 ) then            if ( ustmp .ne. 0. _d 0 ) then
102               ustar = sqrt(ustmp/atmrho)               ustar = sqrt(ustmp/atmrho)
103               cw(i,j,bi,bj) = ustress(i,j,bi,bj)/sqrt(ustmp)               cw(i,j,bi,bj) = ustress(i,j,bi,bj)/sqrt(ustmp)
# Line 107  C    (ustar, ... etc ...) is derived dir Line 111  C    (ustar, ... etc ...) is derived dir
111            if ( ustar .eq. 0. _d 0 ) then            if ( ustar .eq. 0. _d 0 ) then
112               us(i,j,bi,bj) = 0. _d 0               us(i,j,bi,bj) = 0. _d 0
113            else if ( ustar .lt. ustofu11 ) then            else if ( ustar .lt. ustofu11 ) then
114               tmp1 = -cquadrag_2/cquadrag_1/2               tmp1 = -cquadrag_2/cquadrag_1/2.
115               tmp2 = sqrt(tmp1*tmp1 + ustar*ustar/cquadrag_1)               tmp2 = sqrt(tmp1*tmp1 + ustar*ustar/cquadrag_1)
116               us(i,j,bi,bj) = sqrt(tmp1 + tmp2)               us(i,j,bi,bj) = sqrt(tmp1 + tmp2)
117            else            else
118               tmp3 = clindrag_2/clindrag_1/3               tmp3 = clindrag_2/clindrag_1/3.
119               tmp4 = ustar*ustar/clindrag_1/2 - tmp3**3               tmp4 = ustar*ustar/clindrag_1/2. - tmp3**3
120               tmp5 = sqrt(ustar*ustar/clindrag_1*               tmp5 = sqrt(ustar*ustar/clindrag_1*
121       &            (ustar*ustar/clindrag_1/4 - tmp3**3))       &            (ustar*ustar/clindrag_1/4. - tmp3**3))
122               us(i,j,bi,bj)   = (tmp4 + tmp5)**(1/3) +               us(i,j,bi,bj)   = (tmp4 + tmp5)**(1./3.) +
123       &            tmp3**2 * (tmp4 + tmp5)**(-1/3) - tmp3       &            tmp3**2 * (tmp4 + tmp5)**(-1./3.) - tmp3
124            endif            endif
125            uwind(i,j,bi,bj) = us(i,j,bi,bj)*cw(i,j,bi,bj)            uwind(i,j,bi,bj) = us(i,j,bi,bj)*cw(i,j,bi,bj)
126            vwind(i,j,bi,bj) = us(i,j,bi,bj)*sw(i,j,bi,bj)            vwind(i,j,bi,bj) = us(i,j,bi,bj)*sw(i,j,bi,bj)

Legend:
Removed from v.1.5  
changed lines
  Added in v.1.6

  ViewVC Help
Powered by ViewVC 1.1.22