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

No change in phase change using interPhaseChangeFoam

Register Blogs Community New Posts Updated Threads Search

Like Tree2Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 22, 2014, 09:57
Default No change in phase change using interPhaseChangeFoam
  #1
New Member
 
Reza
Join Date: Feb 2013
Posts: 8
Rep Power: 13
Reza_CFD is on a distinguished road
Hello friends,
I would like to simulate pool boiling in a box, using interPhaseChangeFoam. I am using OpenFOAM 2.3.
However, I cannot see any change in alpha.water, although the temperature of the walls are higher than saturated temperature.
Is anybody here to help me?

Thanks,
Reza
Reza_CFD is offline   Reply With Quote

Old   August 22, 2014, 12:08
Default
  #2
New Member
 
Reza
Join Date: Feb 2013
Posts: 8
Rep Power: 13
Reza_CFD is on a distinguished road
That's very weird since the temperature field covers a broad range of temperature, including below and above the saturation temperature. However, I don't see any change in alpha.water as such it remains one.
Have you ever encountered this issue?

Thanks
Reza_CFD is offline   Reply With Quote

Old   August 22, 2014, 15:14
Default
  #3
New Member
 
Reza
Join Date: Feb 2013
Posts: 8
Rep Power: 13
Reza_CFD is on a distinguished road
I think I got the reason, however I cannot solve the issue.
In fact, I am modifying the interPhaseChangeFoam based on the work by Andersen at http://www.tfd.chalmers.se/~hani/kur...ChangeFoam.pdf

When I add the temperature equation, I cannot see change in volume fractions of water.
Is there any comment, help?

Thanks
Reza_CFD is offline   Reply With Quote

Old   August 24, 2014, 10:41
Default
  #4
New Member
 
Reza
Join Date: Feb 2013
Posts: 8
Rep Power: 13
Reza_CFD is on a distinguished road
Seems nobody is interested.
Reza_CFD is offline   Reply With Quote

Old   August 24, 2014, 10:44
Default
  #5
New Member
 
Reza
Join Date: Feb 2013
Posts: 8
Rep Power: 13
Reza_CFD is on a distinguished road
The problem in this work is that I get negative temperature.
Do you have any clue to resolve this problem?

Thanks
Reza_CFD is offline   Reply With Quote

Old   August 26, 2014, 15:36
Default Bug in interPhaseChangeFoam 2.1.x
  #6
Member
 
Parisa
Join Date: Feb 2013
Posts: 51
Rep Power: 13
Parisa_Khiabani is on a distinguished road
Hey Reza,
Did you solve your problem? Please let me know since I think my case is very similar to yours.

Thanks,
Parisa

-----

I am aware that there have been lots of discussions about bugs in interPhaseChangeFoam in 2.1.0 and then the bug was resolved in 2.1.x.
However, I am following the tutorial by Martin Andersen and I added the energy equation as well as temperature dependent PSat.
But, I got completely unrealistic results. PSat become zero in many places in the domain since the temperature dropped much below zero.
Is there any solution for that?

Thanks,
Parisa

Last edited by wyldckat; August 30, 2014 at 09:36. Reason: merged 2 threads on the same topic, and merged two posts to make it a bit more consistent
Parisa_Khiabani is offline   Reply With Quote

Old   August 26, 2014, 15:42
Default
  #7
Member
 
Parisa
Join Date: Feb 2013
Posts: 51
Rep Power: 13
Parisa_Khiabani is on a distinguished road
Please let me clarify myself.
The energy equation is solved without any problem, and actually I obtained reasonable temperature distribution.
However, as soon as the temperature dependent PSat is inserted, the solver becomes confused and generate some unrealistic results.
So, I think the problem is coupling between PSat and temperature distribution.
I appreciate if you help me at this.

Thanks,
Parisa
Parisa_Khiabani is offline   Reply With Quote

Old   August 26, 2014, 18:18
Default
  #8
Member
 
Parisa
Join Date: Feb 2013
Posts: 51
Rep Power: 13
Parisa_Khiabani is on a distinguished road
I also have the same problem with OpenFOAM 2.2.x.

Any help?
Parisa_Khiabani is offline   Reply With Quote

Old   August 27, 2014, 13:40
Default
  #9
Member
 
Parisa
Join Date: Feb 2013
Posts: 51
Rep Power: 13
Parisa_Khiabani is on a distinguished road
Just more updates on my problem.
I am solving the same case in OpenFOAM 2.3. In fact there is no phase change inside the domain.
I am looking forward to hearing from you guys,

Thanks,
Parisa
Parisa_Khiabani is offline   Reply With Quote

Old   August 27, 2014, 19:14
Default
  #10
Member
 
Parisa
Join Date: Feb 2013
Posts: 51
Rep Power: 13
Parisa_Khiabani is on a distinguished road
Please, I am really anticipating any kind of help.

Parisa
Parisa_Khiabani is offline   Reply With Quote

Old   August 30, 2014, 09:44
Default
  #11
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,975
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Greetings to all!

I've merged your two threads into a single one, since almost the exact same problem. This way it makes it easier for other people to find this thread to help or to find help in any answers that can arise.

Regarding your questions, I've taken a quick look at the PDF by Andersen, that Reza pointed out, and the first detail that popped up to me was: the original author used OpenFOAM 2.0.x.

Now, you might not be familiar with how OpenFOAM evolves over time, but from personal experience I can tell you that solvers can change considerably between versions of OpenFOAM, therefore the probabilities of making an example that works on 2.0.x, work on 2.1.x or 2.3.x, requires some considerable time and experience.

Therefore, the first step you should take is to install OpenFOAM 2.0.x and then test the case with that version.

Secondly, it takes quite some time to set-up an example case that you're working on, therefore it makes it a lot harder for someone with more experience to step in and spend 2-5h trying to reproduce the same steps. Therefore, please read, study and follow these instructions: http://www.cfd-online.com/Forums/ope...-get-help.html

Best regards,
Bruno
__________________
wyldckat is offline   Reply With Quote

Old   September 4, 2014, 17:18
Default Follow up
  #12
New Member
 
Reza
Join Date: Feb 2013
Posts: 8
Rep Power: 13
Reza_CFD is on a distinguished road
First of all thanks from wyldckat for the nice and professional explanation.
Parisa:

I am sorry for delay in response. I solved that issue. However, I am changing the solver and I am using interFoam. I updated the solver with mass transfer and temperature distribution. I hesitate sending the code to you since it's not complete yet.
Maybe the experts can help me, then I will resolve the problem and make the code ready for you.
The problem is that the code is running for some time steps, I get boiling, and/or condensation. The results are convincing and somehow I validated with some solid results.
However, after a while, the courant number increases rapidly and the rsults are ruined such that the volume fractions reach to -50 and +600.
I use very low deltaT, and also adjustdeltaT is on.
Any help, comment. suggestion from experts?

Thanks everybody for the nice cooperation.
Reza

Quote:
Originally Posted by wyldckat View Post
Greetings to all!

I've merged your two threads into a single one, since almost the exact same problem. This way it makes it easier for other people to find this thread to help or to find help in any answers that can arise.

Regarding your questions, I've taken a quick look at the PDF by Andersen, that Reza pointed out, and the first detail that popped up to me was: the original author used OpenFOAM 2.0.x.

Now, you might not be familiar with how OpenFOAM evolves over time, but from personal experience I can tell you that solvers can change considerably between versions of OpenFOAM, therefore the probabilities of making an example that works on 2.0.x, work on 2.1.x or 2.3.x, requires some considerable time and experience.

Therefore, the first step you should take is to install OpenFOAM 2.0.x and then test the case with that version.

Secondly, it takes quite some time to set-up an example case that you're working on, therefore it makes it a lot harder for someone with more experience to step in and spend 2-5h trying to reproduce the same steps. Therefore, please read, study and follow these instructions: http://www.cfd-online.com/Forums/ope...-get-help.html

Best regards,
Bruno
Reza_CFD is offline   Reply With Quote

Old   September 6, 2014, 14:38
Default
  #13
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,975
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Hi Reza,

Quote:
Originally Posted by Reza_CFD View Post
The problem is that the code is running for some time steps, I get boiling, and/or condensation. The results are convincing and somehow I validated with some solid results.
However, after a while, the courant number increases rapidly and the rsults are ruined such that the volume fractions reach to -50 and +600.
I use very low deltaT, and also adjustdeltaT is on.
Any help, comment. suggestion from experts?
Mmm... OK, not much information to work with. There are several possibilities that come to my mind:
  1. The mesh is to blame, because it has either very big, very small or bad looking cells. Have a look at this blog post of mine, to better understand what I'm referring to: OpenFOAM: Interesting cases of bad meshes and bad initial conditions - more specifically, "Case two", which is the one conceptually more similar.
  2. Still from the previous link and case, you'll notice how I diagnosed the problem. More specifically, instead of being only interested in the solution and writing only occasional time snapshots, I configured it to write as many time steps as possible, so that I could carefully examine how the flow behaved in certain locations.
  3. When dealing with evaporation, it's easy to enter the compressible working range. Perhaps you should use compressibleInterFoam instead.
  4. I'm also guessing here, but probably you're reaching temperatures or pressure differences that are not contemplated by the simulation model you're using.
  5. Running in parallel can sometimes give unexpected results. When developing a new solver, you should always only run in serial, until you are able to have a properly working and tested solver. Then run in parallel the same validated case, to diagnose if it still gives you the same results.
Best regards,
Bruno
__________________
wyldckat is offline   Reply With Quote

Old   March 29, 2015, 06:07
Default
  #14
Senior Member
 
Join Date: May 2011
Posts: 231
Rep Power: 15
Kanarya is on a distinguished road
Hi Reza,

I am interested in condensation and do you think interFoam is more suitable to solve the problem in comparison to interPhaseChangeFoam?
Did you managed to solve the problem?
Thanks in advance!
best regards,

Quote:
Originally Posted by Reza_CFD View Post
First of all thanks from wyldckat for the nice and professional explanation.
Parisa:

I am sorry for delay in response. I solved that issue. However, I am changing the solver and I am using interFoam. I updated the solver with mass transfer and temperature distribution. I hesitate sending the code to you since it's not complete yet.
Maybe the experts can help me, then I will resolve the problem and make the code ready for you.
The problem is that the code is running for some time steps, I get boiling, and/or condensation. The results are convincing and somehow I validated with some solid results.
However, after a while, the courant number increases rapidly and the rsults are ruined such that the volume fractions reach to -50 and +600.
I use very low deltaT, and also adjustdeltaT is on.
Any help, comment. suggestion from experts?

Thanks everybody for the nice cooperation.
Reza
Kanarya is offline   Reply With Quote

Old   April 17, 2015, 23:16
Default
  #15
Senior Member
 
Mihai Pruna
Join Date: Apr 2010
Location: Boston
Posts: 195
Rep Power: 16
mihaipruna is on a distinguished road
there is one extra step for Martin Andersen's tutorial that is not specified I believe:

you have to recompile the phaseChangeTwoPhaseMixture, by going in that folder and typing wclean and then wmake.
Make sure you first go in the file called files in the make folder in phaseChangeTwoPhaseMixture and change to LIB= $(FOAM_USER_LIBBIN) etc instead of $(FOAM_LIBBIN)

then (dunno if you need to do that) do wmake from the myInterPhaseChangeFoam folder

This at least makes the alpha change, not sure about the results
fuku likes this.
__________________
Mihai Pruna's Bio
mihaipruna is offline   Reply With Quote

Old   April 21, 2015, 06:39
Default
  #16
Senior Member
 
Join Date: May 2011
Posts: 231
Rep Power: 15
Kanarya is on a distinguished road
thanks for the answer!

did you implement is to latest version of OF or 210?
Quote:
Originally Posted by mihaipruna View Post
there is one extra step for Martin Andersen's tutorial that is not specified I believe:

you have to recompile the phaseChangeTwoPhaseMixture, by going in that folder and typing wclean and then wmake.
Make sure you first go in the file called files in the make folder in phaseChangeTwoPhaseMixture and change to LIB= $(FOAM_USER_LIBBIN) etc instead of $(FOAM_LIBBIN)

then (dunno if you need to do that) do wmake from the myInterPhaseChangeFoam folder

This at least makes the alpha change, not sure about the results
Kanarya is offline   Reply With Quote

Old   April 21, 2015, 08:59
Default
  #17
Senior Member
 
Mihai Pruna
Join Date: Apr 2010
Location: Boston
Posts: 195
Rep Power: 16
mihaipruna is on a distinguished road
Version 2.3.1
The tutorial should be applied pretty much the same way except for the extra compilation for the libraries i mentioned

Also there is a Tfinal field in fvSolution which I made the same as T, not sure what it does yet

You don't have to do this part: #include "../interFoam/correctPhi.H"

I am still having issues with Courant number blowing up
__________________
Mihai Pruna's Bio
mihaipruna is offline   Reply With Quote

Old   April 24, 2015, 09:17
Default
  #18
Senior Member
 
Mihai Pruna
Join Date: Apr 2010
Location: Boston
Posts: 195
Rep Power: 16
mihaipruna is on a distinguished road
I think I have figure out how to get decent behavior, with decent time step size that allows you to simulate over longer periods of time.

I believe the evaporation rate was unphysical.
I used the Kunz model into the transport properties and looked deeper into how the coefficients are determined:
dimensionedScalar UInf_;
dimensionedScalar tInf_;
dimensionedScalar Cc_;
dimensionedScalar Cv_;

Uinf is the reference velocity, I set it to something like 1m/s.
tinf I set dividing the diameter of the vessel by Uinf.

Cc_ and Cv_ are proportional to the phase change rate.In a nutshell, the smaller they are, the smaller the evaporation rate, which would in turn lowers the maximum Courant number it gets to.
In this paper: http://www.personal.psu.edu/faculty/...MEsummer99.pdf they were set to 0.2, which are values determined experimentally.
Of course, you might have to set different numbers, especially since you are not doing cavitation, but rather, boiling.

What I plan to do next is correlate the volume fraction/time obtained from CFD with a simple system analysis spreadsheet I did for my vessel, where I can vary some parameters and observe the boiling through basic formulas independent of geometry save for general sizing.

Then I will change the Cc_ and Cv_ values accordingly to match the same evaporation rate on gross terms.
__________________
Mihai Pruna's Bio
mihaipruna is offline   Reply With Quote

Old   May 27, 2015, 04:14
Default
  #19
Senior Member
 
Join Date: May 2011
Posts: 231
Rep Power: 15
Kanarya is on a distinguished road
Hi,
I am not getting the correct results from when I set the inlet BC for alpha =0 which is vapur...I do not see any condensation in side the tube..what kind of geometry are you using? I am trying t simulate pipe flw but I am not sure about alpha and p_rgh BC?
do you have any idea?

Thanks in advance!


Quote:
Originally Posted by mihaipruna View Post
I think I have figure out how to get decent behavior, with decent time step size that allows you to simulate over longer periods of time.

I believe the evaporation rate was unphysical.
I used the Kunz model into the transport properties and looked deeper into how the coefficients are determined:
dimensionedScalar UInf_;
dimensionedScalar tInf_;
dimensionedScalar Cc_;
dimensionedScalar Cv_;

Uinf is the reference velocity, I set it to something like 1m/s.
tinf I set dividing the diameter of the vessel by Uinf.

Cc_ and Cv_ are proportional to the phase change rate.In a nutshell, the smaller they are, the smaller the evaporation rate, which would in turn lowers the maximum Courant number it gets to.
In this paper: http://www.personal.psu.edu/faculty/...MEsummer99.pdf they were set to 0.2, which are values determined experimentally.
Of course, you might have to set different numbers, especially since you are not doing cavitation, but rather, boiling.

What I plan to do next is correlate the volume fraction/time obtained from CFD with a simple system analysis spreadsheet I did for my vessel, where I can vary some parameters and observe the boiling through basic formulas independent of geometry save for general sizing.

Then I will change the Cc_ and Cv_ values accordingly to match the same evaporation rate on gross terms.
Kanarya is offline   Reply With Quote

Old   May 27, 2015, 07:45
Default
  #20
Senior Member
 
Mihai Pruna
Join Date: Apr 2010
Location: Boston
Posts: 195
Rep Power: 16
mihaipruna is on a distinguished road
As I posted earlier in the thread, to get it to work for me, I had to recompile
phaseChangeTwoPhaseMixture
__________________
Mihai Pruna's Bio
mihaipruna is offline   Reply With Quote

Reply


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
help for simulation phase change sudni COMSOL 0 January 17, 2014 02:47
homogeneous free surface flow with phase change. Niru CFX 13 December 26, 2013 10:27
Pressure Outlet for phase change simulation dinesh FLUENT 0 November 21, 2013 23:50
Solid/liquid phase change fabian_roesler OpenFOAM 10 December 24, 2012 06:37
Two phase flow with phase change Ahmad Al-Zoubi CFX 1 November 26, 2008 03:59


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