class FullGenLinSOE : public LinearSOE


Inheritance:


Public Methods

FullGenLinSOE(FullGenLinSolver &theSolver)
FullGenLinSOE(int N, FullGenLinSolver &theSolver)
~FullGenLinSOE()
int getNumEqn(void) const
int setSize(Graph &theGraph)
int addA(const Matrix &, const ID &, double fact = 1.0)
int addB(const Vector &, const ID &, double fact = 1.0)
int setB(const Vector &, double fact = 1.0)
void zeroA(void)
void zeroB(void)
const Vector& getX(void)
const Vector& getB(void)
double normRHS(void)
void setX(int loc, double value)
int setFullGenSolver(FullGenLinSolver &newSolver)
friend include <FullGenLinLapackSolver.h> int sendSelf(int commitTag, Channel &theChannel)
int recvSelf(int commitTag, Channel &theChannel, FEM_ObjectBroker &theBroker)

Inherited from LinearSOE:

Public Methods

virtual int solve(void)

Protected Methods

int setSolver(LinearSOESolver &newSolver)
LinearSOESolver* getSolver(void)

Inherited from SystemOfEqn:


Inherited from MovableObject:

Public Methods

int getClassTag(void) const
int getDbTag(void) const
void setDbTag(int dbTag)

Documentation

FullGenLinSOE is class which is used to store a full general system. The A matrix is stored in a 1d double array with n*n elements, where n is the size of the system. A_{i,j} is stored at location (i + j*(n), where i and j range from 0 to n-1, i.e. C notation. For example when n=3:

\left[ \begin{array}{ccc} a_{0,0} & a_{0,1} & a_{0,2}

FullGenLinSOE(FullGenLinSolver &theSolver)

FullGenLinSOE(int N, FullGenLinSolver \&theSolver);

FullGenLinSOE(int N, FullGenLinSolver &theSolver)

~FullGenLinSOE()

The solver and a unique class tag (defined in <classTags.h>) are passed to the LinearSOE constructor. The system size is set to 0 and the matrix A is marked as not having been factored. Invokes setLinearSOE(*this) on the solver. No memory is allocated for the 3 1d arrays.

int getNumEqn(void) const

A method which returns the current size of the system

int setSize(Graph &theGraph)

The size of the system is determined by invoking getNumVertex() on theGraph. If the old space allocated for the 1d arrays is not big enough, it the old space is returned to the heap and new space is allocated from the heap. Prints a warning message, sets size to 0 and returns a -1, if not enough memory is available on the heap for the 1d arrays. If memory is available, the components of the arrays are zeroed and A is marked as being unfactored. If the system size has increased, new Vector objects for x and b using the (double ,int) Vector constructor are created. Finally, the result of invoking setSize() on the associated Solver object is returned.

int addA(const Matrix &, const ID &, double fact = 1.0)

First tests that loc and M are of compatible sizes; if not a warning message is printed and a -1 is returned. The LinearSOE object then assembles fact times the Matrix M into the matrix A. The Matrix is assembled into A at the locations given by the ID object loc, i.e. a_{loc(i),loc(j)} += fact * M(i,j). If the location specified is outside the range, i.e. (-1,-1) the corresponding entry in M is not added to A. If fact is equal to 0.0 or 1.0, more efficient steps are performed. Returns 0.

int addB(const Vector &, const ID &, double fact = 1.0)

First tests that loc and V are of compatible sizes; if not a warning message is printed and a -1 is returned. The LinearSOE object then assembles fact times the Vector V into the vector b. The Vector is assembled into b at the locations given by the ID object loc, i.e. b_{loc(i)} += fact * V(i). If a location specified is outside the range, e.g. -1, the corresponding entry in V is not added to b. If fact is equal to 0.0, 1.0 or -1.0, more efficient steps are performed. Returns 0.

int setB(const Vector &, double fact = 1.0)

First tests that V and the size of the system are of compatible sizes; if not a warning message is printed and a -1 is returned. The LinearSOE object then sets the vector b to be fact times the Vector V. If fact is equal to 0.0, 1.0 or -1.0, more efficient steps are performed. Returns 0.

void zeroA(void)

Zeros the entries in the 1d array for A and marks the system as not having been factored

void zeroB(void)

Zeros the entries in the 1d array for b

const Vector& getX(void)

Returns the Vector object created for x

const Vector& getB(void)

Returns the Vector object created for b

double normRHS(void)

Returns the 2-norm of the vector x

void setX(int loc, double value)

If loc is within the range of x, sets x(loc) = value

int setFullGenSolver(FullGenLinSolver &newSolver)

friend include <FullGenLinLapackSolver.h> int sendSelf(int commitTag, Channel &theChannel)

int recvSelf(int commitTag, Channel &theChannel, FEM_ObjectBroker &theBroker)


This class has no child classes.

alphabetic index Contents

this page has been generated automatically by a slightly modified version of doc++ for OpenSees

Copyright Contact Us