CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > FLUENT

Dynamic mesh without udf file

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 4, 2020, 05:34
Default Dynamic mesh without udf file
  #1
New Member
 
Viktor
Join Date: Apr 2020
Posts: 17
Rep Power: 6
vodoley is on a distinguished road
Hello,

Can I use and a dynamic mesh without using of UDF file?

The problem is simple. 2D, some rectangular region with air. Side walls - walls. Bottom - velocity inlet with U m/s, Upper boundary - pressure outlet. We have also 1 or 2 rigid bodyes (circules) placed in the air. Gravity (-9.81) is on.

Can I use and a dynamic mesh without using of UDF profile? Can the motion of rigid circules be determined by the flow calculations only (using Gravity g and U)?

vodoley is offline   Reply With Quote

Old   April 6, 2020, 06:12
Default 6dof
  #2
Senior Member
 
vinerm's Avatar
 
Vinerm
Join Date: Jun 2009
Location: Nederland
Posts: 2,946
Blog Entries: 1
Rep Power: 35
vinerm will become famous soon enough
Older versions of Fluent always needed a UDF to provide properties of the object that has degrees of freedom. However, newer version do not need it. There are options to specify the properties within the GUI. There is not UDF needed for profile. Profile is required if user wants to specify the motion of the solid body. If user wants Fluent to determine the motion based on the flow, then 6DOF is to be used. If you want to specify the motion, you can use text based profile file. Here, all 6 motions (3 in 2D; two translations and one rotation) can be specified via a simple file.
__________________
Regards,
Vinerm

PM to be used if and only if you do not want something to be shared publicly. PM is considered to be of the least priority.
vinerm is offline   Reply With Quote

Old   April 6, 2020, 09:35
Default
  #3
New Member
 
Viktor
Join Date: Apr 2020
Posts: 17
Rep Power: 6
vodoley is on a distinguished road
Thanks for reply.

I turned ON 6DOF option. But when I press Create button I receve message that there is no UDF profile. May be I should specify something else within the GUI?







The geometry is simple:



vodoley is offline   Reply With Quote

Old   April 6, 2020, 09:54
Default SDOF Properties
  #4
Senior Member
 
vinerm's Avatar
 
Vinerm
Join Date: Jun 2009
Location: Nederland
Posts: 2,946
Blog Entries: 1
Rep Power: 35
vinerm will become famous soon enough
Do you observe the option Six DOF UDF/Properties drop-down menu on the window? This is meant to provide properties of the solid object that is in motion. In newer versions, you can provide numbers via GUI but in older one, you have to use UDF.
__________________
Regards,
Vinerm

PM to be used if and only if you do not want something to be shared publicly. PM is considered to be of the least priority.
vinerm is offline   Reply With Quote

Old   April 6, 2020, 12:02
Default
  #5
New Member
 
Viktor
Join Date: Apr 2020
Posts: 17
Rep Power: 6
vodoley is on a distinguished road
Yes, but "Six DOF UDF/Properties" drop-down menu is empty. May be I should specify something else within Fluent... I don't know where.

P.S. Of couse I can do unnecessary action in my problem described above (imho) and specify some property of rigid bodyes (density for example) whithout specifing any motion. But I cannot connect Fluent with Microsoft Visual Studio compiler...
vodoley is offline   Reply With Quote

Old   April 6, 2020, 13:41
Default SixDOF
  #6
Senior Member
 
vinerm's Avatar
 
Vinerm
Join Date: Jun 2009
Location: Nederland
Posts: 2,946
Blog Entries: 1
Rep Power: 35
vinerm will become famous soon enough
You have to select option Six DOF on the right. Then click on Settings and create a Six DOF object. Then, it will automatically appear in the list.

To connect VS, you can go to Command Prompt of VS; not the usual command prompt. Then start Fluent from this Visual Studio Command Prompt and compile the UDF.
__________________
Regards,
Vinerm

PM to be used if and only if you do not want something to be shared publicly. PM is considered to be of the least priority.
vinerm is offline   Reply With Quote

Old   April 7, 2020, 02:12
Smile
  #7
New Member
 
Viktor
Join Date: Apr 2020
Posts: 17
Rep Power: 6
vodoley is on a distinguished road
Thank you, you helped me a lot!
vodoley is offline   Reply With Quote

Old   April 26, 2020, 05:44
Default
  #8
New Member
 
Viktor
Join Date: Apr 2020
Posts: 17
Rep Power: 6
vodoley is on a distinguished road
Hello! I still keep performing the task described above.

2D, some rectangular region with air (160x160 mm). Side walls - walls. Bottom - velocity inlet with U m/s, Upper boundary - pressure outlet. We have also One rigid body (droplet 20 mm diam) placed in the air.

Gravity (-9.81) is ON. Multiphase is OFF.

I want to determine motion of the droplet (using Gravity g and air flow from the bottom U m/s).

In 'Dynamic mesh' I created 'droplet' 1e-06 kg:





I also created two Dynamic mesh zones: 'droplet' (SixDOF is on) and 'droplet_walls' (SixDOF is on; SixDOF is passive)



Velocity U is very big:



AND something wrong... My very light Droplet falls down in time. But with such a high flow rate (1000m/s) from below, it is obvious that the droplet (1E-6 kg) must moves up!

After that I turned gravity off. The Droplet froze and did not move in time. But with air flow from below, it is obvious that the droplet must moves up!

Can you tell me what the problem is? Such a simple task... Why the droplet is not affected by any force from below!
vodoley is offline   Reply With Quote

Old   April 26, 2020, 16:04
Default Droplet
  #9
Senior Member
 
vinerm's Avatar
 
Vinerm
Join Date: Jun 2009
Location: Nederland
Posts: 2,946
Blog Entries: 1
Rep Power: 35
vinerm will become famous soon enough
You have not entered values for Moment of Inertia.

And why do you wish to use dynamic mesh for droplet? A 1 mg of droplet of water means a diameter of approximately 1 cm. That's quite large for a droplet to behave like a rigid body. You should use VOF.
__________________
Regards,
Vinerm

PM to be used if and only if you do not want something to be shared publicly. PM is considered to be of the least priority.
vinerm is offline   Reply With Quote

Old   April 28, 2020, 09:12
Default
  #10
New Member
 
Viktor
Join Date: Apr 2020
Posts: 17
Rep Power: 6
vodoley is on a distinguished road
Quote:
Originally Posted by vinerm View Post
You have not entered values for Moment of Inertia.

And why do you wish to use dynamic mesh for droplet? A 1 mg of droplet of water means a diameter of approximately 1 cm. That's quite large for a droplet to behave like a rigid body. You should use VOF.
Thanks for reply!
I set some random mass and diameter of droplet so far... Just for debugging of the problem statement. I think this task is interesting for understanding how Fluent works.

In fact I want to determine the motion of real droplet (5.24E-10 kg; 0.1 mm). in air flow from the bottom with U m/s. I decided such droplet behave like a rigid body for simplicity.

You have not entered values for Moment of Inertia... You mean inertia tensor in 'Six DOF prorerties' or shear contition on droplet walls in 'Boundary conditions'?




I found some formula.

In order for a droplet hung in a stream of vapor (wet air) with the flow velocity U m/s, the weight of the droplet should be compensated by the force which air flow acts on a droplet:


D = 0.1mm
md - droplet mass = 5.24E-10 kg
g = 9.81

Cd - a drag coefficient of a spherical droplet, depending on the Reynolds number;
Sd - cross-sectional area = 3.14*D*D/4=0.00785 mm2;
ρv — saturated air density;
U ~ 0.27 m/s.
vodoley is offline   Reply With Quote

Old   April 28, 2020, 11:58
Default Rigid Body Solver
  #11
Senior Member
 
vinerm's Avatar
 
Vinerm
Join Date: Jun 2009
Location: Nederland
Posts: 2,946
Blog Entries: 1
Rep Power: 35
vinerm will become famous soon enough
The equations for rigid body are simpler than those for multiphase flow. Whether a bubble or droplet deforms or not depends on We and not on diameter but for water-air system, 0.1 mm droplet may maintain spherical shape. So, you can certainly use rigid body (six-DOF) solver.

Yes, you have to provide inertia tensor. However, only three values (and all equal to each other) exist for a sphere. So, you only need to provide Ixx, Iyy, and Izz and all will be equal.

The expression you mentioned is nothing but comparison of drag and weight and is usually used to determine terminal velocity. Fluent has got nothing to do with it nor do you need to worry about it. Just provide droplet mass, its inertia, and it would work alright provided you have a good quality mesh.
__________________
Regards,
Vinerm

PM to be used if and only if you do not want something to be shared publicly. PM is considered to be of the least priority.
vinerm is offline   Reply With Quote

Old   April 29, 2020, 04:37
Default
  #12
New Member
 
Viktor
Join Date: Apr 2020
Posts: 17
Rep Power: 6
vodoley is on a distinguished road
Thank you, now I will try to provide inertia tensor. First of all I need to find the correct values of inertia tensor. It's not so obvious for me yet. I'll write teh result.
vodoley is offline   Reply With Quote

Old   April 29, 2020, 11:35
Default Inertia Tensor
  #13
Senior Member
 
vinerm's Avatar
 
Vinerm
Join Date: Jun 2009
Location: Nederland
Posts: 2,946
Blog Entries: 1
Rep Power: 35
vinerm will become famous soon enough
For a sphere of radius r and mass m, it is just

\frac{2}{5}mr^2

And all three values are same. Ixy, Iyz, and Izx are 0.
__________________
Regards,
Vinerm

PM to be used if and only if you do not want something to be shared publicly. PM is considered to be of the least priority.
vinerm is offline   Reply With Quote

Old   April 30, 2020, 00:18
Default
  #14
New Member
 
Viktor
Join Date: Apr 2020
Posts: 17
Rep Power: 6
vodoley is on a distinguished road
Yes, you are absolutely right that Ixx=Iyy=Izz=2*m*r*r/5 for solid sphere.

Since I have a flat geometry I tried to not fill in Izz. But Fluent does not allow you to do this so I put Ixx=Iyy=Izz=2*m*r*r/5 and Ixy, Iyz, and Izx are 0...

2D, some rectangular region with air (160x160 mm). We have also One rigid body (droplet 20 mm diam) placed in the air. Bottom - very big velocity inlet with U m/s (5000 m/s!), Upper boundary - pressure outlet.

Gravity (-9.81) is OFF. I put droplet mass to 1E-05, therefore Ixx=Iyy=Izz=4E-10...



And the droplet is not affected by air flow from below. The droplet stands still.

But there is another problem. After several time steps I saw that Ixx and Iyy becomes empty automatically! Only Izz=2*m*r*r/5. But I have a flat geometry...



vodoley is offline   Reply With Quote

Old   April 30, 2020, 05:16
Default Domain
  #15
Senior Member
 
vinerm's Avatar
 
Vinerm
Join Date: Jun 2009
Location: Nederland
Posts: 2,946
Blog Entries: 1
Rep Power: 35
vinerm will become famous soon enough
What you are modeling is not a droplet, but a cylinder. So, you have to provide moment of inertia values accordingly. The equation is different for each axis.

As far as the motion is concerned, that depends on rigid body setup. You need to have only one Dynamic Mesh Object, the droplet. Secondly, if there is not enough force due to the flow, then the object won't move.
__________________
Regards,
Vinerm

PM to be used if and only if you do not want something to be shared publicly. PM is considered to be of the least priority.
vinerm is offline   Reply With Quote

Old   April 30, 2020, 06:04
Default
  #16
New Member
 
Viktor
Join Date: Apr 2020
Posts: 17
Rep Power: 6
vodoley is on a distinguished road
I simplified the problem: 2D, rectangular region with WATER (160x160 mm, 998 kg/m3). We have also One rigid body (20 mm diam, 100kg/m3) placed in water. Upper boundary - pressure outlet, other boundaries - walls.

According to Archimedes' principle the rigid body should moves up in water. But it does not.

May be the problem is... When I provide moment of inertia (any values of Ixx, Iyy) and press 'Calculate' after several time steps Ixx and Iyy become 0.0 automatically!
vodoley is offline   Reply With Quote

Old   April 30, 2020, 06:13
Default Movement and MoI
  #17
Senior Member
 
vinerm's Avatar
 
Vinerm
Join Date: Jun 2009
Location: Nederland
Posts: 2,946
Blog Entries: 1
Rep Power: 35
vinerm will become famous soon enough
Since you are dealing with 2D, planar problem, Ixx and Iyy have no significance. The rotation is allowed only around z-axis, hence, Ixx and Iyy are being reset to 0. As far as the motion is concerned, buoyancy works due to gravity. If gravity is not enabled for Six-DOF setup, it won't work.
__________________
Regards,
Vinerm

PM to be used if and only if you do not want something to be shared publicly. PM is considered to be of the least priority.
vinerm is offline   Reply With Quote

Old   April 30, 2020, 07:38
Default
  #18
New Member
 
Viktor
Join Date: Apr 2020
Posts: 17
Rep Power: 6
vodoley is on a distinguished road
Yes, I understood. I turned on gravity and rigid body (100 kg/m3) started to falls down in water (998 kg/m3). I setted arbitrary values (Izz) from 1E-08 to 1.0.

May be I do something wrong. I'll check...
vodoley is offline   Reply With Quote

Old   April 30, 2020, 07:59
Default Moment of Inertia
  #19
Senior Member
 
vinerm's Avatar
 
Vinerm
Join Date: Jun 2009
Location: Nederland
Posts: 2,946
Blog Entries: 1
Rep Power: 35
vinerm will become famous soon enough
MoI affects only rotation. As long as there is no rotation, which is not expected for your case, it won't matter.
__________________
Regards,
Vinerm

PM to be used if and only if you do not want something to be shared publicly. PM is considered to be of the least priority.
vinerm is offline   Reply With Quote

Old   May 1, 2020, 03:11
Default
  #20
New Member
 
Viktor
Join Date: Apr 2020
Posts: 17
Rep Power: 6
vodoley is on a distinguished road
I continue to struggle with this simple task

I found macro for Six DOF. To specify custom external forces to a rigid moving object I use the following macro:

SDOF_LOAD_F_X, /* external force */
SDOF_LOAD_F_Y, /* external force */
SDOF_LOAD_F_Z, /* external force */

As far as I understand it is available only in UDF. I guess that for my task I need a UDF to provide properties of the object (mass and external force SDOF_LOAD_F_Y). But what is the dimension of the external forse in SDOF_LOAD_F_Y...
vodoley 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
[swak4Foam] swak4foam for OpenFOAM 4.0 mnikku OpenFOAM Community Contributions 80 May 17, 2022 08:06
polynomial BC srv537 OpenFOAM Pre-Processing 4 December 3, 2016 09:07
[OpenFOAM] Annoying issue of automatic "Rescale to Data Range " with paraFoam/paraview 3.12 keepfit ParaView 60 September 18, 2013 03:23
DxFoam reader update hjasak OpenFOAM Post-Processing 69 April 24, 2008 01:24
DecomposePar links against liblamso0 with OpenMPI jens_klostermann OpenFOAM Bugs 11 June 28, 2007 17:51


All times are GMT -4. The time now is 18:13.