BC in openFoam
hi dear foamer
how i can use a value in a file as my boundary condition ? for example for patch inlet for pressure i want that boundary in inlet change as i change the value of pSat in constant directory transporperties file: inlet { type fixedValue; value $FOAM_CASE/constant/transporperties/pSat; } |
Quote:
I have made a few of my own BC's in foam that read in data from files. You can use input file streams (IFStream class) to read in files. I got the original code I use from $FOAM_SRC/dynamicFvMesh/solidBodyMotionFvMesh/solidBodyMotionFunctions/SKA/SKA.C, so I suggest that as a starting point. I do not know if this would be the most ideal option for you, but I'm sure you could get it to work. I hope this helps, Dominic |
Did you take a look at the user manual section 4.2.9?
There it is exactly explained how to use a value from a file. For an example, take a look at the motorBike tutorial of simpleFoam. |
yep u are right but i would like to read a value from an existing dic for example transportproperties dic not from a file in directory 0
|
Hi Nima,
Just a wild guess, I think you need a boundary data file like the one in pimpleFoam. Or you can input some forAll and if else command directly in your solver... Regards, Robert |
Dear Foamer!!
how i can define a variable (non constant) boundary condition (pressure inlet),for example for patch total pressure i want that boundary in inlet changes at every iteration step, i have value in files which come from real test. Any idea please! Best regards. |
Hi Abdel,
Please find this discussion http://www.cfd-online.com/Forums/ope...onditions.html Otherwise, if the properties you want to vary with time is not a volScalarField (NO_READ in createFields.H) then you can do based from my previous post. Regards, Robert |
continuity BC
hi,
I am new to OpenFoam, does anybody know how to set a continuity BC in OpenFOAM? Thanks in advance |
where do u need continuity boundary condition?
which solver do u talking about and which variables? |
thanks for reply, i use interFoam to simulate the droplet break-up in a t-junction
and i need continuity BC(for pressure,velocity and alpha1) for the patch between vertical and horizontal arm because i tried to merge (with mergePathPairs) the two blocks but the simulation result not is what is expected: changing several BC i obtain that the fluid stop at this patch or a continuous flow. |
are you sure your problem is the boundary condition between horizontal and vertical patches? i think you have done the right work yet and using merge patches to merge two blocks i think its better to open a new thread and put some of ur result and what you are expecting from result in it! different issues from mesh resolution or solver limitation or overall conditions or initial conditions cause your problem! and it think here the patch issue is not ur problem
|
Ok,thanks a lot for your advice
|
hi,
can u tell me how to write partial velocity differential condition for outlet |
All times are GMT -4. The time now is 14:07. |