OOFEM  2.4
OOFEM.org - Object Oriented Finite Element Solver
twofluidmaterial.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 
35 #ifndef twofluidmaterial_h
36 #define twofluidmaterial_h
37 
38 #include "fluiddynamicmaterial.h"
39 #include "intarray.h"
40 #include "matstatus.h"
41 
42 #include <memory>
43 
45 
46 #define _IFT_TwoFluidMaterial_Name "twofluidmat"
47 #define _IFT_TwoFluidMaterial_mat "mat"
48 
49 
50 namespace oofem {
51 class GaussPoint;
52 
58 {
59 protected:
61 
62 public:
70  virtual ~TwoFluidMaterial() { }
71 
73  virtual void giveInputRecord(DynamicInputRecord &input);
74 
75  virtual void computeDeviatoricStressVector(FloatArray &answer, GaussPoint *gp, const FloatArray &eps, TimeStep *tStep);
76  virtual void giveDeviatoricStiffnessMatrix(FloatMatrix &answer, MatResponseMode mode, GaussPoint *gp, TimeStep *tStep);
77 
78  virtual double giveEffectiveViscosity(GaussPoint *gp, TimeStep *tStep);
79  virtual double give(int aProperty, GaussPoint *gp);
80  virtual int giveIPValue(FloatArray &answer, GaussPoint *gp, InternalStateType type, TimeStep *tStep);
81  virtual const char *giveClassName() const { return "TwoFluidMaterial"; }
82  virtual const char *giveInputRecordName() const { return _IFT_TwoFluidMaterial_Name; }
83  virtual int checkConsistency();
84  virtual MaterialStatus *CreateStatus(GaussPoint *gp) const;
85 
86 protected:
87  FluidDynamicMaterial *giveMaterial(int i) const;
88  double giveTempVOF(GaussPoint *gp);
89 };
90 
91 
93 {
94 protected:
95  std :: unique_ptr< GaussPoint >slaveGp0;
96  std :: unique_ptr< GaussPoint >slaveGp1;
97 
98 public:
103 
104  virtual void printOutputAt(FILE *file, TimeStep *tStep);
105 
106  virtual void initTempStatus();
107  virtual void updateYourself(TimeStep *tStep);
108 
109  virtual contextIOResultType saveContext(DataStream &stream, ContextMode mode, void *obj = NULL);
110  virtual contextIOResultType restoreContext(DataStream &stream, ContextMode mode, void *obj = NULL);
111  virtual const char *giveClassName() const { return "TwoFluidMaterialStatus"; }
112 
113  GaussPoint *giveSlaveGaussPoint0() { return this->slaveGp0.get(); }
114  GaussPoint *giveSlaveGaussPoint1() { return this->slaveGp1.get(); }
115 };
116 } // end namespace oofem
117 #endif // twofluidmaterial_h
InternalStateType
Type representing the physical meaning of element or constitutive model internal variable.
virtual MaterialStatus * CreateStatus(GaussPoint *gp) const
Creates new copy of associated status and inserts it into given integration point.
Class and object Domain.
Definition: domain.h:115
Abstract base class for all fluid materials.
virtual void computeDeviatoricStressVector(FloatArray &answer, GaussPoint *gp, const FloatArray &eps, TimeStep *tStep)
Computes the deviatoric stress vector from given strain.
The purpose of DataStream abstract class is to allow to store/restore context to different streams...
Definition: datastream.h:54
std::unique_ptr< GaussPoint > slaveGp1
virtual contextIOResultType saveContext(DataStream &stream, ContextMode mode, void *obj=NULL)
Stores receiver state to output stream.
Definition: femcmpnn.C:51
Class implementing an array of integers.
Definition: intarray.h:61
MatResponseMode
Describes the character of characteristic material matrix.
virtual double giveEffectiveViscosity(GaussPoint *gp, TimeStep *tStep)
Gives the effective viscosity for the given integration point.
double giveTempVOF(GaussPoint *gp)
Material coupling the behavior of two particular materials based on rule of mixture.
FluidDynamicMaterial * giveMaterial(int i) const
This class implements a transport material status information.
virtual ~TwoFluidMaterialStatus()
Destructor.
virtual int giveIPValue(FloatArray &answer, GaussPoint *gp, InternalStateType type, TimeStep *tStep)
Returns the integration point corresponding value in Reduced form.
std::unique_ptr< GaussPoint > slaveGp0
Abstract base class representing a material status information.
Definition: matstatus.h:84
virtual const char * giveInputRecordName() const
Class representing vector of real numbers.
Definition: floatarray.h:82
Implementation of matrix containing floating point numbers.
Definition: floatmatrix.h:94
IRResultType
Type defining the return values of InputRecord reading operations.
Definition: irresulttype.h:47
virtual double give(int aProperty, GaussPoint *gp)
Returns the value of material property &#39;aProperty&#39;.
virtual void giveInputRecord(DynamicInputRecord &input)
Setups the input record string of receiver.
virtual void giveDeviatoricStiffnessMatrix(FloatMatrix &answer, MatResponseMode mode, GaussPoint *gp, TimeStep *tStep)
Computes the deviatoric stiffness; .
TwoFluidMaterial(int n, Domain *d)
Constructor.
Class representing the general Input Record.
Definition: inputrecord.h:101
#define _IFT_TwoFluidMaterial_Name
virtual void printOutputAt(FILE *file, TimeStep *tStep)
Prints output of receiver to stream, for given time step.
Definition: femcmpnn.h:171
Class representing the a dynamic Input Record.
long ContextMode
Context mode (mask), defining the type of information written/read to/from context.
Definition: contextmode.h:43
virtual contextIOResultType restoreContext(DataStream &stream, ContextMode mode, void *obj=NULL)
Restores the receiver state previously written in stream.
Definition: femcmpnn.C:64
virtual int checkConsistency()
Allows programmer to test some internal data, before computation begins.
virtual const char * giveClassName() const
the oofem namespace is to define a context or scope in which all oofem names are defined.
virtual void initTempStatus(GaussPoint *gp)
Initializes temporary variables stored in integration point status at the beginning of new time step...
Definition: material.C:267
virtual const char * giveClassName() const
virtual ~TwoFluidMaterial()
Destructor.
Class representing integration point in finite element program.
Definition: gausspoint.h:93
Class representing solution step.
Definition: timestep.h:80
virtual IRResultType initializeFrom(InputRecord *ir)
Initializes receiver according to object description stored in input record.

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:32 for OOFEM by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2011