JavaView© v3.95.000

jvx.numeric
Class PnMassMatrix

java.lang.Object
  extended byjv.object.PsObject
      extended byjvx.numeric.PnSparseMatrix
          extended byjvx.numeric.PnStiffMatrix
              extended byjvx.numeric.PnMassMatrix
All Implemented Interfaces:
java.lang.Cloneable, PsUpdateIf, java.io.Serializable

public class PnMassMatrix
extends PnStiffMatrix

Mass matrix of triangulated surface and functions linear in each triangle. To recompute the matrix after position of vertices changed call init. If combinatorics change a constructor must be called again.

A diagonalization method is available useLumpedMass.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class jvx.numeric.PnStiffMatrix
m_noe
 
Fields inherited from class jvx.numeric.PnSparseMatrix
m_nop, m_sindx, m_snoe, m_stiff
 
Fields inherited from class jv.object.PsObject
HAS_CONFIG_PANEL, HAS_INFO_PANEL, HAS_LABEL_PANEL, HAS_MATERIAL_PANEL, HAS_TEXTURE_PANEL, HAS_VECTOR_PANEL, INSPECTOR_INFO, INSPECTOR_INFO_EXT, IS_DELETED, IS_FIXED, IS_FOCUSSED, IS_PICKED, IS_SELECTED, IS_USED, NUM_TAGS
 
Constructor Summary
PnMassMatrix(PgElementSet surface)
          Constructor computes mass matrix with respect to the actual surface.
PnMassMatrix(PgElementSet surface, boolean useLumped)
          Constructor computes mass matrix with respect to the actual surface.
 
Method Summary
 PnBiconjugateGradient getSolver()
          Get class that computes the inverse mass matrix.
 void init(PgElementSet surface)
          Initializes the stiffness matrix by computing the index vector and matrix entries.
 boolean isUsingLumpedMass()
          Check if usage of the lumped mass matrix is enabled.
 PdVector[] multInvMassMatrix(PdVector[] vec)
          Multiply vertex-based vector field with inverse mass matrix.
static PdMatrix[] multInvMassMatrix(PgElementSet geom, PdMatrix[] tensor, boolean useLumped)
          Multiply vertex-based tensor field with inverse mass matrix.
static PdVector[] multInvMassMatrix(PgElementSet geom, PdVector[] vec, boolean useLumped)
          Multiply vertex-based vector field with inverse mass matrix.
static PdVector multInvMassMatrix(PgElementSet geom, PdVector vec, boolean useLumped)
          Multiply vertex-based function with inverse mass matrix.
 void useLumpedMass(boolean flag)
          Enable/Disable usage of the lumped mass matrix.
 
Methods inherited from class jvx.numeric.PnStiffMatrix
init
 
Methods inherited from class jvx.numeric.PnSparseMatrix
diagonalSolve, getIndex, leftMult, leftMult, multScalar, rightMult, rightMult, toString
 
Methods inherited from class jv.object.PsObject
addInspector, addUpdateListener, assureInspector, clearTag, clone, clone, clone, copy, getFather, getInfoPanel, getInspector, getName, getNumObjects, getSymbol, hasInspector, hasTag, hasUpdateListener, init, instanceOf, instanceOf, newInspector, newInspector, removeInspector, removeInspector, removeUpdateListener, setName, setParent, setSymbol, setTag, update, updatePanels
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

PnMassMatrix

public PnMassMatrix(PgElementSet surface)
Constructor computes mass matrix with respect to the actual surface.


PnMassMatrix

public PnMassMatrix(PgElementSet surface,
                    boolean useLumped)
Constructor computes mass matrix with respect to the actual surface. If useLumped is true a diagonalized mass matrix is used useLumpedMass.

Method Detail

init

public void init(PgElementSet surface)
Initializes the stiffness matrix by computing the index vector and matrix entries. Method can be used to reset the stiffness matrix. All memory allocation is done in constructor.

Overrides:
init in class PnStiffMatrix

useLumpedMass

public void useLumpedMass(boolean flag)
Enable/Disable usage of the lumped mass matrix. The lumped mass matrix is diagonalized. The entry on diagonal of the lumped mass matrix is the sum of all entries of one row of the mass matrix. This method does not re-initialize (recompute) the matrix, init method must be called elseware.


isUsingLumpedMass

public boolean isUsingLumpedMass()
Check if usage of the lumped mass matrix is enabled. The lumped mass matrix is diagonalized. The entry on diagonal of the lumped mass matrix is the sum of all entries of one row of the mass matrix.


getSolver

public PnBiconjugateGradient getSolver()
Get class that computes the inverse mass matrix.

See Also:
multInvMassMatrix(PdVector[]), multInvMassMatrix(PgElementSet, PdMatrix[], boolean), multInvMassMatrix(PgElementSet, PdVector[], boolean)

multInvMassMatrix

public PdVector[] multInvMassMatrix(PdVector[] vec)
Multiply vertex-based vector field with inverse mass matrix. The array given as a pararmeter should specify a PdVector for each vertex of the surface, i.e. a vertex-based vector field on the surface.

Parameters:
vec - Length of the array must equal the number of vertices of the surface, the mass matrix is computed from. All vector must have the same length.

multInvMassMatrix

public static PdVector multInvMassMatrix(PgElementSet geom,
                                         PdVector vec,
                                         boolean useLumped)
Multiply vertex-based function with inverse mass matrix. The vector given as a pararmeter should specify a value for each vertex of the surface. Using the full mass matrix has not been implemented yet.

Parameters:
vec - vector specifies a function value for each vertex of the geometry.

multInvMassMatrix

public static PdVector[] multInvMassMatrix(PgElementSet geom,
                                           PdVector[] vec,
                                           boolean useLumped)
Multiply vertex-based vector field with inverse mass matrix. The array given as a pararmeter should specify a PdVector for each vertex of the surface, i.e. a vertex-based vector field on the surface.

Parameters:
vec - length of the array must equal the number of vertices of the surface, the mass matrix is computed from. All vector must have the same length.

multInvMassMatrix

public static PdMatrix[] multInvMassMatrix(PgElementSet geom,
                                           PdMatrix[] tensor,
                                           boolean useLumped)
Multiply vertex-based tensor field with inverse mass matrix. The array given as a pararmeter should specify a PdVector for each vertex of the surface, i.e. a vertex-based vector field on the surface.

Only usage of lumped mass matrix is implemented yet.

Parameters:
tensor - length of the array must equal the number of vertices of the surface, the mass matrix is computed from. All vector must have the same length.

JavaView© v3.95.000

The software JavaView© is copyright protected. All Rights Reserved.