Changeset 1276 for palm/trunk


Ignore:
Timestamp:
Jan 15, 2014 1:40:41 PM (10 years ago)
Author:
heinze
Message:

Usage of Dirichlet bottom boundary condition for scalars in conjunction with large scale forcing enabled

Location:
palm/trunk/SOURCE
Files:
4 edited

Legend:

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

    r1242 r1276  
    2020! Current revisions:
    2121! -----------------
    22 !
     22! Use LSF_DATA also in case of Dirichlet bottom boundary condition for scalars
    2323!
    2424! Former revisions:
     
    16131613    ENDIF
    16141614
    1615     IF ( surface_heatflux == 9999999.9  .AND.  .NOT. large_scale_forcing )  THEN
    1616         constant_heatflux     = .FALSE.
     1615    IF ( surface_heatflux == 9999999.9  )  THEN
     1616       constant_heatflux = .FALSE.
     1617       IF ( large_scale_forcing )  THEN
     1618          IF ( ibc_pt_b == 0 )  THEN
     1619             constant_heatflux = .FALSE.
     1620          ELSEIF ( ibc_pt_b == 1 )  THEN
     1621             constant_heatflux = .TRUE.
     1622             IF ( TRIM( initializing_actions ) /= 'read_restart_data' )  THEN
     1623                surface_heatflux = shf_surf(1)
     1624             ENDIF
     1625          ENDIF
     1626       ENDIF
    16171627    ELSE
    1618         constant_heatflux     = .TRUE.
     1628        constant_heatflux = .TRUE.
    16191629        IF ( TRIM( initializing_actions ) /= 'read_restart_data' .AND. &
    16201630               large_scale_forcing ) THEN
    1621            surface_heatflux      = shf_surf(1)
     1631           surface_heatflux = shf_surf(1)
    16221632        ENDIF
    16231633    ENDIF
     
    17421752       ENDIF
    17431753
    1744        IF ( surface_waterflux == 9999999.9  .AND.  &
    1745                              .NOT. large_scale_forcing )  THEN
    1746            constant_waterflux     = .FALSE.
     1754       IF ( surface_waterflux == 9999999.9  )  THEN
     1755          constant_waterflux = .FALSE.
     1756          IF ( large_scale_forcing )  THEN
     1757             IF ( ibc_q_b == 0 )  THEN
     1758                constant_waterflux = .FALSE.
     1759             ELSEIF ( ibc_q_b == 1 )  THEN
     1760                constant_waterflux = .TRUE.
     1761                IF ( TRIM( initializing_actions ) /= 'read_restart_data' )  THEN
     1762                   surface_waterflux = qsws_surf(1)
     1763                ENDIF
     1764             ENDIF
     1765          ENDIF
    17471766       ELSE
    1748            constant_waterflux    = .TRUE.
    1749            IF ( TRIM( initializing_actions ) /= 'read_restart_data' .AND. &
    1750                large_scale_forcing ) THEN
    1751               surface_waterflux      = qsws_surf(1)
    1752            ENDIF
     1767          constant_waterflux = .TRUE.
     1768          IF ( TRIM( initializing_actions ) /= 'read_restart_data' .AND. &
     1769                 large_scale_forcing ) THEN
     1770             surface_waterflux = qsws_surf(1)
     1771          ENDIF
    17531772       ENDIF
    17541773
  • palm/trunk/SOURCE/ls_forcing.f90

    r1250 r1276  
    238238       fac = ( time -time_surf(t) ) / ( time_surf(t+1) - time_surf(t) )
    239239
    240        shf              = shf_surf(t) + fac * ( shf_surf(t+1) - shf_surf(t) )
    241        qsws             = qsws_surf(t) + fac * ( qsws_surf(t+1) - qsws_surf(t) )
    242        pt_surface       = pt_surf(t) + fac * ( pt_surf(t+1) - pt_surf(t) )
     240       IF ( ibc_pt_b == 0 )  THEN
     241!
     242!--       In case of Dirichlet boundary condition shf must not
     243!--       be set - it is calculated via MOST in prandtl_fluxes
     244          pt_surface = pt_surf(t) + fac * ( pt_surf(t+1) - pt_surf(t) )
     245
     246       ELSEIF ( ibc_pt_b == 1 )  THEN
     247!
     248!--       In case of Neumann boundary condition pt_surface is needed for
     249!--       calculation of reference density
     250          shf        = shf_surf(t) + fac * ( shf_surf(t+1) - shf_surf(t) )
     251          pt_surface = pt_surf(t) + fac * ( pt_surf(t+1) - pt_surf(t) )
     252
     253       ENDIF
     254
     255       IF ( ibc_q_b == 0 )  THEN
     256!
     257!--       In case of Dirichlet boundary condition qsws must not
     258!--       be set - it is calculated via MOST in prandtl_fluxes
     259          q_surface = q_surf(t) + fac * ( q_surf(t+1) - q_surf(t) )
     260
     261       ELSEIF ( ibc_pt_b == 1 )  THEN
     262
     263          qsws = qsws_surf(t) + fac * ( qsws_surf(t+1) - qsws_surf(t) )
     264
     265       ENDIF
     266
    243267       surface_pressure = p_surf(t) + fac * ( p_surf(t+1) - p_surf(t) )
    244268
  • palm/trunk/SOURCE/prandtl_fluxes.f90

    r1258 r1276  
    2020! Current revisions:
    2121! -----------------
    22 !
     22! Use LSF_DATA also in case of Dirichlet bottom boundary condition for scalars
    2323!
    2424! Former revisions:
     
    120120!--    For a given surface temperature:
    121121!--    (the Richardson number is still the one from the previous time step)
     122   
     123       IF ( large_scale_forcing .AND. lsf_surf )  THEN
     124          pt(0,:,:) = pt_surface
     125       ENDIF
     126
    122127       !$OMP PARALLEL DO PRIVATE( a, b, k, z_p )
    123128       !$acc kernels loop
     
    334339       ELSE
    335340          coupled_run = ( coupling_mode == 'atmosphere_to_ocean' .AND. run_coupled )
     341
     342           IF ( large_scale_forcing .AND. lsf_surf )  THEN
     343              q(0,:,:) = q_surface
     344           ENDIF
     345
    336346          !$OMP PARALLEL DO PRIVATE( a, b, k, z_p )
    337347          !$acc kernels loop independent
  • palm/trunk/SOURCE/time_integration.f90

    r1258 r1276  
    2020! Current revisions:
    2121! ------------------
    22 !
     22! Use LSF_DATA also in case of Dirichlet bottom boundary condition for scalars
    2323!
    2424! Former revisions:
     
    574574
    575575!
     576!--          Determine surface fluxes shf and qsws and surface values
     577!--          pt_surface and q_surface in dependence on data from external
     578!--          file LSF_DATA respectively
     579             IF ( ( large_scale_forcing .AND. lsf_surf ) .AND. &
     580                 intermediate_timestep_count == intermediate_timestep_count_max )&
     581             THEN
     582                CALL ls_forcing_surf ( simulated_time )
     583             ENDIF
     584
     585!
    576586!--          First the vertical fluxes in the Prandtl layer are being computed
    577587             IF ( prandtl_layer )  THEN
     
    579589                CALL prandtl_fluxes
    580590                CALL cpu_log( log_point(19), 'prandtl_fluxes', 'stop' )
    581              ENDIF
    582 
    583 !
    584 !--          Determine shf and qsws in dependence on data from external file
    585 !--          LSF_DATA
    586              IF ( ( large_scale_forcing .AND. lsf_surf ) .AND. &
    587                  intermediate_timestep_count == intermediate_timestep_count_max )&
    588              THEN
    589                 CALL ls_forcing_surf ( simulated_time )
    590591             ENDIF
    591592
Note: See TracChangeset for help on using the changeset viewer.