> ## Documentation Index
> Fetch the complete documentation index at: https://developer.synopsys.com/llms.txt
> Use this file to discover all available pages before exploring further.

# result:compute stress von mises

**Version: 0.0.0**

## Description

Computes the stress from an elastic strain field. compute\_total\_strain limitations are applicable for stress computationGet the Von Mises equivalent stress.

## 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 number | Name | Status | Expected type(s) |
| - | - | - | - |
| **1** | [scoping](#input_1) | | [`scoping`](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/dpf-types#scoping) |
| **3** | [streams\_container](#input_3) | | [`streams_container`](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/dpf-types#streams-container) |
| **4** | [data\_sources](#input_4) | | [`data_sources`](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/dpf-types#data-sources) |
| **9** | [requested\_location](#input_9) | | [`string`](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/dpf-types#standard-types) |
| **10** | [strain](#input_10) | Required | [`fields_container`](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/dpf-types#fields-container), [`field`](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/dpf-types#field) |

### scoping (Pin 1)

* **Required:** No
* **Expected type(s):** [`scoping`](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/dpf-types#scoping)

The element scoping on which the result is computed.

### streams\_container (Pin 3)

* **Required:** No
* **Expected type(s):** [`streams_container`](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/dpf-types#streams-container)

Needed to get mesh and material ids. Optional if a data\_sources have been connected.

### data\_sources (Pin 4)

* **Required:** No
* **Expected type(s):** [`data_sources`](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/dpf-types#data-sources)

Needed to get mesh and material ids. Optional if a streams\_container have been connected.

### requested\_location (Pin 9)

* **Required:** No
* **Expected type(s):** [`string`](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/dpf-types#standard-types)

Average the Elemental Nodal result to the requested location.

### strain (Pin 10)

* **Required:** Yes
* **Expected type(s):** [`fields_container`](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/dpf-types#fields-container), [`field`](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/dpf-types#field)

Field/or fields container containing only the elastic strain field (element nodal).

## 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 number | Name | Expected type(s) |
| - | - | - |
| **0** | [fields\_container](#output_0) | [`fields_container`](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/dpf-types#fields-container) |

### fields\_container (Pin 0)

* **Expected type(s):** [`fields_container`](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/dpf-types#fields-container)

The computed result fields container (elemental nodal).

## Configurations

This operator supports [configuration options](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/operator-configurations.md) that modify its behavior.

### [mutex](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/operator-configurations.md#mutex)

* **Expected type(s):** [`bool`](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/dpf-types#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](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/operator-configurations.md#run_in_parallel)

* **Expected type(s):** [`bool`](https://developer.synopsys.com/docs/dpf/dpf-framework/core-concepts/dpf-types#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\_stress\_von\_mises

**Full name**: result.compute\_stress\_von\_mises

**Internal name**: compute\_stress\_von\_mises

**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.

<details>
  <summary>C++</summary>

  ```cpp theme={null}
  #include "dpf_api.h"

  ansys::dpf::Operator op("compute_stress_von_mises"); // operator instantiation
  op.connect(1, my_scoping);
  op.connect(3, my_streams_container);
  op.connect(4, my_data_sources);
  op.connect(9, my_requested_location);
  op.connect(10, my_strain);
  ansys::dpf::FieldsContainer my_fields_container = op.getOutput<ansys::dpf::FieldsContainer>(0);
  ```
</details>

<details>
  <summary>CPython</summary>

  ```python theme={null}
  import ansys.dpf.core as dpf

  op = dpf.operators.result.compute_stress_von_mises() # operator instantiation
  op.inputs.scoping.connect(my_scoping)
  op.inputs.streams_container.connect(my_streams_container)
  op.inputs.data_sources.connect(my_data_sources)
  op.inputs.requested_location.connect(my_requested_location)
  op.inputs.strain.connect(my_strain)
  my_fields_container = op.outputs.fields_container()
  ```
</details>

<details>
  <summary>IPython</summary>

  ```python theme={null}
  import mech_dpf
  import Ans.DataProcessing as dpf

  op = dpf.operators.result.compute_stress_von_mises() # operator instantiation
  op.inputs.scoping.Connect(my_scoping)
  op.inputs.streams_container.Connect(my_streams_container)
  op.inputs.data_sources.Connect(my_data_sources)
  op.inputs.requested_location.Connect(my_requested_location)
  op.inputs.strain.Connect(my_strain)
  my_fields_container = op.outputs.fields_container.GetData()
  ```
</details>

## Changelog

* Version 0.0.0: Initial release.
