|
Bertini 2 - C++ Core
Software for Numerical Algebraic Geometry
|
Bertini extensions of the Eigen linear algebra library. More...
#include "bertini2/num_traits.hpp"#include <boost/serialization/complex.hpp>#include <boost/serialization/array.hpp>#include <boost/serialization/split_member.hpp>#include <Eigen/Core>#include <Eigen/Geometry>#include <Eigen/Eigenvalues>#include <Eigen/SVD>#include <Eigen/Dense>Go to the source code of this file.
Classes | |
| struct | Eigen::NumTraits< mpfr_complex > |
| This templated struct permits us to use the mpfr_complex type in Eigen matrices. More... | |
Functions | |
| template<typename Derived> | |
| bool | bertini::IsEmpty (Eigen::MatrixBase< Derived > const &v) |
| Checks whether the number of rows and columns are either 0. | |
| template<typename T> | |
| bool | bertini::IsLargeChange (T const &numerator, T const &denomenator) |
| template<typename T> | |
| bool | bertini::IsSmallValue (T const &testme) |
| template<typename T> | |
| bool | bertini::IsSymmRelDiffSmall (T const &a, T const &b, typename Eigen::NumTraits< T >::Real const &e) |
| Check whether two values are very close to each other. | |
| template<typename NumberType> | |
| Eigen::Matrix< NumberType, Eigen::Dynamic, Eigen::Dynamic > | bertini::KahanMatrix (unsigned int mat_size, NumberType c) |
| Make a Kahan matrix with a given number type. | |
| template<typename Derived> | |
| MatrixSuccessCode | bertini::LUPartialPivotDecompositionSuccessful (Eigen::MatrixBase< Derived > const &LU) |
| Check the diagonal elements of an LU decomposition for small values and large ratios. | |
| template<typename Derived> | |
| void | bertini::Precision (Eigen::MatrixBase< Derived > &v, unsigned prec) |
| Set the precision of an Eigen object. | |
| template<typename Derived> | |
| unsigned | bertini::Precision (Eigen::MatrixBase< Derived > const &v) |
| Get the precision of an Eigen object. If the object is empty, it's the precision of a default-constructed Scalar. If it actually has content, then it's the precision of the first element. | |
| template<typename Derived> | |
| unsigned | bertini::PrecisionRequireUniform (Eigen::MatrixBase< Derived > const &v) |
| Query the precision of an Eigen object, requiring it to be non-empty, and of uniform precision. | |
| template<typename NumberType> | |
| Mat< NumberType > | bertini::RandomOfUnits (uint rows, uint cols) |
| Make a random matrix of units (numbers with norm 1). | |
| template<typename NumberType> | |
| Vec< NumberType > | bertini::RandomOfUnits (uint size) |
| Make a random vector of units (numbers with norm 1). | |
Bertini extensions of the Eigen linear algebra library.
|
inline |
Checks whether the number of rows and columns are either 0.
|
inline |
Test two numbers for having large ratio.
The basis for comparison is Eigen's fuzzy precision, Eigen::NumTraits<T>::dummy_precision();
| numerator | The numerator for the ratio. |
| denomenator | The denomenator for the ratio. |
|
inline |
Test a numbers being very small.
Compares the number against machine epsilon (or software epsilon if a multiple precision type), times 100.
| testme | The number to test |
|
inline |
Check whether two values are very close to each other.
The tolerance for being close See \url http://www.boost.org/doc/libs/1_34_0/libs/test/doc/components/test_tools/floating_point_comparison.html, for example.
| Eigen::Matrix< NumberType, Eigen::Dynamic, Eigen::Dynamic > bertini::KahanMatrix | ( | unsigned int | mat_size, |
| NumberType | c ) |
Make a Kahan matrix with a given number type.
| MatrixSuccessCode bertini::LUPartialPivotDecompositionSuccessful | ( | Eigen::MatrixBase< Derived > const & | LU | ) |
Check the diagonal elements of an LU decomposition for small values and large ratios.
This function requires a square non-empty matrix.
| Derived | Matrix type from Eigen. |
| void bertini::Precision | ( | Eigen::MatrixBase< Derived > & | v, |
| unsigned | prec ) |
Set the precision of an Eigen object.
| v | the matrix to change |
| prec | the new precision |
|
inline |
Get the precision of an Eigen object. If the object is empty, it's the precision of a default-constructed Scalar. If it actually has content, then it's the precision of the first element.
If you require that the object be of uniform precision when you check, use PrecisionRequireUniform
| unsigned bertini::PrecisionRequireUniform | ( | Eigen::MatrixBase< Derived > const & | v | ) |
Query the precision of an Eigen object, requiring it to be non-empty, and of uniform precision.
| runtime_error | if not uniform precision Dies in an Eigen assert if empty (assuming you didn't disable these) |
|
inline |
Make a random matrix of units (numbers with norm 1).
| rows | The number of rows. |
| cols | The number of columns. |
| NumberType | the type of number to fill the matrix with. |
|
inline |
Make a random vector of units (numbers with norm 1).
| size | The length of the vector. |
| NumberType | the type of number to fill the vector with. |