op2/result_objects Package

design_response Module

digraph inheritanced241b14d87 { bgcolor=transparent; rankdir=LR; size=""; "pyNastran.op2.result_objects.design_response.Convergence" [URL="#pyNastran.op2.result_objects.design_response.Convergence",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "pyNastran.op2.result_objects.design_response.DSCMCOL" [URL="#pyNastran.op2.result_objects.design_response.DSCMCOL",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="' ----- IDENTIFICATION OF COLUMNS IN THE DESIGN SENSITIVITY -----'"]; "pyNastran.op2.result_objects.design_response.Desvars" [URL="#pyNastran.op2.result_objects.design_response.Desvars",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "pyNastran.op2.result_objects.design_response.DisplacementResponse" [URL="#pyNastran.op2.result_objects.design_response.DisplacementResponse",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "pyNastran.op2.result_objects.design_response.FlutterResponse" [URL="#pyNastran.op2.result_objects.design_response.FlutterResponse",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "pyNastran.op2.result_objects.design_response.ForceResponse" [URL="#pyNastran.op2.result_objects.design_response.ForceResponse",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "pyNastran.op2.result_objects.design_response.PropertyResponse" -> "pyNastran.op2.result_objects.design_response.ForceResponse" [arrowsize=0.5,style="setlinewidth(0.5)"]; "pyNastran.op2.result_objects.design_response.FractionalMassResponse" [URL="#pyNastran.op2.result_objects.design_response.FractionalMassResponse",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "pyNastran.op2.result_objects.design_response.PropertyResponse" [URL="#pyNastran.op2.result_objects.design_response.PropertyResponse",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="common class for StressResponse, StrainResponse, and ForceResponse"]; "pyNastran.op2.result_objects.design_response.Responses" [URL="#pyNastran.op2.result_objects.design_response.Responses",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Defines SOL 200 responses from the R1TABRG table"]; "pyNastran.op2.result_objects.design_response.StrainResponse" [URL="#pyNastran.op2.result_objects.design_response.StrainResponse",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "pyNastran.op2.result_objects.design_response.PropertyResponse" -> "pyNastran.op2.result_objects.design_response.StrainResponse" [arrowsize=0.5,style="setlinewidth(0.5)"]; "pyNastran.op2.result_objects.design_response.StressResponse" [URL="#pyNastran.op2.result_objects.design_response.StressResponse",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "pyNastran.op2.result_objects.design_response.PropertyResponse" -> "pyNastran.op2.result_objects.design_response.StressResponse" [arrowsize=0.5,style="setlinewidth(0.5)"]; "pyNastran.op2.result_objects.design_response.WeightResponse" [URL="#pyNastran.op2.result_objects.design_response.WeightResponse",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; }
class pyNastran.op2.result_objects.design_response.Convergence(ndesign_variables)[source]

Bases: object

append(design_iter, iconvergence, conv_result, obj_initial, obj_final, constraint_max, row_constraint_max, desvar_values)[source]
get_convergence()[source]
get_stats(short: bool = False)[source]
class pyNastran.op2.result_objects.design_response.DSCMCOL(responses)[source]

Bases: object

‘ —– IDENTIFICATION OF COLUMNS IN THE DESIGN SENSITIVITY —–’ ‘ —– MATRIX THAT ARE ASSOCIATED WITH DRESP1 ENTRIES —–’ ‘’ ‘’ ‘ —– WEIGHT/VOLUME RESPONSES —–’ ‘ ——————————————’ ‘ COLUMN DRESP1 RESPONSE’ ‘ NO. ENTRY ID TYPE ‘ ‘ ——————————————’ ‘ 1 1 WEIGHT ‘ ‘’ ‘’ ‘ —– STATICS RESPONSES —–’ ‘ ————————————————————————————————————————’ ‘ COLUMN DRESP1 RESPONSE GRID/ELM VIEW COMPONENT SUB PLY ‘ ‘ NO. ENTRY ID TYPE ID ELM ID NO. CASE NO. ‘ #’ COLUMN DRESP1 RESPONSE GRID/ELM VIEW COMPONENT SUB ‘ #’ NO. ENTRY ID TYPE ID ELM ID NO. CASE ‘ ‘ ————————————————————————————————————————’ ‘ 2 2 STRESS 1 5 1’ ‘ 3 2 STRESS 3 5 1’ ‘ 4 10501 DISP 100 1 1’ ‘’ ‘’ #’ —- RETAINED DRESP2 RESPONSES —-’ #’’ #’ ———————————————————————————————————-’ #’ INTERNAL DRESP2 RESPONSE EQUATION LOWER UPPER ‘ #’ ID ID LABEL ID BOUND VALUE BOUND ‘ #’ ———————————————————————————————————-’ #’ 3 105 DISPMAG 3 -1.0000E+20 9.4677E-05 2.5000E-04’ ‘ —– IDENTIFICATION OF COLUMNS IN THE DESIGN SENSITIVITY —–’ ‘ —– MATRIX THAT ARE ASSOCIATED WITH DRESP2 ENTRIES —–’ ‘’ ‘’ ‘ ———————————————————-’ ‘ COLUMN DRESP2 SUB FREQ/ ‘ ‘ NO. ENTRY ID CASE TIME ‘ ‘ ———————————————————-’ ‘ 96 103 0 0.00000’ ‘ 97 104 0 0.00000’ ‘ 100 105 1’

internal_response_id = iresponse + 1 = column in DSCM2

property external_ids: list[int]
get_responses_by_group()[source]
get_stats(short: bool = False)[source]
property names: list[str]
class pyNastran.op2.result_objects.design_response.Desvars(desvars)[source]

Bases: object

get_stats(short: bool = False)[source]
class pyNastran.op2.result_objects.design_response.DisplacementResponse[source]

Bases: object

append(internal_id, dresp_id, response_label, region, subcase, type_flag, seid, nid, component)[source]
get_stats(short: bool = False)[source]
name = 'displacement'
class pyNastran.op2.result_objects.design_response.FlutterResponse[source]

Bases: object

append(internal_id, dresp_id, response_label, region, subcase, type_flag, seid, mode, mach, velocity, density, flutter_id)[source]
get_stats(short: bool = False)[source]
name = 'flutter'
class pyNastran.op2.result_objects.design_response.ForceResponse[source]

Bases: PropertyResponse

name = 'force'
class pyNastran.op2.result_objects.design_response.FractionalMassResponse[source]

Bases: object

append(internal_id, dresp_id, response_label, region, subcase, type_flag, seid)[source]
get_stats(short: bool = False)[source]
name = 'fractional_mass'
class pyNastran.op2.result_objects.design_response.PropertyResponse[source]

Bases: object

common class for StressResponse, StrainResponse, and ForceResponse

append(internal_id, dresp_id, response_label, region, subcase, type_flag, seid, item_code, pid)[source]
get_stats(short: bool = False)[source]
class pyNastran.op2.result_objects.design_response.Responses[source]

Bases: object

Defines SOL 200 responses from the R1TABRG table

get_stats(short: bool = False) str[source]
get_table_types()[source]
class pyNastran.op2.result_objects.design_response.StrainResponse[source]

Bases: PropertyResponse

name = 'strain'
class pyNastran.op2.result_objects.design_response.StressResponse[source]

Bases: PropertyResponse

name = 'stress'
class pyNastran.op2.result_objects.design_response.WeightResponse[source]

Bases: object

add_from_op2(out, log)[source]

Weight Response

1 IRID I Internal response identification number 2 RID I External response identification number 3 TYPE(C) I Response type 4 LABEL(2) CHAR4 Label 6 REGION I Region identifier 7 SCID I Subcase identification number 8 UNDEF(2) I Not used 10 SEID I Superelement identification number or ALL 11 UNDEF(2) I Not used

13 UNDEF I Not used 14 TYFLG I Flag to indicate how response is referenced 15 SEID I Superelement identificaiton number

—> 3i 8s 7i 3i

# —– WEIGHT RESPONSE —– # ——————————————————————————— # INTERNAL DRESP1 RESPONSE ROW COLUMN LOWER INPUT OUTPUT UPPER # ID ID LABEL ID ID BOUND VALUE VALUE BOUND # ——————————————————————————— # 1 1 WEIGHT 3 3 N/A 2.9861E+05 2.9852E+05 N/A

# ? ? ? LABEL? ? ? ROW_ID? COL_ID? ? ? ? ? ? ? #(1, 1, 1, ‘WEIGHT ‘, 0, 1011, 3, 3, 0, 0, 0, 0, 0, 0) #(1, 1000, 1, ‘W ‘, 0, 1, 3, 3, 0, 0, 0, 0, 0, 0) # # per dev forum; 538976288 is probably just ‘ ‘ #(1, 1, 1, ‘WEIGHT ‘, 0, 1, 3, 3, 0, 0, 538976288, 538976288, 0, 0)

append(internal_id, dresp_id, response_label, region, subcase, type_flag, seid, row_id, column_id)[source]
get_stats(short: bool = False)[source]

grid_point_weight Module

#.. inheritance-diagram:: pyNastran.op2.result_objects.grid_point_weight

defines the GridPointWeight class

class pyNastran.op2.result_objects.grid_point_weight.GridPointWeight(reference_point: int, MO: ndarray, S: ndarray, mass: ndarray, cg: ndarray, IS: ndarray, IQ: ndarray, Q: ndarray, approach_code: int = 1, table_code: int = 13, title: str = '', subtitle: str = '', label: str = '', superelement_adaptivity_index: str = '')[source]
export_to_hdf5(group, log) None[source]

exports the object to HDF5 format

get_stats(key: str = '', short: bool = True) str[source]
object_attributes(mode: str = 'public', keys_to_skip=None, filter_properties: bool = False) list[str][source]
object_methods(mode: str = 'public', keys_to_skip=None)[source]
write_f06(f06_file: TextIO, page_stamp: str, page_num: int) int[source]

writes the f06

Parameters:
f06_filefile / StringIO

a file-like object

page_stampstr

the page formatter (e.g., ‘PAGE %i’)

page_numint

the active page number

Returns:
page_numint

the new page number

write_op2(op2_file: BinaryIO, op2_ascii: TextIO, date: tuple[int, int, int], endian: bytes = b'<') int[source]
pyNastran.op2.result_objects.grid_point_weight.make_grid_point_weight(reference_point: int, MO: ndarray, approach_code: int = 1, table_code: int = 13, title: str = '', subtitle: str = '', label: str = '', superelement_adaptivity_index: str = '') GridPointWeight[source]

creates a grid point weight table

# :show-inheritance:

matrix Module

#.. inheritance-diagram:: pyNastran.op2.result_objects.matrix

Defines the Matrix class

class pyNastran.op2.result_objects.matrix.Matrix(name: str, form: int | str, data: ndarray | coo_matrix | None = None)[source]
Defines a Matrix object that’s stored in:
  • op4.matrices

  • op2.matrices

Attributes:
namestr

the name of the matrix

datavaries

dense : np.ndarray sparse : coo_matrix data is generally initialized by setting the matrix.data attribute externally

is_matpoolbool

is this a matpool matrix? A matpool has (grid, component) values similar to a DMIG. A non-matpool matrix is similar to a DMI.

Initializes a Matrix

Parameters:
namestr

the name of the matrix

formint

the matrix type

is_matpoolbool

is this a matpool matrix? A matpool has (grid, component) values similar to a DMIG. A non-matpool matrix is similar to a DMI.

+——+—————–+
| Form | Meaning |
+======+=================+
| 1 | Square |
| 2 | Rectangular |
| 6 | Symmetric |
| 9 | Pseudo identity |
+——+—————–+
property Complex: ndarray
property GCi: ndarray
property GCi_GCj: tuple[ndarray, ndarray]
property GCj: ndarray
property Real: ndarray
build_dataframe()[source]

exports the object to pandas format

data_i_j() tuple[ndarray, ndarray, ndarray][source]
property dtype_str: str
export_to_hdf5(group, log) None[source]

exports the object to HDF5 format

property is_complex: bool
property is_dense
property is_real: bool

1-Real, Single Precision 2=Real, Double Precision 3=Complex, Single 4=Complex, Double

property is_sparse
object_attributes(mode: str = 'public', keys_to_skip=None, filter_properties: bool = False)[source]
object_methods(mode: str = 'public', keys_to_skip=None)[source]
set_matpool_data(data: ndarray, col_nid: ndarray, col_dof: ndarray, row_nid: ndarray, row_dof: ndarray) None[source]
property shape: tuple[int, int]
property shape_str: str

gets the matrix description

symmetric_to_rectangular(log: SimpleLogger)[source]

enforce symmetry if necessary

property tin: int
to_dense() None[source]
to_gcj_gci_form()[source]

once in matrix form, we need to transform to GCj, GCi, Real/Complex form

to_sparse(sparse_type: str = 'coo') None[source]
write(mat, print_full: bool = True) None[source]

writes to the F06

write_dmi(size: int = 8) str[source]
DMI Notes:
  • Additional Forms: - 3 = Diagonal matrix (elements on the diagonal are stored in a column vector having m rows) - 4 = Lower triangular factor - 5 = Upper triangular factor - 8 = Identity matrix (m = number of rows, n = m)

  • The total number of DMIs and DTIs may not exceed 1000.

  • For symmetric matrices, the entire matrix must be input.

  • Form 7 matrices may not be defined on this entry.

  • Form 3 matrices are converted to Form 6 matrices, which may be used by any module.

  • The DMIG entry is more convenient for matrices with rows and columns that are referenced by grid or scalar point degrees-of-freedom.

pyNastran.op2.result_objects.matrix.form_to_int(form: str) int[source]

gets the matrix description

pyNastran.op2.result_objects.matrix.sparse_symmetric_to_rectangular(matrix: sparse_types, log: SimpleLogger)[source]

# :show-inheritance:

monpnt Module

#.. inheritance-diagram:: pyNastran.op2.result_objects.monpnt

class pyNastran.op2.result_objects.monpnt.MONPNT1(frequencies, matrices, comp_matrices)[source]

MONPNT1 table

write(f06_file, page_stamp: str = '', page_num: int = 1)[source]
class pyNastran.op2.result_objects.monpnt.MONPNT3(frequencies, matrix)[source]

MONPNT3 table

write(f06_file, page_stamp: str = '', page_num: int = 1)[source]

# :show-inheritance: