CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Post-Processing (http://www.cfd-online.com/Forums/openfoam-post-processing/)
-   -   SampleDict error (http://www.cfd-online.com/Forums/openfoam-post-processing/70516-sampledict-error.html)

AirS November 26, 2009 10:22

SampleDict error
 
Hi all,
I'd like to use the sampleDict in order to plot the velocity along different lines. But when I run the application sample, I've got this:

Create time

Create mesh for time = 0



keyword surfaces is undefined in dictionary "./case/system/sampleDict"

file: ./case/system/sampleDict from line 25 to line 134.

From function dictionary::lookupEntry(const word&, bool, bool) const
in file db/dictionary/dictionary.C at line 388.

FOAM exiting

I can't understand why it talks about surfaces ...
So I join my sampleDict file if someone can give some hints:

setFormat gnuplot;
surfaceFormat vtk; // what is this line referred to ?
interpolationScheme cellPoint;
fields
(
UMean
);
sets
(
line1
{
type uniform;
axis distance;
start (-0.77 -0.05 0.36);
end (-0.77 1.0 0.36);
nPoints 10;
}
line2
{
type uniform;
axis distance;
start (-0.22 -0.05 0.36);
end (-0.22 1.0 0.36);
nPoints 10;
}
line3
{
type uniform;
axis distance;
start (0.0038 -0.05 0.36);
end (0.0038 1.0 0.36);
nPoints 10;
}
line4
{
type uniform;
axis distance;
start (-0.77 -0.05 0.36);
end (-0.77 1.0 0.36);
nPoints 10;
}
line5
{
type uniform;
axis distance;
start (0.81 -0.05 0.36);
end (0.81 1.0 0.36);
nPoints 10;
}
line6
{
type uniform;
axis distance;
start (1.64 -0.05 0.36);
end (1.64 1.0 0.36);
nPoints 10;
}
line7
{
type uniform;
axis distance;
start (2.25 -0.05 0.36);
end (2.25 1.0 0.36);
nPoints 10;
}
);

I'll appreciate every single idea, thank you !

kumar November 27, 2009 04:19

Hello ,
First of all which version of OF are you using. If you are using OF-1.5 or of-1.6.X,then the line surface format refers to the surface date that you want to extract. But if you are not extracting any surface information you should set that to null.

hope this helps
bye

AirS November 27, 2009 08:21

Thanks kumar,
However after having done the change you suggested to me:
surfaceFormat vtk; ---> surfaceFormat null;
I've still the error. I'm using OF-1.6.
why does it talk about surfaces whereas I want to plot over a line... ?

kumar November 27, 2009 08:47

Hello airs,
I think the sample utility is written in such a way that even if you dont extract any surface information, you still have to put the keyword surface in the file SampleDict.
What I suggest you to do is add the information for surface at the end of your sampleDict file like

surfaces
(
constantPlane
{
type plane; // always triangulated
basePoint (0.0501 0.0501 0.005);
normalVector (0.1 0.1 1);

//- Optional: restrict to a particular zone
// zoneName zone1;
}
);
and since you specify the surfaceFormat to null it wont read the surface information. from your solution files. But you still need the definition for surfaces in your file. I mean that you have to specify the keyword surfaces even if you are not extracting surface information.

hope it helps
bye
K.Suresh kumar

AirS November 27, 2009 10:25

You were right! it works now.
Actually, you don't even need to specify "surfaceFormat null" : I removed it and it works. You just need to add the keyword "surfaces" at the end of the file as you said.
Thank u ;)


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