diff options
Diffstat (limited to 'doc/snippets/Jacobi_makeGivens.cpp')
-rw-r--r-- | doc/snippets/Jacobi_makeGivens.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/doc/snippets/Jacobi_makeGivens.cpp b/doc/snippets/Jacobi_makeGivens.cpp new file mode 100644 index 000000000..4b733c306 --- /dev/null +++ b/doc/snippets/Jacobi_makeGivens.cpp @@ -0,0 +1,6 @@ +Vector2f v = Vector2f::Random(); +JacobiRotation<float> G; +G.makeGivens(v.x(), v.y()); +cout << "Here is the vector v:" << endl << v << endl; +v.applyOnTheLeft(0, 1, G.adjoint()); +cout << "Here is the vector J' * v:" << endl << v << endl;
\ No newline at end of file |