CompositeModel#
- class ansys.dpf.composites.composite_model.CompositeModel(composite_files, server, default_unit_system=None)#
Provides access to the basic composite postprocessing functionality.
On initialization, the
CompositeModel
class automatically adds composite lay-up information to the meshed regions. It prepares the providers for different lay-up properties so that they can be efficiently evaluated. The composite_files provided are automatically uploaded to the server if needed.Note
When creating a
CompositeModel
instance, several providers are created and lay-up information is added to the DPF meshed regions. Depending on the use case, it can be more efficient to create the providers separately.The handling of models with multiple composite definition files (assemblies) differ depending on the version of the DPF server. The handling is simplified with DPF Server 7.0 (2024 R1) or later and the full assembly can be post-processed in the same way as a model with a single ACP model.
Before DPF Server 7.0 (2024 R1):
For assemblies with multiple composite definition files, separate meshes and lay-up operators are generated (wrapped by the
CompositeInfo
class). This is needed because the lay-up provider can only add the data of a single composite definitions file to a mesh. All functions that depend on composite definitions mut be called with the correctcomposite_definition_label
parameter. The layered elements that get information from a given composite definition label can be determined by callingCompositeModel.get_all_layered_element_ids_for_composite_definition_label()
. All the elements that are not part of a composite definition are either homogeneous solids or layered models defined outside of an ACP model. TheCompositeModel.composite_definition_labels()
command returns all available composite definition labels. For more information, see Postprocess an assembly.- Parameters:
composite_files (
ContinuousFiberCompositesFiles
) – Use theget_composite_files_from_workbench_result_folder()
function to obtain theContinuousFiberCompositesFiles
object.server (
BaseServer
) – DPF Server on which the model is createddefault_unit_system (
Optional
[UnitSystem
], default:None
) – Unit system that is used if the result file does not specify the unit system. This happens for pure MAPDL projects.
Methods
Add interlaminar normal stresses to the stresses fields container.
Get a fields container with the evaluated failure criteria.
Get all element IDs with lay-up data.
CompositeModel.get_all_layered_element_ids_for_composite_definition_label
([...])Get all layered element IDs that belong to a composite definition label.
CompositeModel.get_analysis_plies
(element_id)Get analysis ply names.
Get a dictionary with constant properties.
CompositeModel.get_element_info
(element_id)Get element information for an element ID.
Get the laminate offset of an element.
Get the lay-up operator.
CompositeModel.get_mesh
([...])Get the underlying DPF meshed region.
Get a layer property for an element ID.
Get the times or frequencies in the result file.
CompositeModel.get_sampling_point
(...[, ...])Get a sampling point for an element ID and failure criteria.
Attributes
All composite definition labels in the model.
Get the composite file paths on the server.
Underlying DPF core model.
Composite data sources.
Get the context type of the lay-up model.
DPF material ID to metadata map of the materials.
Material name to DPF material ID map.
Material operators.