Ignore:
Timestamp:
Aug 16, 2007 2:30:26 PM (14 years ago)
Author:
raasch
Message:

preliminary update of bugfixes and extensions for non-cyclic BCs

File:
1 edited

Legend:

Unmodified
Added
Removed
  • palm/trunk/SOURCE/flow_statistics.f90

    r102 r106  
    44! Actual revisions:
    55! -----------------
    6 ! Prescribed momentum fluxes at the top surface are used
     6! Prescribed momentum fluxes at the top surface are used,
     7! profiles for w*p* and w"e are calculated
    78!
    89! Former revisions:
     
    620621!
    621622!--    Divergence of vertical flux of resolved scale energy and pressure
    622 !--    fluctuations. First calculate the products, then the divergence.
     623!--    fluctuations as well as flux of pressure fluctuation itself (68).
     624!--    First calculate the products, then the divergence.
    623625!--    Calculation is time consuming. Do it only, if profiles shall be plotted.
    624        IF ( hom(nzb+1,2,55,0) /= 0.0 )  THEN
     626       IF ( hom(nzb+1,2,55,0) /= 0.0  .OR.  hom(nzb+1,2,68,0) /= 0.0 )  THEN
    625627
    626628          sums_ll = 0.0  ! local array
     
    654656             sums_l(k,55,tn) = ( sums_ll(k,1) - sums_ll(k-1,1) ) * ddzw(k)
    655657             sums_l(k,56,tn) = ( sums_ll(k,2) - sums_ll(k-1,2) ) * ddzw(k)
     658             sums_l(k,68,tn) = sums_ll(k,2)
    656659          ENDDO
    657660          sums_l(nzb,55,tn) = sums_l(nzb+1,55,tn)
    658661          sums_l(nzb,56,tn) = sums_l(nzb+1,56,tn)
    659 
    660        ENDIF
    661 
    662 !
    663 !--    Divergence of vertical flux of SGS TKE
    664        IF ( hom(nzb+1,2,57,0) /= 0.0 )  THEN
     662          sums_l(nzb,68,tn) = 0.0    ! because w* = 0 at nzb
     663
     664       ENDIF
     665
     666!
     667!--    Divergence of vertical flux of SGS TKE and the flux itself (69)
     668       IF ( hom(nzb+1,2,57,0) /= 0.0  .OR.  hom(nzb+1,2,69,0) /= 0.0 )  THEN
    665669
    666670          !$OMP DO
     
    669673                DO  k = nzb_s_outer(j,i)+1, nzt
    670674
    671                    sums_l(k,57,tn) = sums_l(k,57,tn) + (                       &
     675                   sums_l(k,57,tn) = sums_l(k,57,tn) - 0.5 * (                 &
    672676                   (km(k,j,i)+km(k+1,j,i)) * (e(k+1,j,i)-e(k,j,i)) * ddzu(k+1) &
    673677                 - (km(k-1,j,i)+km(k,j,i)) * (e(k,j,i)-e(k-1,j,i)) * ddzu(k)   &
    674                                                  ) * ddzw(k)
     678                                                             ) * ddzw(k)
     679
     680                   sums_l(k,69,tn) = sums_l(k,69,tn) - 0.5 * (                 &
     681                   (km(k,j,i)+km(k+1,j,i)) * (e(k+1,j,i)-e(k,j,i)) * ddzu(k+1) &
     682                                                              )
    675683
    676684                ENDDO
     
    678686          ENDDO
    679687          sums_l(nzb,57,tn) = sums_l(nzb+1,57,tn)
     688          sums_l(nzb,69,tn) = sums_l(nzb+1,69,tn)
    680689
    681690       ENDIF
     
    832841       hom(:,1,55,sr) = sums(:,55)     ! w*u*u*/dz
    833842       hom(:,1,56,sr) = sums(:,56)     ! w*p*/dz
    834        hom(:,1,57,sr) = sums(:,57)     ! w"e/dz
     843       hom(:,1,57,sr) = sums(:,57)     ! ( w"e + w"p"/rho )/dz
    835844       hom(:,1,58,sr) = sums(:,58)     ! u"pt"
    836845       hom(:,1,59,sr) = sums(:,59)     ! u*pt*
     
    843852       hom(:,1,66,sr) = sums(:,66)     ! w*sa*
    844853       hom(:,1,67,sr) = sums(:,65) + sums(:,66)    ! wsa
     854       hom(:,1,68,sr) = sums(:,68)     ! w*p*
     855       hom(:,1,69,sr) = sums(:,69)     ! w"e + w"p"/rho
    845856
    846857       hom(:,1,pr_palm-1,sr) = sums(:,pr_palm-1)
Note: See TracChangeset for help on using the changeset viewer.