Changeset 1575 for palm/trunk/SOURCE/lpm_init.f90
- Timestamp:
- Mar 27, 2015 9:56:27 AM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
palm/trunk/SOURCE/lpm_init.f90
r1360 r1575 20 20 ! Current revisions: 21 21 ! ----------------- 22 ! 22 ! initial vertical particle position is allowed to follow the topography 23 23 ! 24 24 ! Former revisions: … … 101 101 102 102 USE indices, & 103 ONLY: nx, nxl, nxlg, nxrg, nxr, ny, nyn, nys, nyng, nysg, nz, nzb, nzt 103 ONLY: nx, nxl, nxlg, nxrg, nxr, ny, nyn, nys, nyng, nysg, nz, nzb, & 104 nzb_w_inner, nzt 104 105 105 106 USE kinds … … 126 127 prt_count, psb, psl, psn, psr, pss, pst, & 127 128 radius, random_start_position, read_particles_from_restartfile,& 128 s kip_particles_for_tail, sort_count,&129 seed_follows_topography, skip_particles_for_tail, sort_count, & 129 130 tail_mask, total_number_of_particles, total_number_of_tails, & 130 131 use_particle_tails, use_sgs_for_particles, & … … 649 650 pos_x = psl(i) 650 651 651 652 xloop: DO WHILE ( pos_x <= psr(i) ) 652 653 653 654 IF ( pos_x >= ( nxl - 0.5_wp ) * dx .AND. & … … 738 739 tmp_particle%tail_id = 0 739 740 ENDIF 741 ! 742 !-- Determine the grid indices of the particle position 740 743 ip = ( tmp_particle%x + 0.5_wp * dx ) * ddx 741 744 jp = ( tmp_particle%y + 0.5_wp * dy ) * ddy 742 745 kp = tmp_particle%z / dz + 1 + offset_ocean_nzt_m1 746 747 IF ( seed_follows_topography ) THEN 748 ! 749 !-- Particle height is given relative to topography 750 kp = kp + nzb_w_inner(jp,ip) 751 tmp_particle%z = tmp_particle%z + zw(kp) 752 IF ( kp > nzt ) THEN 753 pos_x = pos_x + pdx(i) 754 CYCLE xloop 755 ENDIF 756 ENDIF 743 757 744 758 local_count(kp,jp,ip) = local_count(kp,jp,ip) + 1 … … 758 772 pos_x = pos_x + pdx(i) 759 773 760 ENDDO 774 ENDDO xloop 761 775 762 776 ENDIF
Note: See TracChangeset
for help on using the changeset viewer.