Principal Stress Plots

About the development of the FEM module/workbench.

Moderator: bernd

User avatar
HarryvL
Veteran
Posts: 1283
Joined: Sat Jan 06, 2018 7:38 pm
Location: Netherlands

Re: [fixed] Principal Stress Plots

Post by HarryvL »

I can't build - have an issue with shiboken2 library.

I think the error is easy to fix by renaming method "calculate_principal_stress" to "calculate_principal_stress_reinforced" everywhere (3 locations) in resulttools.py. That or change the test to call calculate_principal_stress instead. Not elegant, but it should work. See attached:

resulttools.py
(27.14 KiB) Downloaded 51 times

Sorry, I can't do any better at the moment. I did not know today was the deadline for FC20 release ... pure coincidence.
User avatar
HarryvL
Veteran
Posts: 1283
Joined: Sat Jan 06, 2018 7:38 pm
Location: Netherlands

Re: [fixed] Principal Stress Plots

Post by HarryvL »

Perhaps better to roll back to earlier commit and leave this fix for the next version.

I can't run all the tests required.
User avatar
uwestoehr
Veteran
Posts: 4961
Joined: Sun Jan 27, 2019 3:21 am
Location: Germany
Contact:

Re: [fixed] Principal Stress Plots

Post by uwestoehr »

I had to revert the second PR. Only the removal of the 3 stresses are now in.

The release was made. so everything further in the next release cycle.

Please then just make PRs by yourself. This way the CI will run the tests for us that such trouble won't happen again.

thanks and regards
Uwe
User avatar
HarryvL
Veteran
Posts: 1283
Joined: Sat Jan 06, 2018 7:38 pm
Location: Netherlands

Re: [fixed] Principal Stress Plots

Post by HarryvL »

Great, thanks Uwe.
User avatar
uwestoehr
Veteran
Posts: 4961
Joined: Sun Jan 27, 2019 3:21 am
Location: Germany
Contact:

Re: Principal Stress Plots

Post by uwestoehr »

HarryvL wrote: Mon Jun 13, 2022 2:26 pm 1) I moved the three stresses up to the vector section, because that’s what they are and that’s what you need to display them in ParaView.
I had to revert your removal of the principal stresses because they caused a regression:
- for "normal" mechanical analyses one needs these 3 principal stresses.

It was my mistake to merge this, because when you look at the links in the comments above the definition of the stresses:
git commit 3af54a7dda
you see that we need to distinguish here:
- if reinforced material -> we get PS1Vector etc. but also the principal stress scalars
- otherwise only the scalars

So maybe just a renaming should fix your issue. Here is a PR that does this:
https://github.com/FreeCAD/FreeCAD/pull/7246

Please give it a try and report back.
User avatar
HarryvL
Veteran
Posts: 1283
Joined: Sat Jan 06, 2018 7:38 pm
Location: Netherlands

Re: Principal Stress Plots

Post by HarryvL »

uwestoehr wrote: Sun Jul 24, 2022 3:46 am Please give it a try and report back.
I am not good at github, so manually typed your proposed modifications, compiled and tested this:

Principal Stress Vector Check.png
Principal Stress Vector Check.png (124.58 KiB) Viewed 1295 times

The Principal Stress Vectors are transferred properly to ParaView and can be used in the relevant filters.

Thanks for solving this issue and apologies for the late response.
User avatar
Kunda1
Veteran
Posts: 13434
Joined: Thu Jan 05, 2017 9:03 pm

Re: Principal Stress Plots

Post by Kunda1 »

@HarryvL here's a trick:
Alone you go faster. Together we go farther
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
Jee-Bee
Veteran
Posts: 2566
Joined: Tue Jun 16, 2015 10:32 am
Location: Netherlands

Re: Principal Stress Plots

Post by Jee-Bee »

Thanks I didn't know that too.
User avatar
HarryvL
Veteran
Posts: 1283
Joined: Sat Jan 06, 2018 7:38 pm
Location: Netherlands

Re: Principal Stress Plots

Post by HarryvL »

Kunda1 wrote: Sat Aug 20, 2022 5:46 pm @HarryvL here's a trick:
Thanks !
User avatar
uwestoehr
Veteran
Posts: 4961
Joined: Sun Jan 27, 2019 3:21 am
Location: Germany
Contact:

Re: Principal Stress Plots

Post by uwestoehr »

HarryvL wrote: Sat Aug 20, 2022 2:05 pm The Principal Stress Vectors are transferred properly to ParaView and can be used in the relevant filters.

Thanks for solving this issue and apologies for the late response.
Thanks. I merged the PR now and will backport this to FreeCAD 0.20.x later.
Post Reply