Changeset 3637 for palm/trunk/SOURCE
- Timestamp:
- Dec 20, 2018 1:51:36 AM (6 years ago)
- Location:
- palm/trunk/SOURCE
- Files:
-
- 1 added
- 15 edited
Legend:
- Unmodified
- Added
- Removed
-
palm/trunk/SOURCE/Makefile
r3634 r3637 25 25 # ----------------- 26 26 # $Id$ 27 # Implementation of the PALM module interface 28 # 29 # 3634 2018-12-18 12:31:28Z knoop 27 30 # OpenACC port for SPEC 28 31 # … … 623 626 bulk_cloud_model_mod.f90 \ 624 627 model_1d_mod.f90 \ 628 module_interface.f90 \ 625 629 mod_kinds.f90 \ 626 630 mod_particle_attributes.f90 \ … … 785 789 modules.o 786 790 average_3d_data.o: \ 787 biometeorology_mod.o \788 bulk_cloud_model_mod.o \789 chemistry_model_mod.o \790 791 cpulog_mod.o \ 791 792 exchange_horiz_2d.o \ 792 gust_mod.o \ 793 land_surface_model_mod.o \ 794 mod_kinds.o \ 795 modules.o \ 796 ocean_mod.o \ 797 radiation_model_mod.o \ 798 salsa_mod.o \ 799 turbulence_closure_mod.o \ 800 urban_surface_mod.o 793 mod_kinds.o \ 794 module_interface.o \ 795 modules.o \ 796 turbulence_closure_mod.o 801 797 basic_constants_and_equations_mod.o: \ 802 798 mod_kinds.o … … 843 839 check_parameters.o: \ 844 840 basic_constants_and_equations_mod.o \ 845 biometeorology_mod.o \846 bulk_cloud_model_mod.o \847 841 chemistry_model_mod.o \ 848 842 chem_emissions_mod.o \ 849 gust_mod.o \850 843 init_vertical_profiles.o \ 851 land_surface_model_mod.o \852 large_scale_forcing_nudging_mod.o \853 844 model_1d_mod.o \ 854 mod _kinds.o \855 mod ules.o \856 nesting_offl_mod.o \845 module_interface.o \ 846 mod_kinds.o \ 847 modules.o \ 857 848 netcdf_data_input_mod.o \ 858 849 netcdf_interface_mod.o \ 859 ocean_mod.o \860 plant_canopy_model_mod.o \861 850 pmc_interface_mod.o \ 862 radiation_model_mod.o \863 salsa_mod.o \864 spectra_mod.o \865 851 subsidence_mod.o \ 866 surface_output_mod.o \867 synthetic_turbulence_generator_mod.o \868 852 turbulence_closure_mod.o \ 869 urban_surface_mod.o \ 870 vertical_nesting_mod.o \ 871 wind_turbine_model_mod.o 853 vertical_nesting_mod.o 872 854 chem_emissions_mod.o: \ 873 855 chem_gasphase_mod.o \ … … 978 960 data_output_2d.o: \ 979 961 basic_constants_and_equations_mod.o \ 980 biometeorology_mod.o \ 981 bulk_cloud_model_mod.o \ 982 chemistry_model_mod.o\ 983 cpulog_mod.o \ 984 gust_mod.o \ 962 bulk_cloud_model_mod.o \ 963 cpulog_mod.o \ 985 964 land_surface_model_mod.o \ 986 965 mod_kinds.o \ 987 966 mod_particle_attributes.o \ 988 modules.o \ 989 netcdf_interface_mod.o \ 990 ocean_mod.o \ 991 radiation_model_mod.o \ 992 salsa_mod.o \ 967 module_interface.o \ 968 modules.o \ 969 netcdf_interface_mod.o \ 993 970 surface_mod.o \ 994 971 urban_surface_mod.o 995 972 data_output_3d.o: \ 996 973 basic_constants_and_equations_mod.o \ 997 biometeorology_mod.o \ 998 bulk_cloud_model_mod.o \ 999 chemistry_model_mod.o \ 1000 cpulog_mod.o \ 1001 gust_mod.o \ 974 bulk_cloud_model_mod.o \ 975 cpulog_mod.o \ 1002 976 land_surface_model_mod.o \ 1003 977 mod_kinds.o \ 1004 978 mod_particle_attributes.o \ 1005 module s.o \1006 netcdf_interface_mod.o \1007 ocean_mod.o \1008 salsa_mod.o \979 module_interface.o \ 980 modules.o \ 981 netcdf_interface_mod.o \ 982 radiation_model_mod.o \ 1009 983 turbulence_closure_mod.o \ 1010 984 urban_surface_mod.o … … 1058 1032 basic_constants_and_equations_mod.o \ 1059 1033 bulk_cloud_model_mod.o \ 1060 chemistry_model_mod.o \ 1061 cpulog_mod.o \ 1062 gust_mod.o \ 1034 chem_modules.o \ 1035 cpulog_mod.o \ 1063 1036 land_surface_model_mod.o \ 1064 1037 large_scale_forcing_nudging_mod.o \ 1065 1038 mod_kinds.o \ 1039 module_interface.o \ 1066 1040 modules.o \ 1067 1041 netcdf_interface_mod.o \ … … 1076 1050 header.o: \ 1077 1051 basic_constants_and_equations_mod.o \ 1078 biometeorology_mod.o \ 1079 bulk_cloud_model_mod.o \ 1080 chemistry_model_mod.o \ 1052 bulk_cloud_model_mod.o \ 1081 1053 cpulog_mod.o \ 1082 1054 date_and_time_mod.o \ 1083 gust_mod.o \1084 land_surface_model_mod.o \1085 large_scale_forcing_nudging_mod.o \1086 1055 model_1d_mod.o \ 1087 mod _kinds.o \1088 mod ules.o \1089 netcdf_interface_mod.o \1090 ne sting_offl_mod.o \1056 module_interface.o \ 1057 mod_kinds.o \ 1058 modules.o \ 1059 netcdf_interface_mod.o \ 1091 1060 ocean_mod.o \ 1092 1061 plant_canopy_model_mod.o \ 1093 1062 pmc_handle_communicator_mod.o \ 1094 1063 pmc_interface_mod.o \ 1095 radiation_model_mod.o \1096 salsa_mod.o \1097 spectra_mod.o \1098 1064 subsidence_mod.o \ 1099 surface_mod.o \ 1100 virtual_flight_mod.o 1065 surface_mod.o 1101 1066 indoor_model_mod.o: \ 1102 1067 cpulog_mod.o \ … … 1355 1320 modules.o \ 1356 1321 time_to_string.o 1322 module_interface.o: \ 1323 mod_kinds.o \ 1324 modules.o \ 1325 biometeorology_mod.o \ 1326 bulk_cloud_model_mod.o \ 1327 chemistry_model_mod.o \ 1328 gust_mod.o \ 1329 indoor_model_mod.o \ 1330 land_surface_model_mod.o \ 1331 large_scale_forcing_nudging_mod.o \ 1332 multi_agent_system_mod.o \ 1333 nesting_offl_mod.o \ 1334 ocean_mod.o \ 1335 plant_canopy_model_mod.o \ 1336 radiation_model_mod.o \ 1337 salsa_mod.o \ 1338 spectra_mod.o \ 1339 surface_output_mod.o \ 1340 synthetic_turbulence_generator_mod.o \ 1341 urban_surface_mod.o \ 1342 user_read_restart_data_mod.o \ 1343 user_write_restart_data_mod.o \ 1344 virtual_flight_mod.o \ 1345 virtual_measurement_mod.o \ 1346 wind_turbine_model_mod.o 1357 1347 modules.o: \ 1358 1348 mod_kinds.o … … 1436 1426 write_restart_data_mod.o 1437 1427 parin.o: \ 1438 biometeorology_mod.o \1439 bulk_cloud_model_mod.o \1440 chemistry_model_mod.o \1441 1428 chem_modules.o \ 1442 1429 cpulog_mod.o \ 1443 1430 date_and_time_mod.o \ 1444 gust_mod.o \1445 indoor_model_mod.o \1446 land_surface_model_mod.o \1447 1431 model_1d_mod.o \ 1448 1432 mod_kinds.o \ 1449 1433 modules.o \ 1450 multi_agent_system_mod.o \ 1451 nesting_offl_mod.o \ 1452 netcdf_interface_mod.o \ 1453 ocean_mod.o \ 1454 plant_canopy_model_mod.o \ 1434 netcdf_interface_mod.o \ 1455 1435 pmc_interface_mod.o \ 1456 1436 progress_bar_mod.o \ 1457 radiation_model_mod.o \1458 1437 read_restart_data_mod.o \ 1459 salsa_mod.o \1460 spectra_mod.o \1461 surface_output_mod.o \1462 synthetic_turbulence_generator_mod.o \1463 1438 turbulence_closure_mod.o \ 1464 vertical_nesting_mod.o \ 1465 virtual_flight_mod.o \ 1466 virtual_measurement_mod.o \ 1467 wind_turbine_model_mod.o 1439 vertical_nesting_mod.o 1468 1440 plant_canopy_model_mod.o: \ 1469 1441 bulk_cloud_model_mod.o \ … … 1601 1573 modules.o 1602 1574 read_restart_data_mod.o: \ 1603 bulk_cloud_model_mod.o \ 1604 chemistry_model_mod.o \ 1575 chem_modules.o \ 1605 1576 cpulog_mod.o \ 1606 1577 date_and_time_mod.o \ 1607 gust_mod.o \1608 land_surface_model_mod.o \1609 modules.o \1610 1578 mod_kinds.o \ 1611 1579 model_1d_mod.o \ 1580 module_interface.o \ 1581 modules.o \ 1612 1582 netcdf_interface_mod.o \ 1613 1583 radiation_model_mod.o \ 1614 1584 random_function_mod.o\ 1615 1585 random_generator_parallel_mod.o \ 1616 salsa_mod.o \1617 1586 spectra_mod.o \ 1618 1587 surface_mod.o \ 1619 synthetic_turbulence_generator_mod.o \ 1620 urban_surface_mod.o \ 1621 user_read_restart_data_mod.o \ 1622 vertical_nesting_mod.o \ 1623 virtual_flight_mod.o \ 1624 wind_turbine_model_mod.o 1588 vertical_nesting_mod.o 1625 1589 run_control.o: \ 1626 1590 cpulog_mod.o \ … … 1661 1625 sum_up_3d_data.o: \ 1662 1626 basic_constants_and_equations_mod.o \ 1663 biometeorology_mod.o \ 1664 bulk_cloud_model_mod.o \ 1665 chemistry_model_mod.o \ 1666 cpulog_mod.o \ 1667 gust_mod.o \ 1668 land_surface_model_mod.o \ 1669 mod_kinds.o \ 1670 modules.o \ 1671 radiation_model_mod.o \ 1672 salsa_mod.o \ 1627 bulk_cloud_model_mod.o \ 1628 cpulog_mod.o \ 1629 mod_kinds.o \ 1630 module_interface.o \ 1631 modules.o \ 1673 1632 surface_mod.o \ 1674 1633 turbulence_closure_mod.o \ … … 1700 1659 surface_mod.o 1701 1660 swap_timelevel.o: \ 1702 bulk_cloud_model_mod.o \ 1703 chemistry_model_mod.o \ 1704 cpulog_mod.o \ 1705 gust_mod.o \ 1706 land_surface_model_mod.o \ 1707 mod_kinds.o \ 1708 modules.o \ 1709 ocean_mod.o \ 1661 cpulog_mod.o \ 1662 mod_kinds.o \ 1663 module_interface.o \ 1664 modules.o \ 1710 1665 pmc_interface_mod.o \ 1711 salsa_mod.o \ 1712 turbulence_closure_mod.o \ 1713 urban_surface_mod.o 1666 turbulence_closure_mod.o 1714 1667 synthetic_turbulence_generator_mod.o: \ 1715 1668 basic_constants_and_equations_mod.o \ … … 1992 1945 mod_kinds.o 1993 1946 write_restart_data_mod.o: \ 1994 bulk_cloud_model_mod.o \1995 chemistry_model_mod.o \1996 1947 date_and_time_mod.o \ 1997 gust_mod.o \1998 land_surface_model_mod.o \1999 1948 mod_kinds.o \ 2000 1949 mod_particle_attributes.o \ 2001 1950 model_1d_mod.o \ 2002 module s.o \2003 netcdf_interface_mod.o \2004 ocean_mod.o \1951 module_interface.o \ 1952 modules.o \ 1953 netcdf_interface_mod.o \ 2005 1954 radiation_model_mod.o \ 2006 1955 random_function_mod.o \ 2007 1956 random_generator_parallel_mod.o \ 2008 spectra_mod.o surface_mod.o \ 2009 synthetic_turbulence_generator_mod.o \ 2010 urban_surface_mod.o \ 2011 user_write_restart_data_mod.o \ 2012 vertical_nesting_mod.o \ 2013 virtual_flight_mod.o \ 2014 wind_turbine_model_mod.o 1957 spectra_mod.o \ 1958 surface_mod.o \ 1959 vertical_nesting_mod.o -
palm/trunk/SOURCE/average_3d_data.f90
r3597 r3637 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Implementation of the PALM module interface 28 ! 29 ! 3597 2018-12-04 08:40:18Z maronga 27 30 ! Added theta_2m 28 31 ! … … 173 176 USE averaging 174 177 175 USE biometeorology_mod, &176 ONLY: bio_3d_data_averaging177 178 USE bulk_cloud_model_mod, &179 ONLY: bulk_cloud_model, bcm_3d_data_averaging180 181 USE chemistry_model_mod, &182 ONLY: chem_3d_data_averaging183 184 178 USE control_parameters, & 185 ONLY: air_chemistry, average_count_3d, biometeorology, doav, doav_n, & 186 land_surface, ocean_mode, salsa, urban_surface, varnamelength 179 ONLY: average_count_3d, doav, doav_n, varnamelength 187 180 188 181 USE cpulog, & 189 182 ONLY: cpu_log, log_point 190 183 191 USE gust_mod, &192 ONLY: gust_3d_data_averaging, gust_module_enabled193 194 184 USE indices, & 195 185 ONLY: nbgp, nxl, nxlg, nxr, nxrg, nyn, nyng, nys, nysg, nzb, nzt … … 197 187 USE kinds 198 188 199 USE land_surface_model_mod, & 200 ONLY: lsm_3d_data_averaging 201 202 USE ocean_mod, & 203 ONLY: ocean_3d_data_averaging 204 205 USE radiation_model_mod, & 206 ONLY: radiation, radiation_3d_data_averaging 207 208 USE salsa_mod, & 209 ONLY: salsa_3d_data_averaging 189 USE module_interface, & 190 ONLY: module_interface_3d_data_averaging 210 191 211 192 USE turbulence_closure_mod, & 212 193 ONLY: tcm_3d_data_averaging 213 214 USE urban_surface_mod, &215 ONLY: usm_average_3d_data216 194 217 195 … … 573 551 574 552 CASE DEFAULT 575 ! 576 !-- Averaging of data from other modules 577 IF ( air_chemistry .AND. & 578 (trimvar(1:3) == 'kc_' .OR. trimvar(1:3) == 'em_') ) THEN 579 CALL chem_3d_data_averaging( 'average', doav(ii) ) 580 ENDIF 581 582 IF ( bulk_cloud_model ) THEN 583 CALL bcm_3d_data_averaging( 'average', doav(ii) ) 584 ENDIF 585 586 IF ( gust_module_enabled ) THEN 587 CALL gust_3d_data_averaging( 'average', doav(ii) ) 588 ENDIF 589 590 IF ( land_surface ) THEN 591 CALL lsm_3d_data_averaging( 'average', doav(ii) ) 592 ENDIF 593 594 IF ( ocean_mode ) THEN 595 CALL ocean_3d_data_averaging( 'average', doav(ii) ) 596 ENDIF 597 598 IF ( radiation ) THEN 599 CALL radiation_3d_data_averaging( 'average', doav(ii) ) 600 ENDIF 601 602 IF ( salsa ) THEN 603 CALL salsa_3d_data_averaging( 'average', doav(ii) ) 604 ENDIF 605 606 IF ( biometeorology ) THEN 607 CALL bio_3d_data_averaging( 'average', doav(ii) ) 608 ENDIF 609 610 CALL tcm_3d_data_averaging( 'average', doav(ii) ) 611 612 IF ( urban_surface .AND. trimvar(1:4) == 'usm_' ) THEN 613 CALL usm_average_3d_data( 'average', doav(ii) ) 614 ENDIF 615 616 ! 617 !-- User-defined quantities 618 CALL user_3d_data_averaging( 'average', doav(ii) ) 553 554 ! 555 !-- Averaging of data from turbulence closure module 556 CALL tcm_3d_data_averaging( 'average', trimvar ) 557 ! 558 !-- Averaging of data from all other modules 559 CALL module_interface_3d_data_averaging( 'average', trimvar ) 619 560 620 561 END SELECT -
palm/trunk/SOURCE/check_parameters.f90
r3597 r3637 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Implementation of the PALM module interface 28 ! 29 ! 3597 2018-12-04 08:40:18Z maronga 27 30 ! Added checks for theta_2m 28 31 ! … … 748 751 USE basic_constants_and_equations_mod 749 752 750 USE biometeorology_mod, &751 ONLY: bio_check_data_output, bio_check_parameters752 753 753 USE bulk_cloud_model_mod, & 754 ONLY: bulk_cloud_model, bcm_check_parameters, bcm_check_data_output, & 755 bcm_check_data_output_pr 756 757 USE chem_emissions_mod, & 758 ONLY: chem_emissions_check_parameters 754 ONLY: bulk_cloud_model 759 755 760 756 USE chem_modules 761 757 762 758 USE chemistry_model_mod, & 763 ONLY: chem_boundary_conds, chem_check_data_output, & 764 chem_check_data_output_pr, chem_check_parameters, chem_species 759 ONLY: chem_boundary_conds 765 760 766 761 USE control_parameters … … 770 765 USE grid_variables 771 766 772 USE gust_mod, &773 ONLY: gust_check_data_output, gust_check_data_output_pr, &774 gust_check_parameters, gust_module_enabled775 776 767 USE kinds 777 768 778 769 USE indices 779 780 USE land_surface_model_mod, &781 ONLY: lsm_check_data_output, lsm_check_data_output_pr, &782 lsm_check_parameters783 784 USE lsf_nudging_mod, &785 ONLY: lsf_nudging_check_parameters, lsf_nudging_check_data_output_pr786 770 787 771 USE model_1d_mod, & 788 772 ONLY: damp_level_1d, damp_level_ind_1d 789 773 790 USE nesting_offl_mod, & 791 ONLY: nesting_offl_check_parameters 792 774 USE module_interface, & 775 ONLY: module_interface_check_parameters, & 776 module_interface_check_data_output_pr, & 777 module_interface_check_data_output 778 793 779 USE netcdf_data_input_mod, & 794 780 ONLY: init_model, input_pids_static, netcdf_data_input_check_dynamic, & … … 800 786 waterflux_output_unit, momentumflux_output_unit 801 787 802 USE ocean_mod, &803 ONLY: ocean_check_data_output, ocean_check_data_output_pr, &804 ocean_check_parameters805 806 788 USE particle_attributes 807 789 808 790 USE pegrid 809 810 USE plant_canopy_model_mod, &811 ONLY: pcm_check_data_output, pcm_check_parameters812 791 813 792 USE pmc_interface, & … … 816 795 USE profil_parameter 817 796 818 USE radiation_model_mod, &819 ONLY: radiation, radiation_check_data_output, &820 radiation_check_data_output_pr, radiation_check_parameters821 822 USE salsa_mod, &823 ONLY: salsa_check_data_output, salsa_check_parameters824 825 USE spectra_mod, &826 ONLY: calculate_spectra, spectra_check_parameters827 828 797 USE statistics 829 798 830 799 USE subsidence_mod 831 800 832 USE surface_output_mod, &833 ONLY: surface_output_check_parameters834 835 USE synthetic_turbulence_generator_mod, &836 ONLY: stg_check_parameters837 838 801 USE transpose_indices 839 802 840 803 USE turbulence_closure_mod, & 841 ONLY: tcm_check_data_output, tcm_check_parameters 842 843 USE urban_surface_mod, & 844 ONLY: usm_check_data_output, usm_check_parameters 845 846 USE wind_turbine_model_mod, & 847 ONLY: wtm_check_parameters 804 ONLY: tcm_check_parameters, & 805 tcm_check_data_output 848 806 849 807 USE vertical_nesting_mod, & 850 ONLY: vnested, vnest_check_parameters 808 ONLY: vnested, & 809 vnest_check_parameters 851 810 852 811 … … 1525 1484 1526 1485 ! 1527 !-- Check the module settings: 1528 !-- tcm_check_parameters must be called at first 1486 !-- tcm_check_parameters must be called before all other module calls 1529 1487 CALL tcm_check_parameters 1530 1488 1531 IF ( biometeorology ) CALL bio_check_parameters 1532 IF ( bulk_cloud_model ) CALL bcm_check_parameters 1533 IF ( air_chemistry ) CALL chem_check_parameters 1534 ! IF ( air_chemistry ) CALL chem_emissions_check_parameters ! forkel preliminary 1535 IF ( gust_module_enabled ) CALL gust_check_parameters 1536 IF ( large_scale_forcing .OR. nudging ) & 1537 CALL lsf_nudging_check_parameters 1538 IF ( land_surface ) CALL lsm_check_parameters 1539 IF ( nesting_offline ) CALL nesting_offl_check_parameters 1540 IF ( ocean_mode ) CALL ocean_check_parameters 1541 IF ( plant_canopy ) CALL pcm_check_parameters 1542 IF ( radiation ) CALL radiation_check_parameters 1543 IF ( calculate_spectra ) CALL spectra_check_parameters 1544 CALL stg_check_parameters 1545 IF ( urban_surface ) CALL usm_check_parameters 1546 IF ( wind_turbine ) CALL wtm_check_parameters 1547 ! 1548 !-- Checks for surface data output 1549 IF ( surface_data_output ) CALL surface_output_check_parameters 1550 ! 1551 !-- When SALSA is used, perform additional checks 1552 IF ( salsa ) CALL salsa_check_parameters 1489 !-- Check the module settings 1490 CALL module_interface_check_parameters 1553 1491 1554 1492 ! … … 1562 1500 IF ( humidity ) q_init = q_surface 1563 1501 IF ( passive_scalar ) s_init = s_surface 1564 ! 1565 !-- TODO 1566 !-- Russo: Is done in chem_init and would overwrite what is done there 1567 !-- --> kanani: Revise 1568 ! IF ( air_chemistry ) THEN 1569 ! DO lsp = 1, nvar 1570 ! chem_species(lsp)%conc_pr_init = cs_surface(lsp) 1571 ! ENDDO 1572 ! ENDIF 1573 ! 1502 1574 1503 !-- 1575 1504 !-- If required, compute initial profile of the geostrophic wind … … 2960 2889 ! 2961 2890 !-- Check for other modules 2962 IF ( unit == 'illegal' .AND. bulk_cloud_model ) THEN 2963 CALL bcm_check_data_output_pr( data_output_pr(i), i, unit, & 2964 dopr_unit(i) ) 2965 ENDIF 2966 2967 IF ( unit == 'illegal' .AND. air_chemistry ) THEN 2968 CALL chem_check_data_output_pr( data_output_pr(i), i, unit, & 2969 dopr_unit(i) ) 2970 ENDIF 2971 2972 IF ( unit == 'illegal' .AND. gust_module_enabled ) THEN 2973 CALL gust_check_data_output_pr( data_output_pr(i), i, unit, & 2974 dopr_unit(i) ) 2975 ENDIF 2976 2977 IF ( unit == 'illegal' ) THEN 2978 CALL lsf_nudging_check_data_output_pr( data_output_pr(i), i, & 2979 unit, dopr_unit(i) ) 2980 ENDIF 2981 2982 IF ( unit == 'illegal' ) THEN 2983 CALL lsm_check_data_output_pr( data_output_pr(i), i, unit, & 2984 dopr_unit(i) ) 2985 ENDIF 2986 IF ( unit == 'illegal' ) THEN 2987 CALL ocean_check_data_output_pr( data_output_pr(i), i, unit, & 2988 dopr_unit(i) ) 2989 ENDIF 2990 2991 IF ( unit == 'illegal' ) THEN 2992 CALL radiation_check_data_output_pr( data_output_pr(i), i, & 2993 unit, dopr_unit(i) ) 2994 ENDIF 2995 2996 ! 2997 !-- Finally, check for user defined quantities 2998 IF ( unit == 'illegal' ) THEN 2999 unit = '' 3000 CALL user_check_data_output_pr( data_output_pr(i), i, unit ) 3001 ENDIF 2891 CALL module_interface_check_data_output_pr( data_output_pr(i), i, & 2892 unit, dopr_unit(i) ) 3002 2893 3003 2894 ! … … 3224 3115 3225 3116 CALL tcm_check_data_output( var, unit ) 3226 3227 3117 ! 3228 3118 !-- Check for other modules 3229 IF ( unit == 'illegal' .AND. bulk_cloud_model ) THEN 3230 CALL bcm_check_data_output( var, unit ) 3231 ENDIF 3232 3233 IF ( unit == 'illegal' .AND. air_chemistry & 3234 .AND. (var(1:3) == 'kc_' .OR. var(1:3) == 'em_') ) THEN 3235 CALL chem_check_data_output( var, unit, i, ilen, k ) 3236 ENDIF 3237 3238 IF ( unit == 'illegal' ) THEN 3239 CALL lsm_check_data_output ( var, unit, i, ilen, k ) 3240 ENDIF 3241 3242 IF ( unit == 'illegal' .AND. gust_module_enabled ) THEN 3243 CALL gust_check_data_output ( var, unit ) 3244 ENDIF 3245 3246 IF ( unit == 'illegal' .AND. biometeorology ) THEN 3247 CALL bio_check_data_output( var, unit, i, ilen, k ) 3248 ENDIF 3249 3250 IF ( unit == 'illegal' .AND. ocean_mode ) THEN 3251 CALL ocean_check_data_output( var, unit ) 3252 ENDIF 3253 3254 IF ( unit == 'illegal' .AND. plant_canopy & 3255 .AND. var(1:4) == 'pcm_' ) THEN 3256 CALL pcm_check_data_output( var, unit ) 3257 ENDIF 3258 3259 IF ( unit == 'illegal' ) THEN 3260 CALL radiation_check_data_output( var, unit, i, ilen, k ) 3261 ENDIF 3262 3263 IF ( unit == 'illegal' .AND. salsa ) THEN 3264 CALL salsa_check_data_output( var, unit ) 3265 ENDIF 3266 3267 IF ( unit == 'illegal' .AND. urban_surface & 3268 .AND. var(1:4) == 'usm_' ) THEN 3269 CALL usm_check_data_output( var, unit ) 3270 ENDIF 3271 ! 3272 !-- Finally, check for user-defined quantities 3273 IF ( unit == 'illegal' ) THEN 3274 unit = '' 3275 CALL user_check_data_output( var, unit ) 3276 ENDIF 3119 CALL module_interface_check_data_output( var, unit, i, ilen, k ) 3277 3120 3278 3121 IF ( unit == 'illegal' ) THEN … … 3986 3829 3987 3830 CALL location_message( 'finished', .TRUE. ) 3988 !3989 !-- Check &userpar parameters3990 CALL user_check_parameters3991 3831 3992 3832 CONTAINS -
palm/trunk/SOURCE/chemistry_model_mod.f90
r3636 r3637 27 27 ! ----------------- 28 28 ! $Id$ 29 ! Implementation of the PALM module interface 30 ! 31 ! 3636 2018-12-19 13:48:34Z raasch 29 32 ! nopointer option removed 30 33 ! … … 588 591 INTEGER(iwp) :: lsp !< running index for chem spcs 589 592 593 IF ( (variable(1:3) == 'kc_' .OR. variable(1:3) == 'em_') ) THEN 590 594 591 595 IF ( mode == 'allocate' ) THEN … … 662 666 ENDIF 663 667 ENDDO 668 669 ENDIF 664 670 665 671 ENDIF -
palm/trunk/SOURCE/data_output_2d.f90
r3597 r3637 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Implementation of the PALM module interface 28 ! 29 ! 3597 2018-12-04 08:40:18Z maronga 27 30 ! Added theta_2m 28 31 ! … … 284 287 ONLY: c_p, lv_d_cp, l_v 285 288 286 USE biometeorology_mod, &287 ONLY: bio_data_output_2d288 289 289 USE bulk_cloud_model_mod, & 290 ONLY: bulk_cloud_model, bcm_data_output_2d 291 292 USE chemistry_model_mod, & 293 ONLY: chem_data_output_2d 290 ONLY: bulk_cloud_model 294 291 295 292 USE control_parameters, & 296 ONLY: air_chemistry, biometeorology, data_output_2d_on_each_pe,&293 ONLY: data_output_2d_on_each_pe, & 297 294 data_output_xy, data_output_xz, data_output_yz, do2d, & 298 295 do2d_xy_last_time, do2d_xy_time_count, & 299 296 do2d_xz_last_time, do2d_xz_time_count, & 300 297 do2d_yz_last_time, do2d_yz_time_count, & 301 ibc_uv_b, io_blocks, io_group, land_surface, message_string,&298 ibc_uv_b, io_blocks, io_group, message_string, & 302 299 ntdim_2d_xy, ntdim_2d_xz, ntdim_2d_yz, & 303 ocean_mode, psolver, salsa, section, simulated_time,&300 psolver, section, simulated_time, & 304 301 time_since_reference_point 305 302 306 303 USE cpulog, & 307 ONLY: cpu_log, log_point 308 309 USE gust_mod, & 310 ONLY: gust_data_output_2d, gust_module_enabled 304 ONLY: cpu_log, log_point 311 305 312 306 USE indices, & … … 317 311 318 312 USE land_surface_model_mod, & 319 ONLY: lsm_data_output_2d, zs 313 ONLY: zs 314 315 USE module_interface, & 316 ONLY: module_interface_data_output_2d 320 317 321 318 #if defined( __netcdf ) … … 327 324 id_var_time_xy, id_var_time_xz, id_var_time_yz, nc_stat, & 328 325 netcdf_data_format, netcdf_handle_error 329 330 USE ocean_mod, &331 ONLY: ocean_data_output_2d332 326 333 327 USE particle_attributes, & … … 336 330 337 331 USE pegrid 338 339 USE radiation_model_mod, &340 ONLY: radiation, radiation_data_output_2d341 342 USE salsa_mod, &343 ONLY: salsa_data_output_2d344 332 345 333 USE surface_mod, & … … 1362 1350 ! 1363 1351 !-- Quantities of other modules 1364 IF ( .NOT. found .AND. bulk_cloud_model ) THEN1365 CALL bcm_data_output_2d( av, do2d(av,ivar), found, grid, mode,&1366 local_pf, two_d, nzb_do, nzt_do )1367 ENDIF1368 1369 IF ( .NOT. found .AND. gust_module_enabled ) THEN1370 CALL gust_data_output_2d( av, do2d(av,ivar), found, grid, &1371 local_pf, two_d, nzb_do, nzt_do )1372 ENDIF1373 1374 IF ( .NOT. found .AND. biometeorology ) THEN1375 CALL bio_data_output_2d( av, do2d(av,ivar), found, grid, &1376 local_pf, two_d, nzb_do, nzt_do )1377 ENDIF1378 1379 IF ( .NOT. found .AND. land_surface ) THEN1380 CALL lsm_data_output_2d( av, do2d(av,ivar), found, grid, mode,&1381 local_pf, two_d, nzb_do, nzt_do )1382 ENDIF1383 1384 IF ( .NOT. found .AND. ocean_mode ) THEN1385 CALL ocean_data_output_2d( av, do2d(av,ivar), found, grid, &1386 mode, local_pf, nzb_do, nzt_do )1387 ENDIF1388 1389 IF ( .NOT. found .AND. radiation ) THEN1390 CALL radiation_data_output_2d( av, do2d(av,ivar), found, grid,&1391 mode, local_pf, two_d, &1392 nzb_do, nzt_do )1393 ENDIF1394 1395 IF ( .NOT. found .AND. salsa ) THEN1396 CALL salsa_data_output_2d( av, do2d(av,ivar), found, grid, &1397 mode, local_pf, two_d, nzb_do, &1398 nzt_do)1399 ENDIF1400 1401 IF ( .NOT. found .AND. air_chemistry ) THEN1402 CALL chem_data_output_2d( av, do2d(av,ivar), found, grid, mode, &1403 local_pf, two_d, nzb_do, nzt_do, fill_value )1404 ENDIF1405 !1406 !-- User defined quantities1407 1352 IF ( .NOT. found ) THEN 1408 CALL user_data_output_2d( av, do2d(av,ivar), found, grid, & 1409 local_pf, two_d, nzb_do, nzt_do ) 1353 CALL module_interface_data_output_2d( & 1354 av, do2d(av,ivar), found, grid, mode, & 1355 local_pf, two_d, nzb_do, nzt_do, & 1356 fill_value & 1357 ) 1410 1358 ENDIF 1411 1359 -
palm/trunk/SOURCE/data_output_3d.f90
r3589 r3637 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Implementation of the PALM module interface 28 ! 29 ! 3589 2018-11-30 15:09:51Z suehring 27 30 ! Move the control parameter "salsa" from salsa_mod to control_parameters 28 31 ! (M. Kurppa) … … 245 248 ONLY: lv_d_cp 246 249 247 USE biometeorology_mod, &248 ONLY: bio_data_output_3d249 250 250 USE bulk_cloud_model_mod, & 251 ONLY: bulk_cloud_model, bcm_data_output_3d 252 253 USE chemistry_model_mod, & 254 ONLY: chem_data_output_3d 251 ONLY: bulk_cloud_model 255 252 256 253 USE control_parameters, & … … 263 260 USE cpulog, & 264 261 ONLY: log_point, cpu_log 265 266 USE gust_mod, &267 ONLY: gust_data_output_3d, gust_module_enabled268 262 269 263 #if defined( __parallel ) … … 282 276 ONLY: lsm_data_output_3d, nzb_soil, nzt_soil 283 277 278 USE module_interface, & 279 ONLY: module_interface_data_output_3d 280 284 281 #if defined( __netcdf ) 285 282 USE NETCDF … … 289 286 ONLY: fill_value, id_set_3d, id_var_do3d, id_var_time_3d, nc_stat, & 290 287 netcdf_data_format, netcdf_handle_error 291 292 USE ocean_mod, &293 ONLY: ocean_data_output_3d294 288 295 289 USE particle_attributes, & 296 290 ONLY: grid_particles, number_of_particles, particles, & 297 291 particle_advection_start, prt_count 298 292 299 293 USE pegrid 300 294 301 USE plant_canopy_model_mod, &302 ONLY: pcm_data_output_3d303 304 295 USE radiation_model_mod, & 305 ONLY: nzub, nzut, radiation, radiation_data_output_3d 306 307 USE salsa_mod, & 308 ONLY: salsa_data_output_3d 296 ONLY: nzub, nzut 309 297 310 298 USE turbulence_closure_mod, & … … 399 387 400 388 ! 401 !-- Temporary solution to account for data output within the new urban 389 !-- Initiate found flag and resorting flag 390 found = .FALSE. 391 resorted = .FALSE. 392 ! 393 !-- Temporary solution to account for data output within the new urban 402 394 !-- surface model (urban_surface_mod.f90), see also SELECT CASE ( trimvar ). 403 395 !-- Store the array chosen on the temporary array. 396 nzb_do = nzb 397 nzt_do = nz_do3d 398 404 399 trimvar = TRIM( do3d(av,ivar) ) 405 IF ( urban_surface .AND. trimvar(1:4) == 'usm_' ) THEN406 trimvar = 'usm_output'407 resorted = .TRUE.408 nzb_do = nzub409 nzt_do = nzut410 ELSE411 resorted = .FALSE.412 nzb_do = nzb413 nzt_do = nz_do3d414 ENDIF415 !416 !-- Set flag to steer output of radiation, land-surface, or user-defined417 !-- quantities418 found = .FALSE.419 400 ! 420 401 !-- Allocate a temporary array with the desired output dimensions. … … 715 696 to_be_resorted => w_av 716 697 ENDIF 717 !718 !-- Block of urban surface model outputs719 CASE ( 'usm_output' )720 CALL usm_data_output_3d( av, do3d(av,ivar), found, local_pf, &721 nzb_do, nzt_do )722 698 723 699 CASE DEFAULT 724 700 725 ! 726 !-- Quantities of other modules 727 IF ( .NOT. found .AND. bulk_cloud_model ) THEN 728 CALL bcm_data_output_3d( av, do3d(av,ivar), found, local_pf, & 701 IF ( .NOT. found ) THEN 702 CALL tcm_data_output_3d( av, trimvar, found, local_pf, & 729 703 nzb_do, nzt_do ) 730 704 resorted = .TRUE. 731 705 ENDIF 732 706 733 IF ( .NOT. found .AND. air_chemistry ) THEN 734 CALL chem_data_output_3d( av, do3d(av,ivar), found, & 735 local_pf, fill_value, nzb_do, nzt_do ) 736 resorted = .TRUE. 737 ENDIF 738 739 IF ( .NOT. found .AND. gust_module_enabled ) THEN 740 CALL gust_data_output_3d( av, do3d(av,ivar), found, local_pf, & 741 nzb_do, nzt_do ) 742 resorted = .TRUE. 743 ENDIF 744 745 IF ( .NOT. found .AND. land_surface ) THEN 746 ! 747 !-- For soil model quantities, it is required to re-allocate local_pf 748 nzb_do = nzb_soil 749 nzt_do = nzt_soil 707 ! 708 !-- Quantities of other modules 709 IF ( .NOT. found ) THEN 710 CALL module_interface_data_output_3d( & 711 av, trimvar, found, local_pf, & 712 fill_value, resorted, nzb_do, nzt_do & 713 ) 714 ENDIF 715 716 ! 717 !-- Temporary workaround: ToDo: refactor local_pf allocation 718 IF ( .NOT. found .AND. urban_surface .AND. trimvar(1:4) == 'usm_' ) THEN 719 ! 720 !-- For urban model quantities, it is required to re-allocate local_pf 721 nzb_do = nzub 722 nzt_do = nzut 750 723 751 724 DEALLOCATE ( local_pf ) … … 753 726 local_pf = fill_value 754 727 755 CALL lsm_data_output_3d( av, do3d(av,ivar), found, local_pf ) 728 CALL usm_data_output_3d( av, trimvar, found, local_pf, & 729 nzb_do, nzt_do ) 756 730 resorted = .TRUE. 757 731 … … 763 737 764 738 DEALLOCATE ( local_pf ) 765 ALLOCATE( local_pf(nxl:nxr,nys:nyn,nzb_do:nzt_do) ) 766 ENDIF 767 768 ENDIF 769 770 IF ( .NOT. found .AND. ocean_mode ) THEN 771 CALL ocean_data_output_3d( av, do3d(av,ivar), found, local_pf, & 772 nzb_do, nzt_do ) 739 ALLOCATE( local_pf(nxl:nxr,nys:nyn,nzb_do:nzt_do) ) 740 ENDIF 741 742 ENDIF 743 744 ! 745 !-- Temporary workaround: ToDo: refactor local_pf allocation 746 IF ( .NOT. found .AND. land_surface ) THEN 747 ! 748 !-- For soil model quantities, it is required to re-allocate local_pf 749 nzb_do = nzb_soil 750 nzt_do = nzt_soil 751 752 DEALLOCATE ( local_pf ) 753 ALLOCATE( local_pf(nxl:nxr,nys:nyn,nzb_do:nzt_do) ) 754 local_pf = fill_value 755 756 CALL lsm_data_output_3d( av, trimvar, found, local_pf ) 773 757 resorted = .TRUE. 774 ENDIF 775 776 IF ( .NOT. found .AND. plant_canopy ) THEN 777 CALL pcm_data_output_3d( av, do3d(av,ivar), found, local_pf, & 778 fill_value, nzb_do, nzt_do ) 779 resorted = .TRUE. 780 ENDIF 781 782 IF ( .NOT. found .AND. radiation ) THEN 783 CALL radiation_data_output_3d( av, do3d(av,ivar), found, & 784 local_pf, nzb_do, nzt_do ) 785 resorted = .TRUE. 786 ENDIF 787 788 IF ( .NOT. found ) THEN 789 CALL tcm_data_output_3d( av, do3d(av,ivar), found, local_pf, & 790 nzb_do, nzt_do ) 791 resorted = .TRUE. 792 ENDIF 793 794 ! 795 !-- SALSA output 796 IF ( .NOT. found .AND. salsa ) THEN 797 CALL salsa_data_output_3d( av, do3d(av,ivar), found, local_pf, & 798 nzb_do, nzt_do ) 799 resorted = .TRUE. 800 ENDIF 801 802 IF ( .NOT. found .AND. biometeorology ) THEN 803 CALL bio_data_output_3d( av, do3d(av,ivar), found, local_pf, & 804 nzb_do, nzt_do ) 805 ENDIF 806 807 ! 808 !-- User defined quantities 809 IF ( .NOT. found ) THEN 810 CALL user_data_output_3d( av, do3d(av,ivar), found, local_pf, & 811 nzb_do, nzt_do ) 812 resorted = .TRUE. 758 759 ! 760 !-- If no soil model variable was found, re-allocate local_pf 761 IF ( .NOT. found ) THEN 762 nzb_do = nzb 763 nzt_do = nz_do3d 764 765 DEALLOCATE ( local_pf ) 766 ALLOCATE( local_pf(nxl:nxr,nys:nyn,nzb_do:nzt_do) ) 767 ENDIF 768 813 769 ENDIF 814 770 -
palm/trunk/SOURCE/flow_statistics.f90
r3458 r3637 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Implementation of the PALM module interface 28 ! 29 ! 3458 2018-10-30 14:51:23Z kanani 27 30 ! from chemistry branch r3443, basit: 28 31 ! bug fixed in chemistry profiles … … 309 312 ONLY: g, lv_d_cp 310 313 314 USE bulk_cloud_model_mod, & 315 ONLY: bulk_cloud_model, microphysics_morrison, microphysics_seifert 311 316 312 317 USE chem_modules, & 313 318 ONLY: max_pr_cs 314 315 USE chemistry_model_mod, &316 ONLY: chem_species, chem_statistics317 319 318 320 USE control_parameters, & … … 330 332 USE grid_variables, & 331 333 ONLY: ddx, ddy 332 333 USE gust_mod, &334 ONLY: gust_module_enabled, gust_statistics335 334 336 335 USE indices, & … … 340 339 341 340 USE kinds 342 343 USE bulk_cloud_model_mod, &344 ONLY: bulk_cloud_model, microphysics_morrison, microphysics_seifert345 341 346 342 USE land_surface_model_mod, & … … 349 345 USE lsf_nudging_mod, & 350 346 ONLY: td_lsa_lpt, td_lsa_q, td_sub_lpt, td_sub_q, time_vert 347 348 USE module_interface, & 349 ONLY: module_interface_statistics 351 350 352 351 USE netcdf_interface, & … … 1795 1794 ENDDO 1796 1795 ENDIF 1797 ! 1798 !-- Calculate the gust module profiles 1799 IF ( gust_module_enabled ) THEN 1800 CALL gust_statistics( 'profiles', sr, tn, dots_max ) 1801 ENDIF 1802 ! 1803 !-- Calculate the chemistry module profiles 1804 IF ( air_chemistry ) THEN 1805 CALL chem_statistics( 'profiles', sr, tn ) 1806 ENDIF 1807 ! 1808 !-- Calculate the user-defined profiles 1809 CALL user_statistics( 'profiles', sr, tn ) 1810 !$OMP END PARALLEL 1796 1797 ! 1798 !-- Calculate the profiles for all other modules 1799 CALL module_interface_statistics( 'profiles', sr, tn, dots_max ) 1811 1800 1812 1801 ! … … 2268 2257 2269 2258 ! 2270 !-- Calculate additional statistics provided by the gust module 2271 IF ( gust_module_enabled ) THEN 2272 CALL gust_statistics( 'time_series', sr, 0, dots_max ) 2273 ENDIF 2274 2275 ! 2276 !-- Calculate additional statistics provided by the user interface 2277 CALL user_statistics( 'time_series', sr, 0 ) 2259 !-- Calculate additional statistics provided by other modules 2260 CALL module_interface_statistics( 'time_series', sr, 0, dots_max ) 2278 2261 2279 2262 ENDDO ! loop of the subregions -
palm/trunk/SOURCE/header.f90
r3589 r3637 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Implementation of the PALM module interface 28 ! 29 ! 3589 2018-11-30 15:09:51Z suehring 27 30 ! Move the control parameter "salsa" from salsa_mod to control_parameters 28 31 ! (M. Kurppa) … … 420 423 ONLY: g, kappa, l_v 421 424 422 USE biometeorology_mod, &423 ONLY: bio_header424 425 425 USE bulk_cloud_model_mod, & 426 ONLY: bulk_cloud_model, bcm_header 427 428 USE chemistry_model_mod, & 429 ONLY: chem_header 426 ONLY: bulk_cloud_model 430 427 431 428 USE control_parameters … … 439 436 USE dvrp_variables, & 440 437 ONLY: use_seperate_pe_for_dvrp_output 441 442 USE flight_mod, & 443 ONLY: flight_header 444 438 445 439 USE grid_variables, & 446 440 ONLY: dx, dy 447 448 USE gust_mod, &449 ONLY: gust_header, gust_module_enabled450 441 451 442 USE indices, & 452 443 ONLY: mg_loc_ind, nnx, nny, nnz, nx, ny, nxl_mg, nxr_mg, nyn_mg, & 453 444 nys_mg, nzt, nzt_mg 454 445 455 446 USE kinds 456 457 USE land_surface_model_mod, &458 ONLY: lsm_header459 460 USE lsf_nudging_mod, &461 ONLY: lsf_nudging_header462 447 463 448 USE model_1d_mod, & 464 449 ONLY: damp_level_ind_1d, dt_pr_1d, dt_run_control_1d, end_time_1d 465 450 451 USE module_interface, & 452 ONLY: module_interface_header 453 466 454 USE netcdf_interface, & 467 455 ONLY: netcdf_data_format, netcdf_data_format_string, netcdf_deflate 468 456 469 USE nesting_offl_mod, &470 ONLY: nesting_offl_header471 472 457 USE ocean_mod, & 473 ONLY: ibc_sa_t, ocean_header, prho_reference, sa_surface,&458 ONLY: ibc_sa_t, prho_reference, sa_surface, & 474 459 sa_vertical_gradient, sa_vertical_gradient_level, & 475 460 sa_vertical_gradient_level_ind … … 487 472 total_number_of_particles, use_sgs_for_particles, & 488 473 vertical_particle_advection, write_particle_statistics 489 474 490 475 USE pegrid 491 492 USE plant_canopy_model_mod, &493 ONLY: pcm_header494 476 495 477 #if defined( __parallel ) … … 501 483 ONLY: nested_run, nesting_datatransfer_mode, nesting_mode 502 484 503 USE radiation_model_mod, &504 ONLY: radiation, radiation_header505 506 USE salsa_mod, &507 ONLY: salsa_header508 509 USE spectra_mod, &510 ONLY: calculate_spectra, spectra_header511 512 485 USE surface_mod, & 513 486 ONLY: surf_def_h, get_topography_top_index_ji 514 515 USE synthetic_turbulence_generator_mod, &516 ONLY: stg_header517 487 518 488 USE turbulence_closure_mod, & … … 935 905 936 906 ! 937 !-- Large scale forcing and nudging938 IF ( large_scale_forcing ) CALL lsf_nudging_header( io )939 940 !941 !-- Offline nesting942 IF ( nesting_offline ) CALL nesting_offl_header( io )943 944 !945 907 !-- Profile for the large scale vertial velocity 946 908 !-- Building output strings, starting with surface value … … 1161 1123 ENDIF 1162 1124 ENDIF 1163 1164 !1165 !-- Header information from other modules1166 IF ( biometeorology ) CALL bio_header ( io )1167 IF ( gust_module_enabled ) CALL gust_header( io )1168 IF ( land_surface ) CALL lsm_header( io )1169 IF ( ocean_mode ) CALL ocean_header( io )1170 IF ( plant_canopy ) CALL pcm_header( io )1171 IF ( radiation ) CALL radiation_header( io )1172 IF ( syn_turb_gen ) CALL stg_header( io )1173 1174 IF ( air_chemistry ) CALL chem_header ( io )1175 1125 ! 1176 1126 !-- Boundary conditions … … 1924 1874 ENDIF 1925 1875 #endif 1926 ! 1927 !-- Output of virtual flight information 1928 IF ( virtual_flight ) CALL flight_header( io ) 1929 1930 ! 1931 !-- Output of spectra related quantities 1932 IF ( calculate_spectra ) CALL spectra_header( io ) 1876 1933 1877 1934 1878 WRITE ( io, 99 ) … … 1958 1902 ENDIF 1959 1903 ENDIF 1960 1961 !1962 !-- Output of microphysics information1963 IF ( bulk_cloud_model ) CALL bcm_header( io )1964 1904 1965 1905 ! … … 2083 2023 ENDIF 2084 2024 ENDIF 2085 2086 ! 2087 !-- SALSA information 2088 IF ( salsa ) CALL salsa_header( io ) 2089 2090 ! 2091 !-- User-defined information 2092 CALL user_header( io ) 2025 2026 ! 2027 !-- Header information from other modules 2028 CALL module_interface_header( io ) 2029 2093 2030 2094 2031 WRITE ( io, 99 ) -
palm/trunk/SOURCE/parin.f90
r3569 r3637 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Implementation of the PALM module interface 28 ! 29 ! 3569 2018-11-27 17:03:40Z kanani 27 30 ! dom_dwd_user, Schrempf: 28 31 ! Remove uv exposure model code, this is now part of biometeorology_mod. … … 468 471 ug, u_init, v_init, vg 469 472 470 USE biometeorology_mod, &471 ONLY: bio_parin472 473 USE bulk_cloud_model_mod, &474 ONLY: bcm_parin475 476 USE chemistry_model_mod, &477 ONLY: chem_parin478 479 473 USE chem_modules 480 474 … … 490 484 ONLY: local_dvrserver_running 491 485 492 USE flight_mod, &493 ONLY: flight_parin494 495 486 USE grid_variables, & 496 487 ONLY: dx, dy 497 488 498 USE gust_mod, &499 ONLY: gust_parin500 501 489 USE indices, & 502 490 ONLY: nx, ny, nz 503 491 504 USE indoor_model_mod, &505 ONLY: im_parin506 507 492 USE kinds 508 509 USE land_surface_model_mod, &510 ONLY: lsm_parin511 493 512 494 USE model_1d_mod, & 513 495 ONLY: damp_level_1d, dt_pr_1d, dt_run_control_1d, end_time_1d 514 496 515 USE multi_agent_system_mod, & 516 ONLY: mas_parin 517 518 USE nesting_offl_mod, & 519 ONLY: nesting_offl_parin 520 497 USE module_interface, & 498 ONLY: module_interface_parin 499 521 500 USE netcdf_interface, & 522 501 ONLY: netcdf_data_format, netcdf_deflate, netcdf_precision 523 502 524 USE ocean_mod, &525 ONLY: ocean_parin526 527 503 USE pegrid 528 529 USE plant_canopy_model_mod, &530 ONLY: pcm_parin531 504 532 505 USE pmc_interface, & … … 539 512 ONLY : progress_bar_disabled 540 513 541 USE radiation_model_mod, &542 ONLY: radiation_parin543 544 514 USE read_restart_data_mod, & 545 ONLY: rrd_global 546 547 USE salsa_mod, & 548 ONLY: salsa_parin 549 550 USE spectra_mod, & 551 ONLY : spectra_parin 515 ONLY: rrd_global 552 516 553 517 USE statistics, & 554 518 ONLY: hom, hom_sum, pr_palm, region, statistic_regions 555 519 556 USE surface_output_mod, &557 ONLY: surface_output_parin558 559 USE synthetic_turbulence_generator_mod, &560 ONLY: stg_parin561 562 520 USE turbulence_closure_mod, & 563 521 ONLY: rans_const_c, rans_const_sigma 564 522 565 USE urban_surface_mod, &566 ONLY: usm_parin567 568 523 USE vertical_nesting_mod, & 569 524 ONLY: vnest_start_time 570 571 USE virtual_measurement_mod, &572 ONLY: vm_parin573 574 USE wind_turbine_model_mod, &575 ONLY: wtm_parin576 525 577 526 … … 917 866 ! 918 867 !-- Check for module namelists and read them 919 CALL bio_parin 920 CALL lsm_parin 921 CALL bcm_parin 922 CALL surface_output_parin 923 CALL usm_parin 924 CALL spectra_parin 925 CALL radiation_parin 926 CALL gust_parin 927 CALL mas_parin 928 CALL nesting_offl_parin 929 CALL ocean_parin 930 CALL pcm_parin 931 CALL package_parin 932 CALL wtm_parin 933 CALL flight_parin 934 CALL stg_parin 935 CALL chem_parin 936 CALL im_parin 937 CALL salsa_parin 938 CALL vm_parin 939 ! 940 !-- Read user-defined variables 941 CALL user_parin 868 CALL module_interface_parin 942 869 943 870 ! -
palm/trunk/SOURCE/read_restart_data_mod.f90
r3589 r3637 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Implementation of the PALM module interface 28 ! 29 ! 3589 2018-11-30 15:09:51Z suehring 27 30 ! Move the control parameter "salsa" from salsa_mod to control_parameters 28 31 ! (M. Kurppa) … … 88 91 89 92 90 USE control_parameters 93 USE arrays_3d, & 94 ONLY: inflow_damping_factor, mean_inflow_profiles, pt_init, & 95 q_init, ref_state, sa_init, s_init, u_init, ug, v_init, vg, & 96 e, kh, km, p, pt, q, ql, s, u, u_m_l, u_m_n, u_m_r, u_m_s, & 97 v, v_m_l, v_m_n, v_m_r, v_m_s, vpt, w, w_m_l, w_m_n, w_m_r, w_m_s 98 99 USE averaging 91 100 92 101 USE chem_modules, & 93 102 ONLY: max_pr_cs 103 104 USE control_parameters 105 106 USE cpulog, & 107 ONLY: cpu_log, log_point_s 108 109 USE date_and_time_mod, & 110 ONLY: day_of_year_init, time_utc_init 111 112 USE grid_variables, & 113 ONLY: dx, dy 114 115 USE indices, & 116 ONLY: nbgp, nx, nxl, nxlg, nxr, nxrg, nx_on_file, ny, nys, nysg, nyn, & 117 nyng, ny_on_file, nz, nzb, nzt 118 119 USE kinds 120 121 USE model_1d_mod, & 122 ONLY: damp_level_1d, dt_pr_1d, dt_run_control_1d, end_time_1d 123 124 USE module_interface, & 125 ONLY: module_interface_rrd_global, & 126 module_interface_rrd_local 127 128 USE netcdf_interface, & 129 ONLY: netcdf_precision, output_for_t0 130 131 USE particle_attributes, & 132 ONLY: curvature_solution_effects, iran_part 133 134 USE pegrid 135 136 USE radiation_model_mod, & 137 ONLY: time_radiation 138 139 USE random_function_mod, & 140 ONLY: random_iv, random_iy 141 142 USE random_generator_parallel, & 143 ONLY: id_random_array, seq_random_array 144 145 USE spectra_mod, & 146 ONLY: average_count_sp, spectrum_x, spectrum_y 147 148 USE surface_mod, & 149 ONLY : surface_rrd_local 150 151 USE statistics, & 152 ONLY: statistic_regions, hom, hom_sum, pr_palm, u_max, u_max_ijk, & 153 v_max, v_max_ijk, w_max, w_max_ijk, z_i 154 155 USE vertical_nesting_mod, & 156 ONLY: vnest_init 94 157 95 158 … … 127 190 SUBROUTINE rrd_global 128 191 129 130 USE arrays_3d, &131 ONLY: inflow_damping_factor, mean_inflow_profiles, pt_init, &132 q_init, ref_state, sa_init, s_init, u_init, ug, v_init, vg133 134 USE bulk_cloud_model_mod, &135 ONLY: bcm_rrd_global136 137 USE date_and_time_mod, &138 ONLY: day_of_year_init, time_utc_init139 140 USE flight_mod, &141 ONLY: flight_rrd_global142 143 USE grid_variables, &144 ONLY: dx, dy145 146 USE gust_mod, &147 ONLY : gust_rrd_global148 149 USE indices, &150 ONLY: nz, nx, nx_on_file, ny, ny_on_file151 152 USE model_1d_mod, &153 ONLY: damp_level_1d, dt_pr_1d, dt_run_control_1d, end_time_1d154 155 USE netcdf_interface, &156 ONLY: netcdf_precision, output_for_t0157 158 USE ocean_mod, &159 ONLY: ocean_rrd_global160 161 USE particle_attributes, &162 ONLY: curvature_solution_effects163 164 USE pegrid165 166 USE radiation_model_mod, &167 ONLY: time_radiation168 169 USE spectra_mod, &170 ONLY: average_count_sp, spectrum_x, spectrum_y171 172 USE statistics, &173 ONLY: statistic_regions, hom, hom_sum, pr_palm, u_max, u_max_ijk, &174 v_max, v_max_ijk, w_max, w_max_ijk, z_i175 176 USE synthetic_turbulence_generator_mod, &177 ONLY: stg_rrd_global178 179 USE user_read_restart_data_mod, &180 ONLY: user_rrd_global181 182 USE vertical_nesting_mod, &183 ONLY: vnest_init184 185 USE wind_turbine_model_mod, &186 ONLY: wtm_rrd_global187 188 189 IMPLICIT NONE190 192 191 193 CHARACTER (LEN=10) :: binary_version_global, version_on_file … … 772 774 ! 773 775 !-- Read global variables from of other modules 774 IF ( .NOT. found ) CALL bcm_rrd_global( found ) 775 IF ( .NOT. found ) CALL flight_rrd_global( found ) 776 IF ( .NOT. found ) CALL gust_rrd_global( found ) 777 IF ( .NOT. found ) CALL ocean_rrd_global( found ) 778 IF ( .NOT. found ) CALL stg_rrd_global ( found ) 779 IF ( .NOT. found ) CALL wtm_rrd_global( found ) 780 ! 781 !-- Read user-defined global variables 782 IF ( .NOT. found ) CALL user_rrd_global( found ) 776 CALL module_interface_rrd_global( restart_string(1:length), found ) 783 777 784 778 IF ( .NOT. found ) THEN … … 818 812 SUBROUTINE rrd_read_parts_of_global 819 813 820 821 USE arrays_3d, &822 ONLY: ref_state823 824 USE indices, &825 ONLY: nz, nx_on_file, ny_on_file826 827 USE kinds828 829 USE pegrid830 831 USE statistics, &832 ONLY: statistic_regions, hom, hom_sum, pr_palm833 834 IMPLICIT NONE835 814 836 815 CHARACTER (LEN=10) :: version_on_file … … 959 938 WRITE( message_string, * ) 'inflow profiles not ', & 960 939 'temporally averaged. &Averaging will be ', & 961 'done now using', average_count_pr, & 940 'done now using', average_count_pr, & 962 941 ' samples.' 963 942 CALL message( 'rrd_read_parts_of_global', 'PA0309', & … … 1043 1022 !> (binary format). 1044 1023 !------------------------------------------------------------------------------! 1045 SUBROUTINE rrd_local 1046 1047 1048 USE arrays_3d, & 1049 ONLY: e, kh, km, p, pt, q, ql, s, u, u_m_l, u_m_n, u_m_r, u_m_s, & 1050 v, v_m_l, v_m_n, v_m_r, v_m_s, vpt, w, w_m_l, w_m_n, w_m_r, w_m_s 1051 1052 USE bulk_cloud_model_mod, & 1053 ONLY : bcm_rrd_local 1054 1055 USE averaging 1056 1057 USE chemistry_model_mod, & 1058 ONLY: chem_rrd_local 1059 1060 USE cpulog, & 1061 ONLY: cpu_log, log_point_s 1062 1063 USE gust_mod, & 1064 ONLY : gust_rrd_local 1065 1066 USE indices, & 1067 ONLY: nbgp, nx, nxl, nxlg, nxr, nxrg, nx_on_file, ny, nys, nysg, nyn, & 1068 nyng, ny_on_file, nzb, nzt 1069 1070 USE kinds 1071 1072 USE land_surface_model_mod, & 1073 ONLY: lsm_rrd_local 1074 1075 USE ocean_mod, & 1076 ONLY: ocean_rrd_local 1077 1078 USE particle_attributes, & 1079 ONLY: iran_part 1080 1081 USE pegrid 1082 1083 USE radiation_model_mod, & 1084 ONLY: radiation_rrd_local 1085 1086 USE random_function_mod, & 1087 ONLY: random_iv, random_iy 1088 1089 USE random_generator_parallel, & 1090 ONLY: id_random_array, seq_random_array 1091 1092 USE salsa_mod, & 1093 ONLY: salsa_rrd_local 1094 1095 USE surface_mod, & 1096 ONLY : surface_rrd_local 1097 1098 USE urban_surface_mod, & 1099 ONLY: usm_rrd_local 1100 1101 USE user_read_restart_data_mod, & 1102 ONLY: user_rrd_local 1103 1104 1105 IMPLICIT NONE 1024 SUBROUTINE rrd_local 1025 1106 1026 1107 1027 CHARACTER (LEN=7) :: myid_char_save … … 1866 1786 1867 1787 ! 1868 !-- Read restart data of other modules 1869 IF ( .NOT. found ) CALL bcm_rrd_local( i, k, nxlf, & 1870 nxlc, nxl_on_file, nxrf, nxrc, & 1871 nxr_on_file, nynf, nync, & 1872 nyn_on_file, nysf, nysc, & 1873 nys_on_file, tmp_2d, tmp_3d, found ) 1874 1875 IF ( .NOT. found ) CALL chem_rrd_local( i, k, nxlf, & 1876 nxlc, nxl_on_file, nxrf, nxrc, & 1877 nxr_on_file, nynf, nync, & 1878 nyn_on_file, nysf, nysc, & 1879 nys_on_file, tmp_3d, found ) 1880 1881 IF ( .NOT. found ) CALL gust_rrd_local( i, k, nxlf, & 1882 nxlc, nxl_on_file, nxrf, nxrc, & 1883 nxr_on_file, nynf, nync, & 1884 nyn_on_file, nysf, nysc, & 1885 nys_on_file, tmp_2d, tmp_3d, found ) 1886 1887 IF ( .NOT. found ) CALL lsm_rrd_local( i, k, nxlf, & 1888 nxlc, nxl_on_file, nxrf, nxrc, & 1889 nxr_on_file, nynf, nync, & 1890 nyn_on_file, nysf, nysc, & 1891 nys_on_file, tmp_2d, found ) 1892 1893 IF ( .NOT. found ) CALL ocean_rrd_local( i, k, nxlf, & 1894 nxlc, nxl_on_file, nxrf, nxrc, & 1895 nxr_on_file, nynf, nync, & 1896 nyn_on_file, nysf, nysc, & 1897 nys_on_file, tmp_2d, tmp_3d, found ) 1898 1899 IF ( .NOT. found ) CALL radiation_rrd_local( i, k, nxlf, & 1900 nxlc, nxl_on_file, nxrf, nxrc, & 1901 nxr_on_file, nynf, nync, & 1902 nyn_on_file, nysf, nysc, & 1903 nys_on_file, tmp_2d, tmp_3d, found ) 1904 1788 !-- Read restart data of surfaces 1905 1789 IF ( .NOT. found ) CALL surface_rrd_local( i, k, nxlf, & 1906 nxlc, nxl_on_file, nxrf, nxrc, &1907 nxr_on_file, nynf, nync, &1908 nyn_on_file, nysf, nysc, &1909 nys_on_file, found )1910 1911 IF ( .NOT. found ) CALL usm_rrd_local( i, k, nxlf, &1912 1790 nxlc, nxl_on_file, nxrf, nxrc, & 1913 1791 nxr_on_file, nynf, nync, & … … 1915 1793 nys_on_file, found ) 1916 1794 1917 IF ( .NOT. found .AND. salsa ) CALL salsa_rrd_local( i, & 1918 k, nxlf, nxlc, nxl_on_file, nxrf, & 1919 nxrc, nxr_on_file, nynf, nync, & 1920 nyn_on_file, nysf, nysc, & 1921 nys_on_file, tmp_3d, found ) 1922 1923 ! 1924 !-- Read user-defined restart data 1925 IF ( .NOT. found ) CALL user_rrd_local( i, k, nxlf, & 1926 nxlc, nxl_on_file, nxrf, nxrc, & 1927 nxr_on_file, nynf, nync, & 1928 nyn_on_file, nysf, nysc, & 1929 nys_on_file, tmp_3d, found ) 1795 ! 1796 !-- Read restart data of other modules 1797 IF ( .NOT. found ) CALL module_interface_rrd_local( & 1798 restart_string(1:length), i, k, & 1799 nxlf, nxlc, nxl_on_file, & 1800 nxrf, nxrc, nxr_on_file, & 1801 nynf, nync, nyn_on_file, & 1802 nysf, nysc, nys_on_file, & 1803 tmp_2d, tmp_3d, found ) 1930 1804 1931 1805 … … 1994 1868 1995 1869 1996 IMPLICIT NONE1997 1998 1870 CHARACTER (LEN=1) :: cdum 1999 1871 … … 2005 1877 2006 1878 READ ( 13 ) cdum 2007 READ ( 13 ) length 1879 READ ( 13 ) length 2008 1880 READ ( 13 ) restart_string(1:length) 2009 1881 -
palm/trunk/SOURCE/salsa_mod.f90
r3636 r3637 26 26 ! ----------------- 27 27 ! $Id$ 28 ! Implementation of the PALM module interface 29 ! 30 ! 3636 2018-12-19 13:48:34Z raasch 28 31 ! nopointer option removed 29 32 ! … … 91 94 92 95 USE control_parameters 93 96 94 97 USE indices, & 95 98 ONLY: nbgp, nx, nxl, nxlg, nxr, nxrg, ny, nyn, nyng, nys, nysg, nzb, & … … 1956 1959 INTEGER(iwp) :: g !< 1957 1960 1961 IF ( simulated_time >= time_since_reference_point ) THEN 1958 1962 1959 1963 SELECT CASE ( mod_count ) … … 2010 2014 2011 2015 END SELECT 2016 2017 ENDIF 2012 2018 2013 2019 END SUBROUTINE salsa_swap_timelevel -
palm/trunk/SOURCE/sum_up_3d_data.f90
r3597 r3637 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Implementation of the PALM module interface 28 ! 29 ! 3597 2018-12-04 08:40:18Z maronga 27 30 ! Added output of theta_2m 28 31 ! … … 259 262 ONLY: c_p, lv_d_cp, l_v 260 263 261 USE biometeorology_mod, &262 ONLY: bio_3d_data_averaging263 264 264 USE bulk_cloud_model_mod, & 265 ONLY: bulk_cloud_model, bcm_3d_data_averaging 266 267 USE chemistry_model_mod, & 268 ONLY: chem_3d_data_averaging 265 ONLY: bulk_cloud_model 269 266 270 267 USE control_parameters, & 271 ONLY: air_chemistry, average_count_3d, biometeorology, doav, doav_n, & 272 land_surface, ocean_mode, rho_surface, salsa, urban_surface, & 268 ONLY: average_count_3d, doav, doav_n, rho_surface, urban_surface, & 273 269 varnamelength 274 270 … … 276 272 ONLY: cpu_log, log_point 277 273 278 USE gust_mod, &279 ONLY: gust_3d_data_averaging, gust_module_enabled280 281 274 USE indices, & 282 275 ONLY: nxl, nxlg, nxr, nxrg, nyn, nyng, nys, nysg, nzb, nzt … … 284 277 USE kinds 285 278 286 USE land_surface_model_mod, & 287 ONLY: lsm_3d_data_averaging 288 289 USE ocean_mod, & 290 ONLY: ocean_3d_data_averaging 279 USE module_interface, & 280 ONLY: module_interface_3d_data_averaging 291 281 292 282 USE particle_attributes, & 293 283 ONLY: grid_particles, number_of_particles, particles, prt_count 294 295 USE radiation_model_mod, &296 ONLY: radiation, radiation_3d_data_averaging297 298 USE salsa_mod, &299 ONLY: salsa_3d_data_averaging300 284 301 285 USE surface_mod, & … … 307 291 308 292 USE urban_surface_mod, & 309 ONLY: usm_ average_3d_data293 ONLY: usm_3d_data_averaging 310 294 311 295 … … 535 519 536 520 ! 537 !-- Allocating and initializing data arrays for other modules 538 539 IF ( air_chemistry .AND. & 540 (trimvar(1:3) == 'kc_' .OR. trimvar(1:3) == 'em_') ) THEN 541 CALL chem_3d_data_averaging( 'allocate', doav(ii) ) 542 ENDIF 543 544 IF ( bulk_cloud_model ) THEN 545 CALL bcm_3d_data_averaging( 'allocate', doav(ii) ) 546 ENDIF 547 548 IF ( gust_module_enabled ) THEN 549 CALL gust_3d_data_averaging( 'allocate', doav(ii) ) 550 ENDIF 551 552 IF ( biometeorology ) THEN 553 CALL bio_3d_data_averaging( 'allocate', doav(ii) ) 554 ENDIF 555 556 IF ( land_surface ) THEN 557 CALL lsm_3d_data_averaging( 'allocate', doav(ii) ) 558 ENDIF 559 560 IF ( ocean_mode ) THEN 561 CALL ocean_3d_data_averaging( 'allocate', doav(ii) ) 562 ENDIF 563 564 IF ( radiation ) THEN 565 CALL radiation_3d_data_averaging( 'allocate', doav(ii) ) 566 ENDIF 567 568 IF ( salsa ) THEN 569 CALL salsa_3d_data_averaging( 'allocate', doav(ii) ) 570 ENDIF 571 572 CALL tcm_3d_data_averaging( 'allocate', doav(ii) ) 573 574 IF ( urban_surface .AND. trimvar(1:4) == 'usm_' ) THEN 575 CALL usm_average_3d_data( 'allocate', doav(ii) ) 576 ENDIF 577 578 ! 579 !-- User-defined quantities 580 CALL user_3d_data_averaging( 'allocate', doav(ii) ) 521 !-- Allocating and initializing data arrays for turbulence closure module 522 CALL tcm_3d_data_averaging( 'allocate', trimvar ) 523 524 ! 525 !-- Allocating and initializing data arrays for all other modules 526 CALL module_interface_3d_data_averaging( 'allocate', trimvar ) 527 581 528 582 529 END SELECT … … 1183 1130 1184 1131 CASE DEFAULT 1185 !1186 !-- Summing up data from other modules1187 IF ( bulk_cloud_model ) THEN1188 CALL bcm_3d_data_averaging( 'sum', doav(ii) )1189 ENDIF1190 1191 IF ( air_chemistry .AND. &1192 (trimvar(1:3) == 'kc_' .OR. trimvar(1:3) == 'em_') ) THEN1193 CALL chem_3d_data_averaging( 'sum',doav(ii) )1194 ENDIF1195 1196 IF ( gust_module_enabled ) THEN1197 CALL gust_3d_data_averaging( 'sum', doav(ii) )1198 ENDIF1199 1200 IF ( biometeorology ) THEN1201 CALL bio_3d_data_averaging( 'sum', doav(ii) )1202 ENDIF1203 1204 IF ( land_surface ) THEN1205 CALL lsm_3d_data_averaging( 'sum', doav(ii) )1206 ENDIF1207 1208 IF ( ocean_mode ) THEN1209 CALL ocean_3d_data_averaging( 'sum', doav(ii) )1210 ENDIF1211 1212 IF ( radiation ) THEN1213 CALL radiation_3d_data_averaging( 'sum', doav(ii) )1214 ENDIF1215 1216 IF ( salsa ) THEN1217 CALL salsa_3d_data_averaging( 'sum', doav(ii) )1218 ENDIF1219 1220 CALL tcm_3d_data_averaging( 'sum', doav(ii) )1221 1132 1222 1133 !-- In case of urban surface variables it should be always checked 1223 1134 !-- if respective arrays are allocated, at least in case of a restart 1224 1135 !-- run, as averaged usm arrays are not read from file at the moment. 1225 IF ( urban_surface .AND. trimvar(1:4) == 'usm_' ) THEN 1226 CALL usm_average_3d_data( 'allocate', doav(ii) ) 1227 CALL usm_average_3d_data( 'sum', doav(ii) ) 1228 ENDIF 1229 1230 ! 1231 !-- User-defined quantities 1232 CALL user_3d_data_averaging( 'sum', doav(ii) ) 1136 IF ( urban_surface ) THEN 1137 CALL usm_3d_data_averaging( 'allocate', trimvar ) 1138 ENDIF 1139 1140 ! 1141 !-- Summing up data from turbulence closure module 1142 CALL tcm_3d_data_averaging( 'sum', trimvar ) 1143 1144 ! 1145 !-- Summing up data from all other modules 1146 CALL module_interface_3d_data_averaging( 'sum', trimvar ) 1147 1233 1148 1234 1149 END SELECT -
palm/trunk/SOURCE/swap_timelevel.f90
r3636 r3637 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Implementation of the PALM module interface 28 ! 29 ! 3636 2018-12-19 13:48:34Z raasch 27 30 ! nopointer option removed 28 31 ! … … 151 154 v, v_1, v_2, v_p, w, w_1, w_2, w_p 152 155 153 USE bulk_cloud_model_mod, &154 ONLY: bulk_cloud_model, bcm_swap_timelevel155 156 USE chemistry_model_mod, &157 ONLY: chem_swap_timelevel158 159 156 USE cpulog, & 160 157 ONLY: cpu_log, log_point 161 158 162 159 USE control_parameters, & 163 ONLY: air_chemistry, humidity, land_surface, neutral, ocean_mode, & 164 passive_scalar, simulated_time, timestep_count, urban_surface, & 165 time_since_reference_point, salsa 166 167 USE gust_mod, & 168 ONLY: gust_module_enabled, gust_swap_timelevel 169 170 USE land_surface_model_mod, & 171 ONLY: lsm_swap_timelevel 172 173 USE ocean_mod, & 174 ONLY: ocean_swap_timelevel 160 ONLY: humidity, neutral, passive_scalar, timestep_count 161 162 USE kinds 163 164 USE module_interface, & 165 ONLY: module_interface_swap_timelevel 175 166 176 167 USE pmc_interface, & 177 168 ONLY: nested_run, pmci_set_swaplevel 178 179 USE salsa_mod, &180 ONLY: salsa_swap_timelevel, skip_time_do_salsa181 169 182 170 USE turbulence_closure_mod, & 183 171 ONLY: tcm_swap_timelevel 184 172 185 USE urban_surface_mod, &186 ONLY: usm_swap_timelevel187 188 173 189 174 IMPLICIT NONE 190 175 191 INTEGER :: swap_level !> swap_level for steering the pmc data transfer176 INTEGER(iwp) :: swap_level !> swap_level for steering the pmc data transfer 192 177 193 178 ! … … 237 222 END SELECT 238 223 239 IF ( humidity .AND. bulk_cloud_model ) THEN 240 CALL bcm_swap_timelevel( MOD( timestep_count, 2) ) 241 ENDIF 242 243 IF ( air_chemistry ) CALL chem_swap_timelevel( MOD( timestep_count, 2) ) 244 245 IF ( gust_module_enabled ) THEN 246 CALL gust_swap_timelevel( MOD( timestep_count, 2) ) 247 ENDIF 248 249 IF ( land_surface ) THEN 250 CALL lsm_swap_timelevel( MOD( timestep_count, 2) ) 251 ENDIF 252 253 IF ( ocean_mode ) THEN 254 CALL ocean_swap_timelevel( MOD( timestep_count, 2 ) ) 255 ENDIF 256 257 IF ( salsa .AND. simulated_time >= time_since_reference_point ) THEN 258 CALL salsa_swap_timelevel( MOD( timestep_count, 2 ) ) 259 ENDIF 260 224 ! 225 !-- Set the swap level the turbulence closure module 261 226 CALL tcm_swap_timelevel( MOD( timestep_count, 2) ) 262 227 263 IF ( urban_surface ) THEN 264 CALL usm_swap_timelevel( MOD( timestep_count, 2) ) 265 ENDIF228 ! 229 !-- Set the swap level for all other modules 230 CALL module_interface_swap_timelevel( MOD( timestep_count, 2) ) 266 231 267 232 ! -
palm/trunk/SOURCE/urban_surface_mod.f90
r3636 r3637 28 28 ! ----------------- 29 29 ! $Id$ 30 ! Implementation of the PALM module interface 31 ! 32 ! 3636 2018-12-19 13:48:34Z raasch 30 33 ! nopointer option removed 31 34 ! … … 52 55 ! 53 56 ! 3449 2018-10-29 19:36:56Z suehring 54 ! Bugfix: Fix average arrays allocations in usm_ average_3d_data(J.Resler)57 ! Bugfix: Fix average arrays allocations in usm_3d_data_averaging (J.Resler) 55 58 ! Bugfix: Fix reading wall temperatures (J.Resler) 56 59 ! Bugfix: Fix treating of outputs for wall temperature and sky view factors (J.Resler) … … 182 185 ! 2906 2018-03-19 08:56:40Z Giersch 183 186 ! Local variable ids has to be initialized with a value of -1 in 184 ! usm_ average_3d_data187 ! usm_3d_data_averaging 185 188 ! 186 189 ! 2894 2018-03-15 09:17:58Z Giersch … … 1125 1128 END INTERFACE usm_allocate_surface 1126 1129 1127 INTERFACE usm_ average_3d_data1128 MODULE PROCEDURE usm_ average_3d_data1129 END INTERFACE usm_ average_3d_data1130 INTERFACE usm_3d_data_averaging 1131 MODULE PROCEDURE usm_3d_data_averaging 1132 END INTERFACE usm_3d_data_averaging 1130 1133 1131 1134 … … 1138 1141 usm_rrd_local, & 1139 1142 usm_surface_energy_balance, usm_material_heat_model, & 1140 usm_swap_timelevel, usm_check_data_output, usm_ average_3d_data,&1143 usm_swap_timelevel, usm_check_data_output, usm_3d_data_averaging, & 1141 1144 usm_data_output_3d, usm_define_netcdf_grid, usm_parin, & 1142 1145 usm_wrd_local, usm_allocate_surface … … 1563 1566 !> the array necessary for storing the average. 1564 1567 !------------------------------------------------------------------------------! 1565 SUBROUTINE usm_ average_3d_data( mode, variable )1568 SUBROUTINE usm_3d_data_averaging( mode, variable ) 1566 1569 1567 1570 IMPLICIT NONE … … 1575 1578 CHARACTER(LEN=6), DIMENSION(0:nd-1), PARAMETER :: dirname = (/ '_roof ', '_south', '_north', '_west ', '_east ' /) 1576 1579 INTEGER(iwp), DIMENSION(0:nd-1), PARAMETER :: dirint = (/ iup_u, isouth_u, inorth_u, iwest_u, ieast_u /) 1580 1581 IF ( variable(1:4) == 'usm_' ) THEN ! is such a check really rquired? 1577 1582 1578 1583 !-- find the real name of the variable … … 2447 2452 ENDIF 2448 2453 2449 END SUBROUTINE usm_average_3d_data 2454 ENDIF 2455 2456 END SUBROUTINE usm_3d_data_averaging 2450 2457 2451 2458 -
palm/trunk/SOURCE/write_restart_data_mod.f90
r3589 r3637 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Implementation of the PALM module interface 28 ! 29 ! 3589 2018-11-30 15:09:51Z suehring 27 30 ! Move the control parameter "salsa" from salsa_mod to control_parameters 28 31 ! (M. Kurppa) … … 69 72 70 73 74 USE arrays_3d, & 75 ONLY: inflow_damping_factor, mean_inflow_profiles, pt_init, & 76 q_init, ref_state, s_init, u_init, ug, v_init, vg, & 77 e, kh, km, p, pt, q, ql, s, u, u_m_l, u_m_n, u_m_r, & 78 u_m_s, v, v_m_l, v_m_n, v_m_r, v_m_s, vpt, w, w_m_l, w_m_n, & 79 w_m_r, w_m_s 80 81 USE averaging 82 71 83 USE control_parameters 72 73 USE kinds 84 85 USE date_and_time_mod, & 86 ONLY: day_of_year_init, time_utc_init 87 88 USE grid_variables, & 89 ONLY: dx, dy 90 91 USE indices, & 92 ONLY: nx, nxl, nxr, ny, nys, nyn, nz, nzb, nzt 93 94 USE kinds 95 96 USE model_1d_mod, & 97 ONLY: damp_level_1d, dt_pr_1d, dt_run_control_1d, end_time_1d 98 99 USE module_interface, & 100 ONLY: module_interface_wrd_global, & 101 module_interface_wrd_local 102 103 USE netcdf_interface, & 104 ONLY: netcdf_precision, output_for_t0 105 106 USE particle_attributes, & 107 ONLY: curvature_solution_effects, iran_part 74 108 75 109 USE pegrid, & 76 ONLY: myid, numprocs 77 110 ONLY: collective_wait, hor_index_bounds, myid, numprocs 111 112 USE radiation_model_mod, & 113 ONLY: time_radiation 114 115 USE random_function_mod, & 116 ONLY: random_iv, random_iy 117 118 USE random_generator_parallel, & 119 ONLY: id_random_array, seq_random_array 120 121 USE spectra_mod, & 122 ONLY: average_count_sp, spectrum_x, spectrum_y 123 124 USE statistics, & 125 ONLY: statistic_regions, hom, hom_sum, u_max, u_max_ijk, v_max, & 126 v_max_ijk, w_max, w_max_ijk, z_i 127 128 USE surface_mod, & 129 ONLY : surface_wrd_local 130 131 USE vertical_nesting_mod, & 132 ONLY: vnest_init 133 78 134 79 135 IMPLICIT NONE … … 103 159 SUBROUTINE wrd_global 104 160 105 106 USE arrays_3d, &107 ONLY: inflow_damping_factor, mean_inflow_profiles, pt_init, &108 q_init, ref_state, s_init, u_init, ug, v_init, vg109 110 USE bulk_cloud_model_mod, &111 ONLY: bulk_cloud_model, bcm_wrd_global112 113 USE date_and_time_mod, &114 ONLY: day_of_year_init, time_utc_init115 116 USE flight_mod, &117 ONLY: flight_wrd_global118 119 USE grid_variables, &120 ONLY: dx, dy121 122 USE gust_mod, &123 ONLY : gust_module_enabled, gust_wrd_global124 125 USE indices, &126 ONLY: nx, ny, nz127 128 USE model_1d_mod, &129 ONLY: damp_level_1d, dt_pr_1d, dt_run_control_1d, end_time_1d130 131 USE netcdf_interface, &132 ONLY: netcdf_precision, output_for_t0133 134 USE ocean_mod, &135 ONLY: ocean_wrd_global136 137 USE particle_attributes, &138 ONLY: curvature_solution_effects139 140 USE pegrid, &141 ONLY: hor_index_bounds, collective_wait142 143 USE radiation_model_mod, &144 ONLY: time_radiation145 146 USE spectra_mod, &147 ONLY: average_count_sp, spectrum_x, spectrum_y148 149 USE synthetic_turbulence_generator_mod, &150 ONLY: stg_wrd_global151 152 USE statistics, &153 ONLY: statistic_regions, hom, hom_sum, u_max, u_max_ijk, v_max, &154 v_max_ijk, w_max, w_max_ijk, z_i155 156 USE user_write_restart_data_mod, &157 ONLY: user_wrd_global158 159 USE vertical_nesting_mod, &160 ONLY: vnest_init161 162 USE wind_turbine_model_mod, &163 ONLY: wtm_wrd_global164 165 166 IMPLICIT NONE167 161 168 162 CHARACTER (LEN=10) :: binary_version_global !< … … 886 880 ! 887 881 !-- Write restart data of the other modules 888 !-- The order of the calls can be different as in read_restart_data_mod where 889 !-- the restart data will be read 890 IF ( bulk_cloud_model ) CALL bcm_wrd_global 891 IF ( virtual_flight ) CALL flight_wrd_global 892 IF ( gust_module_enabled ) CALL gust_wrd_global 893 IF ( ocean_mode ) CALL ocean_wrd_global 894 IF ( syn_turb_gen ) CALL stg_wrd_global 895 IF ( wind_turbine ) CALL wtm_wrd_global 896 ! 897 !-- Write restart data of the user-interface 898 CALL user_wrd_global 882 CALL module_interface_wrd_global 899 883 900 884 … … 910 894 !------------------------------------------------------------------------------! 911 895 SUBROUTINE wrd_local 912 913 914 USE arrays_3d, & 915 ONLY: e, kh, km, p, pt, q, ql, s, u, u_m_l, u_m_n, u_m_r, & 916 u_m_s, v, v_m_l, v_m_n, v_m_r, v_m_s, vpt, w, w_m_l, w_m_n, & 917 w_m_r, w_m_s 918 919 USE averaging 920 921 USE bulk_cloud_model_mod, & 922 ONLY: bulk_cloud_model, bcm_wrd_local 923 924 USE chemistry_model_mod, & 925 ONLY: chem_wrd_local 926 927 USE gust_mod, & 928 ONLY : gust_module_enabled, gust_wrd_local 929 930 USE indices, & 931 ONLY: nxl, nxr, nys, nyn, nzb, nzt 932 933 USE land_surface_model_mod, & 934 ONLY: lsm_wrd_local 935 936 USE ocean_mod, & 937 ONLY: ocean_wrd_local 938 939 USE particle_attributes, & 940 ONLY: iran_part 941 942 USE radiation_model_mod, & 943 ONLY: radiation, radiation_wrd_local 944 945 USE random_function_mod, & 946 ONLY: random_iv, random_iy 947 948 USE random_generator_parallel, & 949 ONLY: id_random_array, seq_random_array 950 951 USE salsa_mod, & 952 ONLY: salsa_wrd_local 953 954 USE surface_mod, & 955 ONLY : surface_wrd_local 956 957 USE urban_surface_mod, & 958 ONLY: usm_wrd_local 959 960 USE user_write_restart_data_mod, & 961 ONLY: user_wrd_local 962 963 964 IMPLICIT NONE 896 965 897 966 898 CHARACTER (LEN=10) :: binary_version_local !< 967 968 899 969 900 ! … … 1271 1202 ENDIF 1272 1203 1204 1205 CALL surface_wrd_local 1206 1273 1207 ! 1274 1208 !-- Write restart data of other modules 1275 IF ( bulk_cloud_model ) CALL bcm_wrd_local 1276 IF ( air_chemistry ) CALL chem_wrd_local 1277 IF ( gust_module_enabled ) CALL gust_wrd_local 1278 IF ( land_surface ) CALL lsm_wrd_local 1279 IF ( ocean_mode ) CALL ocean_wrd_local 1280 IF ( radiation ) CALL radiation_wrd_local 1281 IF ( salsa ) CALL salsa_wrd_local 1282 CALL surface_wrd_local 1283 IF ( urban_surface ) CALL usm_wrd_local 1284 1285 ! 1286 !-- Write user-defined restart data 1287 CALL user_wrd_local 1209 CALL module_interface_wrd_local 1288 1210 1289 1211 !
Note: See TracChangeset
for help on using the changeset viewer.