CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   sample dict and Boundary Condition (https://www.cfd-online.com/Forums/openfoam-solving/178125-sample-dict-boundary-condition.html)

pappo1890 September 29, 2016 08:50

sample dict and Boundary Condition
 
Hello to everybody.

Since I am struggling in the implementation of an Inlet Boundary condition I want ask you some suggestions.
I would like to impose a boundary at the inlet for a scalar quantity. My Geometrical domain is a cylinder and at the bottom (where there is my inlet patch plus coflow patch) I have to impose a variation of this variable from the centre (equal to one) until zero until a certain radius of the coflow patch)
I was wondering if groovyBC could help me but unfortunately I was not so able to write a function in x, y variables. So thinking another option I had the idea to sample the data of the scalar quantity on a surface parallel to the bottom and then give this value as a boundary. The value are taking as cell face value and the number of faces is the same as the number of data extracted.
My question is.. Is there some way to give this values in the right order?

I was using these datas on the same geometry but in a different case and it did not work.

How can I do?

anishtain4 September 29, 2016 13:18

Hi Alessandro, Let's see if we understood what you want:

You want a linear distribution of a scalar from centre to a certain radius and then it'd be zero after that radius?
Do you have this distribution in another solution and want to map it? Is it the same grid?

pappo1890 September 29, 2016 14:32

Hi Anishtain4,

First of all thank you for the reply.
Yes I would like to do exactly what you asked. I have some experimental data from which I can get a profile through a cubic regression. Anyway the regression give me the values just on a line of the circle (variation in x when y=0) as the dependence on the y coordinate is not included.
So I have tried with sampledict: I have sampled the data from the face of a circular surface parallel to the bottom circle. The problem is that when I copy-paste the list of values corresponding to the value on the face centre the order is wrong.
Of such important consideration is the fact that my circle at the bottom is divided in two patch: an inlet for one species and a coflow for the other. By the way the variation of this scalar quantity is linear thorugh the two patches

anishtain4 October 5, 2016 10:39

it's usually not the best idea to copy and paste data in OF.

I didn't quiet understand you, do you have your data experimentally or do you use sample utility to get them out of another run?

If your geometry is axisymmetry but you want to have a full simulation check this:
http://www.tfd.chalmers.se/~hani/kur...bergReport.pdf

If it's a RANS simulation (no azimuthal dependency) then try using wedge boundary condition.

If you are sampling from another run it's easier to use boundaryData to feed it into another solver not sampleDict.

I think if you use the cylinderical coordinate then you can use your fitted curve (which is only a function of radius) in the groovyBC


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