- Timestamp:
- Mar 6, 2017 6:16:35 PM (8 years ago)
- Location:
- palm/trunk/SOURCE
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
palm/trunk/SOURCE/check_parameters.f90
r2143 r2169 20 20 ! Current revisions: 21 21 ! ----------------- 22 ! 22 ! Bugfix, move setting for topography grid convention to init_grid 23 23 ! 24 24 ! Former revisions: … … 826 826 TRIM( action ) 827 827 CALL message( 'check_parameters', 'PA0014', 1, 2, 0, 6, 0 ) 828 ENDIF829 !830 !-- In case of non-flat topography, check whether the convention how to831 !-- define the topography grid has been set correctly, or whether the default832 !-- is applicable. If this is not possible, abort.833 IF ( TRIM( topography_grid_convention ) == ' ' ) THEN834 IF ( TRIM( topography ) /= 'single_building' .AND. &835 TRIM( topography ) /= 'single_street_canyon' .AND. &836 TRIM( topography ) /= 'read_from_file' ) THEN837 !-- The default value is not applicable here, because it is only valid838 !-- for the two standard cases 'single_building' and 'read_from_file'839 !-- defined in init_grid.840 WRITE( message_string, * ) &841 'The value for "topography_grid_convention" ', &842 'is not set. Its default value is & only valid for ', &843 '"topography" = ''single_building'', ', &844 '''single_street_canyon'' & or ''read_from_file''.', &845 ' & Choose ''cell_edge'' or ''cell_center''.'846 CALL message( 'check_parameters', 'PA0239', 1, 2, 0, 6, 0 )847 ELSE848 !-- The default value is applicable here.849 !-- Set convention according to topography.850 IF ( TRIM( topography ) == 'single_building' .OR. &851 TRIM( topography ) == 'single_street_canyon' ) THEN852 topography_grid_convention = 'cell_edge'853 ELSEIF ( TRIM( topography ) == 'read_from_file' ) THEN854 topography_grid_convention = 'cell_center'855 ENDIF856 ENDIF857 ELSEIF ( TRIM( topography_grid_convention ) /= 'cell_edge' .AND. &858 TRIM( topography_grid_convention ) /= 'cell_center' ) THEN859 WRITE( message_string, * ) &860 'The value for "topography_grid_convention" is ', &861 'not recognized. & Choose ''cell_edge'' or ''cell_center''.'862 CALL message( 'check_parameters', 'PA0240', 1, 2, 0, 6, 0 )863 828 ENDIF 864 829 -
palm/trunk/SOURCE/init_grid.f90
r2129 r2169 20 20 ! Current revisions: 21 21 ! ----------------- 22 ! 22 ! Bugfix, move setting for topography grid convention to init_grid, else, if no 23 ! value is set, the simulation may abort in case of restarts 23 24 ! 24 25 ! Former revisions: … … 896 897 ENDIF 897 898 899 ! 900 !-- In case of non-flat topography, check whether the convention how to 901 !-- define the topography grid has been set correctly, or whether the default 902 !-- is applicable. If this is not possible, abort. 903 IF ( TRIM( topography_grid_convention ) == ' ' ) THEN 904 IF ( TRIM( topography ) /= 'single_building' .AND. & 905 TRIM( topography ) /= 'single_street_canyon' .AND. & 906 TRIM( topography ) /= 'read_from_file' ) THEN 907 !-- The default value is not applicable here, because it is only valid 908 !-- for the two standard cases 'single_building' and 'read_from_file' 909 !-- defined in init_grid. 910 WRITE( message_string, * ) & 911 'The value for "topography_grid_convention" ', & 912 'is not set. Its default value is & only valid for ', & 913 '"topography" = ''single_building'', ', & 914 '''single_street_canyon'' & or ''read_from_file''.', & 915 ' & Choose ''cell_edge'' or ''cell_center''.' 916 CALL message( 'init_grid', 'PA0239', 1, 2, 0, 6, 0 ) 917 ELSE 918 !-- The default value is applicable here. 919 !-- Set convention according to topography. 920 IF ( TRIM( topography ) == 'single_building' .OR. & 921 TRIM( topography ) == 'single_street_canyon' ) THEN 922 topography_grid_convention = 'cell_edge' 923 ELSEIF ( TRIM( topography ) == 'read_from_file' ) THEN 924 topography_grid_convention = 'cell_center' 925 ENDIF 926 ENDIF 927 ELSEIF ( TRIM( topography_grid_convention ) /= 'cell_edge' .AND. & 928 TRIM( topography_grid_convention ) /= 'cell_center' ) THEN 929 WRITE( message_string, * ) & 930 'The value for "topography_grid_convention" is ', & 931 'not recognized. & Choose ''cell_edge'' or ''cell_center''.' 932 CALL message( 'init_grid', 'PA0240', 1, 2, 0, 6, 0 ) 933 ENDIF 934 898 935 IF ( topography_grid_convention == 'cell_edge' ) THEN 899 936 !
Note: See TracChangeset
for help on using the changeset viewer.