CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM

some problem about the ultility of sample

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Display Modes
Old   April 11, 2012, 02:51
Question some problem about the ultility of sample
  #1
Member
 
张德胜
Join Date: Oct 2011
Posts: 71
Rep Power: 5
hei@ge is on a distinguished road
I use sample to get some points'value of U.The file of sampledict is as following:
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.1.0 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
object sampleDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //


setFormat raw;


interpolationScheme cellPoint;

fields
(
magU
);

sets
(
somePoints
{
type cloud;
axis distance;
points ( (-2.7930000e+003 8.8481152e+002 1.3003200e+001)
(-2.7697279e+003 8.7943448e+002 1.3007100e+001)
(-3.0252744e+002 3.0986790e+002 4.2658100e+001)
);
}


// ************************************************** ********************* //
when i execute sample ,the output is:
0 8.69387055526;
1 8.74148226095;
2 6.58627288222
I do not get the distance.who can tell me the reason?Thanks a lot.

Last edited by hei@ge; April 11, 2012 at 03:08.
hei@ge is offline   Reply With Quote

Old   April 11, 2012, 21:45
Default
  #2
Member
 
张德胜
Join Date: Oct 2011
Posts: 71
Rep Power: 5
hei@ge is on a distinguished road
I do not know why there is not one reply me. Is my question not clear? If so,Please tell me and i will correct it。Thanks in advice.
hei@ge is offline   Reply With Quote

Old   April 19, 2012, 06:41
Default
  #3
Senior Member
 
Join Date: Mar 2011
Posts: 174
Rep Power: 6
anon_a is on a distinguished road
I suspect you need to have

start (x1, y1, z1)
end (x2, y2, z2)

instead of

points (x1, y1, z1)
(x2, y2, z2)
(x3, y3, z3)

because the numbers probably correspond to each point.

EDIT: you must also change "cloud" to "uniform". Actually, take a look at applications/utilities/postProcessing/sampling/sample/sampleDict, it will help you a lot.

If you need to have the two intervals between the 3 points, you can check the sampleDict of the compressible/rhoCentralFoam/biconic25-55Run35 tutorial and the sampleCone script in the same directory.

I saw your post kind of late, if you had already found the solution ignore this.
anon_a is offline   Reply With Quote

Old   April 19, 2012, 21:44
Default
  #4
Member
 
张德胜
Join Date: Oct 2011
Posts: 71
Rep Power: 5
hei@ge is on a distinguished road
First,Thanks for your reply.But my line is curve,not straight line.i think the type of "start end "is used to define straight line.if i was wrong,please not hesitate to correct me.Tanks again.
hei@ge is offline   Reply With Quote

Reply

Tags
sample distance

Thread Tools
Display Modes

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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
sample utility problem And OpenFOAM Post-Processing 36 May 20, 2014 08:50
UDF compiling problem Wouter Fluent UDF and Scheme Programming 6 June 6, 2012 04:43
Can I solve this problem by Fluent? Kai_kc FLUENT 1 October 27, 2010 05:29
natural convection problem for a CHT problem Se-Hee CFX 2 June 10, 2007 06:29
Adiabatic and Rotating wall (Convection problem) ParodDav CFX 5 April 29, 2007 19:13


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