Native STL objects in cfdOF ?

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

jr222
Posts: 10
Joined: Sat Sep 06, 2014 10:53 am

Native STL objects in cfdOF ?

Postby jr222 » Tue Jul 17, 2018 11:47 pm

Hi, is it possible to use a mesh (from an STL) ?, say for example for use in an external flow model (i.e., putting inside a box and assigning a no-slip wall BC to the entire mesh)? Thanks in advance.
User avatar
oliveroxtoby
Posts: 256
Joined: Fri Dec 23, 2016 9:43 am
Location: South Africa

Re: Native STL objects in cfdOF ?

Postby oliveroxtoby » Wed Jul 18, 2018 6:19 am

jr222 wrote:
Tue Jul 17, 2018 11:47 pm
Hi, is it possible to use a mesh (from an STL) ?, say for example for use in an external flow model (i.e., putting inside a box and assigning a no-slip wall BC to the entire mesh)? Thanks in advance.
You should be able to import an stl to use as a surface definition for the body. You would then use the meshing tools supplied to create the CFD volume mesh around this. You can't import an external mesh to use for this at the moment however.
jr222
Posts: 10
Joined: Sat Sep 06, 2014 10:53 am

Re: Native STL objects in cfdOF ?

Postby jr222 » Wed Jul 18, 2018 11:45 pm

Hi Oliver,

When I import an STL, I cannot select its surface within the "CFD boundary condition" task. I tried the "select from list" button+drop-box, and I also tried selecting it with the cursor. None worked.
show.PNG
show.PNG (115.72 KiB) Viewed 352 times
(the shoe is a grabcad STL - Shoe #001 Tiago Müller)

Thanks
chrisb
Posts: 15756
Joined: Tue Mar 17, 2015 9:14 am

Re: Native STL objects in cfdOF ?

Postby chrisb » Thu Jul 19, 2018 4:00 am

jr222 wrote:
Wed Jul 18, 2018 11:45 pm
None worked.
Of course not, as Oliver had told you:
oliveroxtoby wrote:
Wed Jul 18, 2018 6:19 am
You can't import an external mesh to use for this at the moment however.
Apply Part->Create shape from mesh and then
Convert to solid.
jr222
Posts: 10
Joined: Sat Sep 06, 2014 10:53 am

Re: Native STL objects in cfdOF ?

Postby jr222 » Thu Jul 19, 2018 12:01 pm

Chrisb,
In OpenFOAM speak, an STL is a surface file, and a mesh is the discretized volume broken into many elements. This is why I came back with the second post.

Oliver,
I have been using openFOAM on and off for a few of years and thank you very much for this contribution that bringing two awesome open source projects together. The advent of BlueCFD, and their kind contribution to bring OpenFOAM to windows (on multicores) is also awesome.

Thanks,

Jose
User avatar
oliveroxtoby
Posts: 256
Joined: Fri Dec 23, 2016 9:43 am
Location: South Africa

Re: Native STL objects in cfdOF ?

Postby oliveroxtoby » Thu Jul 19, 2018 12:16 pm

jr222 wrote:
Thu Jul 19, 2018 12:01 pm
Chrisb,
In OpenFOAM speak, an STL is a surface file, and a mesh is the discretized volume broken into many elements. This is why I came back with the second post.

Oliver,
I have been using openFOAM on and off for a few of years and thank you very much for this contribution that bringing two awesome open source projects together. The advent of BlueCFD, and their kind contribution to bring OpenFOAM to windows (on multicores) is also awesome.

Thanks,

Jose
Thanks Jose! Glad to hear it's useful to you. Thanks @chrisb for the help.
thschrader
Posts: 1394
Joined: Sat May 20, 2017 12:06 pm
Location: Germany

Re: Native STL objects in cfdOF ?

Postby thschrader » Thu Jul 19, 2018 4:29 pm

jr222 wrote:
Thu Jul 19, 2018 12:01 pm
This is why I came back with the second post.
Hi jr222,

the problem is: the triangulated stl remains triangulated after converting
to a solid (I needed 10 min, FC pushes up to 2,8 GB memory).
The stl has more than 125000 faces (check it with meshes-wb, analyse).
For adressing the boundary-conditions, lets say wall-noSlip, you have to select
every single facet on the body. You get more than 125000 patch entries.
At the moment, there is no (easy) way in FC to reconstruct a smooth surface from triangulated bodies.
My workflow is always to redesign the body with FC to get a body with a smooth surface
and only a few faces.

When using mesh-analysis, you get a lot of intersections in the stl.

btw 1: how can I use cfd for shoes? :o
btw 2: here is a specialist for shoedesign (microelly) :)
https://forum.freecadweb.org/viewtopic. ... &start=130
btw 3: you are right, the cfd-wb is a novum. 8-)
sapato1.JPG
sapato1.JPG (166.76 KiB) Viewed 313 times
sapato2.JPG
sapato2.JPG (70.47 KiB) Viewed 313 times
jr222
Posts: 10
Joined: Sat Sep 06, 2014 10:53 am

Re: Native STL objects in cfdOF ?

Postby jr222 » Fri Jul 20, 2018 1:29 am

:lol: Shoes and CFD make perfect sense. Aerodynamic shoes are indispensable in daily life :D

I looked at the shoemaker forum topic, that was pretty serious and cool stuff though.