CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   STAR-CCM+ (https://www.cfd-online.com/Forums/star-ccm/)
-   -   How to define volume of a fluid in star ccm+ using a field function? (https://www.cfd-online.com/Forums/star-ccm/164351-how-define-volume-fluid-star-ccm-using-field-function.html)

sarvesh34 December 19, 2015 11:11

How to define volume of a fluid in star ccm+ using a field function?
 
Hello

Can anyone help me define volume of a fluid in star ccm+ using a feild function.

Thnak you

Regards

Sarvesh

lcarasik December 20, 2015 13:33

Quote:

Originally Posted by sarvesh34 (Post 578123)
Hello

Can anyone help me define volume of a fluid in star ccm+ using a feild function.

Thnak you

Regards

Sarvesh

Can you give a few more details? Such as, are you trying to define a water level in a volume?

Also, please take a look at the VOF: Gravity Driven Flow tutorial of the user manual. It discusses some basics of VOF.

sarvesh34 December 21, 2015 16:23

Sir

I want to define a Liquid Steel level in a single strand tundish using a field function there is a tutorial that says you can define fluid levels by coordinats example:
The setup steps for the example in Figure 1 are shown below.
For the water:
Tools > Field Functions > New > User Field Function 1 > Properties
Type: Scalar
Function Name:Change User Field Function 1 to Initial_Height_Water
Definition: ($$Position[2]<=0.7)?1:0
For the oil:
Tools > Field Functions > New > User Field Function 1 > Properties
Type: Scalar
Function Name: Change User Field Function 1 to Initial_Height_Oil
Definition: ($$Position[2]>=0.7)?1:0
$$Position[2]: Z direction (height)

In my case my inlet is through the air level and submerged in the fluid. My tundish is of 1m height and 0.8m consist of liquid steel and the rest is air. My inlet consist of only liquid steel not air i just want to know how can I setup my field function definition. I am not able to share my image here if i can have your email id i can send it to you. let me know if you need any further details

Thank you

Ahmed Elhanafi April 23, 2016 12:03

1 Attachment(s)
Hi All,

I have the same problem discussed here. I need to assign Water (VOF) to specific volumes (two volumes).

The full domain is 0<=x<=10 m, 0<=y<=2 m, 0<=z<=10 m. The domain should contain air, while the following volumes should have water:

Volume1: 0<=x<=10, 0<=y<=2, 0<=z<=5
Volume2: 4<=x<=6, 0<=y<=2, 5<=z<=6

I know how to do this for one volume using a field function such as the following for Volume 1:
(0<=$$Centroid[0]<=10 && 0<=$$Centroid[1]<=2 && 0<=$$Centroid[2]<=5)?0.0 : 1.0.

For Volume 2:

(4<=$$Centroid[0]<=6 && 0<=$$Centroid[1]<=2 && 5<=$$Centroid[2]<=6)?0.0 : 1.0.

But I do not know how to combine them properly.

Would you please help me solving this problem.

Attached is a simple description of what I'm looking for.

Cheers,

Ahmed

sarvesh34 April 24, 2016 05:00

Hello!

Is your domain square or cylinder?
Can you send me your simulation file?
sarvesh34@gmail.com
I can try it!!

Thanks

Ahmed Elhanafi April 25, 2016 11:53

1 Attachment(s)
Hi All,

I figured out how to combine the two field functions using a || logical operator.

Now it works, and using a scene to show the selected/combined field function.

Attached is the outcome.

Cheers,

Ahmed


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