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/)
-   -   Sampling fields data from regions (cellZoneSet) (http://www.cfd-online.com/Forums/openfoam-post-processing/106727-sampling-fields-data-regions-cellzoneset.html)

caduqued September 6, 2012 10:32

Sampling fields data from regions (cellZoneSet)
 
Hi OF comunity,

I am working with OF 2.1.1, and I need to extract values of fields (velocity, pressure, etc) from within regions previously defined.

I have created cellZoneSet sets using topoSet, and I am able to visualize the fields values for those defined zones in paraFoam, however I was wondering if it was possible to get that data directly using some OF tool, like sample or something similar.

Any help in this regard is very much appreciated.

Cheers,

unnikrsn September 12, 2012 09:32

Hi

Did you find an answer for the SampleDict for Regions.
I use chtMultiRegionSimpleFoam. so i have many regions. I tried to use the

sample -region

But it doesnt seem to work. my region name is Kuhlkoerper.
Should i define the region name somewhere in the SampleDict File or

is it only required while running from terminal...

sample -Kuhlkoerper

Kindly Help
Thanks & Regards
Unni

sebware November 16, 2012 11:07

hey guys,

you can create one sampleDict file for each Region and copy them into the folder "system/regionname/"

After that you can run sample in each region by the command

sample -region regionname

for example

sample -region fluid
sample -region solid

best regards
Sebastian

ZKW November 19, 2012 02:26

Thanks Sebastian.

aujamal20 November 21, 2012 07:27

sampleDict using cloud option along with data file...
 
Hi

I have to use sampleDict file to sample field varialble T at a set of points in the simulation domain and I am using "cloud" option for Set. Now I am having a data file containing point coordinates, at which data is to be sampled.
The problem is how i could specify that points data file in sampleDict file.

Quote:

sets
sets
(
domainCell
{
type cloud;
axis xyz;
points (matrix.dat its the file which i want to specify);
}
);

gschaider November 21, 2012 15:31

Quote:

Originally Posted by aujamal20 (Post 393407)
Hi

I have to use sampleDict file to sample field varialble T at a set of points in the simulation domain and I am using "cloud" option for Set. Now I am having a data file containing point coordinates, at which data is to be sampled.
The problem is how i could specify that points data file in sampleDict file.

I think the best way to do this would be to write a script that transforms the points data file into the list-format that OF understands and include it into the sampleDict (rither by edititing or with #include)

aujamal20 November 22, 2012 10:28

Hi
thanks for your response and I just have done that by writing some script and get a list of cell coordinates and then giving that list to sampleDict...


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