mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-01-18 14:34:17 +08:00
Add missing snippet files.
This commit is contained in:
parent
a0a36ad0ef
commit
5165de97a4
2
doc/snippets/Cwise_boolean_xor.cpp
Normal file
2
doc/snippets/Cwise_boolean_xor.cpp
Normal file
@ -0,0 +1,2 @@
|
||||
.Array3d v(-1,2,1), w(-3,2,3);
|
||||
cout << ((v<w) ^ (v<0)) << endl;
|
6
doc/snippets/MatrixBase_selfadjointView.cpp
Normal file
6
doc/snippets/MatrixBase_selfadjointView.cpp
Normal file
@ -0,0 +1,6 @@
|
||||
Matrix3i m = Matrix3i::Random();
|
||||
cout << "Here is the matrix m:" << endl << m << endl;
|
||||
cout << "Here is the symmetric matrix extracted from the upper part of m:" << endl
|
||||
<< Matrix3i(m.selfadjointView<Upper>()) << endl;
|
||||
cout << "Here is the symmetric matrix extracted from the lower part of m:" << endl
|
||||
<< Matrix3i(m.selfadjointView<Lower>()) << endl;
|
Loading…
Reference in New Issue
Block a user