# Does anyone know how to smooth data from tensile MD simulations?

**URL:** <https://gromacs.bioexcel.eu/t/does-anyone-know-how-to-smooth-data-from-tensile-md-simulations/10529>\
**Category:** User discussions\
**Tags:** analysis-tools\
**Created:** [November 12, 2024, 1:11pm UTC](https://gromacs.bioexcel.eu/t/does-anyone-know-how-to-smooth-data-from-tensile-md-simulations/10529 "2024-11-12T13:11:28Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ema2022](https://avatars.discourse-cdn.com/v4/letter/e/c5a1d2/32.png) [@Ema2022](https://gromacs.bioexcel.eu/u/Ema2022)\
**Post date:** [November 12, 2024, 1:11pm UTC](https://gromacs.bioexcel.eu/t/does-anyone-know-how-to-smooth-data-from-tensile-md-simulations/10529/1 "2024-11-12T13:11:28Z")

</div>

Hi All,

I performed a tensile MD simulation for a polymer and calculated stress and strain values from the MD data. However, the stress-strain curve shows significant fluctuations, making the trend difficult to interpret. Could anyone suggest tools or techniques commonly used to smooth MD simulation data for clearer visualization?

---

<div class="post-metadata">

**Author:** ![MagnusL](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/magnusl/32/2380_2.png) [@MagnusL](https://gromacs.bioexcel.eu/u/MagnusL)\
**Post date:** [November 12, 2024, 1:33pm UTC](https://gromacs.bioexcel.eu/t/does-anyone-know-how-to-smooth-data-from-tensile-md-simulations/10529/2 "2024-11-12T13:33:13Z")

</div>

If you are using xmgrace, you can use Data-\>Transformations-\>Running Averages, and set the length to a suitable value - you can try different lengths. Most software alternatives have something similar.

---

<div class="post-metadata">

**Author:** ![Ema2022](https://avatars.discourse-cdn.com/v4/letter/e/c5a1d2/32.png) [@Ema2022](https://gromacs.bioexcel.eu/u/Ema2022)\
**Post date:** [November 12, 2024, 1:54pm UTC](https://gromacs.bioexcel.eu/t/does-anyone-know-how-to-smooth-data-from-tensile-md-simulations/10529/3 "2024-11-12T13:54:38Z")

</div>

Thanks a lot.

---

<div class="post-metadata">

**Author:** ![hess](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/hess/32/416_2.png) [@hess](https://gromacs.bioexcel.eu/u/hess)\
**Post date:** [November 13, 2024, 8:36am UTC](https://gromacs.bioexcel.eu/t/does-anyone-know-how-to-smooth-data-from-tensile-md-simulations/10529/4 "2024-11-13T08:36:40Z")

</div>

In addition, you need to strain very slowly, not only to obtain more statistics, but more importantly to avoid hysteresis. Strain rates in MD simulations are often many orders of magnitude higher than realistic strain rates.

---

<div class="post-metadata">

**Author:** ![Ema2022](https://avatars.discourse-cdn.com/v4/letter/e/c5a1d2/32.png) [@Ema2022](https://gromacs.bioexcel.eu/u/Ema2022)\
**Post date:** [November 13, 2024, 6:25pm UTC](https://gromacs.bioexcel.eu/t/does-anyone-know-how-to-smooth-data-from-tensile-md-simulations/10529/5 "2024-11-13T18:25:29Z")

</div>

@hess Thank you. I have a few more questions. I read papers on stress-strain calculations, and some researchers used pressure tensors (e.g., -Pz) as stress, and some used Vir-ZZ as stress.

1. I am confused, about which one to use in my simulations. What is the rationale behind the two ways?
2. If I select Vir-ZZ and the stress, its unit is kJ/mol, energy per mol. How do we convert it to a pressure unit, what is the relation in the conversion?

Thank you.

---

<div class="post-metadata">

**Author:** ![hess](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/hess/32/416_2.png) [@hess](https://gromacs.bioexcel.eu/u/hess)\
**Post date:** [November 15, 2024, 8:21am UTC](https://gromacs.bioexcel.eu/t/does-anyone-know-how-to-smooth-data-from-tensile-md-simulations/10529/6 "2024-11-15T08:21:30Z")

</div>

I don’t see why you would want to use the virial, except when simulating at zero Kelvin, in which case the pressure is identical to the virial. Use the pressure.

---

<div class="post-metadata">

**Author:** ![Ema2022](https://avatars.discourse-cdn.com/v4/letter/e/c5a1d2/32.png) [@Ema2022](https://gromacs.bioexcel.eu/u/Ema2022)\
**Post date:** [November 15, 2024, 9:30am UTC](https://gromacs.bioexcel.eu/t/does-anyone-know-how-to-smooth-data-from-tensile-md-simulations/10529/7 "2024-11-15T09:30:36Z")

</div>

Thanks for clarifying this.
