Changeset 3876


Ignore:
Timestamp:
Apr 8, 2019 6:41:49 PM (5 years ago)
Author:
knoop
Message:

Moved "photolysis_scheme", "chem_species" and "phot_frequen" to chem_modules

Location:
palm/trunk/SOURCE
Files:
11 edited

Legend:

Unmodified
Added
Removed
  • palm/trunk/SOURCE/Makefile

    r3875 r3876  
    882882        basic_constants_and_equations_mod.o \
    883883        chem_gasphase_mod.o \
    884         chemistry_model_mod.o \
     884        chem_modules.o \
    885885        mod_kinds.o \
    886886        modules.o \
     
    13331333        basic_constants_and_equations_mod.o \
    13341334        biometeorology_mod.o \
    1335         chemistry_model_mod.o \
    13361335        cpulog_mod.o \
    13371336        mod_kinds.o \
     
    13681367        user_module.o
    13691368nesting_offl_mod.o: \
    1370         chemistry_model_mod.o \
     1369        chem_modules.o \
    13711370        cpulog_mod.o \
    13721371        mod_kinds.o \
     
    14411440pmc_interface_mod.o: \
    14421441        bulk_cloud_model_mod.o \
     1442        chem_modules.o \
    14431443        chemistry_model_mod.o \
    14441444        chem_gasphase_mod.o \
     
    15841584        advec_s_up.o \
    15851585        chem_gasphase_mod.o \
    1586         chemistry_model_mod.o \
     1586        chem_modules.o \
    15871587        diffusion_s.o \
    15881588        netcdf_data_input_mod.o \
     
    18511851virtual_measurement_mod.o: \
    18521852        cpulog_mod.o \
    1853         chemistry_model_mod.o \
     1853        chem_modules.o \
    18541854        chem_gasphase_mod.o \
    18551855        mod_kinds.o \
  • palm/trunk/SOURCE/chem_modules.f90

    r3835 r3876  
    9494    CHARACTER (LEN=80) ::  mode_emis      = 'PARAMETERIZED'     !< namelist parameter: mode of chemistry emissions - DEFAULT, EXPERT, PARAMETERIZED
    9595    CHARACTER (LEN=80) ::  time_fac_type  = 'MDH'               !< namelist parameter: type of time treatment in the mode_emis DEFAULT - HOUR, MDH
    96    
     96    CHARACTER (LEN=10) ::  photolysis_scheme                    !< 'constant',
     97                                                                !< 'simple' (Simple parameterisation from MCM, Saunders et al., 2003, Atmos. Chem. Phys., 3, 161-180
     98                                                                !< 'fastj'  (Wild et al., 2000, J. Atmos. Chem., 37, 245-282) STILL NOT IMPLEMENTED
     99
    97100    CHARACTER (LEN=11), DIMENSION(99) ::  cs_name             = 'novalue'  !< namelist parameter: names of species with given fluxes (see csflux)
    98101    CHARACTER (LEN=11), DIMENSION(99) ::  cs_profile_name     = 'novalue'  !< namelist parameter: tbc...???
     
    183186    REAL, PARAMETER ::  xm_NO3   = xm_N + xm_O * 3         !< NO3      molecular weight (kg/mol)
    184187    REAL, PARAMETER ::  xm_SO4   = xm_S + xm_O * 4         !< SO4      molecular weight (kg/mol)
     188!
     189!-  Define chemical variables within chem_species
     190    TYPE species_def
     191       CHARACTER(LEN=15)                            ::  name         !< name of chemical species
     192       CHARACTER(LEN=15)                            ::  unit         !< unit (ppm for gases, kg m^-3 for aerosol tracers)
     193       REAL(kind=wp), POINTER, DIMENSION(:,:,:)     ::  conc         !< concentrations of trace gases
     194       REAL(kind=wp), POINTER, DIMENSION(:,:,:)     ::  conc_av      !< averaged concentrations
     195       REAL(kind=wp), POINTER, DIMENSION(:,:,:)     ::  conc_p       !< conc at prognostic time level
     196       REAL(kind=wp), POINTER, DIMENSION(:,:,:)     ::  tconc_m      !< weighted tendency of conc for previous sub-timestep (Runge-Kutta)
     197       REAL(kind=wp), ALLOCATABLE, DIMENSION(:,:)   ::  cssws_av     !< averaged fluxes of trace gases at surface
     198       REAL(kind=wp), ALLOCATABLE, DIMENSION(:,:)   ::  flux_s_cs    !< 6th-order advective flux at south face of grid box of chemical species (='cs')
     199       REAL(kind=wp), ALLOCATABLE, DIMENSION(:,:)   ::  diss_s_cs    !< artificial numerical dissipation flux at south face of grid box of chemical species
     200       REAL(kind=wp), ALLOCATABLE, DIMENSION(:,:,:) ::  flux_l_cs    !< 6th-order advective flux at left face of grid box of chemical species (='cs')
     201       REAL(kind=wp), ALLOCATABLE, DIMENSION(:,:,:) ::  diss_l_cs    !< artificial numerical dissipation flux at left face of grid box of chemical species
     202       REAL(kind=wp), ALLOCATABLE, DIMENSION(:)     ::  conc_pr_init !< initial profile of chemical species
     203    END TYPE species_def
     204!
     205!-- Define photolysis frequencies in phot_frequen
     206    TYPE photols_def
     207       CHARACTER(LEN=15)                            :: name          !< name of pgotolysis frequency
     208       CHARACTER(LEN=15)                            :: unit          !< unit (1/s)
     209       REAL(kind=wp), POINTER, DIMENSION(:,:,:)     :: freq          !< photolysis frequency
     210    END TYPE photols_def
     211
     212
     213    TYPE(species_def), ALLOCATABLE, DIMENSION(:), TARGET ::  chem_species
     214    TYPE(photols_def), ALLOCATABLE, DIMENSION(:), TARGET ::  phot_frequen
    185215
    186216    SAVE
  • palm/trunk/SOURCE/chem_photolysis_mod.f90

    r3838 r3876  
    7878        ONLY: nphot, phot_names, phot
    7979
    80     USE chemistry_model_mod,                                                   &
     80    USE chem_modules,                                                          &
    8181        ONLY: phot_frequen, photolysis_scheme
    8282
  • palm/trunk/SOURCE/chemistry_model_mod.f90

    r3862 r3876  
    318318
    319319    LOGICAL ::  nest_chemistry = .TRUE.  !< flag for nesting mode of chemical species, independent on parent or not
    320 !
    321 !-  Define chemical variables within chem_species
    322     TYPE species_def
    323        CHARACTER(LEN=15)                            ::  name         !< name of chemical species
    324        CHARACTER(LEN=15)                            ::  unit         !< unit (ppm for gases, kg m^-3 for aerosol tracers)
    325        REAL(kind=wp), POINTER, DIMENSION(:,:,:)     ::  conc         !< concentrations of trace gases
    326        REAL(kind=wp), POINTER, DIMENSION(:,:,:)     ::  conc_av      !< averaged concentrations
    327        REAL(kind=wp), POINTER, DIMENSION(:,:,:)     ::  conc_p       !< conc at prognostic time level
    328        REAL(kind=wp), POINTER, DIMENSION(:,:,:)     ::  tconc_m      !< weighted tendency of conc for previous sub-timestep (Runge-Kutta)
    329        REAL(kind=wp), ALLOCATABLE, DIMENSION(:,:)   ::  cssws_av     !< averaged fluxes of trace gases at surface
    330        REAL(kind=wp), ALLOCATABLE, DIMENSION(:,:)   ::  flux_s_cs    !< 6th-order advective flux at south face of grid box of chemical species (='cs')
    331        REAL(kind=wp), ALLOCATABLE, DIMENSION(:,:)   ::  diss_s_cs    !< artificial numerical dissipation flux at south face of grid box of chemical species
    332        REAL(kind=wp), ALLOCATABLE, DIMENSION(:,:,:) ::  flux_l_cs    !< 6th-order advective flux at left face of grid box of chemical species (='cs')
    333        REAL(kind=wp), ALLOCATABLE, DIMENSION(:,:,:) ::  diss_l_cs    !< artificial numerical dissipation flux at left face of grid box of chemical species
    334        REAL(kind=wp), ALLOCATABLE, DIMENSION(:)     ::  conc_pr_init !< initial profile of chemical species
    335     END TYPE species_def
    336 !
    337 !-- Define photolysis frequencies in phot_frequen
    338     TYPE photols_def                                                           
    339        CHARACTER(LEN=15)                            :: name          !< name of pgotolysis frequency
    340        CHARACTER(LEN=15)                            :: unit          !< unit (1/s)
    341        REAL(kind=wp), POINTER, DIMENSION(:,:,:)     :: freq          !< photolysis frequency
    342     END TYPE photols_def
    343 
    344 
    345     TYPE(species_def), ALLOCATABLE, DIMENSION(:), TARGET, PUBLIC ::  chem_species
    346     TYPE(photols_def), ALLOCATABLE, DIMENSION(:), TARGET, PUBLIC ::  phot_frequen 
    347320
    348321    REAL(kind=wp), ALLOCATABLE, DIMENSION(:,:,:,:), TARGET ::  spec_conc_1  !< pointer for swapping of timelevels for conc
     
    374347
    375348    REAL(kind=wp), PUBLIC ::  cs_time_step = 0._wp
    376     CHARACTER(10), PUBLIC ::  photolysis_scheme
    377                               !< 'constant',
    378                               !< 'simple' (Simple parameterisation from MCM, Saunders et al., 2003, Atmos. Chem. Phys., 3, 161-180
    379                               !< 'fastj'  (Wild et al., 2000, J. Atmos. Chem., 37, 245-282) STILL NOT IMPLEMENTED
    380 
    381349
    382350!
     
    445413    PUBLIC nspec               !< number of gas phase chemical species including constant compound (e.g. N2)
    446414    PUBLIC nvar                !< number of variable gas phase chemical species (nvar <= nspec)
    447     PUBLIC photols_def         !< type defining phot_frequen
    448     PUBLIC species_def         !< type defining chem_species
    449415    PUBLIC spc_names           !< names of gas phase chemical species (come from KPP) (come from KPP)
    450416    PUBLIC spec_conc_2 
  • palm/trunk/SOURCE/multi_agent_system_mod.f90

    r3833 r3876  
    27752775           ONLY:  u, v, pt, exner
    27762776
    2777 !       USE chemistry_model_mod,                                                &
    2778 !           ONLY:  chem_species
    2779 
    2780 !       USE control_parameters,                                                 &
    2781 !              ONLY:  air_chemistry
    2782 
    27832777       IMPLICIT NONE
    27842778
     
    28462840!--                Calculate temperature at agent position
    28472841                   agents(nl)%t = pt(kl,jl,il) * exner(kl)
    2848 ! !
    2849 ! !--                Get PM10 concentration at agent position, if possible
    2850 !                    IF ( ind_pm10 == -9 ) THEN
    2851 !                       agents(nl)%pm10 = 0.0_wp
    2852 !                    ELSE
    2853 !                       agents(nl)%pm10 = chem_species(ind_pm10)%conc(kl,jl,il)
    2854 !                    ENDIF
    2855 ! !
    2856 ! !--                Get PM10 concentration at agent position, if possible
    2857 !                    IF ( ind_pm25 == -9 ) THEN
    2858 !                       agents(nl)%pm25 = 0.0_wp
    2859 !                    ELSE
    2860 !                       agents(nl)%pm25 = chem_species(ind_pm25)%conc(kl,jl,il)
    2861 !                    ENDIF
     2842
    28622843                ENDDO
    28632844
     
    30172998    SUBROUTINE mas_init
    30182999
    3019 !       USE chem_gasphase_mod,                                                  &
    3020 !           ONLY:  nvar
    3021 
    3022 !       USE chemistry_model_mod,                                                &
    3023 !           ONLY:  chem_species
    3024 
    30253000       USE control_parameters,                                                 &
    30263001           ONLY:  coupling_char, initializing_actions, io_blocks, io_group
     
    31083083          ENDDO
    31093084       ENDDO
    3110 ! !
    3111 ! !--    Get indices of PM10 and PM2.5 species, if active
    3112 !        IF ( air_chemistry ) THEN
    3113 !           DO il = 1, nvar
    3114 ! print*,chem_species(il)%name
    3115 ! !              IF ( spec_name(1:4) == 'PM10' ) THEN 
    3116 ! !                 ind_pm10 = il
    3117 ! !              ELSEIF ( spec_name(1:4) == 'PM25' ) THEN
    3118 ! !                 ind_pm25 = il
    3119 ! !              ENDIF
    3120 !
    3121 !           ENDDO
    3122 !        ENDIF
    3123 ! stop
     3085
    31243086       CALL mas_create_obstacle_flags
    31253087
  • palm/trunk/SOURCE/nesting_offl_mod.f90

    r3858 r3876  
    6363               v_init, vg, w, zu, zw
    6464                 
    65     USE chemistry_model_mod,                                                   &
     65    USE chem_modules,                                                          &
    6666        ONLY:  chem_species
    6767
  • palm/trunk/SOURCE/pmc_interface_mod.f90

    r3864 r3876  
    403403               roughness_length, salsa, topography, volume_flow
    404404
    405     USE chem_gasphase_mod,                                                          &
     405    USE chem_gasphase_mod,                                                     &
    406406        ONLY:  nspec
    407407
     408    USE chem_modules,                                                          &
     409        ONLY:  chem_species
     410
    408411    USE chemistry_model_mod,                                                   &
    409         ONLY:  chem_species, nest_chemistry, spec_conc_2
     412        ONLY:  nest_chemistry, spec_conc_2
    410413
    411414    USE cpulog,                                                                &
  • palm/trunk/SOURCE/prognostic_equations.f90

    r3875 r3876  
    389389    USE chem_modules,                                                          &
    390390        ONLY:  call_chem_at_all_substeps, chem_gasphase_on, cs_name,           &
    391                deposition_dry
     391               deposition_dry, chem_species
    392392
    393393    USE chem_gasphase_mod,                                                     &
     
    399399    USE chemistry_model_mod,                                                   &
    400400        ONLY:  chem_boundary_conds, chem_depo, chem_integrate,                 &
    401                chem_prognostic_equations, chem_species
     401               chem_prognostic_equations
    402402
    403403    USE control_parameters,                                                    &
  • palm/trunk/SOURCE/salsa_mod.f90

    r3872 r3876  
    135135        ONLY:  nspec, nvar, spc_names
    136136
    137     USE chemistry_model_mod,                                                   &
    138         ONLY:  chem_species
    139 
    140137    USE chem_modules,                                                          &
    141         ONLY:  call_chem_at_all_substeps, chem_gasphase_on
     138        ONLY:  call_chem_at_all_substeps, chem_gasphase_on, chem_species
    142139
    143140    USE control_parameters
  • palm/trunk/SOURCE/time_integration.f90

    r3875 r3876  
    509509
    510510    USE chem_modules,                                                                              &
    511         ONLY:  bc_cs_t_val, cs_name, emissions_anthropogenic, nspec_out
     511        ONLY:  bc_cs_t_val, cs_name, emissions_anthropogenic, nspec_out, chem_species
    512512
    513513    USE chemistry_model_mod,                                                                       &
    514         ONLY:  chem_boundary_conds, chem_species
     514        ONLY:  chem_boundary_conds
    515515
    516516    USE control_parameters,                                                                        &
     
    892892
    893893!
    894 !--    Execute alle other module actions routunes
     894!--    Execute all other module actions routunes
    895895       CALL module_interface_actions( 'before_timestep' )
    896896       
     
    950950             CALL calc_mean_profile( q, 41 )
    951951          ENDIF
    952 
     952!
     953!--       Execute all other module actions routunes
     954          CALL module_interface_actions( 'before_prognostic_equations' )
    953955!
    954956!--       Solve the prognostic equations. A fast cache optimized version with
  • palm/trunk/SOURCE/virtual_measurement_mod.f90

    r3855 r3876  
    8686        ONLY:  nvar
    8787
    88     USE chemistry_model_mod,                                                   &
     88    USE chem_modules,                                                          &
    8989        ONLY:  chem_species
    9090       
Note: See TracChangeset for help on using the changeset viewer.