HQP
1.9.6
|
Meschach declarations and some extensions. More...
#include <limits>
#include <string.h>
#include <assert.h>
#include <meschach/matrix.h>
#include <meschach/sparse.h>
Classes | |
class | Mesch::VECP |
Wrapper for Meschach VEC*. More... | |
class | Mesch::IVECP |
Wrapper for Meschach IVEC*. More... | |
class | Mesch::PERMP |
Wrapper for Meschach PERM*. More... | |
class | Mesch::MATROWP |
Wrapper for a row in Meschach MAT. More... | |
class | Mesch::MATP |
Wrapper for Meschach MAT*. More... | |
Namespaces | |
Mesch | |
Wrappers for Meschach data structures allowing use of C++ operators. | |
Macros | |
#define | max(a, b) ((a) > (b) ? (a) : (b)) |
Avoid multiple inclusion. | |
#define | min(a, b) ((a) < (b) ? (a) : (b)) |
#define | MESCH_BOUNDS_CHECK(i, first_index, next_index) |
Bounds check for wrappers of Meschach types if compiled with DEBUG flag. | |
#define | MESCH_NULL_CHECK(ptr) |
NULL check for wrappers of Meschach types if compiled with DEBUG flag. | |
Typedefs | |
typedef SPMAT * | Mesch::SPMATP |
Place holder for wrapper of Meschach SPMAT*. | |
typedef BAND * | Mesch::BANDP |
Place holder for wrapper of Meschach BAND*. | |
Functions | |
bool | Mesch::is_finite (Real x) |
check if a number is finite | |
bool | Mesch::is_nan (Real x) |
check for not a number | |
Real | Mesch::sscan_real (const char *str) |
Scan a string for a real number, including infinity (Inf, -Inf); Return the number or NaN in case of error. More... | |
Additional Meschach functions | |
IVEC * | iv_set (IVEC *, int) |
IVEC * | iv_part (IVEC *iv, int offs, int dim, IVEC *header) |
IVEC * | iv_expand (IVEC *iv, int nel, int granul) |
IVEC * | iv_copy_elements (const IVEC *, IVEC *) |
VEC * | v_set (VEC *, Real) |
VEC * | v_part (VEC *v, int offs, int dim, VEC *header) |
VEC * | v_expand (VEC *v, int nel, int granul) |
VEC * | v_copy_elements (const VEC *, VEC *) |
VEC * | bd_mv_mlt (const BAND *, const VEC *, VEC *) |
MAT * | m_mltadd (const MAT *, const MAT *, const MAT *, MAT *) |
MAT * | m_copy_elements (const MAT *, MAT *) |
Real | sp_norm_inf (SPMAT *) |
SPMAT * | sp_copy3 (const SPMAT *, SPMAT *) |
int | sp_update_val (SPMAT *, int, int, Real) |
void | sp_insert_mat (SPMAT *dst, int i_offs, int j_offs, const MAT *src) |
void | symsp_insert_symmat (SPMAT *dst, int offs, const MAT *src) |
void | sp_update_mat (SPMAT *dst, int i_offs, int j_offs, const MAT *src) |
void | sp_extract_mat (const SPMAT *src, int i_offs, int j_offs, MAT *dst) |
void | symsp_extract_mat (const SPMAT *src, int offs, MAT *dst) |
void | sp_insert_mrow (SPMAT *dst, int i_offs, int j_offs, const MAT *src, int i) |
void | sp_update_mrow (SPMAT *dst, int i_offs, int j_offs, const MAT *src, int i) |
void | sp_extract_mrow (const SPMAT *src, int i_offs, int j_offs, MAT *dst, int i) |
SPMAT * | sp_ident (SPMAT *) |
SPMAT * | sp_ones (SPMAT *) |
VEC * | sp_mv_mltadd (const VEC *v1, const VEC *v2, const SPMAT *A, Real alpha, VEC *out) |
VEC * | sp_vm_mltadd (const VEC *v1, const VEC *v2, const SPMAT *A, Real alpha, VEC *out) |
VEC * | sp_mv_symmlt (SPMAT *A, const VEC *v, VEC *out) |
Real | sprow_inprod (const SPROW *r1, const VEC *inner, const SPROW *r2) |
void | sprow_zero (SPROW *row) |
SPMAT * | spLUfactor2 (SPMAT *A, PERM *px) |
SPMAT * | sp_transp (const SPMAT *, SPMAT *) |
BKP factor and solve routines | |
Reference: J.R.Bunch, L.Kaufman, and B.N.Parlett: Decomposition of a Symmetric Matrix, Numer Math 27, 95–109 (1976). | |
MAT * | matBKPfactor (MAT *A, PERM *pivot) |
VEC * | matBKPsolve (const MAT *A, const PERM *pivot, const VEC *b, VEC *x) |
BAND * | bdBKPfactor (BAND *A, PERM *pivot, PERM *relief) |
VEC * | bdBKPsolve (const BAND *A, const PERM *pivot, const PERM *relief, const VEC *b, VEC *x) |
SPMAT * | spBKPfactor (SPMAT *, PERM *pivot, Real tol) |
VEC * | spBKPsolve (const SPMAT *, const PERM *pivot, const VEC *b, VEC *x) |
Routines for copying sparse matrices into sparse/band matrices | |
("sym" means that only the upper part of a symmetric matrix is filled) | |
void | sp_into_sp (const SPMAT *src, Real s, SPMAT *dst, const PERM *px, int i_offs, int j_offs) |
void | spT_into_sp (const SPMAT *src, Real s, SPMAT *dst, const PERM *px, int i_offs, int j_offs) |
void | sp_into_symsp (const SPMAT *src, Real s, SPMAT *dst, const PERM *px, int i_offs, int j_offs) |
void | symsp_into_symsp (const SPMAT *src, Real s, SPMAT *dst, const PERM *px, int offs) |
void | spT_into_symsp (const SPMAT *src, Real s, SPMAT *dst, const PERM *px, int i_offs, int j_offs) |
void | sp_into_bd (const SPMAT *sp, Real s, BAND *bd, const PERM *px, int i_offs, int j_offs) |
void | spT_into_bd (const SPMAT *sp, Real s, BAND *bd, const PERM *px, int i_offs, int j_offs) |
Variables | |
const Real | Mesch::Inf = (Real)std::numeric_limits<double>::infinity() |
Infinity for non existing constraints and numerical overflow. | |
Meschach declarations and some extensions.
rf, 8/18/94