*DMAT

*DMAT, Matrix, Type, Method, Val1, Val2, Val3, Val4, Val5
Creates a dense matrix.

Valid Products: Pro | Premium | Enterprise | PrepPost | Solver | AS add-on

Argument Descriptions

Matrix

Name used to identify the matrix. Must be specified.

Type

Matrix type:

D -- 

Double precision real values (default).

Z -- 

Complex double precision values.

I -- 

Integer values.

Method

Method used to create the matrix:

ALLOC -- 

Allocate space for a matrix (default).

RESIZE -- 

Resize an existing matrix to new row and column dimensions. Values are kept from the original matrix. If the dimensions specified by Val1 (rows) and Val2 (columns) are greater than the original matrix size, the additional entries are assigned a value of zero.

COPY -- 

Copy an existing matrix.

LINK -- 

Link to an existing matrix. The memory will be shared between the original matrix and the new matrix. This is useful for manipulating a submatrix of a larger matrix. The Val1 through Val5 arguments will be used to specify the lower and upper bounds of row and column numbers from the original matrix.

IMPORT -- 

Import the matrix from a file.

Val1, Val2, Val3, Val4, Val5

Additional input. The meaning of Val1 through Val5 will vary depending on the specified Method. See details below.

The following Valx fields are used with Method = ALLOC or Method = RESIZE:

Val1

Number of rows in the matrix.

Val2

Number of columns in the matrix.

Val3

Memory allocation type (used only with Method = ALLOC):

INCORE -- 

In-core memory allocation (default).

OUTOFCORE -- 

Out-of-core memory allocation.

The following Valx fields are used with Method = COPY:

Val1

Name of the matrix to copy.

Val2

Method used for copying the matrix:

TRANS -- 

Transpose the original matrix. Val3 and Val4 are ignored.

REAL -- 

Copy the real part to the output matrix. This option only applies when copying a complex value matrix to a real value matrix. Val3 and Val4 are ignored.

IMAG -- 

Copy the imaginary part to the output matrix. This option only applies when copying a complex value matrix to a real value matrix. Val3 and Val4 are ignored.

EXTRACT -- 

Extract a submatrix based on row and column numbers specified by Val3 and Val4.

Val3

Name of integer vector (*VEC) containing row numbers. If no vector is specified, defaults to all rows.

Val4

Name of integer vector (*VEC) containing column numbers. If no vector is specified, defaults to all columns.

The following Valx fields are used with Method = LINK:

Val1

Name of the original matrix.

Val2

First column number (defaults to 1).

Val3

Last column number (defaults to the maximum column number of the original matrix).

Val4

First row number (defaults to 1).

Val5

Last row number (defaults to the maximum row number of the original matrix).

The following table describes the Valx fields used with Method = IMPORT:

Method = IMPORT
Val1Val2Val3Val4Val5Description
FULLFile name [a]Matrix type:
STIFF - Stiffness matrix
MASS - Mass matrix
DAMP - Damping matrix
RHS - Load vector
K_RE - Real part of the stiffness matrix
K_IM - Imaginary part of the stiffness matrix
(not used)(not used)Import a matrix or load vector from an existing FULL file.
For a complex stiffness matrix, you can use the K_RE or K_IM label to import only the real part or only the imaginary part. The K_RE and K_IM options both create real matrices.
MODEFile name [a]First mode numberLast mode number(not used)Import a set of modes from an existing MODE file.
CMSFile name [a]Mode type:
NOR - Normal modes
IRF - Inertial relief modes
CST - Constraint modes
RSD - Residual modes
(not used)(not used)Import a modal basis from an existing CMS file.
TCMSFile name [a]Mode type:
NOR - Normal modes
IRF - Inertial relief modes
CST - Constraint modes
(not used)(not used)Import a modal basis from an existing TCMS file.
RSTFile name [a]First data set numberLast data set number

Result Type:

NSL - Nodal Solution
VSL - Transient velocity solution
ASL - Transient acceleration solution
RF - Reaction Forces
Import degree of freedom results from an existing RST file.
SUBFile name [a]Matrix type:
STIFF - Stiffness (or conductivity) matrix
MASS - Mass (or specific heat) matrix
DAMP - Damping matrix
RHS - Load vector
(not used)(not used)Import a matrix or load vector from an existing SUB file.
HBMATFile name [a]File format:
ASCII
BINARY
(not used)(not used)Import a matrix from an existing Harwell-Boeing format file.
EMATFile name [a]Matrix type:
STIFF - Stiffness matrix
MASS - Mass matrix
DAMP - Damping matrix
STRESS - Stress-stiffness matrix
RHS - Load vector
Element number(not used)Import an element matrix or load vector from an existing EMAT file.
MATFile name [a](not used)(not used)(not used)Restore from a previous *EXPORT (FORMAT = MAT) command.
APDLArray parameter name(not used)(not used)(not used)Import an existing array parameter.
MMFFile name [a](not used)(not used)(not used)Import a dense matrix from an existing Matrix Market file.
DMIGFile name [a]File Format:
FREE - Free field format
LARGE - Large field format (default)

(see "Notes" for examples)

Delimiter character (only for FREE field format):
’,’ - comma character (default)
’S’ - space character
Matrix name (default is the first matrix of the DMIG file)Import a matrix from an existing Nastran DMIG file.

[a] File name is case-sensitive with a 32-character maximum.

Notes

This command allows you to create a dense matrix. To create a sparse matrix, use the *SMAT command. *SMAT is recommended for large matrices obtained from the .FULL or .HBMAT file. Refer to the HBMAT command documentation for more information about .FULL file contents.

Use the *VEC command to create a vector.

For very large matrices, use the OUTOFCORE option (Method = ALLOC or COPY) to keep some of the matrix on disk if there is insufficient memory.

When importing a dense matrix from a DMIG file, you can define the formatting of the file using the Val3 and Val4 fields. Here are a few different example of formats:

  • A LARGE field format file (using Val3 = ’LARGE’):

    ...
    DMIG*   KAAX                          21               2
    *                     21               1-2.261491337E+08
    ...
  • A FREE field format file with blank separators (using Val4 = ’S’):

    ...
    DMIG stiff 1 2 1 2 29988.
    1 6 149940. 2 2 -29988.
    2 6 149940.
    ...
  • A FREE field format file with a comma separator (using Val4 = ’,’):

    ...
    DMIG,KF,22321,3,,22321,2,-5.00E+6
    DMIG,KF,22320,3,,22320,2,-5.00E+6
    ...

Requirement when importing matrices from a Nastran DMIG file: To ensure that the .sub file is properly generated from matrices imported from Nastran DMIG file, the generalized coordinates for a CMS superelement (SPOINTS in Nastran) must appear last (have highest ID number).

Menu Paths

This command cannot be accessed from a menu.