# Beam deformation and Stress Field plots

**URL:** https://community.freefem.org/t/beam-deformation-and-stress-field-plots/441
**Category:** General Discussion
**Created:** [May 29, 2020, 9:32pm UTC](https://community.freefem.org/t/beam-deformation-and-stress-field-plots/441 "2020-05-29T21:32:28Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![pdapte1999](https://avatars.discourse-cdn.com/v4/letter/p/d9b06d/32.png) [@pdapte1999](https://community.freefem.org/u/pdapte1999)
#### Post date: [May 29, 2020, 9:32pm UTC](https://community.freefem.org/t/beam-deformation-and-stress-field-plots/441/1 "2020-05-29T21:32:28Z")

</div>

Dear all,  
Please let me know how to plot the stress field for a model of beam. I have gone through the example beam-3D available in the examples. What changes can I make to plot the stress field?  
Thanks.

---

<div class="post-metadata">

### Author: ![prj](https://avatars.discourse-cdn.com/v4/letter/p/ecae2f/32.png) [@prj](https://community.freefem.org/u/prj)
#### Post date: [May 30, 2020, 8:01am UTC](https://community.freefem.org/t/beam-deformation-and-stress-field-plots/441/2 "2020-05-30T08:01:26Z")

</div>

Could you please write down mathematically what you want to plot exactly?

---

<div class="post-metadata">

### Author: ![pdapte1999](https://avatars.discourse-cdn.com/v4/letter/p/d9b06d/32.png) [@pdapte1999](https://community.freefem.org/u/pdapte1999)
#### Post date: [May 30, 2020, 1:25pm UTC](https://community.freefem.org/t/beam-deformation-and-stress-field-plots/441/3 "2020-05-30T13:25:03Z")

</div>

Yes.  
The variational form is as follows:  
∫︁𝜆∇.𝑢∇.𝑣 + 2𝜇𝜖(u) : 𝜖(v) 𝑑𝑥 −∫︁v𝑓 𝑑𝑥 = 0;  
and the expression that I want to plot is:  
Stress=E\*(du/dx), where E is a constant.  
Thanks.

---

<div class="post-metadata">

### Author: ![prj](https://avatars.discourse-cdn.com/v4/letter/p/ecae2f/32.png) [@prj](https://community.freefem.org/u/prj)
#### Post date: [May 30, 2020, 1:36pm UTC](https://community.freefem.org/t/beam-deformation-and-stress-field-plots/441/4 "2020-05-30T13:36:17Z")

</div>

```auto
Vh stress = E * dx(u);
plot(stress);

```

---

<div class="post-metadata">

### Author: ![pdapte1999](https://avatars.discourse-cdn.com/v4/letter/p/d9b06d/32.png) [@pdapte1999](https://community.freefem.org/u/pdapte1999)
#### Post date: [May 30, 2020, 1:44pm UTC](https://community.freefem.org/t/beam-deformation-and-stress-field-plots/441/5 "2020-05-30T13:44:26Z")

</div>

It worked well.  
Thanks a lot.
