Skip to content

Porosity

Manolis Veveakis edited this page Mar 30, 2015 · 9 revisions

Breaking down the code in several materials (for mechanics and the rest for example) creates an issue with the treatment of porosity. The total porosity is the sum of the initial, mechanical and chemical components, where the chemical and mechanical components are computed in different materials, but those materials each use the total porosity, hence the dependency headache...

There are at least 3 ways of solving this problem:

  1. Add porosity as a variable and solve for it. This is the only proper way, but it might be costly so let's try to avoid it for now if possible... (Let see)

  2. Let MOOSE do its magic and see if it converges. (This can be done by using the code below and computing the mechanical porosity at residuals. It works but takes ages...)

  3. Let's give MOOSE a bit of help and solve for the mechanical porosity component in an explicit manner since it's quite small.

We've chosen the last approach (for now). In practise this means that one needs to create some AuxVariables for the total and mechanical porosity. (The chemical one is computed as a material property.)

[./total_porosity]
  order = FIRST
  family = MONOMIAL
[../]
[./mech_porosity]
  order = FIRST
  family = MONOMIAL
[../]

Those AuxVariables are then computed in AuxKernels. Note that in this example the mechanical_porosity is only computed at the end of the tilmestep (explicit). The user can opt for the fully implicit method, in which case the mechanical_porosity needs to be solved at residual/linear/nonlinear. The total_porosity needs to be told where to find the mechanical_porosity, but will find the chemical one directly as a material property.

[./total_porosity]
  type = RedbackTotalPorosityAux
  variable = total_porosity
  mechanical_porosity = mech_porosity
[../]
[./mech_porosity]
  type = MaterialRealAux
  variable = mech_porosity
  execute_on = timestep_end
  property = mechanical_porosity
[../]

The materials then need to be told where to find the total_porosity:

[Materials]
  [./mat_mech]
    type = RedbackMechMaterialJ2
    ...
    total_porosity = total_porosity
  [../]
  [./mat_nomech]
    type = RedbackMaterial
    ...
    total_porosity = total_porosity
  [../]
[]