CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Meshing & Mesh Conversion

[CAD formats] create an STL file

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 25, 2013, 00:59
Default create an STL file
  #1
Pj.
Member
 
Luca
Join Date: Mar 2013
Posts: 68
Rep Power: 13
Pj. is on a distinguished road
Hi everybody,

it's an easy question, but i couldn't find an answer on the forum:

i need to create and stl file (for snappyHex) of a rectangular parallelepiped keeping the surfaces separated to allow force coeffs to gives me the force coefficient of each face.

I'm able to use AutoCAD, but when i create the stl it asks me to use a volume, so all the faces got "merged" in one surface.

Is there a way to do this with AutoCAD? Or have I to use another program? In case, can you tell me an easy one to use?

Thank you very much
Pj. is offline   Reply With Quote

Old   April 25, 2013, 03:58
Default
  #2
Senior Member
 
Pablo Higuera
Join Date: Jan 2011
Location: Auckland
Posts: 627
Rep Power: 19
Phicau is on a distinguished road
Hi

for such a simple case you can do it by hand or set up a script. Find here the stl file for 2 faces:

Code:
solid face1
facet normal -0.000000 0.0 1.000000
   outer loop
      vertex 0.000000 1.000000 0.500000 
      vertex 0.000000 -1.000000 0.500000 
      vertex 10.000000 -1.000000 0.500000 
   endloop
endfacet
facet normal -0.000000 0.0 1.000000
   outer loop
      vertex 0.000000 1.000000 0.500000 
      vertex 10.000000 1.000000 0.500000 
      vertex 10.000000 -1.000000 0.500000 
   endloop
endfacet
endsolid face1
solid face2
facet normal -0.000000 0.0 1.000000
   outer loop
      vertex 0.000000 1.000000 -0.500000 
      vertex 0.000000 -1.000000 -0.500000 
      vertex 10.000000 -1.000000 -0.500000 
   endloop
endfacet
facet normal -0.000000 0.0 1.000000
   outer loop
      vertex 0.000000 1.000000 -0.500000 
      vertex 10.000000 1.000000 -0.500000 
      vertex 10.000000 -1.000000 -0.500000 
   endloop
endfacet
endsolid face2
Best,

Pablo
Phicau is offline   Reply With Quote

Old   April 25, 2013, 05:51
Default
  #3
Pj.
Member
 
Luca
Join Date: Mar 2013
Posts: 68
Rep Power: 13
Pj. is on a distinguished road
Thank you very much. For this first phase I'll try to do what you say.

For more complex cases (that i'll have to face later) instead, how can i do?
Pj. is offline   Reply With Quote

Old   April 25, 2013, 07:12
Default CAD software for generating STLs
  #4
Senior Member
 
JR22's Avatar
 
Jose Rey
Join Date: Oct 2012
Posts: 134
Rep Power: 18
JR22 will become famous soon enough
It has to be a solid, not just a collection of edges. Its been a while since I've used AutoCAD, but I think by default you just get a collection of edges. You can do solids with AutoCAD, but Inventor (also Autodesk), solidworks, etc, are made for solids modeling. There are many open source and free options for solids modeling CAD software, here are some (from this thread):In the case of many of these packages, you make the solid, then create a mesh from that solid, then export that mesh as a ASCII-STL.
JR22 is offline   Reply With Quote

Reply

Tags
snappyhexmesh, stl


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
how to calculate mass flow rate on patches and summation of that during the run? immortality OpenFOAM Post-Processing 104 February 16, 2021 09:46
[Other] Adding solvers from DensityBasedTurbo to foam-extend 3.0 Seroga OpenFOAM Community Contributions 9 June 12, 2015 18:18
centOS 5.6 : paraFoam not working yossi OpenFOAM Installation 2 October 9, 2013 02:41
pisoFoam compiling error with OF 1.7.1 on MAC OSX Greg Givogue OpenFOAM Programming & Development 3 March 4, 2011 18:18
ParaView Compilation jakaranda OpenFOAM Installation 3 October 27, 2008 12:46


All times are GMT -4. The time now is 07:07.