OOFEM 3.0
Loading...
Searching...
No Matches
structuralfe2material.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 structuralfe2material_h
36#define structuralfe2material_h
37
40
41#include <memory>
42
44
45#define _IFT_StructuralFE2Material_Name "structfe2material"
46#define _IFT_StructuralFE2Material_fileName "filename"
47#define _IFT_StructuralFE2Material_useNumericalTangent "use_num_tangent"
49
50namespace oofem {
51class EngngModel;
52class PrescribedGradientHomogenization;
53
55{
56protected:
58 std :: unique_ptr< EngngModel > rve;
61
63 bool oldTangent = true;
64
67
68 std :: string mInputFile;
69
70public:
71 StructuralFE2MaterialStatus(int rank, GaussPoint * g, const std :: string & inputfile);
72
73 EngngModel *giveRVE() const { return this->rve.get(); }
74 PrescribedGradientHomogenization *giveBC();// { return this->bc; }
75
76 void markOldTangent();
77 void computeTangent(TimeStep *tStep);
78
80 bool createRVE(int n, const std :: string &inputfile, int rank);
81
83 void setTimeStep(TimeStep *tStep);
84
86
87 const char *giveClassName() const override { return "StructuralFE2MaterialStatus"; }
88
89 void initTempStatus() override;
90
91 void updateYourself(TimeStep *tStep) override;
92
93 void saveContext(DataStream &stream, ContextMode mode) override;
94 void restoreContext(DataStream &stream, ContextMode mode) override;
95
96 const FloatArray &giveNormal() const { return mNormalDir; }
97 void letNormalBe(FloatArray iN) { mNormalDir = std :: move(iN); }
98
99 double giveRveLength();
100
102 void copyStateVariables(const MaterialStatus &iStatus) override;
103 void addStateVariables(const MaterialStatus &iStatus) override { OOFEM_ERROR("Not implemented."); }
104
105 // For debugging only
106 bool mNewlyInitialized = true;
107};
108
109
121{
122protected:
123 std :: string inputfile;
124 static int n;
125 bool useNumTangent = false;
126
127public:
129
130 void initializeFrom(InputRecord &ir) override;
131 void giveInputRecord(DynamicInputRecord &input) override;
132 const char *giveInputRecordName() const override { return _IFT_StructuralFE2Material_Name; }
133 const char *giveClassName() const override { return "StructuralFE2Material"; }
134 bool isCharacteristicMtrxSymmetric(MatResponseMode rMode) const override { return true; }
135
136 std::unique_ptr<MaterialStatus> CreateStatus(GaussPoint *gp) const override;
137 FloatArrayF<6> giveRealStressVector_3d(const FloatArrayF<6> &strain, GaussPoint *gp, TimeStep *tStep) const override;
139 FloatMatrixF<6,6> give3dMaterialStiffnessMatrix(MatResponseMode mode, GaussPoint *gp, TimeStep *tStep) const override;
140 FloatMatrixF<4,4> givePlaneStrainStiffMtrx(MatResponseMode mode, GaussPoint *gp, TimeStep *tStep) const override;
141 FloatMatrixF<3,3> givePlaneStressStiffMtrx(MatResponseMode mmode, GaussPoint *gp, TimeStep *tStep) const override;
142};
143
144} // end namespace oofem
145#endif // structuralfe2material_h
const char * giveClassName() const override
PrescribedGradientHomogenization * giveBC()
void setTimeStep(TimeStep *tStep)
Copies time step data to RVE.
StructuralFE2MaterialStatus(int rank, GaussPoint *g, const std ::string &inputfile)
bool createRVE(int n, const std ::string &inputfile, int rank)
Creates/Initiates the RVE problem.
FloatArray mNormalDir
Interface normal direction.
void addStateVariables(const MaterialStatus &iStatus) override
void saveContext(DataStream &stream, ContextMode mode) override
const FloatArray & giveNormal() const
void copyStateVariables(const MaterialStatus &iStatus) override
Functions for MaterialStatusMapperInterface.
void restoreContext(DataStream &stream, ContextMode mode) override
void updateYourself(TimeStep *tStep) override
PrescribedGradientHomogenization * bc
Boundary condition in RVE that performs the computational homogenization.
std ::unique_ptr< EngngModel > rve
The RVE.
void giveInputRecord(DynamicInputRecord &input) override
const char * giveInputRecordName() const override
FloatMatrixF< 4, 4 > givePlaneStrainStiffMtrx(MatResponseMode mode, GaussPoint *gp, TimeStep *tStep) const override
void initializeFrom(InputRecord &ir) override
const char * giveClassName() const override
FloatArrayF< 6 > giveRealStressVector_3d(const FloatArrayF< 6 > &strain, GaussPoint *gp, TimeStep *tStep) const override
Default implementation relies on giveRealStressVector for second Piola-Kirchoff stress.
FloatMatrixF< 6, 6 > give3dMaterialStiffnessMatrix(MatResponseMode mode, GaussPoint *gp, TimeStep *tStep) const override
std::unique_ptr< MaterialStatus > CreateStatus(GaussPoint *gp) const override
bool isCharacteristicMtrxSymmetric(MatResponseMode rMode) const override
FloatMatrixF< 3, 3 > givePlaneStressStiffMtrx(MatResponseMode mmode, GaussPoint *gp, TimeStep *tStep) const override
FloatArrayF< 3 > giveRealStressVector_PlaneStress(const FloatArrayF< 3 > &strain, GaussPoint *gp, TimeStep *tStep) const override
Default implementation relies on giveRealStressVector_StressControl.
StructuralMaterialStatus(GaussPoint *g)
Constructor. Creates new StructuralMaterialStatus with IntegrationPoint g.
StructuralMaterial(int n, Domain *d)
#define OOFEM_ERROR(...)
Definition error.h:79
long ContextMode
Definition contextmode.h:43
#define _IFT_StructuralFE2Material_Name

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