Commit 3f47a2b2 authored by Tandri Gauksson's avatar Tandri Gauksson

minor changes before uploading to CodeExpert

parent d5a7b6ca
......@@ -11,7 +11,7 @@
// END
/* SAM_LISTING_BEGIN_0 */
Eigen::Matrix2d smallTriangular(double a, double b, double c) {
Eigen::Matrix<double, 2, 2> smallTriangular(double a, double b, double c) {
/*
* This functions returns a 2 by 2 triangular matrix of doubles a, b, c.
*/
......@@ -142,7 +142,6 @@ Eigen::VectorXcd arithmetics(int n) {
B(k,l) = tmp/std::conj(tmp);
}
}
std::cout<<B<<std::endl;
// END
// We can perform arithmetics on matrices: +, -, *
......@@ -164,8 +163,6 @@ Eigen::VectorXcd arithmetics(int n) {
v = C * u;
// END
// std::cout<<v<<std::endl;
return v;
}
/* SAM_LISTING_END_3 */
......
......@@ -10,7 +10,7 @@ int main(){
std::cout<< "\nTest of casting():\n";
std::cout<< casting() << std::endl;
std::cout<< "\nTest of arithmetics():\n";
std::cout<< arithmetics(5) << std::endl;
std::cout<< arithmetics(4) << std::endl;
return 0;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment