|
[Sponsors] |
February 24, 2010, 07:15 |
binary or ascii stl?
|
#1 |
New Member
Ruben Wetind
Join Date: Dec 2009
Location: Alnö Sweden
Posts: 6
Rep Power: 17 |
Just received a stl file produced with ProE.
I loaded it to ParaFOAM and the geometry was nicely reproduced. Now my plan was to follow the motorcycle tutorials but with my geometry instead. When running surfaceCheck only mishmash comes out. I guess my stl is binary. Do I need a new stl or how can I use the one that I have? ------------------ ruben@ruben-desktop:~/OpenFOAM/ruben-1.6.x/run/KFA/constant/triSurface$ surfaceCheck KFA.stl > log.surfacecheck word::stripInvalid() called for word ��tC�U�C For debug level (= 2) > 1 this is considered fatal Aborted |
|
February 25, 2010, 04:00 |
|
#2 |
Senior Member
Mark Olesen
Join Date: Mar 2009
Location: https://olesenm.github.io/
Posts: 1,715
Rep Power: 40 |
If it is binary, try renaming to *.stlb so that OpenFOAM knows to treat it as a binary STL.
|
|
August 31, 2010, 09:38 |
|
#3 |
Senior Member
|
Hi,
If you have the Package "python-vtk" (as is called for debian) installed. You can convert your ASCII-type STL into a BINARY-Type STL file or vice versa. PHP Code: #!/usr/bin/env python import vtk reader = vtk.vtkSTLReader() # path to binary or ascii stl file to be converted reader.SetFileName("~/OpenFOAM/ruben-1.6.x/run/KFA/constant/triSurface/KFA.stl") reader.Update() write = vtk.vtkSTLWriter() #uncomment unnecessary 2Ascii or 2Binary write.SetFileTypeToASCII() #write.SetFileTypeToBinary() write.SetInput(reader.GetOutput()) # path to write.SetFileName("~/OpenFOAM/ruben-1.6.x/run/KFA/constant/triSurface/KFAascii.stl") write.Write() this script converts Binary.STL -> ASCII.STL and ASCII.STL-> Binary.STL greets elvis |
|
December 1, 2011, 07:28 |
stl giving error in FOAM
|
#4 |
New Member
bubuncfd
Join Date: Nov 2011
Posts: 9
Rep Power: 15 |
Hello everyone,
I am trying to go for a snappyHexMesh for my own STL file. Like Calobra said, I can also see my file in paraView too. blockMesh is running fine but "snappyHexMesh" is giving error. I have attached the error clip in attachment. Can anyone help me please where I am wrong. I followed the below steps as given in the userguide. 1. I have put the file in the "trisurface" folder located below. $run.../.../incompressible/pimpleDyMFoam/wingMotion/wingMotion_snappyHexMesh/constant/trisurface. 2. Changed the old filename to new (i.e. test.stl) inside the "snappyHexMeshDict" within "system" folder. Please help... |
|
December 2, 2011, 05:09 |
|
#5 |
Senior Member
Join Date: Aug 2010
Location: Groningen, The Netherlands
Posts: 216
Rep Power: 19 |
it is a little bit hard to tell what is wrong in particular, but the error message
looks to me like you eventually forgot a bracket or a semicolon, but it is easier to say if you attach your sHMD file so we can have a look at it. And since you didn't mention it specifically: you have a blockMesh background mesh? regards Colin |
|
December 6, 2011, 02:01 |
stl giving error in FOAM
|
#6 |
New Member
bubuncfd
Join Date: Nov 2011
Posts: 9
Rep Power: 15 |
Hi colinB,
Yes, I used a blockMesh background. I could not understand what is sHMD file ? Can you help me how to get it ? thanks, anjansir. |
|
December 6, 2011, 03:49 |
|
#7 |
Senior Member
Join Date: Aug 2010
Location: Groningen, The Netherlands
Posts: 216
Rep Power: 19 |
sHMD = snappyHexMeshDict
likewise there is bMD for blockMeshDict and so on |
|
December 6, 2011, 04:29 |
stl giving error in FOAM
|
#8 |
New Member
bubuncfd
Join Date: Nov 2011
Posts: 9
Rep Power: 15 |
Oh thanks. I attached the two files i.e. both sHMD and bMD.
Thanks, Anjan. |
|
December 6, 2011, 05:06 |
|
#9 |
Senior Member
Join Date: Aug 2010
Location: Groningen, The Netherlands
Posts: 216
Rep Power: 19 |
Hi
I just had a look at it and found the failure: you wrote: test.stl { type triSurfaceMesh; } but it has to be written like this: test.stl { type triSurfaceMesh; name ******; } instead of the stars you put the name of the solid of your .stl file which looks like: Code:
solid any_object facet normal -0.52733372213947194 0.7512430031456685 0.39692958534128875 outer loop vertex 234.52195739746094 -0.67765188217163086 19.251394271850586 vertex 234.73222351074219 -0.53262174129486084 19.256250381469727 vertex 234.39920043945313 -0.48949074745178223 18.732187271118164 endloop endfacet . . . . endsolid any_object Note that you have to specify the solids name elsewhere in the sHMD as well see therefore also the motorbike tutorial and compare there the stl file and the sHM which helps quite a lot for understanding sHM I hope I explained everything well regards Colin |
|
December 6, 2011, 08:03 |
STL Error corrected
|
#10 |
New Member
bubuncfd
Join Date: Nov 2011
Posts: 9
Rep Power: 15 |
Thanks a lot Colin for your help. The model is now recognized perfectly by OpenFOAM. The mesh looks pretty interesting now..
Regards, Anjan. |
|
December 8, 2011, 07:58 |
blockMesh editing
|
#11 |
New Member
bubuncfd
Join Date: Nov 2011
Posts: 9
Rep Power: 15 |
Hi Colin,
I am trying to change the vertices inside the blockMesh file. I am trying to generate a cube having all sides equal. The changed vertices are as below. vertices ( (-2 -2 0) (2 -2 0) (2 2 0) (-2 2 0) (-2 -2 4) (2 -2 4) (2 2 4) (-2 2 4) ); Now as per my knowledge it should create a cubical domain having all sides equal but when I am running blockMesh it is generating the default geometry which it was generating before editing the file. I have attached the snapshot in the attachment after opening the domain in paraFoam. Can you please help where I am mistaken. |
|
December 8, 2011, 08:29 |
|
#12 |
Senior Member
Join Date: Aug 2010
Location: Groningen, The Netherlands
Posts: 216
Rep Power: 19 |
try deleting all contents of the polyMesh folder except the bMD file and then
run blockMesh again. this should work |
|
December 9, 2011, 06:21 |
blockMesh editing
|
#13 |
New Member
bubuncfd
Join Date: Nov 2011
Posts: 9
Rep Power: 15 |
Hi Colin,
I had done exactly as you said but I got no improvement in the model. It is as like before. Regards, Anjan. |
|
December 9, 2011, 08:13 |
selection for motorBike solver
|
#14 |
New Member
bubuncfd
Join Date: Nov 2011
Posts: 9
Rep Power: 15 |
Hi Colin,
I could run the motorbike mesh successfully and can see it in paraFoam. But I am confused while I am putting the solver to run. I first selected "MRFSimpleFoam" but it is giving some error. Then I selected "icoFoam", but still it is giving error. Please see the error snapshot attached below. Can you suggest a suitable solver. Thanks, Anjan. |
|
December 9, 2011, 09:05 |
|
#15 |
Senior Member
Join Date: Aug 2010
Location: Groningen, The Netherlands
Posts: 216
Rep Power: 19 |
Hi there,
a general thing concerning the forum: there are different sections for different topics, for a particular reason: people encountering a similar problem can easily find a topic where their problems are eventually already discussed! so the last two posts of you clearly don't match with the ascii or binary stl file for a sHMD anymore and should be in the blockMesh forum and the solving forum Another note: Generally speaking there are no things like stupid questions, but I guess most of the users are not willing to do once home work: An error message like: /***************************************\ FOAM Fatal Error: cannot find file . . . . file .../project/0/p is missing \***************************************/ is more or less self explaining. concerning your blockMesh problem: it is handy to have both files to understand why there are / should be differences. So Bottom line if a problem occurs: - read error message - think - if problem not solved read error message again - think again - if it is still not solved ask google or the forum search for the answer - if they don't have it formulate your problem and gather all data you might think are important - think again - make a forum post - read the post and think again - push the review post button - then think again - if everything is now well documented and well formulated and the problem still hasn't solved push the submit button This rough check list usually works out fine for me, it doesn't always keep me from asking obvious things, but keeps it to a minimum I hope the above text is of assistance regards |
|
February 10, 2012, 11:59 |
|
#16 | |
Member
Aqua
Join Date: Oct 2011
Posts: 96
Rep Power: 15 |
Quote:
I tried to use stl file created form proE, but OF didn't recognize it, after snappyHexMesh, in boundary file, nfaces is 0 for my test.stl. So I wonder, your stl file is from Proe or what software? thank you so much! Aqua |
||
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[Resolved] GPU on Fluent | Daveo643 | FLUENT | 4 | March 7, 2018 09:02 |
Error in solution using "Grid Interface" | agustinvo | FLUENT | 4 | January 20, 2015 13:03 |
[OpenFOAM] Problems with ASCII STL | Tobi | ParaView | 6 | April 30, 2014 14:49 |
Binary or Ascii? | dancfd | OpenFOAM Running, Solving & CFD | 2 | May 6, 2013 22:26 |
Error to re-open fluent case file | J.Gimbun | FLUENT | 0 | April 27, 2006 09:42 |