libMesh
examples
fem_system
fem_system_ex2
solid_system.h
Go to the documentation of this file.
1
// The libMesh Finite Element Library.
2
// Copyright (C) 2002-2025 Benjamin S. Kirk, John W. Peterson, Roy H. Stogner
3
4
// This library is free software; you can redistribute it and/or
5
// modify it under the terms of the GNU Lesser General Public
6
// License as published by the Free Software Foundation; either
7
// version 2.1 of the License, or (at your option) any later version.
8
9
// This library is distributed in the hope that it will be useful,
10
// but WITHOUT ANY WARRANTY; without even the implied warranty of
11
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12
// Lesser General Public License for more details.
13
14
// You should have received a copy of the GNU Lesser General Public
15
// License along with this library; if not, write to the Free Software
16
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17
18
19
20
// \author Robert Weidlich
21
// \date Copyright 2012
22
23
#ifndef SOLID_SYSTEM_H_
24
#define SOLID_SYSTEM_H_
25
26
#include "libmesh/fem_system.h"
27
28
using namespace
libMesh
;
29
30
class
SolidSystem
:
public
FEMSystem
31
{
32
public
:
33
// Constructor
34
SolidSystem
(
EquationSystems
& es,
35
const
std::string &
name
,
36
const
unsigned
int
number);
37
38
// System initialization
39
virtual
void
init_data();
40
41
// Context initialization
42
virtual
void
init_context(
DiffContext
& context);
43
44
// Element residual and jacobian calculations
45
virtual
bool
element_time_derivative(
bool
request_jacobian,
46
DiffContext
& context);
47
48
// Contributions for adding boundary conditions
49
virtual
bool
side_time_derivative(
bool
request_jacobian,
50
DiffContext
& context);
51
52
virtual
bool
eulerian_residual
(
bool
,
DiffContext
&)
53
{
54
return
false
;
55
}
56
57
// Simulation parameters
58
GetPot
args
;
59
60
// Custom Identifier
61
virtual
std::string
system_type
()
const
62
{
63
return
"Solid"
;
64
}
65
66
// override method to update mesh also
67
virtual
void
update();
68
69
// save the undeformed mesh to an auxiliary system
70
void
save_initial_mesh();
71
72
// variable numbers of primary variables in the current system
73
unsigned
int
var[3];
74
75
// variable numbers of primary variables in auxiliary system (for accessing the
76
// undeformed configuration)
77
unsigned
int
undefo_var[3];
78
};
79
80
#endif
/* SOLID_SYSTEM_H_ */
libMesh::Quality::name
std::string name(const ElemQuality q)
This function returns a string containing some name for q.
Definition:
elem_quality.C:42
SolidSystem
Definition:
solid_system.h:30
libMesh::EquationSystems
This is the EquationSystems class.
Definition:
equation_systems.h:68
libMesh::DiffContext
This class provides all data required for a physics package (e.g.
Definition:
diff_context.h:55
libMesh
The libMesh namespace provides an interface to certain functionality in the library.
libMesh::FEMSystem
This class provides a specific system class.
Definition:
fem_system.h:53
SolidSystem::args
GetPot args
Definition:
solid_system.h:58
SolidSystem::system_type
virtual std::string system_type() const
Definition:
solid_system.h:61
SolidSystem::eulerian_residual
virtual bool eulerian_residual(bool, DiffContext &)
Adds a pseudo-convection contribution on elem to elem_residual, if the nodes of elem are being transl...
Definition:
solid_system.h:52
Generated on Fri Jul 18 2025 13:27:25 for libMesh by
1.8.14