I need to update the developer section in the manual to discuss the revised implementation. I will put this high on my TODO list.
In the meantime, here is the short explanation without figures. In implementing the governing equations, the material is associated with the governing equation and the rheology is associated with the bulk constitutive model. We now have a few governing equation cases: elasticity (
pylith::materials::Elasticity), incompressible elasticity (
pylith::materials::IncompressibleElasticity), and poroelasticity (
pylith::materials::Poroelasticity). For each of these three governing equation cases (“materials”), we have various rheologies. For example, in the case of elasticity, the rheologies (linear elasticity, Maxwell viscoelastic, generalize Maxwell viscoelastic, and Drucker Prager elastoplastic) are responsible for supplying the kernels for computing the stress tensor. In order to do this, they need constitutive parameters and (optionally) state variables, which we include in the auxiliary field (e.g., shear modulus, bulk modulus).
RheologyElasticity is the abstract base class that defines the interface that all rheologies for
Elasticity must use. Likewise,
RheologyPoroelasticity is the abstract base class that defines the interface that the rheologies for
Poroelasticity must use.
What is the role of the file
RheologyIncompressibleElasticity.cc in the materials folder and how is it connected with
IncompressibleElasticity in the kernels folder and the ones in the materials folder as well ?
RheologyIncompressibleElasticity is the abstract base class.
IsotropicLinearIncompElasticity is a specific implementation of
RheologyIncompressibleElasticity (this if often denoted as
The files in the kernels directory contain the kernels and any functions used in the kernels. These are all C++ classes with static data members.
How does the variable
_rheology in the
IncompressibleElasticity in the materials is related to the
RheologyIncompressibleElasticity.cc in the materials folder?
IncompressibleElasticity::_rheology holds a pointer the incompressible rheology. The pointer is of type
RheologyIncompressibleElasticity, which is the abstract base class.
IncompressibleElasticity doesn’t know anything about the specific implementation of the rheology. All it knows is that the rheology conforms to the interface defined by the abstract base class.
Similarly, why do we need to specify the files
These define the rheology interface for poroelasticity and elasticity, respectively. As you can see, the differences in the governing equations leads to slightly different forms for the kernels, so the interfaces to the rheologies are different.