Interesting project: DesignSPHysics fluid simulator

A subforum specific to the development of the OpenFoam-based workbenches ( Cfd https://github.com/qingfengxia/Cfd and CfdOF https://github.com/jaheyns/CfdOF )

Moderator: oliveroxtoby

User avatar
kwahoo
Posts: 680
Joined: Fri Nov 29, 2013 3:09 pm
Contact:

Re: Interesting project: DesignSPHysics fluid simulator

Post by kwahoo »

Hi,

Reviving this old thread to share a small news for AMD users.
I converted the CUDA code to AMD HIP/ROCm, to perform calculations of AMD Radeon GPUs.
Code is here https://github.com/kwahoo2/DualSPHysics
Performance difference is quite noticeable, testing the 01_DamBreak:
CPU, Ryzen 7 1700:
real 50m35,257s
user 749m2,203s
sys 0m14,726s

GPU, Radeon 6600XT
real 4m55,682s
user 6m55,447s
sys 0m6,649s
https://github.com/DualSPHysics/DualSPHysics/issues/3

ROCm runs on Linux and AMD Radeon Vega, CDNA and RDNA2 GPUs.
https://rocmdocs.amd.com/en/latest/Curr ... Notes.html
User avatar
Kunda1
Veteran
Posts: 13434
Joined: Thu Jan 05, 2017 9:03 pm

Re: Interesting project: DesignSPHysics fluid simulator

Post by Kunda1 »

https://twitter.com/z_Joker/status/1567168370524540932
https://twitter.com/z_Joker/status/1567168370524540932
Screenshot_20220906_113356.png (275.15 KiB) Viewed 1883 times
A spillway simulated using DualSPHysics workbench
Published on Twitter (link in caption)
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
M4mina
Posts: 8
Joined: Sat Apr 09, 2022 4:48 am

Re: Interesting project: DesignSPHysics fluid simulator

Post by M4mina »

I have played with it. It is very promising but the problem is the boundaries. It is not easy to define inlets and outlets with velocitoes and pressure values.
It best fit for spillway or waves on shore.
Actually this spillway is my work and i posted it on twitter ) interesting
User avatar
Kunda1
Veteran
Posts: 13434
Joined: Thu Jan 05, 2017 9:03 pm

Re: Interesting project: DesignSPHysics fluid simulator

Post by Kunda1 »

M4mina wrote: Fri Oct 14, 2022 6:18 pm I have played with it. It is very promising but the problem is the boundaries. It is not easy to define inlets and outlets with velocitoes and pressure values.
Is there a possibility to improve this limitation? Do the DesignSPHysics devs know ?
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
M4mina
Posts: 8
Joined: Sat Apr 09, 2022 4:48 am

Re: Interesting project: DesignSPHysics fluid simulator

Post by M4mina »

@Kunda1
I haven't contacted the team, but it has futuristic capabilities such as FSI. I believe it is developed for shore applications. Maybe i will try to contact the Manchester university prof when i move near there.
Still thinking of attending their next workshop but no support from my company :)
User avatar
Kunda1
Veteran
Posts: 13434
Joined: Thu Jan 05, 2017 9:03 pm

Re: Interesting project: DesignSPHysics fluid simulator

Post by Kunda1 »

@M4mina if you see functionality in that workbench that improves FreeCAD operations (not relevant necessarily to designsphysics subject matter, please feel free to comment on it. I notice that some of these specialized workbench find workarounds and improve functionality of FreeCAD like 3rd party software installations and UI/UX improvements. But the issue is that these refinements don't feedback in to the FreeCAD master. So it would be great to have liasons between these 3rd party workbench developers (the ones that aren't active in the FC community) and the FC community and developers. It's an invitation more than anything.
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
thschrader
Veteran
Posts: 3129
Joined: Sat May 20, 2017 12:06 pm
Location: Germany

Re: Interesting project: DesignSPHysics fluid simulator

Post by thschrader »

Collapse of the Aquadom-Aquarium in Berlin at 16.12.2022.
The little red cubes are people for scale. Aquadom contains 1 million Liters.
Sounds a lot, but the effect doesnt look very dramatic.
The Aquarium is built around an inner elevator.

Here is the first tutorial I found about using inlet-/outlet definition in DesignSphysics macro for FC:
https://www.youtube.com/watch?v=AqxzzF9REcw
aquadome.JPG
aquadome.JPG (116.76 KiB) Viewed 1383 times
thschrader
Veteran
Posts: 3129
Joined: Sat May 20, 2017 12:06 pm
Location: Germany

Re: Interesting project: DesignSPHysics fluid simulator

Post by thschrader »

My first attempt to simulate a NACA2412 hydrofoil.
Waterdepth 1,3 m, foil is located 300 mm below surface.
Inlet speed 2,6 m/s, equals 5 knots.

312000 particles, distance 5 mm, physical simulation time 3 sec.
chord-length profile 500 mm. 2D-case.
Runtime 40 min on Nvidia Geforce RTX2060 GPU.

The hydrofoil "sucks down" the waterlevel in the wake.
After a while I get these weird artefacts at the bottom of the inlet.

Based on this tutorial:
https://www.youtube.com/watch?v=AqxzzF9REcw

case-files:
CaseNACA2412_2D.zip
(264.22 KiB) Downloaded 39 times
dualsphysics_naca2412.JPG
dualsphysics_naca2412.JPG (187.46 KiB) Viewed 1042 times
paraview2d.JPG
paraview2d.JPG (155.34 KiB) Viewed 1042 times
thschrader
Veteran
Posts: 3129
Joined: Sat May 20, 2017 12:06 pm
Location: Germany

Re: Interesting project: DesignSPHysics fluid simulator

Post by thschrader »

It is more realistic to move the wing, not the fluid.
Wingspeed 2m/s.
Next steps:
-more particles for better wing resolution
-full 3D-case hydrofoil
hydrofoil.gif
hydrofoil.gif (985.85 KiB) Viewed 918 times
Post Reply