Skip to content
Snippets Groups Projects
Commit ce747461 authored by Youett, Jonathan's avatar Youett, Jonathan Committed by akbib@FU-BERLIN.DE
Browse files

add method to embedd the skew matrix in R^3x3

[[Imported from SVN: r7942]]
parent f6cfbc49
No related branches found
No related tags found
No related merge requests found
...@@ -38,6 +38,22 @@ public: ...@@ -38,6 +38,22 @@ public:
{ {
return data_; return data_;
} }
/** \brief Embedd the skey-symmetric matrix in R^3x3 */
Dune::FieldMatrix<T,3,3> toMatrix()
{
Dune::FieldMatrix<T,3,3> mat;
mat = 0;
mat[0][1] = -data_[2];
mat[1][0] = data_[2];
mat[0][2] = data_[1];
mat[2][0] = -data_[1];
mat[1][2] = -data_[0];
mat[2][1] = data_[0];
return mat;
}
private: private:
// we store the axial vector // we store the axial vector
...@@ -45,4 +61,4 @@ private: ...@@ -45,4 +61,4 @@ private:
}; };
#endif #endif
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment