Class EJ_AMatrix

Inheritance Relationships

Base Type

Class Documentation

class EJ_AMatrix : public AMatrix

A class which represents the linear system which must be solved to obtain the jumps in the explicit jump method.

Public Functions

EJ_AMatrix(puma::Matrix<double> *kMat, char dir, int numThreads)

A constructor which takes in the parameters used in solving for the jumps.

Parameters
  • kMat – a pointer to a puma matrix containing the conductivity at each cell.

  • dir – a char indicating the direction of the simulation.

  • numThreads – an integer indicating the number of threads used.

virtual bool A_times_X(puma::Matrix<double> *x, puma::Matrix<double> *r)

multiplies the linear system by a vector.

Parameters
  • x – a pointer to a puma matrix that is multiplied by the linear system.

  • r – a pointer to a puma matrix where the solution is stored.

Returns

a boolean which is true if no errors are encountered.

inline virtual bool Minv_times_X(puma::Matrix<double> *x, puma::Matrix<double> *r)
puma::Vec3<double> computeConductivity(puma::Matrix<double> *T, puma::Matrix<double> *J)

computes the effective conductivity from the solution.

Parameters
  • T – a pointer to a puma matrix containing the solution.

  • J – a pointer to a puma matrix containing the jumps.

Returns

a puma vector containing the thermal conductivity in the x, y, and z directions.

bool setup()

preallocates and sets up matrices for explicit jump method.

Returns

a boolean which is true if no errors are encountered.

bool free()
long getNumInterfaces()

finds the total number of interfaces at which jumps occur.

Returns

a long containing the total number of interfaces.

void getF(puma::Matrix<double> *FOut)

returns F in a puma matrix.

Parameters

FOut – a pointer to a puma matrix into which the values of F will be placed.

void computeHomogenizedSolution(puma::Matrix<double> *T, puma::Matrix<double> *J)

computes the homogenized solution and stores it in a puma matrix.

Parameters
  • T – a pointer to a puma matrix which stores the solution.

  • J – a pointer to a puma matrix containing the jumps.