mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-06-22 22:04:01 -06:00
Eigen: Updated to version 3.3.4
git-svn-id: svn://ultimatepp.org/upp/trunk@11406 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
c91e77562d
commit
abf7bcb9db
337 changed files with 2367 additions and 44663 deletions
|
|
@ -1,23 +0,0 @@
|
|||
#include <unsupported/Eigen/MatrixFunctions>
|
||||
#include <iostream>
|
||||
|
||||
using namespace Eigen;
|
||||
|
||||
std::complex<double> expfn(std::complex<double> x, int)
|
||||
{
|
||||
return std::exp(x);
|
||||
}
|
||||
|
||||
int main()
|
||||
{
|
||||
const double pi = std::acos(-1.0);
|
||||
|
||||
MatrixXd A(3,3);
|
||||
A << 0, -pi/4, 0,
|
||||
pi/4, 0, 0,
|
||||
0, 0, 0;
|
||||
|
||||
std::cout << "The matrix A is:\n" << A << "\n\n";
|
||||
std::cout << "The matrix exponential of A is:\n"
|
||||
<< A.matrixFunction(expfn) << "\n\n";
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue