CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   STAR-CCM+ (http://www.cfd-online.com/Forums/star-ccm/)
-   -   Bubble Modeling in Star-CCM+ (http://www.cfd-online.com/Forums/star-ccm/106203-bubble-modeling-star-ccm.html)

tayo August 21, 2012 18:50

Bubble Modeling in Star-CCM+
 
Please I urgently need your help guys. I'm very new to Star-CCM+ and I want to model a gas bubble rising inside a liquid. I intend to use VOF for the 2-phase but Star-CCM+ does not model "particles" on VOF so I selected Lagrangian multiphase in order to model the bubble as a particle. Since I want 2-phase and not 3-phase, my volume fractions for the VOF was 1:0 for the initial and boundary conditions. Here are my questions?

1) Is this volume fraction assumption correct?

2) Do I need to create a region / interface so that I can track the bubble movement in the velocity field? How do I do this?

3) A mini tutorial on simulating bubble flow using star-ccm+ will be highly appreciated. Note: I"m using the 6.04 version and the none of the tutorials really simulate a bubble flow itself. Also note that I don't want to use segregated multiphase model.

4) Is it possible to couple level set method to the VOF used in star-ccm+? Simply put, how can I use CLSVOF here?

Thanks in advance.

siara817 August 22, 2012 06:14

Hi,
Have you tried Eulerian.
Search this phrase in tutorial
Bubble Formation in a Fluidized Bed
Otherwise, in lagrangian multiphase, you can add Track Model to track the particles and then show later by a streamline.
good luck

tayo August 22, 2012 12:04

Thanks Siamak.

Actually, VOF is an eulerian model but because it does not explicitly model bubble, I'm combining it with Lagrangian. As for the track model, I'm already applying it, I'm just new to it. There is no "bubble formation in fluidized bed" in my user guide and even the "fluidized bed" available just mentions that it is applicable in solid dispersed phase for drag model. Because I want only 2-phase i.e. VOF and lagrangian for each phase, I quietly set the volume fraction for the eulerian to 1:0 for the initial and BCs to ensure that only one phase is active in the eulerian. Do you have any material/tutorial that can guide me? Do you know how starccm couples eulerian and lagrangian? What about CLSVOF, any hope about it in Star-ccm+? Thanks.

Ladnam August 24, 2012 04:13

If you want to model only one bubble then I would have used only VOF. With surface tension if the bubble is small. For many bubbles I would have used lagrangian or segregated multiphase (Eulerian).

tayo August 28, 2012 12:41

Thanks Ladnam. I've stopped using Lagrangian and segregated flow and I'm just focusing on VOF. Apparently, I need adaptive meshing so that it can track the bubble dynamics. Does anyone know how to do this on star-CCM+? I've searched the user-guide and online, nothing at all. Does this imply that star-ccm+ cannot be used to model a single bubble? Please help.

abdul099 August 28, 2012 19:29

Adaptive mesh refinement is not yet available in Star-CCM+.

When you want to model bubbles using VOF, you should have a very fine mesh to resolve the bubbles with a sufficient number of cells.
Also keep the CFL number low or your solution will smear and your bubbles might disappear.

tayo August 29, 2012 11:16

1 Attachment(s)
Thanks abdul.

I'm using a very fine mesh but here are the issues:
1) I tried to separate the liquid and gas into distinct regions by creating two geometries (the circle is meant to represent the bubble) and two meshes to form two regions with an interface created. Then, I assigned each mesh to each region after specifying each phase for each region. The bubble (circle) is meant to be initialized at a specific distance. Unfortunately, the phases were still not distinct after running the simulation. Find attachment below.

Obviously, there should be a better way. I'm new to star-ccm+.

2)How do I get the bubble to rise as it runs. The motion specification icon at the physics value of the bubble region is stationary by default setting and I don't know how to change it.

Please I need help/guide on how to model this bubble. I will appreciate any advice/help from anyone else. Please send any useful material to msgenius10@yahoo.com. Thanks.

abdul099 August 29, 2012 15:51

Well, it all depends on what you exactly try to do, or to be precise, what you want to achieve. Just as an example, what diameter does the bubble have? When it's a "very small" bubble, it's pretty simple, but all hints will not help when it's a big bubble. So please give a little more information, especially about domain and bubble size, fluid types (viscosity, densities), time scales etc.

When you're just doing a VOF simulation, I think you don't need to have two separate regions. You can also initialize with a field function.

But to give you some food for thoughts:
How did you judge your mesh to be fine enough? Can you post some pictures?
Did you switch on gravity?
What about the time step size? What Courant numbers result from your settings?
What boundary do you have at the top side? When it's a pressure outlet, are you aware, there might be liquid leave your domain?

tayo August 29, 2012 21:07

Thanks abdul. My bubble is 10mm diameter, placed in a 100mm by 80mm 2-D domain. The 2-phases have densities of 1.1kg/m3 and 868kg/m3 with a surface tension coefficient of 0.0289N/m. Cell number generated is 332700, vertices number is 1688296 and face number of 1685736, could my mesh be too refined? Surface remesher and polyhedral mesh models were used to generate a 3D mesh and then, it was converted to 2D mesh. Flow is isothermal for now.

Gravity is already placed in the y-direction. BCs are all wall except at the top where the pressure is O(1MPa). Courant number used is less than one (I'm actually using default setting for now) and time step is 5e-6. I was initially using pressure outlet (thanks for pointing that out, I noticed that too), what's an advisable BC to use? Can you give more details about the use of field function?

Please any useful advice/tutorial will be highly appreciated (find my email add in previous reply). I'm new to star-ccm+. Thanks

abdul099 August 30, 2012 19:04

A too fine mesh will not cause issues except for computing time. I'm not sure about the cell count. Are the ~332700 cell from 2D representation or is it the total number including the 3D mesh where the 2D mesh was created from? Could you please post a picture of your mesh?

I think a pressure outlet at the top is fine, but I would put it away from the liquid surface.

I'll look into this in the next week since I'll out for a few days and don't have access to my machine. Hopefully somebody else can support you in the meantime, otherwise it will take some time until I get back to you.

tayo September 4, 2012 09:48

It was the 3D mesh that had the 332700 cell numbers. However, the z-direction was just 0.1mm thick compared to the other directions with 100mm and 80mm. I will be expecting your response / email to me. Thanks

abdul099 September 6, 2012 15:44

Quote:

Originally Posted by tayo (Post 380145)
However, the z-direction was just 0.1mm thick compared to the other directions with 100mm and 80mm.

That means, your domain is very thin, which might cause bad quality cells while volume meshing. I think it would be better to have a thicker 3D region
just to keep the initial cell quality high. It will not harm afterwards since the 2D region will not contain more cells.
I would also use a trimmed mesh instead of a poly mesh, it's quicker to generate, needs less memory, is faster to solve and the motion of your bubble will be pretty much aligned with mesh lines.

However, the mesh should be fine enough since in my case it worked well even with a poly mesh and a thin region. My 3D region had approx. 340 000 cells, the 2D region approx. 160 000. My results are looking pretty nice with a time step of 1e-4s. To keep it simple, I initialized the phases with a square, not a circle. The bubble rises, forming the typical "mushroom shape" (it looks similar to an atomic cloud). Also my results don't smear that much at the top boundary.
Are you sure, you've put the right volume fractions on the top boundary? Maybe there's liquid entering the domain instead of N2.

Which version of Star-CCM+ do you use? I've created the model with v7.02 and can provide you the sim-file when needed.

tayo September 8, 2012 11:18

Quote:

Originally Posted by abdul099 (Post 380624)
That means, your domain is very thin, which might cause bad quality cells while volume meshing. I think it would be better to have a thicker 3D region
just to keep the initial cell quality high. It will not harm afterwards since the 2D region will not contain more cells.
I would also use a trimmed mesh instead of a poly mesh, it's quicker to generate, needs less memory, is faster to solve and the motion of your bubble will be pretty much aligned with mesh lines.

However, the mesh should be fine enough since in my case it worked well even with a poly mesh and a thin region. My 3D region had approx. 340 000 cells, the 2D region approx. 160 000. My results are looking pretty nice with a time step of 1e-4s. To keep it simple, I initialized the phases with a square, not a circle. The bubble rises, forming the typical "mushroom shape" (it looks similar to an atomic cloud). Also my results don't smear that much at the top boundary.
Are you sure, you've put the right volume fractions on the top boundary? Maybe there's liquid entering the domain instead of N2.

Which version of Star-CCM+ do you use? I've created the model with v7.02 and can provide you the sim-file when needed.


Thank you for your time abdul. To get this right, what was the thickness of your z-direction? After generating your 3D mesh, did you convert to 2D mesh? How did you initialize the phases with either a square or a circle? What if I want to work in 3D, can how do I initialize with a sphere or cuboid? To prevent liquid from entering the domain, what BC did you use? I use star-ccm+ v6.04. What volume fraction did you use? Kindly guide me right by answering these questions. I use star-ccm+ v6.04. Please send me your sim-file and whatever info you think would be relevant. My email address is msgenius10@yahoo.com. Thank you.

abdul099 September 15, 2012 16:25

I run a 2D case, so I created a 3D mesh and converted it to a 2D mesh. This means, there is only one cell layer in the z-direction.

I've initialized the domain with a square, by using a field function:
$$Position[0]>=0.045&&$$Position[0]<=0.055&&$$Position[1]>=0.015&&$$Position[1]<=0.025?1:0
A circle would work in a similar way, e.g. sqrt(pow($$Position[0],2)+pow($$Position[1],2))<="radiusOfTheBubble"?1:0 (Not tested). It also might work with local coordinate systems, just have a look in the user guide.
In 3D, it works exactly the same way, you just need to add the third dimension in a similar way.

I've used a pressure outlet boundary condition at the top. A little of the liquid will disappear through the boundary, but I didn't care since it was only a test case. You might put the boundary a little away from the position you want to have liquid surface and initialize according to the intended liquid level.
To make sure there will be no liquid enter the domain, you just need to specify the right volume fraction. Nothing magic.

I could send you the sim-file, but you won't be able to open it. You can't open a sim-file created with a specific version with an older version of Star-CCM+.

tayo September 15, 2012 16:46

Thanks abduls. That would surely help. I didn't realize that it was similar way to initialize in Star-ccm+ just like funkySetField in OpenFoam. Thank you so much.

bryan he October 3, 2012 18:40

Hi Abdul099,
I just start to do a similar 3D case. At first, I was thinking to use lagrangian multiphase, because I just want to simulate a single bubble. But since you've already done it, I'll follow you.
Here is the difference between your case and mine. I'll make the right and left boundary to be periodic interfaces. And, firstly, there is no flow passing the domain. Secondly, I'll add a certain flow over the domain. Do you have any suggestion about that?
And if you can send me your sim.file, that'll be very helpful! I'm using version 7.04.006.
Bryan


Quote:

Originally Posted by abdul099 (Post 381946)
I run a 2D case, so I created a 3D mesh and converted it to a 2D mesh. This means, there is only one cell layer in the z-direction.

I've initialized the domain with a square, by using a field function:
$$Position[0]>=0.045&&$$Position[0]<=0.055&&$$Position[1]>=0.015&&$$Position[1]<=0.025?1:0
A circle would work in a similar way, e.g. sqrt(pow($$Position[0],2)+pow($$Position[1],2))<="radiusOfTheBubble"?1:0 (Not tested). It also might work with local coordinate systems, just have a look in the user guide.
In 3D, it works exactly the same way, you just need to add the third dimension in a similar way.

I've used a pressure outlet boundary condition at the top. A little of the liquid will disappear through the boundary, but I didn't care since it was only a test case. You might put the boundary a little away from the position you want to have liquid surface and initialize according to the intended liquid level.
To make sure there will be no liquid enter the domain, you just need to specify the right volume fraction. Nothing magic.

I could send you the sim-file, but you won't be able to open it. You can't open a sim-file created with a specific version with an older version of Star-CCM+.


abdul099 October 13, 2012 06:07

Well, your first case is pretty much the same, nothing special.

The second case, when you add the flow over the domain, might be more challenging. The issue is, with periodic boundary conditions, you're restricted how you specify the flow crossing your domain. The options at a periodic boundary, pressure jump and mass flow rate, are both not suitable to control the velocity. I don't know what happens when the bubble leaves the domain since the lower density would cause a reduced mass flow rate. I suspect the solver to adjust the velocity. Maybe you can solve it with a field function by taking the average density at the interface into account.

So you might play around with the available options to get the expected result.

t0m November 18, 2012 04:17

(VOF video)
 
Thought I'd share a VOF Bubble Video I made some time ago.

Woo! Multiple Bubbles!

http://www.youtube.com/watch?v=Kf8PlBkqBSg

Have fun! :-)

kman87 December 4, 2012 23:15

Bubble rise in StarCCM+
 
Hi Abdul, would you mind sending me the below case as well, I'm very confused on how to use STARCCM+ interface tracking capability compare to other CFD codes.

(any version of star works) thanks!

Quote:

Originally Posted by abdul099 (Post 381946)
I run a 2D case, so I created a 3D mesh and converted it to a 2D mesh. This means, there is only one cell layer in the z-direction.

I've initialized the domain with a square, by using a field function:
$$Position[0]>=0.045&&$$Position[0]<=0.055&&$$Position[1]>=0.015&&$$Position[1]<=0.025?1:0
A circle would work in a similar way, e.g. sqrt(pow($$Position[0],2)+pow($$Position[1],2))<="radiusOfTheBubble"?1:0 (Not tested). It also might work with local coordinate systems, just have a look in the user guide.
In 3D, it works exactly the same way, you just need to add the third dimension in a similar way.

I've used a pressure outlet boundary condition at the top. A little of the liquid will disappear through the boundary, but I didn't care since it was only a test case. You might put the boundary a little away from the position you want to have liquid surface and initialize according to the intended liquid level.
To make sure there will be no liquid enter the domain, you just need to specify the right volume fraction. Nothing magic.

I could send you the sim-file, but you won't be able to open it. You can't open a sim-file created with a specific version with an older version of Star-CCM+.


MartiJ March 31, 2013 10:35

Hi T0m,

Cool animation you have:)!

Could you say if it was 2D/3D and what was the mesh size to capture the interface of these relatively small bubbles?

Actually, what was the minimum size of the bubbles you were able to resolve in your case?

Cheers!

Marti


All times are GMT -4. The time now is 12:40.