Mechanics of Defect Evolution Library
Loading...
Searching...
No Matches
DislocationLoopIO.h
Go to the documentation of this file.
1/* This file is part of MoDELib, the Mechanics Of Defects Evolution Library.
2 *
3 *
4 * MoDELib is distributed without any warranty under the
5 * GNU General Public License (GPL) v2 <http://www.gnu.org/licenses/>.
6 */
7
8#ifndef model_DislocationLoopIO_H_
9#define model_DislocationLoopIO_H_
10
11#include <iomanip>
12#include <tuple>
13#include <sstream>
14#include <ostream>
15#include <Eigen/Dense>
16#include <Eigen/Dense>
17
18namespace model
19{
20 template<int dim> class DislocationLoop;
21
22 template<short unsigned int dim>
24 {
25
27
28
29 typedef Eigen::Matrix<double,dim,1> VectorDim;
30
31 size_t sID; // sID
32 VectorDim B; // position
33 VectorDim N; // normal
34 VectorDim P; // position
35 size_t grainID; // component ID
37 std::tuple<double,double,double,double> loopLength;
39
41
42 DislocationLoopIO(const size_t& sID_in, // sID
43 const VectorDim& B_in, // position
44 const VectorDim& N_in, // velocity
45 const VectorDim& P_in, // velocity
46 const size_t& grainID_in,
47 const int& loopType_in
48 );
49
51
52 DislocationLoopIO(std::stringstream& ss);
53
54 template <class T>
55 friend T& operator << (T& os, const DislocationLoopIO<dim>& ds)
56 {
57 ds.write(os);
58 return os;
59 }
60
61 std::ostream& write(std::ostream& os) const;
62
63 };
64
65}
66#endif
67
DislocationLoopIO(const DislocationLoop< dim > &dL)
DislocationLoopIO(const size_t &sID_in, const VectorDim &B_in, const VectorDim &N_in, const VectorDim &P_in, const size_t &grainID_in, const int &loopType_in)
Eigen::Matrix< double, dim, 1 > VectorDim
friend T & operator<<(T &os, const DislocationLoopIO< dim > &ds)
DislocationLoopIO(std::stringstream &ss)
std::tuple< double, double, double, double > loopLength
std::ostream & write(std::ostream &os) const
newsubseg ss[0]