missing parameters of grid added to the current structure
This commit is contained in:
parent
12cb043d6d
commit
35b8d5fc7f
|
@ -136,12 +136,16 @@ program DAMASK_grid
|
|||
|
||||
!-------------------------------------------------------------------------------------------------
|
||||
! read (and check) field parameters from numerics file
|
||||
num_grid => config_numerics%get_dict('grid', defaultVal=emptyDict)
|
||||
stagItMax = num_grid%get_asInt('maxStaggeredIter',defaultVal=10)
|
||||
maxCutBack = num_grid%get_asInt('maxCutBack',defaultVal=3)
|
||||
|
||||
if (stagItMax < 0) call IO_error(301,ext_msg='maxStaggeredIter')
|
||||
if (maxCutBack < 0) call IO_error(301,ext_msg='maxCutBack')
|
||||
num_solver => config_numerics%get_dict('solver',defaultVal=emptyDict)
|
||||
num_grid => num_solver%get_dict('grid',defaultVal=emptyDict)
|
||||
|
||||
stagItMax = num_grid%get_asInt('N_staggered_iter_max',defaultVal=10)
|
||||
maxCutBack = num_grid%get_asInt('N_cutback_max',defaultVal=3)
|
||||
|
||||
if (stagItMax < 0) call IO_error(301,ext_msg='N_staggered_iter_max')
|
||||
if (maxCutBack < 0) call IO_error(301,ext_msg='N_cutback_max')
|
||||
|
||||
|
||||
if (worldrank == 0) then
|
||||
fileContent = IO_read(CLI_loadFile)
|
||||
|
@ -156,9 +160,6 @@ program DAMASK_grid
|
|||
config_load => YAML_parse_str_asDict(fileContent) !ToDo: misleading prefix (overlaps with entities from config module)
|
||||
solver => config_load%get_dict('solver')
|
||||
|
||||
num_solver => config_numerics%get_dict('solver',defaultVal=emptyDict)
|
||||
num_grid => num_solver%get_dict('grid',defaultVal=emptyDict)
|
||||
|
||||
!--------------------------------------------------------------------------------------------------
|
||||
! assign mechanics solver depending on selected type
|
||||
|
||||
|
|
|
@ -68,7 +68,7 @@ module grid_damage_spectral
|
|||
contains
|
||||
|
||||
!--------------------------------------------------------------------------------------------------
|
||||
!> @brief allocates all neccessary fields and fills them with data
|
||||
!> @brief Allocate all necessary fields and fill them with data, potentially from restart file.
|
||||
!--------------------------------------------------------------------------------------------------
|
||||
subroutine grid_damage_spectral_init(num_grid)
|
||||
|
||||
|
@ -102,14 +102,14 @@ subroutine grid_damage_spectral_init(num_grid)
|
|||
! read numerical parameters and do sanity checks
|
||||
num_grid_damage => num_grid%get_dict('damage',defaultVal=emptyDict)
|
||||
|
||||
num%itmax = num_grid_damage%get_asInt('N_iter_max', defaultVal=250)
|
||||
num%itmax = num_grid_damage%get_asInt('N_iter_max', defaultVal=100)
|
||||
|
||||
num%eps_damage_atol = num_grid_damage%get_asReal('eps_abs_phi',defaultVal=1.0e-2_pReal)
|
||||
num%eps_damage_rtol = num_grid_damage%get_asReal('eps_rel_phi',defaultVal=1.0e-6_pReal)
|
||||
num%phi_min = num_grid_damage%get_asReal('phi_min', defaultVal=1.0e-6_pReal)
|
||||
|
||||
if (num%phi_min < 0.0_pReal) call IO_error(301,ext_msg='phi_min')
|
||||
if (num%itmax <= 1) call IO_error(301,ext_msg='N_iter_max')
|
||||
if (num%itmax < 1) call IO_error(301,ext_msg='N_iter_max')
|
||||
if (num%eps_damage_atol <= 0.0_pReal) call IO_error(301,ext_msg='eps_abs_phi')
|
||||
if (num%eps_damage_rtol <= 0.0_pReal) call IO_error(301,ext_msg='eps_rel_phi')
|
||||
|
||||
|
|
|
@ -94,7 +94,7 @@ module grid_mechanical_FEM
|
|||
contains
|
||||
|
||||
!--------------------------------------------------------------------------------------------------
|
||||
!> @brief Allocate all necessary fields and fills them with data, potentially from restart info.
|
||||
!> @brief Allocate all necessary fields and fill them with data, potentially from restart info.
|
||||
!--------------------------------------------------------------------------------------------------
|
||||
subroutine grid_mechanical_FEM_init(num_grid)
|
||||
|
||||
|
@ -139,13 +139,13 @@ subroutine grid_mechanical_FEM_init(num_grid)
|
|||
num%eps_stress_rtol = num_grid_mech%get_asReal('eps_rel_P', defaultVal=1.0e-3_pReal)
|
||||
|
||||
num%itmin = num_grid_mech%get_asInt('N_iter_min',defaultVal=1)
|
||||
num%itmax = num_grid_mech%get_asInt('N_iter_max',defaultVal=250)
|
||||
num%itmax = num_grid_mech%get_asInt('N_iter_max',defaultVal=100)
|
||||
|
||||
if (num%eps_div_atol <= 0.0_pReal) extmsg = trim(extmsg)//' eps_abs_div(P)'
|
||||
if (num%eps_div_rtol < 0.0_pReal) extmsg = trim(extmsg)//' eps_rel_div(P)'
|
||||
if (num%eps_stress_atol <= 0.0_pReal) extmsg = trim(extmsg)//' eps_abs_P'
|
||||
if (num%eps_stress_rtol < 0.0_pReal) extmsg = trim(extmsg)//' eps_rel_P'
|
||||
if (num%itmax <= 1) extmsg = trim(extmsg)//' N_iter_max'
|
||||
if (num%itmax < 1) extmsg = trim(extmsg)//' N_iter_max'
|
||||
if (num%itmin > num%itmax .or. num%itmin < 1) extmsg = trim(extmsg)//' N_iter_min'
|
||||
|
||||
if (extmsg /= '') call IO_error(301,ext_msg=trim(extmsg))
|
||||
|
|
|
@ -100,7 +100,7 @@ module grid_mechanical_spectral_basic
|
|||
contains
|
||||
|
||||
!--------------------------------------------------------------------------------------------------
|
||||
!> @brief allocates all necessary fields and fills them with data, potentially from restart info
|
||||
!> @brief Allocate all necessary fields and fill them with data, potentially from restart info.
|
||||
!--------------------------------------------------------------------------------------------------
|
||||
subroutine grid_mechanical_spectral_basic_init(num_grid)
|
||||
|
||||
|
@ -137,7 +137,7 @@ subroutine grid_mechanical_spectral_basic_init(num_grid)
|
|||
num_grid_mech => num_grid%get_dict('mechanical',defaultVal=emptyDict)
|
||||
|
||||
num%itmin = num_grid_mech%get_asInt ('N_iter_min',defaultVal=1)
|
||||
num%itmax = num_grid_mech%get_asInt ('N_iter_max',defaultVal=250)
|
||||
num%itmax = num_grid_mech%get_asInt ('N_iter_max',defaultVal=100)
|
||||
|
||||
num%update_gamma = num_grid_fft%get_asBool ('update_gamma',defaultVal=.false.)
|
||||
|
||||
|
@ -150,7 +150,7 @@ subroutine grid_mechanical_spectral_basic_init(num_grid)
|
|||
if (num%eps_div_rtol < 0.0_pReal) extmsg = trim(extmsg)//' eps_rel_div(P)'
|
||||
if (num%eps_stress_atol <= 0.0_pReal) extmsg = trim(extmsg)//' eps_abs_P'
|
||||
if (num%eps_stress_rtol < 0.0_pReal) extmsg = trim(extmsg)//' eps_rel_P'
|
||||
if (num%itmax <= 1) extmsg = trim(extmsg)//' N_iter_max'
|
||||
if (num%itmax < 1) extmsg = trim(extmsg)//' N_iter_max'
|
||||
if (num%itmin > num%itmax .or. num%itmin < 1) extmsg = trim(extmsg)//' N_iter_min'
|
||||
|
||||
if (extmsg /= '') call IO_error(301,ext_msg=trim(extmsg))
|
||||
|
|
|
@ -112,7 +112,7 @@ module grid_mechanical_spectral_polarisation
|
|||
contains
|
||||
|
||||
!--------------------------------------------------------------------------------------------------
|
||||
!> @brief Allocate all necessary fields and fills them with data, potentially from restart info.
|
||||
!> @brief Allocate all necessary fields and fill them with data, potentially from restart info.
|
||||
!--------------------------------------------------------------------------------------------------
|
||||
subroutine grid_mechanical_spectral_polarisation_init(num_grid)
|
||||
|
||||
|
@ -159,7 +159,7 @@ subroutine grid_mechanical_spectral_polarisation_init(num_grid)
|
|||
num%beta = num_grid_mech%get_asReal('beta', defaultVal=1.0_pReal)
|
||||
|
||||
num%itmin = num_grid_mech%get_asInt ('N_iter_min',defaultVal=1)
|
||||
num%itmax = num_grid_mech%get_asInt ('N_iter_max',defaultVal=250)
|
||||
num%itmax = num_grid_mech%get_asInt ('N_iter_max',defaultVal=100)
|
||||
|
||||
if (num%eps_div_atol <= 0.0_pReal) extmsg = trim(extmsg)//' eps_abs_div(P)'
|
||||
if (num%eps_div_rtol < 0.0_pReal) extmsg = trim(extmsg)//' eps_rel_div(P)'
|
||||
|
@ -167,7 +167,7 @@ subroutine grid_mechanical_spectral_polarisation_init(num_grid)
|
|||
if (num%eps_curl_rtol < 0.0_pReal) extmsg = trim(extmsg)//' eps_rel_curl(F)'
|
||||
if (num%eps_stress_atol <= 0.0_pReal) extmsg = trim(extmsg)//' eps_abs_P'
|
||||
if (num%eps_stress_rtol < 0.0_pReal) extmsg = trim(extmsg)//' eps_rel_P'
|
||||
if (num%itmax <= 1) extmsg = trim(extmsg)//' N_iter_max'
|
||||
if (num%itmax < 1) extmsg = trim(extmsg)//' N_iter_max'
|
||||
if (num%itmin > num%itmax .or. num%itmin < 1) extmsg = trim(extmsg)//' N_iter_min'
|
||||
if (num%alpha <= 0.0_pReal .or. num%alpha > 2.0_pReal) extmsg = trim(extmsg)//' alpha'
|
||||
if (num%beta < 0.0_pReal .or. num%beta > 2.0_pReal) extmsg = trim(extmsg)//' beta'
|
||||
|
|
|
@ -67,7 +67,7 @@ module grid_thermal_spectral
|
|||
contains
|
||||
|
||||
!--------------------------------------------------------------------------------------------------
|
||||
!> @brief allocates all neccessary fields and fills them with data
|
||||
!> @brief Allocate all necessary fields and fill them with data, potentially from restart info.
|
||||
!--------------------------------------------------------------------------------------------------
|
||||
subroutine grid_thermal_spectral_init(num_grid)
|
||||
|
||||
|
@ -98,12 +98,12 @@ subroutine grid_thermal_spectral_init(num_grid)
|
|||
! read numerical parameters and do sanity checks
|
||||
num_grid_thermal => num_grid%get_dict('thermal',defaultVal=emptyDict)
|
||||
|
||||
num%itmax = num_grid_thermal%get_asInt('N_iter_max', defaultVal=250)
|
||||
num%itmax = num_grid_thermal%get_asInt('N_iter_max', defaultVal=100)
|
||||
|
||||
num%eps_thermal_atol = num_grid_thermal%get_asReal('eps_abs_T', defaultVal=1.0e-2_pReal)
|
||||
num%eps_thermal_rtol = num_grid_thermal%get_asReal('eps_rel_T', defaultVal=1.0e-6_pReal)
|
||||
|
||||
if (num%itmax <= 1) call IO_error(301,ext_msg='N_iter_max')
|
||||
if (num%itmax < 1) call IO_error(301,ext_msg='N_iter_max')
|
||||
if (num%eps_thermal_atol <= 0.0_pReal) call IO_error(301,ext_msg='eps_abs_T')
|
||||
if (num%eps_thermal_rtol <= 0.0_pReal) call IO_error(301,ext_msg='eps_rel_T')
|
||||
|
||||
|
|
Loading…
Reference in New Issue