SLIP  1.4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Bug List
Member slip::compareTwoRows2D (double *rowA, double *rowB)
The iterators are invalidated by the sort algorithm. Use [] operator to access data after a sorting operation.
Example:
// Create a Array2d and sort it by the 3rd column, then by the 2nd then by the 1st.
slip::iota(data.begin(), data.end(), 10., -1.);
for (size_t i = 0; i < data.dim1(); ++i)
{
slip::iota(data.row_begin(i), data.row_end(i), 10.-i*0.3);
for (size_t j = 2; j < data.dim2(); ++j)
{
data[i][j]=(int)data[i][j];
}
}
std::cout<<data<<endl<<endl;
data.sort(&compareTwoRows2D);
std::cout<<data<<endl<<endl;
Member slip::compareTwoRows3D (double *rowA, double *rowB)
The iterators are invalidated by the sort algorithm. Use [] operator to access data after a sorting operation.
Example:
// Create a Array2d and sort it by the 3rd column, then by the 2nd then by the 1st.
slip::iota(data.begin(), data.end(), 10., -1.);
for (size_t i = 0; i < data.dim1(); ++i)
{
slip::iota(data.row_begin(i), data.row_end(i), 10.-i*0.3);
for (size_t j = 2; j < data.dim2(); ++j)
{
data[i][j]=(int)data[i][j];
}
}
std::cout<<data<<endl<<endl;
data.sort(&compareTwoRows3D);
std::cout<<data<<endl<<endl;
Member slip::RegularVector2dField2d< T, GridT >::lambda2 (const std::size_t sch_order, Container2D &result)
should be a const method
//computes the lambda2 at order 4 on the field Vxy
slip::Matrix<double> l2(Vxy.rows(),Vxy.cols());
Vxy.lambda2(4,l2);