jvx.numeric

## Class PnMassMatrix

- java.lang.Object
- - jv.object.PsObject
  - - jvx.numeric.PnSparseMatrix
    - - jvx.numeric.PnStiffMatrix
      - - jvx.numeric.PnMassMatrix

- All Implemented Interfaces:
    java.io.Serializable, java.lang.Cloneable, PsUpdateIf, PdMatrixIf

      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
  Author:
    Klaus Hildebrandt
  Version:
    12.12.06, 1.10 revised (ah) added method multInvMassMatrix(PdVector).
    11.03.03, 1.00 created (kh)

- - ### Field Summary

    - ### Fields inherited from class jvx.numeric.PnStiffMatrix

      `m_noe`

    - ### Fields inherited from class jvx.numeric.PnSparseMatrix

      `USE_LARGER_BUFFER`

    - ### Fields inherited from class jv.object.PsObject

      `HAS_BOUNDARY_PANEL, 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

    Constructors
    Constructor and Description
    `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

    All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods
    Modifier and Type | Method and Description
    --- | ---
    `static PdVector` | `getInvLumpedMassMatrix(PgElementSet geom, PdVector invMass)`
    `static PdVector` | `getLumpedMassMatrix(PgElementSet geom, PdVector diagonalMass)`
    `PnBiconjugateGradient` | `getSolver()` Get class that computes the inverse mass matrix.
    `void` | `init()` Initializes the stiffness matrix by computing the index vector and matrix entries.
    `void` | `init(PgElementSet surface)` Deprecated. Since JavaView 3.91, use `init()`.
    `boolean` | `isUsingLumpedMass()` Check if usage of the lumped mass matrix is enabled.
    `PdVector` | `multInvMassMatrix(PdVector vec)`
    `PdVector[]` | `multInvMassMatrix(PdVector[] vec)` Multiply vertex-based vector field with inverse mass matrix.
    `PdVector` | `multInvMassMatrix(PdVector vec, int dim)` Multiply piecewise linear function (mapping to Rn) 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

      `computeRightVector, computeStiffnessMatrix, init`

    - ### Methods inherited from class jvx.numeric.PnSparseMatrix

      `add, add, addDiagonal, addDiagonal, addEntry, addNew, appendEntry, clear, clearColumn, clearRow, compress, concatMatrices, copy, copyNew, deleteColumn, deleteRow, extractRows, getColIndex, getColIndices, getColIndices, getDiagIndex, getEntries, getEntries, getEntry, getEntrySparse, getIndex, getNumCols, getNumEntries, getNumEntries, getNumRows, isEqualTo, isSquare, leftMultMatrix, leftMultVector, leftMultVector, leftMultVector, leftMultVector, multMatrices, multQuadratic, multScalar, multScalar, removeZeros, rightMultMatrix, rightMultVector, rightMultVector, rightMultVector, rightMultVector, setEntry, setEntrySparse, setNumEntries, setRow, setSize, setSize, setSize, sortEntries, sub, subNew, toPdMatrix, toShortString, toString, transpose, transpose, transposeNew, transposeNew, validate, vstackSparseMatrices`

    - ### Methods inherited from class jv.object.PsObject

      `addInspector, addUpdateListener, assureInspector, clearTag, clone, clone, clone, copy, getFather, getInfoPanel, getInspector, getName, getNumObjects, getSymbol, hasInspector, hasTag, hasUpdateListener, 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)

      Deprecated. Since JavaView 3.91, use `init()`.
      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`

    - #### init

          public void init()

      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 `PsObject`

    - #### 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 recomputes the matrix and adjusts the size of the arrays representing the matrix.

    - #### 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 PdVector multInvMassMatrix(PdVector vec)

    - #### multInvMassMatrix

          public PdVector multInvMassMatrix(PdVector vec,
                                            int dim)

      Multiply piecewise linear function (mapping to Rn) with inverse mass matrix. The array given as a parameter should specify a n function values for each vertex of the surface.
      Parameters:
        `vec` - Length of the array must equal dim*number of vertices of the surface.
        `dim` - Dimension of the image space.

    - #### 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.

    - #### getInvLumpedMassMatrix

          public static PdVector getInvLumpedMassMatrix(PgElementSet geom,
                                                        PdVector invMass)

    - #### getLumpedMassMatrix

          public static PdVector getLumpedMassMatrix(PgElementSet geom,
                                                     PdVector diagonalMass)

"

The software JavaView? is copyright protected. All Rights Reserved.
"