    

 ## On this page

  

 

 # result:compute total strain X

 Last update: 31.07.2026 

**Version: 0.0.0**

## Description

Computes the strain from a displacement field. Only SOLID185 (B-Bar, Simplified Enhanced Strain, Enhanced Strain formulations), SOLID186 (Full Integration) &amp; SOLID187 elements are supported. Layered elements are not supported. Thermal strains are not supported. Only one value of material properties are allowed per element for isotropic and orthotropic elasticity. Material nonlinearity is not supported Only linear analysis are supported without On Demand Expansion. All coordinates are global coordinates. Euler Angles need to be included in the database. Get the XX normal component (00 component).

## Inputs

This table lists the input pins for this operator. Input pins define the data that the operator requires to perform its operation. Some inputs are required, while others are optional and provide additional configuration. Each parameter is detailed in the sections that follow the table.

Pin numberNameStatusExpected type(s)0[time\_scoping](#input_0)[`scoping`](../../core-concepts/dpf-types.md#scoping), [`int32`](../../core-concepts/dpf-types.md#standard-types), [`vector<int32>`](../../core-concepts/dpf-types.md#standard-types), [`double`](../../core-concepts/dpf-types.md#standard-types), [`field`](../../core-concepts/dpf-types.md#field), [`vector<double>`](../../core-concepts/dpf-types.md#standard-types)**1**[scoping](#input_1)[`scoping`](../../core-concepts/dpf-types.md#scoping)**3**[streams\_container](#input_3)[`streams_container`](../../core-concepts/dpf-types.md#streams-container)**4**[data\_sources](#input_4)Required[`data_sources`](../../core-concepts/dpf-types.md#data-sources)**5**[extrapolate](#input_5)[`int32`](../../core-concepts/dpf-types.md#standard-types)**6**[nonlinear](#input_6)[`int32`](../../core-concepts/dpf-types.md#standard-types)**7**[abstract\_meshed\_region](#input_7)[`abstract_meshed_region`](../../core-concepts/dpf-types.md#meshed-region)**9**[requested\_location](#input_9)[`string`](../../core-concepts/dpf-types.md#standard-types)**10**[displacement](#input_10)[`fields_container`](../../core-concepts/dpf-types.md#fields-container), [`field`](../../core-concepts/dpf-types.md#field)<a id="input_0"></a>

### time\_scoping (Pin 0)

- **Required:** No
- **Expected type(s):** [`scoping`](../../core-concepts/dpf-types.md#scoping), [`int32`](../../core-concepts/dpf-types.md#standard-types), [`vector<int32>`](../../core-concepts/dpf-types.md#standard-types), [`double`](../../core-concepts/dpf-types.md#standard-types), [`field`](../../core-concepts/dpf-types.md#field), [`vector<double>`](../../core-concepts/dpf-types.md#standard-types)

time/freq values (use doubles or field), time/freq set ids (use ints or scoping) or time/freq step ids (use scoping with TimeFreq\_steps location) required in output. To specify time/freq values at specific load steps, put a Field (and not a list) in input with a scoping located on "TimeFreq\_steps". Linear time freq intrapolation is performed if the values are not in the result files and the data at the max time or freq is taken when time/freqs are higher than available time/freqs in result files. To get all data for all time/freq sets, connect an int with value -1.. Will only be used if no displacement input is given (will be applied on displacement operator).

<a id="input_1"></a>

### scoping (Pin 1)

- **Required:** No
- **Expected type(s):** [`scoping`](../../core-concepts/dpf-types.md#scoping)

The element scoping on which the result is computed.

<a id="input_3"></a>

### streams\_container (Pin 3)

- **Required:** No
- **Expected type(s):** [`streams_container`](../../core-concepts/dpf-types.md#streams-container)

Optional if a mesh or a data\_sources have been connected. Required if no displacement input have been connected.

<a id="input_4"></a>

### data\_sources (Pin 4)

- **Required:** Yes
- **Expected type(s):** [`data_sources`](../../core-concepts/dpf-types.md#data-sources)

Optional if a mesh or a streams\_container have been connected, or if the displacement's field has a mesh support. Required if no displacement input have been connected.

<a id="input_5"></a>

### extrapolate (Pin 5)

- **Required:** No
- **Expected type(s):** [`int32`](../../core-concepts/dpf-types.md#standard-types)

Whether to extrapolate the data from the integration points to the nodes.

<a id="input_6"></a>

### nonlinear (Pin 6)

- **Required:** No
- **Expected type(s):** [`int32`](../../core-concepts/dpf-types.md#standard-types)

Whether to use nonlinear geometry or nonlinear material (1 = large strain, 2 = hyperelasticity).

<a id="input_7"></a>

### abstract\_meshed\_region (Pin 7)

- **Required:** No
- **Expected type(s):** [`abstract_meshed_region`](../../core-concepts/dpf-types.md#meshed-region)

The underlying mesh. Optional if a data\_sources or a streams\_container have been connected, or if the displacement's field has a mesh support.

<a id="input_9"></a>

### requested\_location (Pin 9)

- **Required:** No
- **Expected type(s):** [`string`](../../core-concepts/dpf-types.md#standard-types)

Average the Elemental Nodal result to the requested location.

<a id="input_10"></a>

### displacement (Pin 10)

- **Required:** No
- **Expected type(s):** [`fields_container`](../../core-concepts/dpf-types.md#fields-container), [`field`](../../core-concepts/dpf-types.md#field)

Field/or fields container containing only the displacement field (nodal). If none specified, read displacements from result file using the data\_sources.

## Outputs

This table lists the output pins for this operator. Output pins provide the results of the operator's computation and can be connected to inputs of other operators or retrieved for further processing. Each output is detailed in the sections that follow the table.

Pin numberNameExpected type(s)0[fields\_container](#output_0)[`fields_container`](../../core-concepts/dpf-types.md#fields-container)<a id="output_0"></a>

### fields\_container (Pin 0)

- **Expected type(s):** [`fields_container`](../../core-concepts/dpf-types.md#fields-container)

The computed result fields container (elemental nodal).

## Configurations

This operator supports [configuration options](../../core-concepts/operator-configurations.md) that modify its behavior.

### [mutex](../../core-concepts/operator-configurations.md#mutex)

- **Expected type(s):** [`bool`](../../core-concepts/dpf-types.md#standard-types)
- **Default value:** false

If this option is set to true, the shared memory is prevented from being simultaneously accessed by multiple threads.

### [run\_in\_parallel](../../core-concepts/operator-configurations.md#run_in_parallel)

- **Expected type(s):** [`bool`](../../core-concepts/dpf-types.md#standard-types)
- **Default value:** true

Loops are allowed to run in parallel if the value of this config is set to true.

## Scripting

This operator can be accessed through scripting interfaces using these identifiers.

**Category**: result

**Plugin**: live post

**Scripting name**: compute\_total\_strain\_X

**Full name**: result.compute\_total\_strain\_X

**Internal name**: compute\_total\_strain\_X

**License**: None

## Examples

These examples demonstrate how to use this operator in different programming environments. Each example shows how to instantiate the operator, connect the required inputs, and retrieve the output.

C++```cpp
#include "dpf_api.h"

ansys::dpf::Operator op("compute_total_strain_X"); // operator instantiation
op.connect(0, my_time_scoping);
op.connect(1, my_scoping);
op.connect(3, my_streams_container);
op.connect(4, my_data_sources);
op.connect(5, my_extrapolate);
op.connect(6, my_nonlinear);
op.connect(7, my_abstract_meshed_region);
op.connect(9, my_requested_location);
op.connect(10, my_displacement);
ansys::dpf::FieldsContainer my_fields_container = op.getOutput<ansys::dpf::FieldsContainer>(0);

```

CPython```python
import ansys.dpf.core as dpf

op = dpf.operators.result.compute_total_strain_X() # operator instantiation
op.inputs.time_scoping.connect(my_time_scoping)
op.inputs.scoping.connect(my_scoping)
op.inputs.streams_container.connect(my_streams_container)
op.inputs.data_sources.connect(my_data_sources)
op.inputs.extrapolate.connect(my_extrapolate)
op.inputs.nonlinear.connect(my_nonlinear)
op.inputs.abstract_meshed_region.connect(my_abstract_meshed_region)
op.inputs.requested_location.connect(my_requested_location)
op.inputs.displacement.connect(my_displacement)
my_fields_container = op.outputs.fields_container()

```

IPython```python
import mech_dpf
import Ans.DataProcessing as dpf

op = dpf.operators.result.compute_total_strain_X() # operator instantiation
op.inputs.time_scoping.Connect(my_time_scoping)
op.inputs.scoping.Connect(my_scoping)
op.inputs.streams_container.Connect(my_streams_container)
op.inputs.data_sources.Connect(my_data_sources)
op.inputs.extrapolate.Connect(my_extrapolate)
op.inputs.nonlinear.Connect(my_nonlinear)
op.inputs.abstract_meshed_region.Connect(my_abstract_meshed_region)
op.inputs.requested_location.Connect(my_requested_location)
op.inputs.displacement.Connect(my_displacement)
my_fields_container = op.outputs.fields_container.GetData()

```

  
## Changelog

- Version 0.0.0: Initial release.