OOFEM 3.0
Loading...
Searching...
No Matches
qtrplanestraingraddamage.C
Go to the documentation of this file.
1/*
2 *
3 * ##### ##### ###### ###### ### ###
4 * ## ## ## ## ## ## ## ### ##
5 * ## ## ## ## #### #### ## # ##
6 * ## ## ## ## ## ## ## ##
7 * ## ## ## ## ## ## ## ##
8 * ##### ##### ## ###### ## ##
9 *
10 *
11 * OOFEM : Object Oriented Finite Element Code
12 *
13 * Copyright (C) 1993 - 2025 Borek Patzak
14 *
15 *
16 *
17 * Czech Technical University, Faculty of Civil Engineering,
18 * Department of Structural Mechanics, 166 29 Prague, Czech Republic
19 *
20 * This library is free software; you can redistribute it and/or
21 * modify it under the terms of the GNU Lesser General Public
22 * License as published by the Free Software Foundation; either
23 * version 2.1 of the License, or (at your option) any later version.
24 *
25 * This program is distributed in the hope that it will be useful,
26 * but WITHOUT ANY WARRANTY; without even the implied warranty of
27 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
28 * Lesser General Public License for more details.
29 *
30 * You should have received a copy of the GNU Lesser General Public
31 * License along with this library; if not, write to the Free Software
32 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
33 */
34
36#include "fei2dtrlin.h"
37#include "node.h"
38#include "gausspoint.h"
40#include "floatmatrix.h"
41#include "intarray.h"
42#include "crosssection.h"
43
44#ifdef __OOFEG
45 #include "oofeggraphiccontext.h"
46#endif
47
48namespace oofem {
49
50FEI2dTrLin QTrPlaneStrainGradDamage :: interpolation_lin(1, 2);
51
52QTrPlaneStrainGradDamage :: QTrPlaneStrainGradDamage(int n, Domain *aDomain) : QTrPlaneStrain(n, aDomain), GradientDamageElement()
53{
54 nPrimNodes = 6;
55 nPrimVars = 2;
56 nSecNodes = 3;
57 nSecVars = 1;
61}
62
63
64void
65QTrPlaneStrainGradDamage :: giveDofManDofIDMask(int inode, IntArray &answer) const
66{
67 if ( inode <= 3 ) {
68 answer = {D_u, D_v, G_0};
69 } else {
70 answer = {D_u, D_v};
71 }
72}
73
74
75
76void
77QTrPlaneStrainGradDamage :: giveDofManDofIDMask_u(IntArray &answer) const
78{
79 answer = {D_u, D_v};
80}
81
82
83void
84QTrPlaneStrainGradDamage :: giveDofManDofIDMask_d(IntArray &answer) const
85{
86 /*
87 if ( inode <= 3 ) {
88 answer = {G_0};
89 } else {
90 answer = {};
91 }
92 */
93}
94
95
96
97
98void
99QTrPlaneStrainGradDamage :: initializeFrom(InputRecord &ir, int priority)
100{
102 QTrPlaneStrain :: initializeFrom(ir, priority);
103}
104
105void
106QTrPlaneStrainGradDamage :: computeGaussPoints()
107{
108 if ( integrationRulesArray.size() == 0 ) {
109 integrationRulesArray.resize( 1 );
110 integrationRulesArray [ 0 ].reset( new GaussIntegrationRule(1, this, 1, 3) );
111 this->giveCrossSection()->setupIntegrationPoints(* integrationRulesArray [ 0 ], numberOfGaussPoints, this);
112 }
113}
114
115void
116QTrPlaneStrainGradDamage :: computeNdMatrixAt(GaussPoint *gp, FloatArray &answer)
117{
118 //FloatArray n;
119 this->interpolation_lin.evalN( answer, gp->giveNaturalCoordinates(), FEIElementGeometryWrapper(this) );
120 //answer.beNMatrixOf(n, 1);
121}
122
123void
124QTrPlaneStrainGradDamage :: computeBdMatrixAt(GaussPoint *gp, FloatMatrix &answer)
125{
126 FloatMatrix dnx;
127 this->interpolation_lin.evaldNdx( dnx, gp->giveNaturalCoordinates(), FEIElementGeometryWrapper(this) );
128 answer.beTranspositionOf(dnx);
129}
130}
std::vector< std ::unique_ptr< IntegrationRule > > integrationRulesArray
Definition element.h:157
int numberOfGaussPoints
Definition element.h:175
CrossSection * giveCrossSection()
Definition element.C:534
void beTranspositionOf(const FloatMatrix &src)
const FloatArray & giveNaturalCoordinates() const
Returns coordinate array of receiver.
Definition gausspoint.h:138
QTrPlaneStrain(int n, Domain *d)

This page is part of the OOFEM-3.0 documentation. Copyright Copyright (C) 1994-2025 Borek Patzak Bořek Patzák
Project e-mail: oofem@fsv.cvut.cz
Generated at for OOFEM by doxygen 1.15.0 written by Dimitri van Heesch, © 1997-2011