OOFEM 3.0
Loading...
Searching...
No Matches
linearconstraintbc.h
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
35#ifndef linearconstraintbc_h
36#define linearconstraintbc_h
37
38#include "activebc.h"
39#include "floatarray.h"
40#include "intarray.h"
41#include "chartype.h"
42#include "valuemodetype.h"
43#include "dofmanager.h"
44#include "error.h"
45
46#include <memory>
47
48#define _IFT_LinearConstraintBC_Name "linearconstraintbc"
49
51
52#define _IFT_LinearConstraintBC_weights "weights"
53#define _IFT_LinearConstraintBC_weightsfuncs "weightsltf"
54#define _IFT_LinearConstraintBC_rhs "rhs"
55#define _IFT_LinearConstraintBC_rhsfuncs "rhsltf"
56#define _IFT_LinearConstraintBC_dofmans "dofmans"
57#define _IFT_LinearConstraintBC_dofs "dofs"
58#define _IFT_LinearConstraintBC_lhstype "lhstype"
59#define _IFT_LinearConstraintBC_rhstype "rhstype"
60
62
63namespace oofem {
75{
76protected:
79 double rhs;
80 int rhsTf;
83 std :: unique_ptr< DofManager > md;
84
85
86 // characteristicType of LHS and RHS contributions (this makes this bc trully general, as one can customize, to which
87 // characteristic component the contibution will be assembled)
90
91public:
92 LinearConstraintBC(int n, Domain * d);
94 virtual ~LinearConstraintBC();
95
96 void initializeFrom(InputRecord &ir) override;
97 const char *giveInputRecordName() const override { return _IFT_LinearConstraintBC_Name; }
98 void assemble(SparseMtrx &answer, TimeStep *tStep,
99 CharType type, const UnknownNumberingScheme &r_s,
100 const UnknownNumberingScheme &c_s, double scale = 1.0,
101 void* lock=nullptr) override;
102 void assembleVector(FloatArray &answer, TimeStep *tStep,
103 CharType type, ValueModeType mode,
104 const UnknownNumberingScheme &s, FloatArray *eNorms=nullptr,
105 void*lock=nullptr) override;
106
107 void giveLocationArrays(std :: vector< IntArray > &rows, std :: vector< IntArray > &cols,
108 CharType type, const UnknownNumberingScheme &r_s,
109 const UnknownNumberingScheme &c_s) override;
110
111 int giveNumberOfInternalDofManagers() override { return 1; }
112 DofManager *giveInternalDofManager(int i) override { return this->md.get(); }
113
114 void saveContext(DataStream &stream, ContextMode mode) override;
115 void restoreContext(DataStream &stream, ContextMode mode) override;
116
117 const char *giveClassName() const override { return "LinearConstraintBC"; }
118
119protected:
120 void giveLocArray(const UnknownNumberingScheme &r_s, IntArray &locr, int &lambdaeq);
121};
122} //end of oofem namespace
123#endif // LinearConstraintBC_h
ActiveBoundaryCondition(int n, Domain *d)
Definition activebc.h:71
DofManager * giveInternalDofManager(int i) override
Gives an internal dof manager from receiver.
int giveNumberOfInternalDofManagers() override
Gives the number of internal dof managers.
std ::unique_ptr< DofManager > md
const char * giveInputRecordName() const override
void initializeFrom(InputRecord &ir) override
const char * giveClassName() const override
LinearConstraintBC(int n, Domain *d)
#define _IFT_LinearConstraintBC_Name
long ContextMode
Definition contextmode.h:43
FloatArrayF< N > assemble(const FloatArrayF< M > &x, int const (&c)[M])
Assemble components into zero matrix.
#define OOFEM_EXPORT
Definition oofemcfg.h:7

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