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

interFoam - validation for bubble/droplet flows in microfluidics

Register Blogs Members List Search Today's Posts Mark Forums Read

Like Tree28Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   September 3, 2018, 13:07
Default
  #41
New Member
 
Guang
Join Date: Feb 2015
Location: Stuttgart, Germany
Posts: 15
Rep Power: 5
stardust111 is on a distinguished road
Quote:
Originally Posted by dzordz View Post
I had the same issue with this compilation. For some reason linking in Make/options file to this twoPhaseMixtureThermo folder fails. What solved my problem (probably not smoothest solution) is adding an additional line in options -I/.....path to twoPhaseMixtureThermo folder.... \


Hope it helps.
Hi dzord,
thank you very much for your reply. I tried this too, this can pass the compilation procedure. But then there will be another error when using the new kva_compressibleInterFoam.

keyword water is undefined in dictionary "/home/xxxx/constant/thermophysicalProperties"

Since I used a variable surface tension of water, in the thermophysicalProperties it writes:

phases (water air);
pMin 10000;
sigma
{
type liquidProperties;
phase water;
}


but when I used the standard compressibleInterFoam solver, that error didn't occur. Did you meet this too?
stardust111 is offline   Reply With Quote

Old   September 4, 2018, 01:53
Default
  #42
New Member
 
Join Date: May 2016
Posts: 29
Rep Power: 4
dzordz is on a distinguished road
Hi!
I had not tried this with temperature dependent surface tension via liquid properties, but I had the same problem. The thing is the code has implemented a density weighing and requires the density input for both phases rho1_ and rho2_ in thermophysicalProperties. For example add:

water
{
transportModel Newtonian;
rho [1 -3 0 0 0 0 0] 1000;
}
air
{
transportModel Newtonian;
rho [1 -3 0 0 0 0 0] 1;
}


The issue for me was, that I have highly compressible air phase which density varies throughout my domain. So I turned the weighing off and it principle should work normally. So maybe add a dummy input in there
Cheers.
dzordz is offline   Reply With Quote

Old   September 4, 2018, 05:15
Default
  #43
New Member
 
Guang
Join Date: Feb 2015
Location: Stuttgart, Germany
Posts: 15
Rep Power: 5
stardust111 is on a distinguished road
Quote:
Originally Posted by dzordz View Post
Hi!
I had not tried this with temperature dependent surface tension via liquid properties, but I had the same problem. The thing is the code has implemented a density weighing and requires the density input for both phases rho1_ and rho2_ in thermophysicalProperties. For example add:

water
{
transportModel Newtonian;
rho [1 -3 0 0 0 0 0] 1000;
}
air
{
transportModel Newtonian;
rho [1 -3 0 0 0 0 0] 1;
}


The issue for me was, that I have highly compressible air phase which density varies throughout my domain. So I turned the weighing off and it principle should work normally. So maybe add a dummy input in there
Cheers.
Thanks again. I added the densities, but then got some other errors .
I think I should also turn off the DensidyWeighting, as the density is also not constant in my case. Could you please give me a clue about how to turn it off?

BEST


Create time

Create mesh for time = 0


PIMPLE: Operating solver in PISO mode

Reading field p_rgh

Reading field U

Reading/calculating face flux field phi

Constructing twoPhaseMixtureThermo

Selecting surfaceTensionModel liquidProperties
Selecting curvatureModel vofsmooth
Selecting surfaceTensionModel CSF(densityWeighted=0)
Selecting thermodynamics package
{
type heRhoThermo;
mixture pureMixture;
properties liquid;
energy sensibleInternalEnergy;
}

Selecting thermodynamics package
{
specie specie;
type heRhoThermo;
mixture pureMixture;
transport const;
thermo hConst;
energy sensibleInternalEnergy;
equationOfState perfectGas;
}

Reading thermophysical properties

#0 Foam::error:rintStack(Foam::Ostream&) at ??:?
#1 Foam::sigSegv::sigHandler(int) at ??:?
#2 ? in "/lib64/libc.so.6"
#3 ? at ??:?
#4 __libc_start_main in "/lib64/libc.so.6"
#5 ? at /home/abuild/rpmbuild/BUILD/glibc-2.22/csu/../sysdeps/x86_64/start.S:121
Segmentation fault (core dumped)
stardust111 is offline   Reply With Quote

Old   September 4, 2018, 05:21
Default
  #44
New Member
 
Join Date: May 2016
Posts: 29
Rep Power: 4
dzordz is on a distinguished road
I suggest that to see how it is done you look at the transportProperties that are included in the library compilation file you downloaded.

Nevertheless if there is no densityWeighted entry, the default is set to no, so you should be working with it turned off. Now I do not know why this error occurs for you. Maybe try compiling it yourself.
dzordz is offline   Reply With Quote

Old   September 4, 2018, 05:24
Default
  #45
New Member
 
Guang
Join Date: Feb 2015
Location: Stuttgart, Germany
Posts: 15
Rep Power: 5
stardust111 is on a distinguished road
Quote:
Originally Posted by dzordz View Post
I suggest that to see how it is done you look at the transportProperties that are included in the library compilation file you downloaded.

Nevertheless if there is no densityWeighted entry, the default is set to no, so you should be working with it turned off. Now I do not know why this error occurs for you.
Thanks. I will try to find it out.
stardust111 is offline   Reply With Quote

Old   November 5, 2018, 10:26
Default
  #46
Senior Member
 
floquation's Avatar
 
Kevin van As
Join Date: Sep 2014
Location: TU Delft, The Netherlands
Posts: 250
Rep Power: 14
floquation will become famous soon enough
I'm sorry, I haven't checked this forum for a while.

densityWeighted
densityWeighted is indeed off by default, but regardless of whether it is on or not, rho1_ and rho2_ are read during construction of the class.
I did implement this feature per some paper from Brackbill... But evidently this only makes sense if rho is constant. (And even if it is, I always leave it off, because I found it to negatively impact my cases.)

You could indeed add the lines @dzordz said to transportProperties, and then my code wills imply read them, but not use them. It's ugly, but it solves the problem...
However, my code is just an extension to OpenFOAM itself, and I do not know whether adding those values to transportProperties will in turn affect compressibleInterFoam aversely...

Instead, I propose hacking my code (which is, of course, also dirty, but it's at least guaranteedly safe).
Disclaimer: I did not try these changes, and it's been a while since I did this, so I might have made a syntax error:
In "interfaceProperties.C", rho1_ is read at line 135.
Replace the lookup statement:
Code:
transportPropertiesDict_.subDict( wordList(transportPropertiesDict_.lookup("phases"))[0] )
by
Code:
1
. (Here I assume that the dimensionedField constructor can also take a constant value, rather than a dictionary. I hope it can.)

Secondly, on line 235 it is also read. Replace:
Code:
transportPropertiesDict_.subDict( wordList(transportPropertiesDict_.lookup("phases"))[0] ).lookup("rho") >> rho1_; // KVA
by
Code:
rho1_ = 1;
. That should fix the values just in my code to one, which doesn't do anything as they aren't used if densityWeighted=off, while you leave the rest of OpenFOAM unaffect because your transportProperties file is now "clean".

Finally, do the same for rho2_.
Final-finally, recompile.

twoPhaseMixtureThermo
Quote:
Originally Posted by dzordz
I had the same issue with this compilation. For some reason linking in Make/options file to this twoPhaseMixtureThermo folder fails. What solved my problem (probably not smoothest solution) is adding an additional line in options -I/.....path to twoPhaseMixtureThermo folder.... \
It looks like twoPhaseMixtureThermo resides in a subfolder of the solver... But my automated getSolverMake.sh did not take that into account.
Without hacking my automated script, manually adding the absolute path to "twoPhaseMixtureThermo" is indeed the most elegant solution you can achieve.

of40-dev branch
For those of you who hadn't seen it, the GitHub has multiple branches: of40, of50 and of40-dev: my development branch with much more features.
In the meantime, I have ceased development as the focus of my work has changed considerably... But there are many useful additions in there, amongst which:The relevant papers are referenced in the .H files of each operator, being primarily:
Raeini, Ali Q., Martin J. Blunt, and Branko Bijeljic.
"Modelling two-phase flow in porous media at the pore scale using
the volume-of-fluid method."
Journal of Computational Physics 231, no. 17 (2012): 5653-5668

Perhaps those features can still be of use for someone.
floquation is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Setting BCs for Riverine Flows using Interfoam kflora OpenFOAM Running, Solving & CFD 35 September 20, 2018 12:35
CFX problem in ubuntu (linux) Vigneshramaero CFX 0 July 13, 2012 11:22
CFX-Pre problem, pls help!!! cth_yao CFX 0 February 17, 2012 01:52
validation for densely packed channel flows shefali Main CFD Forum 1 February 8, 2011 04:35
Validation tests for 3-D flows Alexey Main CFD Forum 1 January 6, 2000 00:48


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