OOFEM  2.4
OOFEM.org - Object Oriented Finite Element Solver
prescribedmean.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 - 2013 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 #ifndef PRESCRIBEDMEAN_H
35 #define PRESCRIBEDMEAN_H
36 
37 #include <cstdio>
38 #include <cstdlib>
39 #include <algorithm>
40 #include <memory>
41 
42 #include "activebc.h"
43 #include "node.h"
44 #include "boundaryload.h"
45 
46 namespace oofem
47 {
48 
50 
51 #define _IFT_PrescribedMean_Name "prescribedmean"
52 #define _IFT_PrescribedMean_DofID "dofid"
53 #define _IFT_PrescribedMean_Mean "mean"
54 #define _IFT_PrescribedMean_Edge "edge"
55 
57 
58 class OOFEM_EXPORT PrescribedMean : public ActiveBoundaryCondition
59 {
60 private:
61 
63 
64  double c;
65 
66  static double domainSize;
67 
68  int dofid;
69 
70  void computeDomainSize();
71 
73 
77 
78 public:
79  PrescribedMean (int n, Domain * d) : ActiveBoundaryCondition(n, d), lambdaDman( new Node(0, this->domain) ) {}
80 
81  virtual IRResultType initializeFrom(InputRecord *ir);
82 
83  virtual void assemble(SparseMtrx &answer, TimeStep *tStep, CharType type,
84  const UnknownNumberingScheme &r_s, const UnknownNumberingScheme &c_s, double scale = 1.0);
85 
86  virtual void assembleVector(FloatArray &answer, TimeStep *tStep,
87  CharType type, ValueModeType mode,
88  const UnknownNumberingScheme &s, FloatArray *eNorm = NULL);
89 
90  void giveInternalForcesVector(FloatArray &answer, TimeStep *tStep,
91  CharType type, ValueModeType mode,
92  const UnknownNumberingScheme &s, FloatArray *eNorm = NULL);
93 
94  void giveExternalForcesVector(FloatArray &answer, TimeStep *tStep,
95  CharType type, ValueModeType mode,
96  const UnknownNumberingScheme &s);
97 
98  virtual int giveNumberOfInternalDofManagers() {return 1;}
99 
100  virtual DofManager *giveInternalDofManager(int i) {return lambdaDman;}
101 
102  virtual const char *giveClassName() const { return "PrescribedMean"; }
103  virtual const char *giveInputRecordName() const { return _IFT_PrescribedMean_Name; }
104 
105 };
106 
107 }
108 
109 #endif // PRESCRIBEDMEAN_H
#define _IFT_PrescribedMean_Name
Class and object Domain.
Definition: domain.h:115
static double domainSize
Base class for all matrices stored in sparse format.
Definition: sparsemtrx.h:60
ValueModeType
Type representing the mode of UnknownType or CharType, or similar types.
Definition: valuemodetype.h:78
virtual const char * giveInputRecordName() const
Base class for dof managers.
Definition: dofmanager.h:113
Class implementing an array of integers.
Definition: intarray.h:61
virtual int giveNumberOfInternalDofManagers()
Gives the number of internal dof managers.
Abstract base class allowing to control the way, how equations are assigned to individual DOFs...
Abstract base class for all active boundary conditions.
Definition: activebc.h:63
Class representing vector of real numbers.
Definition: floatarray.h:82
virtual DofManager * giveInternalDofManager(int i)
Gives an internal dof manager from receiver.
IRResultType
Type defining the return values of InputRecord reading operations.
Definition: irresulttype.h:47
CharType
Definition: chartype.h:87
virtual const char * giveClassName() const
Class representing the general Input Record.
Definition: inputrecord.h:101
#define new
the oofem namespace is to define a context or scope in which all oofem names are defined.
Class implementing node in finite element mesh.
Definition: node.h:87
PrescribedMean(int n, Domain *d)
Class representing solution step.
Definition: timestep.h:80

This page is part of the OOFEM documentation. Copyright (c) 2011 Borek Patzak
Project e-mail: info@oofem.org
Generated at Tue Jan 2 2018 20:07:30 for OOFEM by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2011