libMesh
Public Member Functions | Private Attributes | List of all members
LinearElasticityWithContact Class Reference

This class encapsulate all functionality required for assembling and solving a linear elastic model with contact. More...

#include <linear_elasticity_with_contact.h>

Inheritance diagram for LinearElasticityWithContact:
[legend]

Public Member Functions

 LinearElasticityWithContact (NonlinearImplicitSystem &sys_in, Real contact_penalty_in)
 Constructor. More...
 
void set_contact_penalty (Real contact_penalty_in)
 Update the penalty parameter. More...
 
Real get_contact_penalty () const
 Get the penalty parameter. More...
 
Real kronecker_delta (unsigned int i, unsigned int j)
 Kronecker delta function. More...
 
Real elasticity_tensor (Real young_modulus, Real poisson_ratio, unsigned int i, unsigned int j, unsigned int k, unsigned int l)
 Evaluate the fourth order tensor (C_ijkl) that relates stress to strain. More...
 
void move_mesh (MeshBase &input_mesh, const NumericVector< Number > &input_solution)
 Move the mesh nodes of input_mesh based on the displacement field in input_solution. More...
 
void initialize_contact_load_paths ()
 Set up the load paths on the contact surfaces. More...
 
void add_contact_edge_elements ()
 Add edge elements into the mesh based on the contact load paths. More...
 
virtual void residual_and_jacobian (const NumericVector< Number > &soln, NumericVector< Number > *residual, SparseMatrix< Number > *jacobian, NonlinearImplicitSystem &)
 Evaluate the Jacobian of the nonlinear system. More...
 
void compute_stresses ()
 Compute the Cauchy stress for the current solution. More...
 
std::pair< Real, Real > update_lambdas ()
 Update the lambda parameters in the augmented Lagrangian method. More...
 
std::pair< Real, Real > get_least_and_max_gap_function ()
 

Private Attributes

NonlinearImplicitSystem_sys
 Keep a reference to the NonlinearImplicitSystem. More...
 
Real _contact_penalty
 Penalize overlapping elements. More...
 
std::map< dof_id_type, Real > _lambda_plus_penalty_values
 Store the intermediate values of lambda plus penalty. More...
 
std::map< dof_id_type, Real > _lambdas
 Augmented Lagrangian values at each contact node. More...
 
std::map< dof_id_type, dof_id_type > _contact_node_map
 This provides a map between contact nodes. More...
 

Detailed Description

This class encapsulate all functionality required for assembling and solving a linear elastic model with contact.

Definition at line 31 of file linear_elasticity_with_contact.h.

Constructor & Destructor Documentation

◆ LinearElasticityWithContact()

LinearElasticityWithContact::LinearElasticityWithContact ( NonlinearImplicitSystem sys_in,
Real  contact_penalty_in 
)

Constructor.

Member Function Documentation

◆ add_contact_edge_elements()

void LinearElasticityWithContact::add_contact_edge_elements ( )

Add edge elements into the mesh based on the contact load paths.

This ensure proper parallel communication of data, e.g. if a node on one side of the contact surface has a constraint on it, then adding contact elements into the mesh ensures that the constraint will be enforced properly.

◆ compute_stresses()

void LinearElasticityWithContact::compute_stresses ( )

Compute the Cauchy stress for the current solution.

◆ elasticity_tensor()

Real LinearElasticityWithContact::elasticity_tensor ( Real  young_modulus,
Real  poisson_ratio,
unsigned int  i,
unsigned int  j,
unsigned int  k,
unsigned int  l 
)

Evaluate the fourth order tensor (C_ijkl) that relates stress to strain.

◆ get_contact_penalty()

Real LinearElasticityWithContact::get_contact_penalty ( ) const

Get the penalty parameter.

◆ get_least_and_max_gap_function()

std::pair<Real, Real> LinearElasticityWithContact::get_least_and_max_gap_function ( )
Returns
the least and max gap function values for the current solution.

◆ initialize_contact_load_paths()

void LinearElasticityWithContact::initialize_contact_load_paths ( )

Set up the load paths on the contact surfaces.

◆ kronecker_delta()

Real LinearElasticityWithContact::kronecker_delta ( unsigned int  i,
unsigned int  j 
)

Kronecker delta function.

◆ move_mesh()

void LinearElasticityWithContact::move_mesh ( MeshBase input_mesh,
const NumericVector< Number > &  input_solution 
)

Move the mesh nodes of input_mesh based on the displacement field in input_solution.

◆ residual_and_jacobian()

virtual void LinearElasticityWithContact::residual_and_jacobian ( const NumericVector< Number > &  soln,
NumericVector< Number > *  residual,
SparseMatrix< Number > *  jacobian,
NonlinearImplicitSystem  
)
virtual

Evaluate the Jacobian of the nonlinear system.

◆ set_contact_penalty()

void LinearElasticityWithContact::set_contact_penalty ( Real  contact_penalty_in)

Update the penalty parameter.

◆ update_lambdas()

std::pair<Real, Real> LinearElasticityWithContact::update_lambdas ( )

Update the lambda parameters in the augmented Lagrangian method.

Returns
the largest change in the lambdas, and the largest lambda value.

Member Data Documentation

◆ _contact_node_map

std::map<dof_id_type, dof_id_type> LinearElasticityWithContact::_contact_node_map
private

This provides a map between contact nodes.

Definition at line 61 of file linear_elasticity_with_contact.h.

◆ _contact_penalty

Real LinearElasticityWithContact::_contact_penalty
private

Penalize overlapping elements.

Definition at line 44 of file linear_elasticity_with_contact.h.

◆ _lambda_plus_penalty_values

std::map<dof_id_type, Real> LinearElasticityWithContact::_lambda_plus_penalty_values
private

Store the intermediate values of lambda plus penalty.

The dof IDs refer to the nodes on the upper contact surface.

Definition at line 50 of file linear_elasticity_with_contact.h.

◆ _lambdas

std::map<dof_id_type, Real> LinearElasticityWithContact::_lambdas
private

Augmented Lagrangian values at each contact node.

The dof IDs refer to the nodes on the upper contact surface.

Definition at line 56 of file linear_elasticity_with_contact.h.

◆ _sys

NonlinearImplicitSystem& LinearElasticityWithContact::_sys
private

Keep a reference to the NonlinearImplicitSystem.

Definition at line 39 of file linear_elasticity_with_contact.h.


The documentation for this class was generated from the following file: