libMesh
Loading...
Searching...
No Matches
newmark_system.h
Go to the documentation of this file.
1// The libMesh Finite Element Library.
2// Copyright (C) 2002-2026 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#ifndef LIBMESH_NEWMARK_SYSTEM_H
21#define LIBMESH_NEWMARK_SYSTEM_H
22
23// Local Includes
24#include "libmesh/linear_implicit_system.h"
25
26// C++ includes
27
28namespace libMesh
29{
30
52{
53public:
54
59 const std::string & name,
60 const unsigned int number);
61
67 NewmarkSystem (const NewmarkSystem &) = delete;
71 virtual ~NewmarkSystem ();
72
77
82 virtual void clear () override;
83
88 virtual void reinit () override;
89
94 virtual void assemble () override;
95
100 virtual std::string system_type () const override { return "Newmark"; }
101
102
103 //---------------------------------------------------------
104 // These members are specific to the Newmark system
105 //
106
110 void initial_conditions ();
111
116 void compute_matrix ();
117
121 void update_rhs ();
122
126 void update_u_v_a ();
127
133 void set_newmark_parameters (const Real delta_T = _default_timestep,
134 const Real alpha = _default_alpha,
135 const Real delta = _default_delta);
136
137private:
138
150
155
159 static const Real _default_alpha;
160
164 static const Real _default_delta;
165
170};
171
172} // namespace libMesh
173
174#endif // LIBMESH_NEWMARK_SYSTEM_H
This is the EquationSystems class.
Manages consistently variables, degrees of freedom, coefficient vectors, matrices and linear solvers ...
This class contains a specific system class.
bool _finished_assemble
true if the matrix assembly is finished.
virtual void assemble() override
Assemble the linear system.
NewmarkSystem sys_type
The type of system.
virtual void reinit() override
Reinitializes the member data fields associated with the system, so that, e.g., assemble() may be use...
void initial_conditions()
Apply initial conditions.
void update_rhs()
Update the rhs.
void compute_matrix()
Compute the global matrix by adding up scaled mass damping and stiffness matrix.
static const Real _default_delta
Default Newmark delta.
Real _a_0
Constants used for the time integration.
void set_newmark_parameters(const Real delta_T=_default_timestep, const Real alpha=_default_alpha, const Real delta=_default_delta)
Set the time step size and the newmark parameter alpha and delta and calculate the constant parameter...
virtual std::string system_type() const override
NewmarkSystem(NewmarkSystem &&)=default
void update_u_v_a()
Update displacement, velocity and acceleration.
NewmarkSystem(const NewmarkSystem &)=delete
Special functions.
static const Real _default_timestep
Default Newmark time step.
NewmarkSystem & operator=(const NewmarkSystem &)=delete
static const Real _default_alpha
Default Newmark alpha.
virtual void clear() override
Clear all the data structures associated with the system.
const std::string & name() const
Definition system.h:2385
unsigned int number() const
Definition system.h:2393
The libMesh namespace provides an interface to certain functionality in the library.
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real