# sfepy.terms.terms_hyperelastic_tl module

class sfepy.terms.terms_hyperelastic_tl.BulkActiveTLTerm(*args, **kwargs)

  Hyperelastic bulk active term. Stress S_{ij} = A J C_{ij}^{-1}, where A is the activation in [0, F_{\rm max}].

  Definition:

  \int_{\Omega} S_{ij}(\ul{u}) \delta E_{ij}(\ul{u};\ul{v})

  Call signature:

  dw_tl_bulk_active | `(material, virtual, state)`

  Arguments:

    - material : A

    - virtual : \ul{v}

    - state : \ul{u}

  family_data_names = ['det_f', 'sym_inv_c']
  name = 'dw_tl_bulk_active'
  static stress_function(out, mat, det_f, vec_inv_cs)
  static tan_mod_function(out, mat, det_f, vec_inv_cs)

class sfepy.terms.terms_hyperelastic_tl.BulkPenaltyTLTerm(*args, **kwargs)

  Hyperelastic bulk penalty term. Stress S_{ij} = K(J-1)\; J C_{ij}^{-1}.

  Definition:

  \int_{\Omega} S_{ij}(\ul{u}) \delta E_{ij}(\ul{u};\ul{v})

  Call signature:

  dw_tl_bulk_penalty | `(material, virtual, state)`

  Arguments:

    - material : K

    - virtual : \ul{v}

    - state : \ul{u}

  family_data_names = ['det_f', 'sym_inv_c']
  name = 'dw_tl_bulk_penalty'
  static stress_function(out, mat, det_f, vec_inv_cs)
  static tan_mod_function(out, mat, det_f, vec_inv_cs)

class sfepy.terms.terms_hyperelastic_tl.BulkPressureTLTerm(*args, **kwargs)

  Hyperelastic bulk pressure term. Stress S_{ij} = -p J C_{ij}^{-1}.

  Definition:

  \int_{\Omega} S_{ij}(p) \delta E_{ij}(\ul{u};\ul{v})

  Call signature:

  dw_tl_bulk_pressure | `(virtual, state, state_p)`

  Arguments:

    - virtual : \ul{v}

    - state : \ul{u}

    - state_p : p

  arg_geometry_types = {('state_p', None): {'facet_extra': 'facet'}}
  arg_shapes = {'state': 'D', 'state_p': 1, 'virtual': ('D', 'state')}
  arg_types = ('virtual', 'state', 'state_p')
  compute_data(family_data, mode, **kwargs)
  family_data_names = ['det_f', 'sym_inv_c']
  get_eval_shape(virtual, state, state_p, mode=None, term_mode=None, diff_var=None, **kwargs)
  get_fargs(virtual, state, state_p, mode=None, term_mode=None, diff_var=None, **kwargs)
  name = 'dw_tl_bulk_pressure'
  static stress_function(out, pressure_qp, det_f, vec_inv_cs)
  static tan_mod_u_function(out, pressure_qp, det_f, vec_inv_cs)
  static weak_dp_function(out, mtx_f, vec_inv_cs, det_f, cmap_s, cmap_v, transpose, mode)
  static weak_function(out, stress, tan_mod, mtx_f, det_f, cmap, is_diff, mode_ul)

class sfepy.terms.terms_hyperelastic_tl.DiffusionTLTerm(*args, **kwargs)

  Diffusion term in the total Lagrangian formulation with linearized deformation-dependent permeability \ull{K}(\ul{u}) = J \ull{F}^{-1} \ull{k} f(J) \ull{F}^{-T}, where \ul{u} relates to the previous time step (n-1) and f(J) = \max\left(0, \left(1 + \frac{(J - 1)}{N_f}\right)\right)^2 expresses the dependence on volume compression/expansion.

  Definition:

  \int_{\Omega} \ull{K}(\ul{u}^{(n-1)}) : \pdiff{q}{\ul{X}} \pdiff{p}{\ul{X}}

  Call signature:

  dw_tl_diffusion | `(material_1, material_2, virtual, state, parameter)`

  Arguments:

    - material_1 : \ull{k}

    - material_2 : N_f

    - virtual : q

    - state : p

    - parameter : \ul{u}^{(n-1)}

  arg_shapes = {'material_1': 'D, D', 'material_2': '1, 1', 'parameter': 'D', 'state': 1, 'virtual': (1, 'state')}
  arg_types = ('material_1', 'material_2', 'virtual', 'state', 'parameter')
  family_data_names = ['mtx_f', 'det_f']
  static function(out, pressure_grad, mtx_d, ref_porosity, mtx_f, det_f, cmap, mode)
  get_eval_shape(perm, ref_porosity, virtual, state, parameter, mode=None, term_mode=None, diff_var=None, **kwargs)
  get_fargs(perm, ref_porosity, virtual, state, parameter, mode=None, term_mode=None, diff_var=None, **kwargs)
  name = 'dw_tl_diffusion'

class sfepy.terms.terms_hyperelastic_tl.GenYeohTLTerm(*args, **kwargs)

  Hyperelastic generalized Yeoh term [1]. Effective stress S_{ij} = 2 p K (I_1 - 3)^{p-1} J^{-\frac{2}{3}}(\delta{ij} - \frac{1}{3}C_{kk}C{ij}^{-1}).

  Definition:

  \int_{\Omega} S_{ij}(\ul{u}) \delta E_{ij}(\ul{u};\ul{v})

  Call signature:

  dw_tl_he_genyeoh | `(material, virtual, state)`

  Arguments:

    - material : p, K

    - virtual : \ul{v}

    - state : \ul{u}

  [1] Travis W. Hohenberger, Richard J. Windslow, Nicola M. Pugno, James J. C. Busfield. Aconstitutive Model For Both Lowand High Strain Nonlinearities In Highly Filled Elastomers And Implementation With User-Defined Material Subroutines In Abaqus. Rubber Chemistry And Technology, Vol. 92, No. 4, Pp. 653-686 (2019)

  arg_shapes = {'material': '1, 2', 'state': 'D', 'virtual': ('D', 'state')}
  family_data_names = ['det_f', 'tr_c', 'sym_inv_c']
  geometries = ['3_4', '3_8']
  name = 'dw_tl_he_genyeoh'
  stress_function(out, mat, *fargs, **kwargs)
  tan_mod_function(out, mat, *fargs, **kwargs)

class sfepy.terms.terms_hyperelastic_tl.HyperElasticSurfaceTLBase(*args, **kwargs)

  Base class for all hyperelastic surface terms in TL formulation family.

  get_family_data = HyperElasticSurfaceTLFamilyData

class sfepy.terms.terms_hyperelastic_tl.HyperElasticSurfaceTLFamilyData(**kwargs)

  Family data for TL formulation applicable for surface terms.

  cache_name = 'tl_surface_common'
  data_names = ('mtx_f', 'det_f', 'inv_f')
  static family_function(mtx_f, det_f, mtx_fi, state, cmap, fis, conn)

class sfepy.terms.terms_hyperelastic_tl.HyperElasticTLBase(*args, **kwargs)

  Base class for all hyperelastic terms in TL formulation family.

  The subclasses should have the following static method attributes: - stress_function() (the stress) - tan_mod_function() (the tangent modulus)

  The common (family) data are cached in the evaluate cache of state variable.

  get_family_data = HyperElasticTLFamilyData
  hyperelastic_mode = 0
  static weak_function(out, stress, tan_mod, mtx_f, det_f, cmap, is_diff, mode_ul)

class sfepy.terms.terms_hyperelastic_tl.HyperElasticTLFamilyData(**kwargs)

  Family data for TL formulation.

  cache_name = 'tl_common'
  data_names = ('mtx_f', 'det_f', 'sym_c', 'tr_c', 'in2_c', 'sym_inv_c', 'green_strain')
  static family_function(mtx_f, det_f, vec_cs, tr_c, in_2c, vec_inv_cs, vec_es, state, cmap, conn)

class sfepy.terms.terms_hyperelastic_tl.MooneyRivlinTLTerm(*args, **kwargs)

  Hyperelastic Mooney-Rivlin term. Effective stress S_{ij} = \kappa J^{-\frac{4}{3}} (C_{kk} \delta_{ij} - C_{ij} - \frac{2}{3 } I_2 C_{ij}^{-1}).

  Definition:

  \int_{\Omega} S_{ij}(\ul{u}) \delta E_{ij}(\ul{u};\ul{v})

  Call signature:

  dw_tl_he_mooney_rivlin | `(material, virtual, state)`

  Arguments:

    - material : \kappa

    - virtual : \ul{v}

    - state : \ul{u}

  family_data_names = ['det_f', 'tr_c', 'sym_inv_c', 'sym_c', 'in2_c']
  name = 'dw_tl_he_mooney_rivlin'
  static stress_function(out, mat, det_f, tr_c, vec_inv_cs, vec_cs, in_2c)
  static tan_mod_function(out, mat, det_f, tr_c, vec_inv_cs, vec_cs, in_2c)

class sfepy.terms.terms_hyperelastic_tl.NeoHookeanTLTerm(*args, **kwargs)

  Hyperelastic neo-Hookean term. Effective stress S_{ij} = \mu J^{-\frac{2}{3}}(\delta_{ij} - \frac{1}{3}C_{kk}C_{ij}^{-1}).

  Definition:

  \int_{\Omega} S_{ij}(\ul{u}) \delta E_{ij}(\ul{u};\ul{v})

  Call signature:

  dw_tl_he_neohook | `(material, virtual, state)`

  Arguments:

    - material : \mu

    - virtual : \ul{v}

    - state : \ul{u}

  family_data_names = ['det_f', 'tr_c', 'sym_inv_c']
  name = 'dw_tl_he_neohook'
  static stress_function(out, mat, det_f, tr_c, vec_inv_cs)
  static tan_mod_function(out, mat, det_f, tr_c, vec_inv_cs)

class sfepy.terms.terms_hyperelastic_tl.OgdenTLTerm(*args, **kwargs)

  Single term of the hyperelastic Ogden model [1] with the strain energy density

  W = \frac{\mu}{\alpha} \, \left( \lambda_1^{\alpha} + \lambda_2^{\alpha} + \lambda_3^{\alpha} - 3 \right) \; ,

  where \lambda_k, k=1, 2, 3 are the principal stretches, whose squares are the principal values of the right Cauchy-Green deformation tensor \mathbf{C}.

  Effective stress (2nd Piola-Kirchhoff) is [2]

  S_{ij} = 2 \, \frac{\partial W}{\partial C_{ij}} = \sum_{k=1}^3 S^{(k)} \, N^{(k)}_i \, N^{(k)}_j \; ,

  where the principal stresses are

  S^{(k)} = J^{-2/3} \, \left( \mu \, \bar\lambda^{\alpha - 2} -\sum_{j=1}^3 \frac{\mu}{3} \frac{\lambda_j^{\alpha}}{\lambda_k^2} \right) \; , \quad k = 1, 2, 3 \; .

  and \mathbf{N}^{(k)}, k=1, 2, 3 are the eigenvectors of \mathbf{C}.

  Definition:

  \int_{\Omega} S_{ij}(\ul{u}) \delta E_{ij}(\ul{u};\ul{v})

  Call signature:

  dw_tl_he_ogden | `(material, virtual, state)`

  Arguments:

    - material : p, K

    - virtual : \ul{v}

    - state : \ul{u}

  [1] Ogden, R. W. Large deformation isotropic elasticity - on the correlation of theory and experiment for incompressible rubberlike solids. Proceedings of the Royal Society A, Vol. 326, No. 1567, Pp. 565-584 (1972), DOI 10.1098/rspa.1972.0026.

  [2] Steinmann, P., Hossain, M., Possart, G. Hyperelastic models for rubber-like materials: Consistent tangent operators and suitability for Treloar’s data. Archive of Applied Mechanics, Vol. 82, No. 9, Pp. 1183-1217 (2012), DOI 10.1007/s00419-012-0610-z.

  arg_shapes = {'material': '1, 2', 'state': 'D', 'virtual': ('D', 'state')}
  family_data_names = ['det_f', 'sym_c', 'tr_c', 'sym_inv_c']
  geometries = ['3_4', '3_8']
  name = 'dw_tl_he_ogden'
  stress_function(out, mat, *fargs, **kwargs)
  tan_mod_function(out, mat, *fargs, **kwargs)

class sfepy.terms.terms_hyperelastic_tl.SurfaceFluxTLTerm(*args, **kwargs)

  Surface flux term in the total Lagrangian formulation, consistent with `DiffusionTLTerm`.

  Definition:

  \int_{\Gamma} \ul{\nu} \cdot \ull{K}(\ul{u}^{(n-1)}) \pdiff{p}{\ul{X}}

  Call signature:

  ev_tl_surface_flux | `(material_1, material_2, parameter_1, parameter_2)`

  Arguments:

    - material_1 : \ull{k}

    - material_2 : N_f

    - parameter_1 : p

    - parameter_2 : \ul{u}^{(n-1)}

  arg_shapes = {'material_1': 'D, D', 'material_2': '1, 1', 'parameter_1': 1, 'parameter_2': 'D'}
  arg_types = ('material_1', 'material_2', 'parameter_1', 'parameter_2')
  family_data_names = ['det_f', 'inv_f']
  static function(out, pressure_grad, mtx_d, ref_porosity, mtx_fi, det_f, cmap, mode)
  get_eval_shape(perm, ref_porosity, pressure, displacement, mode=None, term_mode=None, diff_var=None, **kwargs)
  get_fargs(perm, ref_porosity, pressure, displacement, mode=None, term_mode=None, diff_var=None, **kwargs)
  integration = 'facet_extra'
  name = 'ev_tl_surface_flux'

class sfepy.terms.terms_hyperelastic_tl.SurfaceTractionTLTerm(*args, **kwargs)

  Surface traction term in the total Lagrangian formulation, expressed using \ul{\nu}, the outward unit normal vector w.r.t. the undeformed surface, \ull{F}(\ul{u}), the deformation gradient, J = \det(\ull{F}), and \ull{\sigma} a given traction, often equal to a given pressure, i.e. \ull{\sigma} = \pi \ull{I}.

  Definition:

  \int_{\Gamma} \ul{\nu} \cdot \ull{F}^{-1} \cdot \ull{\sigma} \cdot \ul{v} J

  Call signature:

  dw_tl_surface_traction | `(opt_material, virtual, state)`

  Arguments:

    - material : \ull{\sigma}

    - virtual : \ul{v}

    - state : \ul{u}

  arg_shapes = [{'opt_material': 'D, D', 'state': 'D', 'virtual': ('D', 'state')}, {'opt_material': None}]
  arg_types = ('opt_material', 'virtual', 'state')
  family_data_names = ['det_f', 'inv_f']
  static function(out, traction, det_f, mtx_fi, bf, cmap, fis, mode)
  get_fargs(mat, virtual, state, mode=None, term_mode=None, diff_var=None, **kwargs)
  integration = 'facet_extra'
  name = 'dw_tl_surface_traction'

class sfepy.terms.terms_hyperelastic_tl.VolumeSurfaceTLTerm(*args, **kwargs)

  Volume of a D-dimensional domain, using a surface integral in the total Lagrangian formulation, expressed using \ul{\nu}, the outward unit normal vector w.r.t. the undeformed surface, \ull{F}(\ul{u}), the deformation gradient, and J = \det(\ull{F}). Uses the approximation of \ul{u} for the deformed surface coordinates \ul{x}.

  Definition:

  1 / D \int_{\Gamma} \ul{\nu} \cdot \ull{F}^{-1} \cdot \ul{x} J

  Call signature:

  ev_tl_volume_surface | `(parameter)`

  Arguments:

    - parameter : \ul{u}

  arg_shapes = {'parameter': 'D'}
  arg_types = ('parameter',)
  family_data_names = ['det_f', 'inv_f']
  static function(out, coors, det_f, mtx_fi, bf, cmap, conn)
  get_eval_shape(parameter, mode=None, term_mode=None, diff_var=None, **kwargs)
  get_fargs(parameter, mode=None, term_mode=None, diff_var=None, **kwargs)
  integration = 'facet_extra'
  name = 'ev_tl_volume_surface'

class sfepy.terms.terms_hyperelastic_tl.VolumeTLTerm(*args, **kwargs)

  Volume term (weak form) in the total Lagrangian formulation.

  Definition:

  \begin{array}{l} \int_{\Omega} q J(\ul{u}) \\ \mbox{volume mode: vector for } K \from \Ical_h: \int_{T_K} J(\ul{u}) \\ \mbox{rel\_volume mode: vector for } K \from \Ical_h: \int_{T_K} J(\ul{u}) / \int_{T_K} 1 \end{array}

  Call signature:

  dw_tl_volume | `(virtual, state)`

  Arguments:

    - virtual : q

    - state : \ul{u}

  arg_geometry_types = {('virtual', None): {'facet_extra': 'facet'}}
  arg_shapes = {'state': 'D', 'virtual': (1, None)}
  arg_types = ('virtual', 'state')
  family_data_names = ['mtx_f', 'det_f', 'sym_inv_c']
  static function(out, mtx_f, vec_inv_cs, det_f, cmap_s, cmap_v, transpose, mode)
  get_eval_shape(virtual, state, mode=None, term_mode=None, diff_var=None, **kwargs)
  get_fargs(virtual, state, mode=None, term_mode=None, diff_var=None, **kwargs)
  name = 'dw_tl_volume'