cratepy.ioput.incoutputfiles.refmatoutput.RefMatOutput

class RefMatOutput(file_path, strain_formulation, problem_type, self_consistent_scheme='regression', ref_output_mode='converged')[source]

Bases: IncrementalOutputFile

Output file: Homogeneous (fictitious) reference material data.

_file_path

Output file path.

Type:

str

_header

List containing the header of each column (str).

Type:

list[str]

_col_width

Output file column width.

Type:

int

_n_dim

Problem number of spatial dimensions.

Type:

int

_comp_order_sym

Strain/Stress components symmetric order.

Type:

list[str]

_comp_order_nsym

Strain/Stress components nonsymmetric order.

Type:

list[str]

init_file(self)[source]

Open reference material output file and write file header.

write_mat(self, inc, ref_material, hom_strain_mf, hom_stress_mf, eff_tangent_mf=None, farfield_strain_mf=None, applied_mac_load_strain_mf=None)

Write reference material output file.

rewind_file(self, rewind_inc)[source]

Rewind reference material output file.

Constructor.

Parameters:
  • file_path (str) – Output file path.

  • strain_formulation ({'infinitesimal', 'finite'}) – Problem strain formulation.

  • problem_type (int) – Problem type: 2D plane strain (1), 2D plane stress (2), 2D axisymmetric (3) and 3D (4).

  • self_consistent_scheme ({'regression',}, default='regression') – Self-consistent scheme to update the elastic reference material properties.

  • ref_output_mode ({'iterative', 'converged'}, default='converged') –

    Output mode:

    • ’iterative’ : outputs the reference material quantities at every self-consistent scheme iteration

    • ’converged’ : outputs the reference material quantities that converged at each loading increment

List of Public Methods

init_file

Open output file and write file header.

rewind_file

Rewind output file.

write_file

Write output file.

Methods

__init__(file_path, strain_formulation, problem_type, self_consistent_scheme='regression', ref_output_mode='converged')[source]

Constructor.

Parameters:
  • file_path (str) – Output file path.

  • strain_formulation ({'infinitesimal', 'finite'}) – Problem strain formulation.

  • problem_type (int) – Problem type: 2D plane strain (1), 2D plane stress (2), 2D axisymmetric (3) and 3D (4).

  • self_consistent_scheme ({'regression',}, default='regression') – Self-consistent scheme to update the elastic reference material properties.

  • ref_output_mode ({'iterative', 'converged'}, default='converged') –

    Output mode:

    • ’iterative’ : outputs the reference material quantities at every self-consistent scheme iteration

    • ’converged’ : outputs the reference material quantities that converged at each loading increment

init_file()[source]

Open output file and write file header.

rewind_file(rewind_inc)[source]

Rewind output file.

Parameters:

rewind_inc (int) – Increment associated with the rewind state.

write_file(inc, ref_material, hom_strain_mf, hom_stress_mf, farfield_strain_mf, applied_mac_load_strain_mf, eff_tangent_mf=None)[source]

Write output file.

Parameters:
  • inc (int) – Loading increment.

  • ref_material (ElasticReferenceMaterial) – Elastic reference material.

  • hom_strain_mf (numpy.ndarray (1d)) – Homogenized strain tensor (matricial form): infinitesimal strain tensor (infinitesimal strains) or deformation gradient (finite strains).

  • hom_stress_mf (numpy.ndarray (1d)) – Homogenized stress tensor (matricial form): Cauchy stress tensor (infinitesimal strains) or first Piola-Kirchhoff stress tensor (finite strains).

  • farfield_strain_mf (numpy.ndarray (1d)) – Far-field strain tensor (matricial form).

  • applied_mac_load_strain_mf (numpy.ndarray (1d)) – Prescribed loading strain tensor (matricial form).

  • eff_tangent_mf (numpy.ndarray (2d), default=None) – CRVE effective material tangent modulus (matricial form).