Model.modent_export#

Model.modent_export(entity, file_name, options)#

Exports a modular entity and its contents using the currently loaded solver template.

Parameters:
  • entity (Entity) – The object describing the modular entity to export. Valid entities are subsystem.

  • file_name (hwString) – Full path and file name of the file to export.

  • options (hwString) –

    Optional list of quoted, comma separated option strings.

    • exporttype=<value>

    The type of exported file (value) is:

    solverdeck - An FE solver.

Example#

Export the contents of subsystem with ID 2 into an LS - DYNA deck named “ C:/export / Subsystem2_Crash5mm.k “#
import hm
import hm.entities as ent

model = hm.Model()

model.modent_export(
    entity=ent.Subsystem(model, 2),
    file_name="C:/export/Subsystem2_Crash5mm.k",
    options="exporttype=solverdeck",
)