Plugins
mat_law_interface_impl.h
Go to the documentation of this file.
1
/*
2
* Copyright (c) 2014-2015: G-CSC, Goethe University Frankfurt
3
* Author: Raphael Prohl
4
*
5
* This file is part of UG4.
6
*
7
* UG4 is free software: you can redistribute it and/or modify it under the
8
* terms of the GNU Lesser General Public License version 3 (as published by the
9
* Free Software Foundation) with the following additional attribution
10
* requirements (according to LGPL/GPL v3 §7):
11
*
12
* (1) The following notice must be displayed in the Appropriate Legal Notices
13
* of covered and combined works: "Based on UG4 (www.ug4.org/license)".
14
*
15
* (2) The following notice must be displayed at a prominent place in the
16
* terminal output of covered works: "Based on UG4 (www.ug4.org/license)".
17
*
18
* (3) The following bibliography is recommended for citation and must be
19
* preserved in all covered files:
20
* "Reiter, S., Vogel, A., Heppner, I., Rupp, M., and Wittum, G. A massively
21
* parallel geometric multigrid solver on hierarchically distributed grids.
22
* Computing and visualization in science 16, 4 (2013), 151-164"
23
* "Vogel, A., Reiter, S., Rupp, M., Nägel, A., and Wittum, G. UG4 -- a novel
24
* flexible software system for simulating pde based models on high performance
25
* computers. Computing and visualization in science 16, 4 (2013), 165-179"
26
*
27
* This program is distributed in the hope that it will be useful,
28
* but WITHOUT ANY WARRANTY; without even the implied warranty of
29
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30
* GNU Lesser General Public License for more details.
31
*/
32
33
#ifndef MAT_LAW_INTERFACE_IMPL_H_
34
#define MAT_LAW_INTERFACE_IMPL_H_
35
36
#include "
mat_law_interface.h
"
37
38
namespace
ug
{
39
namespace
SmallStrainMechanics{
40
41
template
<
typename
TDomain>
42
template
<
typename
TFEGeom>
43
void
44
IMaterialLaw<TDomain>::
45
DisplacementGradient
(
MathMatrix<dim, dim>
& GradU,
const
size_t
ip,
46
const
TFEGeom& geo,
const
LocalVector
& u)
47
{
48
// loop shape-functions at one integration point ip in order
49
// to compute local_grad(ip,i): \frac{\partial N_i}{\eps_ip}
50
// and global_grad(ip,i): \frac{\partial N_i}{\X_ip}
51
52
for
(
size_t
i = 0; i < (size_t)
dim
; ++i)
53
for
(
size_t
J = 0; J < (size_t)
dim
; ++J)
54
{
55
GradU[i][J] = 0.0;
56
57
// compute GradU: displacementGradient
58
for
(
size_t
a = 0; a < geo.num_sh(); ++a)
59
GradU[i][J] += geo.global_grad(ip, a)[J] * u(i, a);
60
}
61
}
62
63
}
// end of namespace SmallStrainMechanics
64
}
// end of namespace ug
65
66
#endif
/* MAT_LAW_INTERFACE_IMPL_H_ */
ug::LocalVector
MathMatrix< dim, dim >
ug::SmallStrainMechanics::IMaterialLaw::DisplacementGradient
void DisplacementGradient(MathMatrix< dim, dim > &GradU, const size_t ip, const TFEGeom &geo, const LocalVector &u)
Definition:
mat_law_interface_impl.h:45
dim
static const int dim
mat_law_interface.h
ug
plugins
SmallStrainMechanics
material_laws
mat_law_interface_impl.h
Generated on Mon Dec 23 2024 01:11:25 for Plugins by
1.9.1