OOFEM  2.4
OOFEM.org - Object Oriented Finite Element Solver
matlabexportmodule.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 matlabexportmodule_h_
36 #define matlabexportmodule_h_
37 
38 #include <vector>
39 
40 #include "exportmodule.h"
41 
43 
44 #define _IFT_MatlabExportModule_Name "matlab"
45 #define _IFT_MatlabExportModule_mesh "mesh"
46 #define _IFT_MatlabExportModule_data "data"
47 #define _IFT_MatlabExportModule_DataNodeSet "datanodeset" // dofmanager set from which data should be exported //JF
48 #define _IFT_MatlabExportModule_area "area"
49 #define _IFT_MatlabExportModule_specials "specials"
50 #define _IFT_MatlabExportModule_homogenizeInternalVars "homogenizeivars"
51 #define _IFT_MatlabExportModule_noScaledHomogenization "noscaling"
52 // Reaction forces
53 #define _IFT_MatlabExportModule_ReactionForces "reactionforces"
54 #define _IFT_MatlabExportModule_DofManList "dofmanlist"
55 #define _IFT_MatlabExportModule_ReactionForcesNodeSet "reactionforcesnodeset"
56 // Integration points
57 #define _IFT_MatlabExportModule_IntegrationPoints "integrationpoints"
58 #define _IFT_MatlabExportModule_internalVarsToExport "internalvars"
59 #define _IFT_MatlabExportModule_ElementList "elementlist"
60 #define _IFT_MatlabExportModule_IPFieldsElSet "ipelset"
61 
62 
63 namespace oofem {
71 class OOFEM_EXPORT MatlabExportModule : public ExportModule
72 {
73 protected:
79  std :: string functionname;
80 
81  FILE *giveOutputStream(TimeStep *);
82  std :: vector< double >smax;
83  std :: vector< double >smin;
84 
85  std :: vector< double > partVolume;
86  std :: vector< std :: string > partName;
87 
88  double Area, Volume;
89  int ndim;
90 
91  bool exportMesh;
92  bool exportData;
93  bool exportArea;
98 
102 
103  bool noscaling;
104 
105 private:
106  void computeArea(TimeStep *tStep);
107 
108  // Export reaction forces
109  IntArray reactionForcesDofManList; // Holds which dof managers reaction forces should be exported from.
110  IntArray dataDofManList; // Holds which dof managers data should be exported from.
111 
112 public:
113  MatlabExportModule(int n, EngngModel * e);
114  virtual ~MatlabExportModule();
115  virtual IRResultType initializeFrom(InputRecord *ir);
116  virtual void doOutput(TimeStep *tStep, bool forcedOutput = false);
117  virtual void initialize();
118  virtual void terminate();
119 
120  void doOutputMesh(TimeStep *tStep, FILE *FID);
121  void doOutputData(TimeStep *tStep, FILE *FID);
122  void doOutputSpecials(TimeStep *tStep, FILE *FID);
123  void doOutputReactionForces(TimeStep *tStep, FILE *FID);
124  void doOutputIntegrationPointFields(TimeStep *tStep, FILE *FID);
125  void doOutputHomogenizeDofIDs(TimeStep *tStep, FILE *FID);
126 
127  virtual const char *giveClassName() const { return "MatlabExportModule"; }
128  virtual const char *giveInputRecordName() const { return _IFT_MatlabExportModule_Name; }
129 };
130 } // end namespace oofem
131 #endif // matlabexportmodule_h_
IntArray primaryVarsToExport
list of primary unknowns to export
virtual const char * giveClassName() const
Returns class name of the receiver.
std::vector< double > partVolume
Represents export output module - a base class for all output modules.
Definition: exportmodule.h:71
Class implementing an array of integers.
Definition: intarray.h:61
virtual const char * giveInputRecordName() const
#define _IFT_MatlabExportModule_Name
std::vector< double > smin
IRResultType
Type defining the return values of InputRecord reading operations.
Definition: irresulttype.h:47
Class representing the general Input Record.
Definition: inputrecord.h:101
std::vector< std::string > partName
(Under development) The Matlab export module enables oofem to export the results to a textfile contai...
Abstract base class representing the "problem" under consideration.
Definition: engngm.h:181
IntArray internalVarsToExport
list of InternalStateType values, identifying the selected vars for export
the oofem namespace is to define a context or scope in which all oofem names are defined.
std::vector< double > smax
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:29 for OOFEM by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2011