Changeset 217 for palm/trunk/SOURCE


Ignore:
Timestamp:
Dec 9, 2008 6:00:48 PM (15 years ago)
Author:
letzel
Message:
  • NCL scripts in trunk/SCRIPTS/NCL updated
Location:
palm/trunk/SOURCE
Files:
1 added
8 edited

Legend:

Unmodified
Added
Removed
  • palm/trunk/SOURCE/CURRENT_MODIFICATIONS

    r216 r217  
    1111User can add additional routines in files user_additional_routines.f90
    1212
     13User can check user parameters and deduce further quantities in user_check_parameters
     14
    1315check_for_restart, check_parameters, data_output_dvrp, init_dvrp, init_pegrid, local_stop, modules, package_parin, palm, surface_coupler, timestep, user_additional_routines
    1416Makefile, mrun, mbuild, subjob
    1517
    16 New: init_coupling
     18New: init_coupling, user_check_parameters
    1719
    1820
     
    4143Origin of the xy-coordinate system shifted from the center of the first
    4244grid cell (indices i=0, j=0) to the south-left corner of this cell. (netcdf)
     45
     46Topography definition according to new user parameter topography_grid_convention
     47(init_grid, modules, user_header, user_init_grid, user_parin)
    4348
    4449Makefile, mbuild, mrun, advec_s_bc, check_parameters, local_stop, modules, netcdf, read_var_list, read_3d_binary, user_read_restart_data
  • palm/trunk/SOURCE/Makefile

    r213 r217  
    7676        timestep_scheme_steering.f90 transpose.f90 user_3d_data_averaging.f90 \
    7777        user_actions.f90 user_additional_routines.f90 user_advec_particles.f90 \
    78         user_check_data_output.f90 \
    79         user_check_data_output_pr.f90 user_data_output_2d.f90 \
     78        user_check_data_output.f90 user_check_data_output_pr.f90 \
     79        user_check_parameters.f90 user_data_output_2d.f90 \
    8080        user_data_output_3d.f90 user_data_output_dvrp.f90 \
    8181        user_define_netcdf_grid.f90 user_dvrp_coltab.f90 user_header.f90 \
     
    116116        timestep.o timestep_scheme_steering.o transpose.o \
    117117        user_3d_data_averaging.o user_actions.o user_additional_routines.o \
    118         user_advec_particles.o \
    119         user_check_data_output.o user_check_data_output_pr.o \
     118        user_advec_particles.o user_check_data_output.o \
     119        user_check_data_output_pr.o user_check_parameters.o \
    120120        user_data_output_2d.o user_data_output_3d.o user_data_output_dvrp.o \
    121121        user_define_netcdf_grid.o user_dvrp_coltab.o user_header.o \
     
    271271user_check_data_output.o: modules.o user_module.o
    272272user_check_data_output_pr.o: modules.o user_module.o
     273user_check_parameters.o: modules.o user_module.o
    273274user_data_output_2d.o: modules.o user_module.o
    274275user_data_output_3d.o: modules.o user_module.o
  • palm/trunk/SOURCE/check_parameters.f90

    r215 r217  
    44! Actual revisions:
    55! -----------------
     6! +user_check_parameters
    67! Output of messages replaced by message handling routine.
    78! Implementation of an MPI-1 coupling: replaced myid with target_id,
     
    29002901    ENDIF
    29012902
     2903!
     2904!-- Check &userpar parameters
     2905    CALL user_check_parameters
     2906
    29022907
    29032908 END SUBROUTINE check_parameters
  • palm/trunk/SOURCE/init_grid.f90

    r145 r217  
    44! Actual revisions:
    55! -----------------
    6 !
     6! +topography_grid_convention
    77!
    88! Former revisions:
     
    372372
    373373!
    374 !--       Set the actual total size of the building. Due to the staggered grid,
    375 !--       the building will be displaced by -0.5dx in x-direction and by -0.5dy
    376 !--       in y-direction compared to the scalar grid.
     374!--       Define the building.
    377375          nzb_local = 0
    378376          nzb_local(bys:byn,bxl:bxr) = bh
     
    419417!
    420418!--       The DEFAULT case is reached either if the parameter topography
    421 !--       contains a wrong character string or if the user has coded a special
     419!--       contains a wrong character string or if the user has defined a special
    422420!--       case in the user interface. There, the subroutine user_init_grid
    423421!--       checks which of these two conditions applies.
     
    435433!
    436434!-- Consistency checks and index array initialization are only required for
    437 !-- non-flat topography, also the initialization of topography heigth arrays
     435!-- non-flat topography, also the initialization of topography height arrays
    438436!-- zu_s_inner and zw_w_inner
    439437    IF ( TRIM( topography ) /= 'flat' )  THEN
     
    472470       ENDIF
    473471
     472       IF ( topography_grid_convention == 'cell_edge' )  THEN
    474473!
    475 !--    The array nzb_local as defined above describes the actual total size of
    476 !--    topography which is defined by u=0 on the topography walls in x-direction
    477 !--    and by v=0 on the topography walls in y-direction. However, PALM uses
    478 !--    individual arrays nzb_u|v|w|s_inner|outer that are based on nzb_s_inner.
    479 !--    Therefore, the extent of topography in nzb_local is now reduced by 1dx
    480 !--    at the E topography walls and by 1dy at the N topography walls to form
    481 !--    the basis for nzb_s_inner.
    482        DO  j = -gls, ny + gls
    483           DO  i = -gls, nx
    484              nzb_local(j,i) = MIN( nzb_local(j,i), nzb_local(j,i+1) )
    485           ENDDO
    486        ENDDO
    487 !--    apply cyclic boundary conditions in x-direction
    488        nzb_local(:,nx+1:nx+gls) = nzb_local(:,0:gls-1)
    489        DO  i = -gls, nx + gls
    490           DO  j = -gls, ny
    491              nzb_local(j,i) = MIN( nzb_local(j,i), nzb_local(j+1,i) )
    492           ENDDO
    493        ENDDO
    494 !--    apply cyclic boundary conditions in y-direction
    495        nzb_local(ny+1:ny+gls,:) = nzb_local(0:gls-1,:)
     474!--       The array nzb_local as defined using the 'cell_edge' convention
     475!--       describes the actual total size of topography which is defined at the
     476!--       cell edges where u=0 on the topography walls in x-direction and v=0
     477!--       on the topography walls in y-direction. However, PALM uses individual
     478!--       arrays nzb_u|v|w|s_inner|outer that are based on nzb_s_inner.
     479!--       Therefore, the extent of topography in nzb_local is now reduced by
     480!--       1dx at the E topography walls and by 1dy at the N topography walls
     481!--       to form the basis for nzb_s_inner.
     482          DO  j = -gls, ny + gls
     483             DO  i = -gls, nx
     484                nzb_local(j,i) = MIN( nzb_local(j,i), nzb_local(j,i+1) )
     485             ENDDO
     486          ENDDO
     487!--       apply cyclic boundary conditions in x-direction
     488!(ist das erforderlich? Ursache von Seung Bus Fehler?)
     489          nzb_local(:,nx+1:nx+gls) = nzb_local(:,0:gls-1)
     490          DO  i = -gls, nx + gls
     491             DO  j = -gls, ny
     492                nzb_local(j,i) = MIN( nzb_local(j,i), nzb_local(j+1,i) )
     493             ENDDO
     494          ENDDO
     495!--       apply cyclic boundary conditions in y-direction
     496!(ist das erforderlich? Ursache von Seung Bus Fehler?)
     497          nzb_local(ny+1:ny+gls,:) = nzb_local(0:gls-1,:)
     498       ENDIF
    496499
    497500!
  • palm/trunk/SOURCE/modules.f90

    r216 r217  
    55! Actual revisions:
    66! -----------------
     7! +topography_grid_convention
    78! some dvrp-variables changed to single precision, variables for dvrp-mode
    89! pathlines added, +target_id, abort_mode, message_string
     
    263264    CHARACTER (LEN=8)    ::  run_date, run_time
    264265    CHARACTER (LEN=9)    ::  simulated_time_chr
     266    CHARACTER (LEN=11)   ::  topography_grid_convention = ' '
    265267    CHARACTER (LEN=12)   ::  version = ' ', revision = ' '
    266268    CHARACTER (LEN=16)   ::  loop_optimization = 'default', &
  • palm/trunk/SOURCE/user_header.f90

    r211 r217  
    44! Actual revisions:
    55! -----------------
     6! +topography_grid_convention
    67! Former file user_interface.f90 split into one file per subroutine
    78!
     
    1516!------------------------------------------------------------------------------!
    1617
     18    USE control_parameters
    1719    USE statistics
    1820    USE user
     
    4143    ENDIF
    4244
    43 
     45    IF ( TRIM( topography ) /= 'flat' )  THEN
     46       WRITE ( io, 300 )
     47       IF ( TRIM( topography_grid_convention ) == ' ' )  THEN
     48          IF ( TRIM( topography ) == 'single_building' )  THEN
     49             WRITE ( io, 301 )
     50          ELSEIF ( TRIM( topography ) == 'read_from_file' )  THEN
     51             WRITE ( io, 302 )
     52          ENDIF
     53       ELSEIF ( TRIM( topography_grid_convention ) == 'cell_edge' )  THEN
     54          WRITE ( io, 301 )
     55       ELSEIF ( TRIM( topography_grid_convention ) == 'cell_center' )  THEN
     56          WRITE ( io, 302 )
     57       ENDIF
     58    ENDIF
    4459
    4560!
     
    5166200 FORMAT (' Output of profiles and time series for following regions:' /)
    5267201 FORMAT (4X,'Region ',I1,':   ',A)
     68300 FORMAT (' Topography grid definition convention:'/)
     69301 FORMAT (' cell edge (staggered grid points'/  &
     70            ' (u in x-direction, v in y-direction))' /)
     71302 FORMAT (' cell center (scalar grid points)' /)
    5372
    5473
  • palm/trunk/SOURCE/user_init_grid.f90

    r211 r217  
    44! Actual revisions:
    55! -----------------
     6! +topography_grid_convention
    67! Former file user_interface.f90 split into one file per subroutine
    78!
     
    4142       CASE ( 'user_defined_topography_1' )
    4243!
    43 !--       Here the user can define his own topography. After definition, please
    44 !--       remove the following three lines!
     44!--       Here the user can define his own topography.
     45
     46!
     47!--       For each user-defined topography, the topography grid convention has
     48!--       to be explicitly set to either 'cell_edge' or 'cell_center'.
     49!--       topography_grid_convention = 'cell_edge'     ! OR:
     50!--       topography_grid_convention = 'cell_center'
     51
     52!
     53!--       After definition, please remove the following three lines!
    4554          PRINT*, '+++ user_init_grid: topography "', &
    4655               topography, '" not available yet'
  • palm/trunk/SOURCE/user_parin.f90

    r211 r217  
    44! Actual revisions:
    55! -----------------
     6! +topography_grid_convention
    67! Former file user_interface.f90 split into one file per subroutine
    78!
     
    2728
    2829
    29     NAMELIST /userpar/  data_output_pr_user, data_output_user, region
     30    NAMELIST /userpar/  data_output_pr_user, data_output_user, region,  &
     31                        topography_grid_convention
    3032
    3133!
Note: See TracChangeset for help on using the changeset viewer.