aboutsummaryrefslogtreecommitdiffhomepage
path: root/doc/snippets/HessenbergDecomposition_compute.cpp
diff options
context:
space:
mode:
authorGravatar Jitse Niesen <jitse@maths.leeds.ac.uk>2010-03-28 17:33:56 +0100
committerGravatar Jitse Niesen <jitse@maths.leeds.ac.uk>2010-03-28 17:33:56 +0100
commite6300efb5c97cbd66b58b944441f66147bb375ad (patch)
tree35967ac404865caf2fe17e8527c93dc0632c22aa /doc/snippets/HessenbergDecomposition_compute.cpp
parent0a5c2d8a54bf0bdab7a7c68e824002ba163bbdca (diff)
Extend documentation for HessenbergDecomposition.
Diffstat (limited to 'doc/snippets/HessenbergDecomposition_compute.cpp')
-rw-r--r--doc/snippets/HessenbergDecomposition_compute.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/doc/snippets/HessenbergDecomposition_compute.cpp b/doc/snippets/HessenbergDecomposition_compute.cpp
new file mode 100644
index 000000000..50e37833a
--- /dev/null
+++ b/doc/snippets/HessenbergDecomposition_compute.cpp
@@ -0,0 +1,6 @@
+MatrixXcf A = MatrixXcf::Random(4,4);
+HessenbergDecomposition<MatrixXcf> hd(4);
+hd.compute(A);
+cout << "The matrix H in the decomposition of A is:" << endl << hd.matrixH() << endl;
+hd.compute(2*A); // re-use hd to compute and store decomposition of 2A
+cout << "The matrix H in the decomposition of 2A is:" << endl << hd.matrixH() << endl;