CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM (http://www.cfd-online.com/Forums/openfoam/)
-   -   Foam fatal io error: (http://www.cfd-online.com/Forums/openfoam/82475-foam-fatal-io-error.html)

basilwatson November 27, 2010 06:28

Foam fatal io error:
 
Hi all

When I try to run my file, I keep getting this error message... though when I check the Polymesh boundary file it all looks ok to me........see below;

Any Ideas to point me in the right direction?

Kind regards Stephen


--> FOAM Warning :
From function entry::getKeyword(keyType&, Istream&)
in file db/dictionary/entry/entryIO.C at line 77
Reading /home/s/OpenFoam/incompressible/simpleFoam/enterprise/constant/polyMesh/boundary
found on line 62 the punctuation token ')'
expected either } or EOF


--> FOAM FATAL IO ERROR:
Expected a ')' or a '}' while reading PtrList, found on line 66 an error

file: /home/s/OpenFoam/incompressible/simpleFoam/enterprise/constant/polyMesh/boundary at line 66.

From function Istream::readEndList(const char*)
in file db/IOstreams/IOstreams/Istream.C at line 151.

FOAM exiting


boundary card ;;;;



/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 1.7.0 |
| \\ / A nd | Web: www.OpenFOAM.com |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class polyBoundaryMesh;
location "constant/polyMesh";
object boundary;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

8231
(
maxY
{
type patch;
nFaces 100;
startFace 1495590;
}
minX
{
type symmetryPlane;
nFaces 274;
startFace 1495690;
}
maxX
{
type symmetryPlane;
nFaces 274;
startFace 1495964;
}
minY
{
type patch;
nFaces 100;
startFace 1496238;
}
minZ
{
type symmetryPlane;
nFaces 250;
startFace 1496338;
}
maxZ
{
type symmetryPlane;
nFaces 250;
startFace 1496588;
}
stlSurface_patch8224
{
type wall;
nFaces 138925;
startFace 1496838;
}
)

// ************************************************** *********************** //

wyldckat November 27, 2010 08:31

Greetings Stephen,

OK, two things:
  1. you should have compressed and attached the file, instead of copy-pasting it :( This way we cannot verify if there is an illegal invisible character :(
  2. Your file is stating that there are 8231 boundaries, when only 7 are listed! That should be why the parser expected more things to come, instead of the end of the file!
By the way, 8231 boundaries? That must have been one hell of an import! ;)

Best regards,
Bruno

basilwatson November 27, 2010 11:06

2 Attachment(s)
Hi there

most likely the numbering , I was ok with simple shapes all going well , so then I decided to see if I could get the Space Ship Enterprise to model

Well you never know!

I did get it to run through once but with a very course mesh , and I had missed a boundary face , , but for some reason I couldnt get it to run again , with the resulting error

yes it was big but not too bad !

I try and attach a zip file I would like to see what happens !

Thanks for the Help

Stephen

wyldckat November 28, 2010 09:36

Hi Stephen,

Uhm... does this mean that you have been able you use it now, or does the same error still occur?

By the way, if the mesh is too coarse - as we can see in the boundary file you attached - there are a lot of patches with zero faces... And setting boundary conditions for these faces might render the simulation impossible to execute. But I don't remember never trying this, so I don't know exactly what will the outcome be.

Ah, another note: you can try AdMesh to plug any holes there might be in the STL file.

Best regards,
Bruno

basilwatson November 30, 2010 10:14

1 Attachment(s)
tried a more simple mesh and it ran ok

I will come back to the enterprise when I have more time

I have attached a screen shot of the new mesh , any tips about mesh size or how to run it ?( ps its a little nws maybe? its the only mesh I had for another Job )

I am searching now , so any help is valuable

Thank you for your help so fay , most appreciated !

Stephen

s.m August 21, 2013 09:07

2 Attachment(s)
Quote:

Originally Posted by wyldckat (Post 285073)
Hi Stephen,

Uhm... does this mean that you have been able you use it now, or does the same error still occur?

By the way, if the mesh is too coarse - as we can see in the boundary file you attached - there are a lot of patches with zero faces... And setting boundary conditions for these faces might render the simulation impossible to execute. But I don't remember never trying this, so I don't know exactly what will the outcome be.

Ah, another note: you can try AdMesh to plug any holes there might be in the STL file.

Best regards,
Bruno

Dear bruno, i have downloaded the admesh-0.95, and i have executed the instructions, as i read in the INSTALL file, my question is, how should i run it ?
i can't use it because i can't run it, would you please guide me.
Thank you very much:)
This is what i do, for making admesh .

Code:

saeide@linux:~/good/zipfiles> tar -zxvf admesh-0.95.tar.gz
admesh-0.95/
admesh-0.95/ADMESH.DOC
admesh-0.95/COPYING
admesh-0.95/ChangeLog
admesh-0.95/INSTALL
admesh-0.95/Makefile.in
admesh-0.95/README
admesh-0.95/admesh.c
admesh-0.95/block.stl
admesh-0.95/configure
admesh-0.95/configure.in
admesh-0.95/connect.c
admesh-0.95/getopt.c
admesh-0.95/getopt.h
admesh-0.95/getopt1.c
admesh-0.95/normals.c
admesh-0.95/shared.c
admesh-0.95/stl.h
admesh-0.95/stl_io.c
admesh-0.95/stlinit.c
admesh-0.95/util.c
saeide@linux:~/good/zipfiles> cd admesh-0.95
saeide@linux:~/good/zipfiles/admesh-0.95> ./configure
loading site script /usr/share/site/x86_64-unknown-linux-gnu
creating cache ./config.cache
checking for gcc... gcc
checking whether we are using GNU C... yes
checking whether gcc accepts -g... yes
checking for -lm... yes
checking for getopt_long... yes
updating cache ./config.cache
creating ./config.status
creating Makefile
saeide@linux:~/good/zipfiles/admesh-0.95> make
gcc -I. -g -O -O2 -Wall -Wno-implicit  -c -o admesh.o admesh.c
admesh.c:31:1: warning: return type of ‘main’ is not ‘int’ [-Wmain]
gcc -I. -g -O -O2 -Wall -Wno-implicit  -c -o connect.o connect.c
gcc -I. -g -O -O2 -Wall -Wno-implicit  -c -o stl_io.o stl_io.c
stl_io.c: In function ‘stl_write_ascii’:
stl_io.c:135:2: warning: implicit declaration of function ‘strlen’ [-Wimplicit-function-declaration]                                                                                           
stl_io.c:135:14: warning: incompatible implicit declaration of built-in function ‘strlen’ [enabled by default]                                                                                 
stl_io.c: In function ‘stl_print_neighbors’:                                                                                                                                                   
stl_io.c:181:14: warning: incompatible implicit declaration of built-in function ‘strlen’ [enabled by default]                                                                                 
stl_io.c: In function ‘stl_write_binary’:                                                                                                                                                     
stl_io.c:254:14: warning: incompatible implicit declaration of built-in function ‘strlen’ [enabled by default]                                                                                 
stl_io.c:263:11: warning: incompatible implicit declaration of built-in function ‘strlen’ [enabled by default]                                                                                 
stl_io.c: In function ‘stl_write_quad_object’:
stl_io.c:354:14: warning: incompatible implicit declaration of built-in function ‘strlen’ [enabled by default]
stl_io.c: In function ‘stl_write_dxf’:
stl_io.c:430:14: warning: incompatible implicit declaration of built-in function ‘strlen’ [enabled by default]
gcc -I. -g -O -O2 -Wall -Wno-implicit  -c -o stlinit.o stlinit.c
gcc -I. -g -O -O2 -Wall -Wno-implicit  -c -o util.o util.c
gcc -I. -g -O -O2 -Wall -Wno-implicit  -c -o normals.o normals.c
normals.c: In function ‘stl_fix_normal_directions’:
normals.c:98:7: warning: variable ‘checked_before’ set but not used [-Wunused-but-set-variable]
gcc -I. -g -O -O2 -Wall -Wno-implicit  -c -o shared.o shared.c
shared.c: In function ‘stl_write_off’:
shared.c:159:2: warning: implicit declaration of function ‘strlen’ [-Wimplicit-function-declaration]
shared.c:159:14: warning: incompatible implicit declaration of built-in function ‘strlen’ [enabled by default]
shared.c: In function ‘stl_write_vrml’:
shared.c:197:14: warning: incompatible implicit declaration of built-in function ‘strlen’ [enabled by default]
gcc  -o admesh admesh.o connect.o stl_io.o stlinit.o util.o normals.o shared.o  -lm
saeide@linux:~/good/zipfiles/admesh-0.95>


wyldckat August 21, 2013 10:21

Hi Saeideh,

Either check the links given at this page: http://openfoamwiki.net/index.php/Sn...xing_STL_files

Or try running:
Code:

admesh -help
Best regards,
Bruno

s.m August 21, 2013 13:15

Quote:

Originally Posted by wyldckat (Post 447171)
Hi Saeideh,

Either check the links given at this page: http://openfoamwiki.net/index.php/Sn...xing_STL_files

Or try running:
Code:

admesh -help
Best regards,
Bruno

Hi Bruno, i do what was write un that site, but it doesn't run!

This is what i do:

Code:

saeide@linux:~/good/zipfiles/admesh-0.95> sudo apt-get install admesh
root's password:
sudo: apt-get: command not found
saeide@linux:~/good/zipfiles/admesh-0.95>

saeide@linux:~/good/zipfiles> admesh -help
If 'admesh' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf admesh
saeide@linux:~/good/zipfiles>


wyldckat August 21, 2013 13:45

Hi Saeideh,

For posting code, please follow the instructions given on the second link on my signature.

As for using AdMesh, since you compiled it from source, you should use the version you have, namely by running from within the folder "~/good/zipfiles/admesh-0.95" like this:
Code:

./admesh -help
If you want to make it possible to simply run:
Code:

admesh
edit your "~/.bashrc" file and add this line to it:
Code:

export PATH=$PATH:/home/good/zipfiles/admesh-0.95
Then start a new terminal window or tab.

Best regards,
Bruno


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