CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (http://www.cfd-online.com/Forums/openfoam-solving/)
-   -   BubbleInterTrackFoam with surfactant (http://www.cfd-online.com/Forums/openfoam-solving/114808-bubbleintertrackfoam-surfactant.html)

amattosc March 18, 2013 07:47

BubbleInterTrackFoam with surfactant
 
Hi everyone,

I was hoping to get some help here about this solver.

I've tried to run the original tutorial "bubble2D_r0.75mm" and it worked fine, but I noticed that the option "cleanInterface" was set as "Yes" in "freeSurfaceProperties".

I've looked into the code and for what I understood with this option enabled, BubbleInterTrackFoam doesn't solve the surfactant's conservation equation (as expected).

So, I've tried to change this option to "No" with the add of "soluble yes" at the end of "freeSurfaceProperties". I've also added an initial field for the concentration of surfactant as a "volScalarField".

The result was the following error:

"--> FOAM FATAL IO ERROR:
cannot open file

file: /home/amanda/OpenFOAM/amanda-1.6-ext/run/tutorials/surfaceTracking/bubbleInterTrackFoam/bubble2D_r0.75mm-teste/1e-05/Cs at line 0.

From function regIOobject::readStream()
in file db/regIOobject/regIOobjectRead.C at line 62.

FOAM exiting"

I've tried to locate where the solver tries to read Cs and found its declaration in the middle of "freeSurface" in the file "makeFreeSurfaceData.C":

"surfactConcPtr_ = new areaScalarField
(
IOobject
(
"Cs",
DB().timeName(),
mesh(),
IOobject::MUST_READ,
IOobject::AUTO_WRITE
),
aMesh()
);"

But at this point the solver had already entered the time loop and was trying to read from a file that has not been created yet.

It might be a silly mistake because I'm a new user of OpenFoam, but could someone give me a hand?

Thanks in advance.

Amanda Mattos

akidess March 18, 2013 14:16

Create the file yourself to specify the initial surfactant distribution.

amattosc March 18, 2013 18:24

Quote:

Originally Posted by akidess (Post 414772)
Create the file yourself to specify the initial surfactant distribution.

Thanks for the answer but as I said in my previous post I've already created this file.

The problem is that the solver tries to read this concentration after it started the time loop so the concentration for time 0 exists but for the next time 1e-5 it doesnt.

Any more ideas?

akidess March 19, 2013 02:44

Ah, yes. You said you created a volScalarField though, whereas what you need is an areaScalarField?

amattosc March 19, 2013 06:14

Quote:

Originally Posted by akidess (Post 414870)
Ah, yes. You said you created a volScalarField though, whereas what you need is an areaScalarField?

I've tried to create a Cs file as an areaScalarField but it didn't work anyway.


All times are GMT -4. The time now is 09:32.