public abstract class AbstractSparseEqnComplexMatrix3x3Impl<T extends ISparseEqnSolver> extends AbstractSparseEquation<T> implements ISparseEqnComplexMatrix3x3
ISparseEquation.IndexType| Modifier and Type | Field and Description |
|---|---|
protected AbstractSparseEqnComplexImpl<T> |
cplxMatrix |
colCnt, factored, rowCnt, solver, squareMatrix, zeroAii_row| Constructor and Description |
|---|
AbstractSparseEqnComplexMatrix3x3Impl(int n) |
AbstractSparseEqnComplexMatrix3x3Impl(int rows,
int cols) |
| Modifier and Type | Method and Description |
|---|---|
void |
addToA(Complex3x3 x,
int i,
int j)
Add the aij object to the matrix.
|
void |
addToB(Complex3x1 bi,
int i)
add to bi element.
|
boolean |
factorization()
Factorization, for example LU decomposition, of the matrix.
|
boolean |
factorization(double tolerance)
Factorization, for example LU decomposition, of the matrix.
|
Complex3x3 |
getA(int i,
int j)
Get the aij object.
|
ComplexSEqnRow |
getElem(int i) |
ISparseEqnComplex |
getSparseEqnComplex() |
int |
getTotalElements()
Get the total elements in the matrix
|
Complex3x1 |
getX(int i)
Get the x[i] object, after the eqn is solved.
|
int |
getZeroA_row()
Get zero aii row number, in case the matrix is singular
|
int |
getZeroAii_row()
During the LU process, aii might be zero.
|
void |
increaseDimension()
Increase matrix dimension by 1.
|
void |
reset()
Reset the matrix to zero - set all aii and bi to 0.0 and clear the sparse structure,
and release memory if necessary
|
void |
setA(Complex3x3 x,
int i,
int j)
Set the aij object.
|
void |
setB2Unity(int i)
Set all b elements to 0.0 and bi = 1.0, a unity vector.
|
void |
setB2Zero()
Set all b elements to 0.0
|
void |
setBi(Complex3x1 bi,
int i)
Set b[i] object, before solving the eqn.
|
void |
setBVector(Complex3x1[] bAry)
Set b vector, before solving the eqn.
|
void |
setElem(int i,
ComplexSEqnRow aii) |
void |
setToZero()
Reset all matrix element to zero, preserve the matrix sparse structure.
|
void |
solveEqn()
Solve the [A]X = B problem
|
boolean |
solveEqn(double tolerance)
LU decomposition of the matrix and the solve the [A]X = B problem.
|
java.lang.String |
toString() |
getBusId, getDimension, getDimension, isFactorized, isSquareMatrix, setBusId, setFactorized, setZeroAii_rowclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetBusId, getDimension, getDimension, isFactorized, isSquareMatrix, setBusId, setFactorizedprotected AbstractSparseEqnComplexImpl<T extends ISparseEqnSolver> cplxMatrix
public AbstractSparseEqnComplexMatrix3x3Impl(int n)
public AbstractSparseEqnComplexMatrix3x3Impl(int rows,
int cols)
public ComplexSEqnRow getElem(int i)
public void setElem(int i,
ComplexSEqnRow aii)
public void addToA(Complex3x3 x, int i, int j)
ISparseEqnObjectaddToA in interface ISparseEqnObject<Complex3x3,Complex3x1>x - the aij elementi - the element row numberj - the element column numberpublic Complex3x1 getX(int i)
ISparseEqnObjectgetX in interface ISparseEqnObject<Complex3x3,Complex3x1>i - the element row numberpublic void setA(Complex3x3 x, int i, int j)
ISparseEqnObjectsetA in interface ISparseEqnObject<Complex3x3,Complex3x1>x - the aij objecti - the element row numberj - the element column numberpublic Complex3x3 getA(int i, int j)
ISparseEqnObjectgetA in interface ISparseEqnObject<Complex3x3,Complex3x1>i - the element row numberj - the element column numberpublic void setBi(Complex3x1 bi, int i)
ISparseEqnObjectsetBi in interface ISparseEqnObject<Complex3x3,Complex3x1>bi - the bi elementi - row numberpublic void setBVector(Complex3x1[] bAry)
ISparseEqnObjectsetBVector in interface ISparseEqnObject<Complex3x3,Complex3x1>bAry - the b vector elementspublic void addToB(Complex3x1 bi, int i)
ISparseEqnObjectaddToB in interface ISparseEqnObject<Complex3x3,Complex3x1>bi - the bi elementi - row numberpublic int getZeroA_row()
ISparseEqnObjectgetZeroA_row in interface ISparseEqnObject<Complex3x3,Complex3x1>public void increaseDimension()
ISparseEquationincreaseDimension in interface ISparseEquationpublic int getTotalElements()
ISparseEquationgetTotalElements in interface ISparseEquationpublic boolean factorization(double tolerance)
throws IpssNumericException
ISparseEquationfactorization in interface ISparseEquationfactorization in class AbstractSparseEquation<T extends ISparseEqnSolver>tolerance - the tolerance for matrix singular detectionIpssNumericExceptionpublic boolean factorization()
throws IpssNumericException
ISparseEquationfactorization in interface ISparseEquationfactorization in class AbstractSparseEquation<T extends ISparseEqnSolver>IpssNumericExceptionpublic boolean solveEqn(double tolerance)
throws IpssNumericException
AbstractSparseEquationsolveEqn in interface ISparseEquationsolveEqn in class AbstractSparseEquation<T extends ISparseEqnSolver>tolerance - the tolerance for matrix singular detectionIpssNumericExceptionpublic void solveEqn()
throws IpssNumericException
ISparseEquationsolveEqn in interface ISparseEquationIpssNumericExceptionpublic void setB2Unity(int i)
ISparseEquationsetB2Unity in interface ISparseEquationi - the element row numberpublic void setB2Zero()
ISparseEquationsetB2Zero in interface ISparseEquationsetB2Zero in class AbstractSparseEquation<T extends ISparseEqnSolver>public void reset()
ISparseEquationreset in interface ISparseEquationpublic void setToZero()
ISparseEquationsetToZero in interface ISparseEquationpublic int getZeroAii_row()
ISparseEquationgetZeroAii_row in interface ISparseEquationgetZeroAii_row in class AbstractSparseEquation<T extends ISparseEqnSolver>public ISparseEqnComplex getSparseEqnComplex()
getSparseEqnComplex in interface ISparseEqnComplexMatrix3x3public java.lang.String toString()
toString in class java.lang.Object