mirror of
https://gitlab.com/libeigen/eigen.git
synced 2026-04-10 11:34:33 +08:00
@@ -6,4 +6,4 @@ int main()
|
||||
{
|
||||
Array4d v(0.5,10,0,-1);
|
||||
std::cout << v.lgamma() << std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -10,7 +10,7 @@ int main()
|
||||
MatrixXi m(size,size+1); // a (size)x(size+1)-matrix of int's
|
||||
for (int j=0; j<m.cols(); ++j) // loop over columns
|
||||
for (int i=0; i<m.rows(); ++i) // loop over rows
|
||||
m(i,j) = i+j*m.rows(); // to access matrix coefficients,
|
||||
m(i,j) = i+j*size; // to access matrix coefficients,
|
||||
// use operator()(int,int)
|
||||
std::cout << m << "\n\n";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user