CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Programming & Development

generation of boundaryData files for timeVaryingMappedFixedValue

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

Like Tree2Likes
  • 2 Post By anishtain4

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 3, 2011, 12:25
Default generation of boundaryData files for timeVaryingMappedFixedValue
  #1
New Member
 
Join Date: Feb 2010
Posts: 2
Rep Power: 0
MartinEB is on a distinguished road
Dear foamers,

I'm trying to generate the boundaryData files (to be read by timeVaryingMappedFixedValue) from a previous run with icoFoam. That is, I want to save the values of U and p at the outlet of a channel (U and p at the outlet are transient and nonuniform) in order to be read as inlet boundary conditions (in a subsequent run) once the BoundaryData files have been created. Mesh at the channel inlet and outlet is the same so really no interpolation is needed.

I've been trying to manipulate the sample utility (using surface at the outlet patch) to write the boundaryData files but canīt really get the appropiate format of the points, U and p files.

I'd be very grateful if someone can give me a hint of how to solve this problem.
MartinEB is offline   Reply With Quote

Old   February 13, 2011, 20:31
Default
  #2
New Member
 
Walter
Join Date: Feb 2011
Posts: 8
Rep Power: 15
wsmith02 is on a distinguished road
This is exactly what I would like to do as well.

I could probably write a script to parse the mesh for locations on the boundaries of interest then look for the U/p values in the solution and format a boundaryData file from that.

There must be an easier way, right? or has someone done this already?
wsmith02 is offline   Reply With Quote

Old   September 19, 2016, 15:03
Default
  #3
Senior Member
 
Mahdi Hosseinali
Join Date: Apr 2009
Location: NB, Canada
Posts: 273
Rep Power: 18
anishtain4 is on a distinguished road
Just in case anyone else stumbles upon this:
add the following lines either to functions in controlDict or sampleDict

Quote:
sampledPlanes
{
type surfaces;
functionObjectLibs ("libsampling.so");
outputControl timeStep;
outputInterval 200;
enabled true;

surfaceFormat boundaryData;
fields (p U R);

interpolationScheme cellPointFace;

surfaces
(
center
{
type patch;
patches (outlet);
interpolate false;
}
);
}
MaySea and TurbulentRandy like this.
anishtain4 is offline   Reply With Quote

Old   June 3, 2020, 11:32
Default
  #4
Senior Member
 
Arijit Saha
Join Date: Feb 2019
Location: Singapore
Posts: 132
Rep Power: 7
ari003 is on a distinguished road
Quote:
Originally Posted by anishtain4 View Post
Just in case anyone else stumbles upon this:
add the following lines either to functions in controlDict or sampleDict
Hi Sir, I tried these steps but the boundaryData dictionary didnt appear at all after the simulation. I m using OF7 ,did you get any alternative way to do that?
ari003 is offline   Reply With Quote

Old   June 3, 2020, 19:02
Default
  #5
Member
 
Hasan Celik
Join Date: Sep 2016
Posts: 64
Rep Power: 9
PositronCascade is on a distinguished road
Quote:
Originally Posted by ari003 View Post
Hi Sir, I tried these steps but the boundaryData dictionary didnt appear at all after the simulation. I m using OF7 ,did you get any alternative way to do that?
Have you added those lines to controlDict? What kind of error did you get?
PositronCascade is offline   Reply With Quote

Old   June 3, 2020, 19:11
Default
  #6
Senior Member
 
Arijit Saha
Join Date: Feb 2019
Location: Singapore
Posts: 132
Rep Power: 7
ari003 is on a distinguished road
It is not showing any error but not creating any dictionary with boundaryData.
FoamFile
{
version 2.0;
format ascii;
class dictionary;
location "system";
object controlDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

application pimpleFoam;

startFrom startTime;

startTime 0;

stopAt endTime;

endTime 10;

deltaT 0.01;

writeControl timeStep;

writeInterval 100;

purgeWrite 0;

writeFormat ascii;

writePrecision 6;

writeCompression off;

timeFormat general;

timePrecision 6;

runTimeModifiable true;

functions
{
#includeFunc writeCellCentres
#includeFunc probes
#includeFunc R
#includeFunc turbulenceIntensity

fieldAverage1
{
type fieldAverage;
libs ("libfieldFunctionObjects.so");
writeControl writeTime;

fields
(
U
{
mean on;
prime2Mean on;
base time;
}

p
{
mean on;
prime2Mean on;
base time;
}
);
}
surfaces
{
type surfaces;
libs ("libsampling.so");
writeControl writeTime;

surfaceFormat foam;
fields ( U );

interpolationScheme cell;

surfaces
(
xNormal
{
type cuttingPlane;
planeType pointAndNormal;
pointAndNormalDict
{
point (1 1 1);
normal (1 0 0);
}
interpolate false;
}


);
}
sampledPlanes
{
type surfaces;
functionObjectLibs ("libsampling.so");
outputControl timeStep;
outputInterval 1;
enabled true;

surfaceFormat boundaryData;
fields (U);

interpolationScheme cellPointFace;

surfaces
(
center
{
type patch;
patches (outlet);
interpolate false;
}
);
}
}
It seems like the command is not functional.
ari003 is offline   Reply With Quote

Reply

Tags
boundarydata files, timevaryingmappedfixedval

Thread Tools Search this Thread
Search this Thread:

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
UDF issue MASOUD Fluent UDF and Scheme Programming 14 December 6, 2012 13:39
critical error during installation of openfoam Fabio88 OpenFOAM Installation 21 June 2, 2010 03:01
OF 1.6 | Ubuntu 9.10 (64bit) | GLIBCXX_3.4.11 not found piprus OpenFOAM Installation 22 February 25, 2010 13:43
Problems in compiling paraview in Suse 10.3 platform chiven OpenFOAM Installation 3 December 1, 2009 07:21
OpenFOAM15 paraFoam bug koen OpenFOAM Bugs 19 June 30, 2009 10:46


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