OOFEM 3.0
Loading...
Searching...
No Matches
simpleslavedof.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 simpleslavedof_h
36#define simpleslavedof_h
37
38#include "dof.h"
39#include "error.h"
40
41namespace oofem {
42class Domain;
43class DofManager;
44class TimeStep;
47
71{
72private:
76 mutable int masterDofIndx;
77
78public:
87 SimpleSlaveDof(DofManager * aNode, int master, DofIDItem id);
88 SimpleSlaveDof(DofManager * aNode, DofIDItem id = Undef);
90 virtual ~SimpleSlaveDof() { }
91
92 dofType giveDofType() override { return DT_simpleSlave; }
93 const char *giveClassName() const override { return "SimpleSlaveDof"; }
99 int __giveEquationNumber() const override;
105 int __givePrescribedEquationNumber() override;
109 int askNewEquationNumber(TimeStep *tStep) override { return 1; }
110 double giveUnknown(ValueModeType, TimeStep *) override;
111 double giveUnknown(PrimaryField &field, ValueModeType, TimeStep *tStep) override;
112 bool hasBc(TimeStep *tStep) override;
113 bool hasIc() override;
114 bool hasIcOn(ValueModeType) override;
115 int giveBcId() override;
116 int giveIcId() override;
117 double giveBcValue(ValueModeType mode, TimeStep *tStep) override;
118
119 void saveContext(DataStream &stream, ContextMode mode) override;
120 void restoreContext(DataStream &stream, ContextMode mode) override;
121
124 void giveMasterDofManArray(IntArray &answer) override {
125 answer.resize(1);
126 answer.at(1) = masterDofMngr;
127 }
128
131 int giveMasterDofIndx() const { return masterDofIndx; }
132
133 void updateLocalNumbering(EntityRenumberingFunctor &f) override;
134
135private:
137 Dof *giveMasterDof() const;
138
139protected:
140 BoundaryCondition *giveBc() override;
141 InitialCondition *giveIc() override;
142};
143} // end namespace oofem
144#endif // simpleslavedof_h
Dof(DofManager *aNode, DofIDItem id=Undef)
Definition dof.C:50
void resize(int n)
Definition intarray.C:73
int & at(std::size_t i)
Definition intarray.h:104
int giveMasterDofIndx() const
Returns number of master dof in master dofManager.
dofType giveDofType() override
Returns the type of the receiver.
int masterDofMngr
Number of DofManager containing master dof (Master DofManager).
SimpleSlaveDof(DofManager *aNode, int master, DofIDItem id)
int askNewEquationNumber(TimeStep *tStep) override
void setMasterDofManagerNum(int i)
Sets master dof manager.
virtual ~SimpleSlaveDof()
Destructor.
void giveMasterDofManArray(IntArray &answer) override
int masterDofIndx
Number of master dof in master dofManager.
const char * giveClassName() const override
Returns class name of the receiver.
int giveMasterDofManagerNum() const
Returns Master Dof Manager Number.
long ContextMode
Definition contextmode.h:43
dofType
Dof Type, determines the type of DOF created.
Definition doftype.h:48
#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