g++ [flags ...] file ... -l /isip/tools/lib/$ISIP_BINARY/lib_math_matrix.a
#include <MatrixComplexFloat.h>
MatrixComplexFloat(long nrows = DEF_SIZE, long ncols = DEF_SIZE,
long type = DEF_TYPE);
MatrixComplexFloat(const MatrixComplexFloat& matrix);
quick start:
MatrixComplexFloat val0(2, 3, L"1.2-6.5j, 2.5+5.4j, -3.6+4.3j,
-4.8-4.2j, -5.1-8j, 6.7-4.6j");
MatrixComplexFloat val1(3, 3, L"1.2-6.5j, 2.5+5.4j, -3.6+4.3j,
-4.8-4.2j, -5.1-8j, 6.7-4.6j",
Integral::LOWER_TRIANGULAR);
description:
static const String CLASS_NAME = L"MatrixComplexFloat";
static const long ERR = 25000;
static MemoryManager mgr_d;
static const String& name();
static boolean diagnose(Integral::DEBUG debug_level);
boolean debug(const unichar* message) const;
~MatrixComplexFloat();
MatrixComplexFloat(long nrows = DEF_SIZE, long ncols = DEF_SIZE, long type = DEF_TYPE);
MatrixComplexFloat(const MatrixComplexFloat& matrix);
these methods are inherited from the MMatrix template class
MatrixComplexFloat& operator=(const MatrixComplexFloat& matrix);
boolean read(Sof& sof, long tag, const String& name = CLASS_NAME);
boolean write(Sof& sof, long tag, const String& name = CLASS_NAME) const;
these methods are inherited from the MMatrix template class
static void* operator new(size_t size);
static void* operator new[](size_t size);
static void operator delete(void* ptr);
static void operator delete[](void* ptr);
static boolean setGrowSize(long grow_size);
MatrixComplexFloat(long nrows, long ncols, const unichar* arg, long type = DEF_TYPE, const Char delim = DEF_DELIM);
MatrixComplexFloat& operator=(complexfloat value);
#include <MatrixComplexFloat.h>
#include <VectorComplexFloat.h>
// this example solve a system of equations Ax = b
// where A is a complex matrix and b is a complex vector
//
int main() {
// define the complex matrix A, complex vector b
// and the resulting complex vector x
//
MatrixComplexFloat A(3, 3, L"1, 2.0j, -3,
-4.0, 0, 1j,
1, 1, 1+1j", Integral::FULL);
VectorComplexFloat b(L"-3.9-3j, -5.4+1j, 1.1+3j");
VectorComplexFloat x;
// compute the matrix inversion
//
A.inverse();
// multiply inverse matrix by b, put the result into x
//
A.multv(x, b);
// print the solution
//
x.debug(L"Solution:");
return true;
}