Finite Element Domain Decomposition Library
FEDDLib
Loading...
Searching...
No Matches
ExporterParaViewAMR_decl.hpp
1#ifndef ExporterParaViewAMR_decl_hpp
2#define ExporterParaViewAMR_decl_hpp
3
4#include <fstream>
5#include "feddlib/core/FEDDCore.hpp"
6#include "feddlib/core/General/DefaultTypeDefs.hpp"
7#include "feddlib/core/LinearAlgebra/MultiVector.hpp"
8#include "feddlib/core/Mesh/Mesh.hpp"
9#include "feddlib/core/General/ExporterParaView.hpp"
10#include "feddlib/amr/ExporterParaViewAMR.hpp"
11// Trilinos
12#include <Teuchos_Array.hpp>
13
14#include <Epetra_ConfigDefs.h>
15#ifdef HAVE_MPI
16#include <mpi.h>
17#include <Epetra_MpiComm.h>
18#include <Epetra_SerialComm.h>
19#else
20#include <Epetra_SerialComm.h>
21#endif
22
23#include <Epetra_Map.h>
24#include <Epetra_MultiVector.h>
25#include <Epetra_Vector.h>
26#include <Epetra_LongLongVector.h>
27#include <Epetra_IntVector.h>
28
29#include <EpetraExt_HDF5.h>
30#include <hdf5.h>
31
40
41namespace FEDD {
42template <class SC = default_sc, class LO = default_lo, class GO = default_go, class NO = default_no>
43class ExporterParaViewAMR : public ExporterParaView<SC,LO,GO,NO> {
44public:
45 typedef std::vector<double> vec_dbl;
46 typedef std::vector<std::vector<double> > vec2D_dbl;
47 typedef std::vector<std::vector<int> > vec2D_int;
48 typedef std::vector<std::vector<long long> > vec2D_longlong;
49 typedef Teuchos::RCP<std::vector<int> > vec_int_ptr;
50 typedef Teuchos::RCP<std::vector<long long> > vec_longlong_ptr;
51 typedef Teuchos::RCP<vec_dbl> vec_dbl_ptr;
52 typedef Teuchos::RCP<std::vector<std::vector<double> > > vec2D_dbl_ptr;
53 typedef Teuchos::RCP<std::vector<std::vector<int> > > vec2D_int_ptr;
54 typedef Teuchos::RCP<vec2D_longlong > vec2D_longlong_ptr;
55 typedef Teuchos::RCP<Epetra_Vector> EpetraVec_ptr;
56 typedef Teuchos::RCP<Epetra_MpiComm> EpetraComm_ptr;
57 typedef Teuchos::RCP<Epetra_IntVector> EpetraVecInt_ptr;
58 typedef Teuchos::RCP<Epetra_LongLongVector> EpetraVecLongLong_ptr;
59 typedef Teuchos::RCP<Epetra_MultiVector> EpetraMVPtr_Type;
60 typedef Teuchos::RCP<Epetra_Map> EpetraMapPtr_Type;
61
62
63 typedef EpetraExt::HDF5 HDF5_Type;
64 typedef Teuchos::RCP<HDF5_Type> HDF5Ptr_Type;
65
66 typedef Teuchos::Comm<int> Comm_Type;
67 typedef Teuchos::RCP<const Comm_Type> CommConstPtr_Type;
68 typedef const Teuchos::RCP<const Comm_Type> CommConstPtrConst_Type;
69
70 typedef Map<LO,GO,NO> Map_Type;
71 typedef Teuchos::RCP<const Map_Type> MapConstPtr_Type;
72 typedef const MapConstPtr_Type MapConstPtrConst_Type;
73
74 typedef MultiVector<SC,LO,GO,NO> MultiVector_Type;
75 typedef Teuchos::RCP<const MultiVector_Type> MultiVectorConstPtr_Type;
76 typedef const MultiVectorConstPtr_Type MultiVectorConstPtrConst_Type;
77
78 typedef Mesh<SC,LO,GO,NO> Mesh_Type;
79 typedef Teuchos::RCP<Mesh_Type> MeshPtr_Type;
80
81 typedef typename Mesh_Type::ElementsPtr_Type ElementsPtr_Type;
82
83
84 ExporterParaViewAMR();
85
86 void updateVariables(MultiVectorConstPtr_Type &u, std::string varName);
87
88 void reSetup(MeshPtr_Type mesh); // Updates the setup values to new Mesh
89
90private:
91
92
93 };
94}
95
96#endif
Definition Map_decl.hpp:36
Definition Mesh_decl.hpp:25
Definition MultiVector_decl.hpp:36
Adaptive Mesh Refinement.
Definition AdaptiveMeshRefinement.cpp:5