Changeset 3142 for palm/trunk/SOURCE


Ignore:
Timestamp:
Jul 17, 2018 3:27:45 PM (6 years ago)
Author:
suehring
Message:

Bugfix in referencing buildings on orography top; minor bugfix for last LSM commit

Location:
palm/trunk/SOURCE
Files:
2 edited

Legend:

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

    r3139 r3142  
    2525! -----------------
    2626! $Id$
     27! Bugfix in referencing buildings on orography top
     28!
     29! 3139 2018-07-17 11:30:10Z Giersch
    2730! Bugfix in case of restarts and grid stretching
    2831!
     
    15221525             DO  k = nzb, nzt
    15231526                IF ( zu(k) - ocean_offset <= oro_max(nr) )                     &
    1524                    oro_max_l = zw(k) - ocean_offset
     1527                   oro_max_l(nr) = zw(k) - ocean_offset
    15251528             ENDDO
    1526              oro_max = oro_max_l
     1529             oro_max(nr) = oro_max_l(nr)
    15271530          ENDDO
    15281531       ENDIF
     
    15321535          DO  j = nys, nyn
    15331536             topo_top_index = 0
     1537!
     1538!--          Obtain index in global building_id array
     1539             IF ( buildings_f%from_file )  THEN
     1540                IF ( building_id_f%var(j,i) /= building_id_f%fill )  THEN
     1541!
     1542!--                Determine index where maximum terrain height occupied by
     1543!--                the respective building height is stored.
     1544                   nr = MINLOC( ABS( build_ids_final -                         &
     1545                                     building_id_f%var(j,i) ), DIM = 1 )
     1546                ENDIF
     1547             ENDIF
    15341548             DO  k = nzb, nzt
    15351549!
     
    15511565!--             3D buildings require separate treatment.
    15521566                IF ( buildings_f%from_file  .AND.  buildings_f%lod == 1 )  THEN
    1553                    IF ( building_id_f%var(j,i) /= building_id_f%fill )  THEN
    1554 !
    1555 !--                   Determine index where maximum terrain height occupied by
    1556 !--                   the respective building height is stored.
    1557                       nr = MINLOC( ABS( build_ids_final -                      &
    1558                                         building_id_f%var(j,i) ), DIM = 1 )
    1559        
     1567                   IF ( building_id_f%var(j,i) /= building_id_f%fill )  THEN       
    15601568                      IF ( zu(k) - ocean_offset <=                             &
    15611569                           oro_max(nr) + buildings_f%var_2d(j,i) )  THEN
     
    15761584             IF ( buildings_f%from_file  .AND.  buildings_f%lod == 2 )  THEN
    15771585                IF ( building_id_f%var(j,i) /= building_id_f%fill )  THEN
    1578 !
    1579 !--                Determine index for maximum-terrain-height array.
    1580                    nr = MINLOC( ABS( build_ids_final -                         &
    1581                                      building_id_f%var(j,i) ), DIM = 1 )
    15821586!
    15831587!--                Extend building down to the terrain surface, i.e. fill-up
  • palm/trunk/SOURCE/land_surface_model_mod.f90

    r3138 r3142  
    2525! -----------------
    2626! $Id$
     27! Minor bugfix for last commit.
     28!
     29! 3138 2018-07-17 08:21:20Z maronga
    2730! Bugfix: limit roughness lengths in case of sea surface with constant_roughness
    2831! = .F.
     
    69816984             ENDIF
    69826985             
    6983              IF ( surf_lsm_h%z0(m) >= surf_lsm_h%z_mo(m) )  THEN
     6986             IF ( surf_lsm_h%z0q(m) >= surf_lsm_h%z_mo(m) )  THEN
    69846987 
    69856988                surf_lsm_h%z0q(m) = 0.9_wp * surf_lsm_h%z_mo(m)
Note: See TracChangeset for help on using the changeset viewer.