Ignore:
Timestamp:
Oct 8, 2015 7:32:13 AM (9 years ago)
Author:
raasch
Message:

bugfix concerning vertical index calculation for particles in case of ocean runs

File:
1 edited

Legend:

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

    r1683 r1685  
    1919! Current revisions:
    2020! ------------------
    21 !
    22 !
     21! TKE check for negative values (so far, only zero value was checked)
     22! offset_ocean_nzt_m1 removed
     23!
    2324! Former revisions:
    2425! -----------------
     
    9495        ONLY:  block_offset, c_0, density_ratio, dt_min_part, grid_particles,  &
    9596               iran_part, log_z_z0, number_of_particles, number_of_sublayers,  &
    96                particles, particle_groups, offset_ocean_nzt,                   &
    97                offset_ocean_nzt_m1, sgs_wfu_part, sgs_wfv_part, sgs_wfw_part,  &
    98                use_sgs_for_particles, vertical_particle_advection, z0_av_global
     97               particles, particle_groups, offset_ocean_nzt, sgs_wfu_part,     &
     98               sgs_wfv_part, sgs_wfw_part, use_sgs_for_particles,              &
     99               vertical_particle_advection, z0_av_global
    99100       
    100101    USE statistics,                                                            &
     
    289290!--    Same procedure for interpolation of the v velocity-component
    290291       DO  n = start_index(nb), end_index(nb)
     292
    291293          IF ( prandtl_layer  .AND.  particles(n)%z < z_p )  THEN
    292294
     
    417419                ENDIF
    418420!
    419 !--             Needed to avoid NaN particle velocities
    420                 IF ( e_int(n) == 0.0_wp )  THEN
     421!--             Needed to avoid NaN particle velocities (this might not be
     422!--             required any more)
     423                IF ( e_int(n) <= 0.0_wp )  THEN
    421424                   e_int(n) = 1.0E-20_wp
    422425                ENDIF
     
    671674                ENDIF
    672675!
    673 !--             Needed to avoid NaN particle velocities
    674                 IF ( e_int(n) == 0.0_wp )  THEN
     676!--             Needed to avoid NaN particle velocities (this might not be
     677!--             required any more)
     678                IF ( e_int(n) <= 0.0_wp )  THEN
    675679                   e_int(n) = 1.0E-20_wp
    676680                ENDIF
     
    11341138             ENDIF
    11351139
    1136  !           kw = particles(n)%z / dz
    1137              kw = kp-1                                    ! ok for ocean??? ( + offset_ocean_nzt_m1 ???)
     1140             kw = kp - 1
    11381141
    11391142             IF ( k == 0 )  THEN
Note: See TracChangeset for help on using the changeset viewer.