Changeset 4301 for palm/trunk/SOURCE
- Timestamp:
- Nov 22, 2019 12:09:09 PM (5 years ago)
- Location:
- palm/trunk/SOURCE
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
palm/trunk/SOURCE/check_parameters.f90
r4297 r4301 25 25 ! ----------------- 26 26 ! 4172 2019-08-20 11:55:33Z oliver.maas 27 ! removed message PA0421, concerning old parameter recycling_yshift 28 ! 29 ! 11:55:33Z oliver.maas 27 30 ! adjust message to the modified parameter recycling_yshift 28 31 ! … … 2974 2977 recycling_plane = recycling_width / dx 2975 2978 ! 2976 !-- recycling_yshift will have no effect with only one pe in y-direction2977 !-- is possible if there is only one PE in y direction.2978 IF ( ( recycling_yshift /= 0 ) .AND. pdims(2) < 2 ) THEN2979 WRITE( message_string, * ) 'recycling_yshift will have no ' // &2980 'effect with only one pe in y-direction.'2981 CALL message( 'check_parameters', 'PA0421', 0, 0, 0, 6, 0 )2982 ENDIF2983 2984 !2985 2979 !-- Check for correct input of recycling method for thermodynamic quantities 2986 2980 IF ( TRIM( recycling_method_for_thermodynamic_quantities ) /= 'turbulent_fluctuation' .AND. & -
palm/trunk/SOURCE/header.f90
r4300 r4301 20 20 ! Current revisions: 21 21 ! ----------------- 22 ! 22 ! replaced recycling_yshift by y_shift 23 23 ! 24 24 ! Former revisions: 25 25 ! ----------------- 26 26 ! $Id$ 27 ! 28 ! 4297 2019-11-21 10:37:50Z oliver.maas 27 29 ! Adjusted format for simulated time and related quantities 28 30 ! … … 926 928 WRITE ( io, 318 ) use_cmax, pt_damping_width, pt_damping_factor 927 929 IF ( turbulent_inflow ) THEN 928 IF ( recycling_yshift == 0 ) THEN930 IF ( y_shift == 0 ) THEN 929 931 WRITE ( io, 319 ) recycling_width, recycling_plane, & 930 932 inflow_damping_height, inflow_damping_width 931 933 ELSE 932 WRITE ( io, 322 ) recycling_yshift, recycling_width, recycling_plane, &934 WRITE ( io, 322 ) y_shift, recycling_width, recycling_plane, & 933 935 inflow_damping_height, inflow_damping_width 934 936 END IF … … 1741 1743 ' ----------------') 1742 1744 322 FORMAT (' turbulence recycling at inflow switched on'/ & 1743 ' y 1745 ' y-shift of the recycled inflow turbulence is',I3,' PE'/ & 1744 1746 ' width of recycling domain: ',F7.1,' m grid index: ',I4/ & 1745 1747 ' inflow damping height: ',F6.1,' m width: ',F6.1,' m'/) -
palm/trunk/SOURCE/inflow_turbulence.f90
r4297 r4301 25 25 ! ----------------- 26 26 ! $Id$ 27 ! use y_shift instead of old parameter recycling_yshift 28 ! 29 ! 4297 2019-11-21 10:37:50Z oliver.maas 27 30 ! changed recycling_yshift so that the y-shift can be a multiple of PE 28 31 ! instead of y-shift of a half domain width … … 55 58 56 59 USE control_parameters, & 57 ONLY: humidity, passive_scalar, recycling_plane, recycling_yshift, &60 ONLY: humidity, passive_scalar, recycling_plane, y_shift, & 58 61 recycling_method_for_thermodynamic_quantities 59 62 … … 87 90 inflow_dist !< turbulence signal of vars, added at inflow boundary 88 91 REAL(wp), DIMENSION(nzb:nzt+1,nysg:nyng,7,nbgp) :: & 89 local_inflow_dist !< auxiliary variable for inflow_dist, used for y shift92 local_inflow_dist !< auxiliary variable for inflow_dist, used for y-shift 90 93 91 94 CALL cpu_log( log_point(40), 'inflow_turbulence', 'start' ) … … 245 248 !-- y-shift for inflow_dist 246 249 !-- Shift inflow_dist in positive y direction by a number of 247 !-- PEs equal to recycling_yshift248 IF ( ( recycling_yshift /= 0 ) .AND. myidx == id_inflow ) THEN250 !-- PEs equal to y_shift 251 IF ( ( y_shift /= 0 ) .AND. myidx == id_inflow ) THEN 249 252 250 253 ! 251 254 !-- Calculate the ID of the PE which sends data to this PE (prev) and of the 252 255 !-- PE which receives data from this PE (next). 253 prev = MODULO(myidy - recycling_yshift , pdims(2))254 next = MODULO(myidy + recycling_yshift , pdims(2))256 prev = MODULO(myidy - y_shift , pdims(2)) 257 next = MODULO(myidy + y_shift , pdims(2)) 255 258 256 259 local_inflow_dist = 0.0_wp -
palm/trunk/SOURCE/init_pegrid.f90
r4264 r4301 25 25 ! ----------------- 26 26 ! $Id$ 27 ! changed message PA0467 28 ! 29 ! 4264 2019-10-15 16:00:23Z scharf 27 30 ! corrected error message string 28 31 ! … … 237 240 !-- Get coordinates of left and right neighbor on PE grid 238 241 IF ( y_shift /= 0 ) THEN 239 240 IF ( bc_lr /= 'cyclic' .OR. bc_ns /= 'cyclic' ) THEN 241 message_string = 'y_shift /= 0 is only allowed for cyclic ' // & 242 'boundary conditions in both directions ' 243 CALL message( 'check_parameters', 'PA0467', 1, 2, 0, 6, 0 ) 244 ENDIF 245 IF ( TRIM( psolver ) /= 'multigrid' .AND. & 246 TRIM( psolver ) /= 'multigrid_noopt') & 247 THEN 248 message_string = 'y_shift /= 0 requires a multigrid pressure solver ' 249 CALL message( 'check_parameters', 'PA0468', 1, 2, 0, 6, 0 ) 250 ENDIF 251 252 CALL MPI_CART_COORDS( comm2d, pright, ndim, rcoord, ierr ) 253 CALL MPI_CART_COORDS( comm2d, pleft, ndim, lcoord, ierr ) 254 255 ! 256 !-- If the x(y)-coordinate of the right (left) neighbor is smaller (greater) 257 !-- than that of the calling process, then the calling process is located on 258 !-- the right (left) boundary of the processor grid. In that case, 259 !-- the y-coordinate of that neighbor is increased (decreased) by y_shift. 260 !-- The rank of the process with that coordinate is then inquired and the 261 !-- neighbor rank for MPI_SENDRECV, pright (pleft) is set to it. 262 !-- In this way, the calling process receives a new right (left) neighbor 263 !-- for all future MPI_SENDRECV calls. That neighbor has a y-coordinate 264 !-- of y+(-)y_shift, where y is the original right (left) neighbor's 265 !-- y-coordinate. The modulo-operation ensures that if the neighbor's 266 !-- y-coordinate exceeds the grid-boundary, it will be relocated to 267 !-- the opposite part of the grid cyclicly. 268 IF ( rcoord(1) < pcoord(1) ) THEN 269 rcoord(2) = MODULO( rcoord(2) + y_shift, pdims(2) ) 270 CALL MPI_CART_RANK( comm2d, rcoord, pright, ierr ) 271 ENDIF 272 273 IF ( lcoord(1) > pcoord(1) ) THEN 274 lcoord(2) = MODULO( lcoord(2) - y_shift, pdims(2) ) 275 CALL MPI_CART_RANK( comm2d, lcoord, pleft, ierr ) 242 IF ( bc_lr == 'cyclic' ) THEN 243 IF ( TRIM( psolver ) /= 'multigrid' .AND. & 244 TRIM( psolver ) /= 'multigrid_noopt') & 245 THEN 246 message_string = 'y_shift /= 0 requires a multigrid pressure solver ' 247 CALL message( 'check_parameters', 'PA0468', 1, 2, 0, 6, 0 ) 248 ENDIF 249 250 CALL MPI_CART_COORDS( comm2d, pright, ndim, rcoord, ierr ) 251 CALL MPI_CART_COORDS( comm2d, pleft, ndim, lcoord, ierr ) 252 253 ! 254 !-- If the x(y)-coordinate of the right (left) neighbor is smaller (greater) 255 !-- than that of the calling process, then the calling process is located on 256 !-- the right (left) boundary of the processor grid. In that case, 257 !-- the y-coordinate of that neighbor is increased (decreased) by y_shift. 258 !-- The rank of the process with that coordinate is then inquired and the 259 !-- neighbor rank for MPI_SENDRECV, pright (pleft) is set to it. 260 !-- In this way, the calling process receives a new right (left) neighbor 261 !-- for all future MPI_SENDRECV calls. That neighbor has a y-coordinate 262 !-- of y+(-)y_shift, where y is the original right (left) neighbor's 263 !-- y-coordinate. The modulo-operation ensures that if the neighbor's 264 !-- y-coordinate exceeds the grid-boundary, it will be relocated to 265 !-- the opposite part of the grid cyclicly. 266 IF ( rcoord(1) < pcoord(1) ) THEN 267 rcoord(2) = MODULO( rcoord(2) + y_shift, pdims(2) ) 268 CALL MPI_CART_RANK( comm2d, rcoord, pright, ierr ) 269 ENDIF 270 271 IF ( lcoord(1) > pcoord(1) ) THEN 272 lcoord(2) = MODULO( lcoord(2) - y_shift, pdims(2) ) 273 CALL MPI_CART_RANK( comm2d, lcoord, pleft, ierr ) 274 ENDIF 275 276 ELSE 277 ! 278 !-- y-shift for non-cyclic boundary conditions is only implemented 279 !-- for the turbulence recycling method in inflow_turbulence.f90 280 IF ( .NOT. turbulent_inflow ) THEN 281 message_string = 'y_shift /= 0 is only allowed for cyclic ' // & 282 'boundary conditions in both directions ' // & 283 'or with turbulent_inflow == .TRUE.' 284 CALL message( 'check_parameters', 'PA0467', 1, 2, 0, 6, 0 ) 285 ENDIF 276 286 ENDIF 277 287 ENDIF -
palm/trunk/SOURCE/modules.f90
r4297 r4301 25 25 ! ----------------- 26 26 ! $Id$ 27 ! removed recycling_yshift 28 ! 29 ! 4297 2019-11-21 10:37:50Z oliver.maas 27 30 ! changed variable type of recycling_yshift from LOGICAL to INTEGER 28 31 ! … … 645 648 INTEGER(iwp) :: vg_vertical_gradient_level_ind(10) = -9999 !< grid index values of vg_vertical_gradient_level(s) 646 649 INTEGER(iwp) :: subs_vertical_gradient_level_i(10) = -9999 !< grid index values of subs_vertical_gradient_level(s) 647 INTEGER(iwp) :: recycling_yshift = 0 !< namelist parameter648 650 INTEGER(iwp), DIMENSION(0:1) :: ntdim_2d_xy !< number of output intervals for 2d data (xy) 649 651 INTEGER(iwp), DIMENSION(0:1) :: ntdim_2d_xz !< number of output intervals for 2d data (xz) -
palm/trunk/SOURCE/parin.f90
r4227 r4301 25 25 ! ----------------- 26 26 ! $Id$ 27 ! removed recycling_yshift 28 ! 29 ! 4227 2019-09-10 18:04:34Z gronemeier 27 30 ! implement new palm_date_time_mod 28 31 ! … … 190 193 random_generator, random_heatflux, rans_const_c, rans_const_sigma,& 191 194 rayleigh_damping_factor, rayleigh_damping_height, & 192 recycling_method_for_thermodynamic_quantities, & 193 recycling_width, recycling_yshift, & 195 recycling_method_for_thermodynamic_quantities, recycling_width, & 194 196 reference_state, residual_limit, & 195 197 rotation_angle, & … … 263 265 random_generator, random_heatflux, rans_const_c, rans_const_sigma,& 264 266 rayleigh_damping_factor, rayleigh_damping_height, & 265 recycling_method_for_thermodynamic_quantities, & 266 recycling_width, recycling_yshift, & 267 recycling_method_for_thermodynamic_quantities, recycling_width, & 267 268 reference_state, residual_limit, & 268 269 rotation_angle, & -
palm/trunk/SOURCE/read_restart_data_mod.f90
r4227 r4301 25 25 ! ----------------- 26 26 ! $Id$ 27 ! removed recycling_yshift 28 ! 29 ! 4227 2019-09-10 18:04:34Z gronemeier 27 30 ! implement new palm_date_time_mod and increased binary version 28 31 ! … … 550 553 CASE ( 'recycling_width' ) 551 554 READ ( 13 ) recycling_width 552 CASE ( 'recycling_yshift' )553 READ ( 13 ) recycling_yshift554 555 CASE ( 'ref_state' ) 555 556 READ ( 13 ) ref_state -
palm/trunk/SOURCE/write_restart_data_mod.f90
r4227 r4301 25 25 ! ----------------- 26 26 ! $Id$ 27 ! removed recycling_yshift 28 ! 29 ! 4227 2019-09-10 18:04:34Z gronemeier 27 30 ! implement new palm_date_time_mod and increased binary version 28 31 ! … … 555 558 WRITE ( 14 ) recycling_width 556 559 557 CALL wrd_write_string( 'recycling_yshift' )558 WRITE ( 14 ) recycling_yshift559 560 560 CALL wrd_write_string( 'ref_state' ) 561 561 WRITE ( 14 ) ref_state
Note: See TracChangeset
for help on using the changeset viewer.