LCOV - code coverage report
Current view: top level - src/materials - PorousFlowConstantBiotModulus.C (source / functions) Hit Total Coverage
Test: porous_flow Test Coverage Lines: 31 31 100.0 %
Date: 2017-11-21 14:47:27 Functions: 6 6 100.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /****************************************************************/
       2             : /* MOOSE - Multiphysics Object Oriented Simulation Environment  */
       3             : /*                                                              */
       4             : /*          All contents are licensed under LGPL V2.1           */
       5             : /*             See LICENSE for full restrictions                */
       6             : /****************************************************************/
       7             : 
       8             : #include "PorousFlowConstantBiotModulus.h"
       9             : 
      10             : template <>
      11             : InputParameters
      12          13 : validParams<PorousFlowConstantBiotModulus>()
      13             : {
      14          13 :   InputParameters params = validParams<PorousFlowMaterialVectorBase>();
      15          52 :   params.addRangeCheckedParam<Real>(
      16          13 :       "biot_coefficient", 1.0, "biot_coefficient>=0 & biot_coefficient<=1", "Biot coefficient");
      17          52 :   params.addRangeCheckedParam<Real>(
      18          13 :       "fluid_bulk_modulus", 2.0E9, "fluid_bulk_modulus>0", "Fluid bulk modulus");
      19          52 :   params.addRangeCheckedParam<Real>("solid_bulk_compliance",
      20             :                                     0.0,
      21             :                                     "solid_bulk_compliance>=0.0",
      22             :                                     "Reciprocal of the drained bulk modulus of the porous "
      23             :                                     "skeleton.  If strain = C * stress, then solid_bulk_compliance "
      24             :                                     "= de_ij de_kl C_ijkl.  If the grain bulk modulus is Kg then "
      25          13 :                                     "1/Kg = (1 - biot_coefficient) * solid_bulk_compliance.");
      26          26 :   params.addClassDescription("Computes the Biot Modulus, which is assumed to be constant for all "
      27          13 :                              "time.  Sometimes 1 / BiotModulus is called storativity");
      28          13 :   return params;
      29             : }
      30             : 
      31          39 : PorousFlowConstantBiotModulus::PorousFlowConstantBiotModulus(const InputParameters & parameters)
      32             :   : PorousFlowMaterialVectorBase(parameters),
      33         117 :     _biot_coefficient(getParam<Real>("biot_coefficient")),
      34         117 :     _fluid_bulk_modulus(getParam<Real>("fluid_bulk_modulus")),
      35         117 :     _solid_bulk_compliance(getParam<Real>("solid_bulk_compliance")),
      36         117 :     _porosity(_nodal_material ? getMaterialProperty<Real>("PorousFlow_porosity_nodal")
      37         117 :                               : getMaterialProperty<Real>("PorousFlow_porosity_qp")),
      38         117 :     _biot_modulus(_nodal_material ? declareProperty<Real>("PorousFlow_constant_biot_modulus_nodal")
      39         117 :                                   : declareProperty<Real>("PorousFlow_constant_biot_modulus_qp")),
      40          39 :     _biot_modulus_old(_nodal_material
      41         117 :                           ? getMaterialPropertyOld<Real>("PorousFlow_constant_biot_modulus_nodal")
      42         351 :                           : getMaterialPropertyOld<Real>("PorousFlow_constant_biot_modulus_qp"))
      43             : {
      44          39 : }
      45             : 
      46             : void
      47       22020 : PorousFlowConstantBiotModulus::initQpStatefulProperties()
      48             : {
      49      110100 :   _biot_modulus[_qp] = 1.0 / ((1.0 - _biot_coefficient) * (_biot_coefficient - _porosity[_qp]) *
      50       44040 :                                   _solid_bulk_compliance +
      51       22020 :                               _porosity[_qp] / _fluid_bulk_modulus);
      52       22020 : }
      53             : 
      54             : void
      55      428956 : PorousFlowConstantBiotModulus::computeQpProperties()
      56             : {
      57     1286868 :   _biot_modulus[_qp] = _biot_modulus_old[_qp];
      58      431455 : }

Generated by: LCOV version 1.11