Skip to content

Commit

Permalink
[HM Test] Added a test together with a reference test for the stagger…
Browse files Browse the repository at this point in the history
…ed scheme
  • Loading branch information
wenqing committed Dec 18, 2017
1 parent 6ba7b1a commit f691ae3
Show file tree
Hide file tree
Showing 7 changed files with 588 additions and 0 deletions.
30 changes: 30 additions & 0 deletions ProcessLib/HydroMechanics/Tests.cmake
@@ -1,4 +1,6 @@
# HydroMechanics; Small deformations, linear poroelastic (HML)

### With monolithic scheme
AddTest(
NAME HydroMechanics_HML_square_1e2_quad8_confined_compression
PATH HydroMechanics/Linear/Confined_Compression
Expand Down Expand Up @@ -84,3 +86,31 @@ AddTest(
expected_square_1e2_UC_late_pcs_0_ts_10_t_1000.000000.vtu square_1e2_UC_late_pcs_0_ts_10_t_1000.000000.vtu displacement displacement 1e-13 1e-16
expected_square_1e2_UC_late_pcs_0_ts_10_t_1000.000000.vtu square_1e2_UC_late_pcs_0_ts_10_t_1000.000000.vtu pressure pressure 1e-13 1e-16
)

## Test as the reference of InjectionProduction1D
AddTest(
NAME InjectionProduction1DMono
PATH HydroMechanics/StaggeredScheme/InjectionProduction1D
EXECUTABLE ogs
EXECUTABLE_ARGS InjectionProduction1DMono.prj
WRAPPER time
TESTER vtkdiff
REQUIREMENTS NOT OGS_USE_MPI
DIFF_DATA
InjectionProduction1D_pcs_1_ts_100_t_8640000.000000.vtu InjectionProduction1D_Mono_pcs_0_ts_100_t_8640000.000000.vtu displacement displacement 1e-11 1e-11
InjectionProduction1D_pcs_1_ts_100_t_8640000.000000.vtu InjectionProduction1D_Mono_pcs_0_ts_100_t_8640000.000000.vtu pressure pressure 1e-11 1e-11
)

### With staggered scheme
AddTest(
NAME InjectionProduction1D
PATH HydroMechanics/StaggeredScheme/InjectionProduction1D
EXECUTABLE ogs
EXECUTABLE_ARGS InjectionProduction1D.prj
WRAPPER time
TESTER vtkdiff
REQUIREMENTS NOT OGS_USE_MPI
DIFF_DATA
InjectionProduction1D_Mono_pcs_0_ts_100_t_8640000.000000.vtu InjectionProduction1D_pcs_1_ts_100_t_8640000.000000.vtu displacement displacement 1e-11 1e-11
InjectionProduction1D_Mono_pcs_0_ts_100_t_8640000.000000.vtu InjectionProduction1D_pcs_1_ts_100_t_8640000.000000.vtu pressure pressure 1e-11 1e-11
)
@@ -0,0 +1,296 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<OpenGeoSysProject>
<mesh>mesh.vtu</mesh>
<geometry>bar.gml</geometry>
<processes>
<process>
<name>HM</name>
<type>HYDRO_MECHANICS</type>
<coupling_scheme>staggered</coupling_scheme>
<integration_order>3</integration_order>
<dimension>2</dimension>
<constitutive_relation>
<type>LinearElasticIsotropic</type>
<youngs_modulus>E</youngs_modulus>
<poissons_ratio>nu</poissons_ratio>
</constitutive_relation>
<intrinsic_permeability>k</intrinsic_permeability>
<specific_storage>S</specific_storage>
<fluid_viscosity>mu</fluid_viscosity>
<fluid_density>rho_f</fluid_density>
<biot_coefficient>alpha</biot_coefficient>
<porosity>phi</porosity>
<solid_density>rho_s</solid_density>
<process_variables>
<pressure>pressure</pressure>
<displacement>displacement</displacement>
</process_variables>
<secondary_variables>
<secondary_variable type="static" internal_name="sigma_xx" output_name="sigma_xx"/>
<secondary_variable type="static" internal_name="sigma_yy" output_name="sigma_yy"/>
<secondary_variable type="static" internal_name="sigma_zz" output_name="sigma_zz"/>
<secondary_variable type="static" internal_name="sigma_xy" output_name="sigma_xy"/>
<secondary_variable type="static" internal_name="epsilon_xx" output_name="epsilon_xx"/>
<secondary_variable type="static" internal_name="epsilon_yy" output_name="epsilon_yy"/>
<secondary_variable type="static" internal_name="epsilon_zz" output_name="epsilon_zz"/>
<secondary_variable type="static" internal_name="epsilon_xy" output_name="epsilon_xy"/>
<secondary_variable type="static" internal_name="velocity" output_name="velocity"/>
</secondary_variables>
<specific_body_force>0 0</specific_body_force>
</process>
</processes>
<time_loop>
<global_process_coupling>
<max_iter> 6 </max_iter>
<convergence_criteria>
<!-- convergence criterion for the first process -->
<convergence_criterion>
<type>DeltaX</type>
<norm_type>NORM2</norm_type>
<reltol>1.e-16</reltol>
</convergence_criterion>
<!-- convergence criterion for the second process -->
<convergence_criterion>
<type>DeltaX</type>
<norm_type>NORM2</norm_type>
<reltol>1.e-16</reltol>
</convergence_criterion>
</convergence_criteria>
</global_process_coupling>

<processes>
<!--For the equations of pressure-->
<process ref="HM">
<nonlinear_solver>basic_newton_p</nonlinear_solver>
<convergence_criterion>
<type>DeltaX</type>
<norm_type>NORM2</norm_type>
<abstol>1e-6</abstol>
</convergence_criterion>
<time_discretization>
<type>BackwardEuler</type>
</time_discretization>
<output>
<variables>
<variable>pressure</variable>
<variable>velocity</variable>
</variables>
</output>
<time_stepping>
<type>FixedTimeStepping</type>
<t_initial>0</t_initial>
<t_end>8.64e6</t_end>
<timesteps>
<pair>
<repeat>100</repeat>
<delta_t>8.64e4</delta_t>
</pair>
</timesteps>
</time_stepping>
</process>
<!--For the equations of deformation-->
<process ref="HM">
<nonlinear_solver>basic_newton_u</nonlinear_solver>
<convergence_criterion>
<type>DeltaX</type>
<norm_type>NORM2</norm_type>
<abstol>1e-6</abstol>
</convergence_criterion>
<time_discretization>
<type>BackwardEuler</type>
</time_discretization>
<output>
<variables>
<variable>displacement</variable>
<variable>sigma_xx</variable>
<variable>sigma_yy</variable>
<variable>sigma_zz</variable>
<variable>sigma_xy</variable>
<variable>epsilon_xx</variable>
<variable>epsilon_yy</variable>
<variable>epsilon_zz</variable>
<variable>epsilon_xy</variable>
</variables>
</output>
<time_stepping>
<type>FixedTimeStepping</type>
<t_initial>0</t_initial>
<t_end>8.64e6</t_end>
<timesteps>
<pair>
<repeat>100</repeat>
<delta_t>8.64e4</delta_t>
</pair>
</timesteps>
</time_stepping>
</process>
</processes>
<output>
<type>VTK</type>
<prefix>InjectionProduction1D</prefix>
<timesteps>
<pair>
<repeat>1</repeat>
<each_steps>1</each_steps>
</pair>
<pair>
<repeat>1</repeat>
<each_steps>19</each_steps>
</pair>
<pair>
<repeat>1</repeat>
<each_steps>100</each_steps>
</pair>
</timesteps>
</output>
</time_loop>
<parameters>
<!-- Mechanics -->
<parameter>
<name>E</name>
<type>Constant</type>
<value>5.0e8</value>
</parameter>
<parameter>
<name>nu</name>
<type>Constant</type>
<value>0.3</value>
</parameter>
<!-- Model parameters -->
<parameter>
<name>k</name>
<type>Constant</type>
<value>4.9346165e-11</value>
</parameter>
<parameter>
<name>S</name>
<type>Constant</type>
<value>1e-5</value>
</parameter>
<parameter>
<name>mu</name>
<type>Constant</type>
<value>1e-3</value>
</parameter>
<parameter>
<name>alpha</name>
<type>Constant</type>
<value>1</value>
</parameter>
<parameter>
<name>phi</name>
<type>Constant</type>
<value>0.3</value>
</parameter>
<parameter>
<name>rho_s</name>
<type>Constant</type>
<value>0.0</value>
</parameter>
<parameter>
<name>rho_f</name>
<type>Constant</type>
<value>1.0e3</value>
</parameter>
<parameter>
<name>displacement0</name>
<type>Constant</type>
<values>0 0</values>
</parameter>
<parameter>
<name>pressure_ic</name>
<type>Constant</type>
<values>0.</values>
</parameter>
<parameter>
<name>dirichlet0</name>
<type>Constant</type>
<value>0</value>
</parameter>
<parameter>
<name>oberburden</name>
<type>Constant</type>
<value>-2.125e6</value>
</parameter>
</parameters>
<process_variables>
<process_variable>
<name>pressure</name>
<components>1</components>
<order>1</order>
<initial_condition>pressure_ic</initial_condition>
</process_variable>
<process_variable>
<name>displacement</name>
<components>2</components>
<order>2</order>
<initial_condition>displacement0</initial_condition>
<boundary_conditions>
<boundary_condition>
<geometrical_set>bar</geometrical_set>
<geometry>left</geometry>
<type>Dirichlet</type>
<component>0</component>
<parameter>dirichlet0</parameter>
</boundary_condition>
<boundary_condition>
<geometrical_set>bar</geometrical_set>
<geometry>right</geometry>
<type>Dirichlet</type>
<component>0</component>
<parameter>dirichlet0</parameter>
</boundary_condition>
<boundary_condition>
<geometrical_set>bar</geometrical_set>
<geometry>bottom</geometry>
<type>Dirichlet</type>
<component>1</component>
<parameter>dirichlet0</parameter>
</boundary_condition>
<boundary_condition>
<geometrical_set>bar</geometrical_set>
<geometry>top</geometry>
<type>Neumann</type>
<component>1</component>
<parameter>oberburden</parameter>
</boundary_condition>
</boundary_conditions>
</process_variable>
</process_variables>
<nonlinear_solvers>
<nonlinear_solver>
<name>basic_newton_p</name>
<type>Newton</type>
<max_iter>50</max_iter>
<linear_solver>linear_solver_p</linear_solver>
</nonlinear_solver>
<nonlinear_solver>
<name>basic_newton_u</name>
<type>Newton</type>
<max_iter>50</max_iter>
<linear_solver>linear_solver_u</linear_solver>
</nonlinear_solver>
</nonlinear_solvers>
<linear_solvers>
<linear_solver>
<name>linear_solver_p</name>
<lis>-i bicg -p jacobi -tol 1e-10 -maxiter 10000</lis>
<eigen>
<solver_type>CG</solver_type>
<precon_type>DIAGONAL</precon_type>
<max_iteration_step>10000</max_iteration_step>
<error_tolerance>1e-10</error_tolerance>
</eigen>
</linear_solver>
<linear_solver>
<name>linear_solver_u</name>
<lis>-i bicg -p jacobi -tol 1e-16 -maxiter 10000</lis>
<eigen>
<solver_type>BiCGSTAB</solver_type>
<precon_type>ILUT</precon_type>
<max_iteration_step>10000</max_iteration_step>
<error_tolerance>1e-16</error_tolerance>
</eigen>
</linear_solver>
</linear_solvers>
</OpenGeoSysProject>

0 comments on commit f691ae3

Please sign in to comment.