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/)
-   -   Mixing Tank using simpleFoam - PLEASE HELP! (http://www.cfd-online.com/Forums/openfoam-solving/123444-mixing-tank-using-simplefoam-please-help.html)

sbusmayer September 12, 2013 20:55

Mixing Tank using simpleFoam - PLEASE HELP!
 
Hi all,
I'm doing my undergrad thesis using OpenFOAM to model potable water reservoirs. The idea is to create different geometries for inlet and outlet pipes and hopefully find out residence time of the system.

I've been reading heaps of threads, tutorials and everything, but still not able to solve a decent simulation. I did the geometry with SALOME 6.3 (Box4 attached) and created the Case3-Box4 to solve with simpleFoam and a modified my_simpleFoam to add streamLines and temperature.

The problem is that using simpleFoam, the result seems not right and I'm not able to visualize particleTrack, either using paraFoam or foamToVTK. And it's even worst when I tried to create my own solver (my_simpleFoam) which is not found when I try to call it (sbusmayer@SBusmayer-CAE:~/Desktop/openfoam201/CFD-OpenFOAM/Case3-Box4$ ./SimpleRun.sh
./SimpleRun.sh: line 3: my_simpleFoam: command not found)


Could someone please go through my case and point out how to:
1) Visualize the behavior of water inside the tank -> streamlines, dead zones, velocity field
2) Calculate residence time - either using particle tracking or other means
3) Any other errors spotted


MORE INFO:
* fluid: water
* incompressible
* turbulence model: k-epsilon

:D
Mixing Tank Case
https://www.dropbox.com/s/c2ox68ged4...Case3-Box4.zip

:confused:
my_simpleFoam modified solver
https://www.dropbox.com/s/fyv6ttnlto...simpleFoam.zip


Appreciate your help!

sbusmayer September 16, 2013 18:13

Really... no one can help? =/

voingiappone October 1, 2013 03:46

Quote:

Originally Posted by sbusmayer (Post 452824)
Dear voingiappone,
Thank you SO MUCH for your reply! It really helped me to understand what to do for now.
I used a modified icoFoam with NaCl as tracer in my tank geometry =)

My following steps are:
1) Just give a pulse of the tracer at t=0 for about 1min, and then plot the concentration curve at the outlet. Have you done this?
2) Add turbulence - Do you think pimpleFoam would do?

;)
Thx mate!!

Samanta,

sorry for the enormous delay... I was quite busy these days. I also reply here for not going OT in the other thread.

I'm glad I have been of some help but regarding SimpleFoam or PimpleFoam, this is as far as I can go.... I routinely use interFOAM so I know little of those two applications.

However I can explain how I did my measurements, maybe you can use the same approach.

First:
I solve the problem for as long as it needs to converge to a stable solution. I usually keep it running for 100 s of simulated time so I am super-sure. I also have then a lot of data to average from which is another favorable point.
During this simulation I set the tracer concentration to 0.

Second:
This step depends on the kind of reactor you have. My reactors are quite simple: a bubble column, an air-lift and a film reactor. The first two are purely-batch reactors, that is I inject the tracer and let it get to an uniform concentration. The latter is a continuous reactor (recirculating but similar to yours) so I was forced to change entirely the inlet concentration to a fixed value (saturated NaCl) end than monitor the outlet concentration. Of course this means that you just use your last time step for the previous simulation, you set the new C value to saturated NaCl and run again. The result will be the tracer slowly populate your domain.
I think a 1 min pulse can be useful only if your residence time is shorter then that... but probably these are just my 2 cents. In all of the reactors I don't have dead spaces where concentration gradients may stagnate but if this is your case, you may ponder to place various probes and follow their time course to see how the tracer distributes in the reactor.

Regarding turbulence, as I said before I use another solver so I cannot help you that much but searching the forum I found this:

http://www.cfd-online.com/Forums/ope...s-icofoam.html

As usual with OF, the turbulence model can be selected in the simulation properties so you just have to choose. Maybe simpleFOAM would be better for your needs, what do you think?

Let me know if I can further help you... I'll try to answer faster.

Luca

sbusmayer October 23, 2013 18:30

Quote:

Originally Posted by voingiappone (Post 454397)
Samanta,

sorry for the enormous delay... I was quite busy these days. I also reply here for not going OT in the other thread.

I'm glad I have been of some help but regarding SimpleFoam or PimpleFoam, this is as far as I can go.... I routinely use interFOAM so I know little of those two applications.

However I can explain how I did my measurements, maybe you can use the same approach.

First:
I solve the problem for as long as it needs to converge to a stable solution. I usually keep it running for 100 s of simulated time so I am super-sure. I also have then a lot of data to average from which is another favorable point.
During this simulation I set the tracer concentration to 0.

Second:
This step depends on the kind of reactor you have. My reactors are quite simple: a bubble column, an air-lift and a film reactor. The first two are purely-batch reactors, that is I inject the tracer and let it get to an uniform concentration. The latter is a continuous reactor (recirculating but similar to yours) so I was forced to change entirely the inlet concentration to a fixed value (saturated NaCl) end than monitor the outlet concentration. Of course this means that you just use your last time step for the previous simulation, you set the new C value to saturated NaCl and run again. The result will be the tracer slowly populate your domain.
I think a 1 min pulse can be useful only if your residence time is shorter then that... but probably these are just my 2 cents. In all of the reactors I don't have dead spaces where concentration gradients may stagnate but if this is your case, you may ponder to place various probes and follow their time course to see how the tracer distributes in the reactor.

Regarding turbulence, as I said before I use another solver so I cannot help you that much but searching the forum I found this:

http://www.cfd-online.com/Forums/ope...s-icofoam.html

As usual with OF, the turbulence model can be selected in the simulation properties so you just have to choose. Maybe simpleFOAM would be better for your needs, what do you think?

Let me know if I can further help you... I'll try to answer faster.

Luca

Hi Luca, thank you for your attention!

Sorry taking a while to reply, but I've been really busy.

I retake the simulations this week, and I'm trying to do something similar to what you said.. The difference is that I'm running simpleFoam (steady state) first until it converges, and then use the last time step as IC for pisoFoam (transient).
The problem is that I'm getting "Floating point exception" when running pisoFoam.. even after changing some parameters (k, epsilon, relTol..) indicated in others threads.

I'll try your way, and see how it goes! =)


All times are GMT -4. The time now is 04:48.