#include <assert.h>
#include "scip/lapack_calls.h"
#include "scip/def.h"
#include "scip/pub_message.h"
#include "blockmemshell/memory.h"
#include "scip/type_retcode.h"
#include "scip/nlpi_ipopt.h"
Go to the source code of this file.
Functions | |
Functions | |
SCIP_Bool | SCIPlapackIsAvailable (void) |
void | SCIPlapackVersion (int *majorver, int *minorver, int *patchver) |
SCIP_RETCODE | SCIPlapackComputeEigenvalues (BMS_BUFMEM *bufmem, SCIP_Bool geteigenvectors, int N, SCIP_Real *a, SCIP_Real *w) |
SCIP_RETCODE | SCIPlapackSolveLinearEquations (BMS_BUFMEM *bufmem, int n, SCIP_Real *A, SCIP_Real *b, SCIP_Real *x, SCIP_Bool *success) |
SCIP_Bool SCIPlapackIsAvailable | ( | void | ) |
returns whether Lapack is available, i.e., whether it has been linked in
Definition at line 121 of file lapack_calls.c.
References FALSE, SCIP_Bool, SCIPisIpoptAvailableIpopt(), and TRUE.
Referenced by detectSocQuadraticComplex(), SCIP_DECL_SEPAEXECLP(), SCIP_DECL_SEPAEXECSOL(), SCIPcomputeFacetVertexPolyhedralNonlinear(), and SCIPexprComputeQuadraticCurvature().
void SCIPlapackVersion | ( | int * | majorver, |
int * | minorver, | ||
int * | patchver ) |
returns whether Lapack s available, i.e., whether it has been linked in
majorver | major version number |
minorver | minor version number |
patchver | patch version number |
Definition at line 181 of file lapack_calls.c.
References assert(), F77_FUNC(), and NULL.
Referenced by doScipCreate().
SCIP_RETCODE SCIPlapackComputeEigenvalues | ( | BMS_BUFMEM * | bufmem, |
SCIP_Bool | geteigenvectors, | ||
int | N, | ||
SCIP_Real * | a, | ||
SCIP_Real * | w ) |
computes eigenvalues and eigenvectors of a dense symmetric matrix
Calls Lapack's DSYEV function.
bufmem | buffer memory (or NULL if IPOPT is used) |
geteigenvectors | should also eigenvectors should be computed? |
N | dimension |
a | matrix data on input (size N*N); eigenvectors on output if geteigenvectors == TRUE |
w | array to store eigenvalues (size N) (or NULL) |
Definition at line 352 of file lapack_calls.c.
References a, assert(), NULL, SCIP_Bool, SCIP_CALL, SCIP_OKAY, SCIP_PLUGINNOTFOUND, SCIP_Real, SCIPcallLapackDsyevIpopt(), SCIPerrorMessage, SCIPisIpoptAvailableIpopt(), and w.
Referenced by detectSocQuadraticComplex(), getEigenValues(), and SCIPexprComputeQuadraticCurvature().
SCIP_RETCODE SCIPlapackSolveLinearEquations | ( | BMS_BUFMEM * | bufmem, |
int | n, | ||
SCIP_Real * | A, | ||
SCIP_Real * | b, | ||
SCIP_Real * | x, | ||
SCIP_Bool * | success ) |
solves a linear problem of the form Ax = b for a regular matrix A
Calls Lapacks DGETRF routine to calculate a LU factorization and uses this factorization to solve the linear problem Ax = b.
Code taken from nlpi_ipopt.cpp
bufmem | buffer memory |
n | dimension |
A | matrix data on input (size N*N); filled column-wise |
b | right hand side vector (size N) |
x | buffer to store solution (size N) |
success | pointer to store if the solving routine was successful |
Definition at line 386 of file lapack_calls.c.
References assert(), b, BMSallocBufferMemoryArray, BMScopyMemoryArray, BMSduplicateBufferMemoryArray, BMSfreeBufferMemoryArray, F77_FUNC(), FALSE, NULL, SCIP_ALLOC, SCIP_Bool, SCIP_CALL, SCIP_OKAY, SCIP_Real, SCIP_UNUSED, SCIPdebugMessage, SCIPisIpoptAvailableIpopt(), SCIPsolveLinearEquationsIpopt(), TRUE, and x.
Referenced by computeHyperplaneThreePoints().