## Fluids

#### dynamic mesh

• mariannebassil
Subscriber

Hello! I am using a model to simulate the motion of a tyre on a cavity in the road. We assume that the tyre has a rotational velocity W and the cavity and the road have a translational velocity V

I made a steady case with sliding mesh (mesh motion) with mesh interface the cavity and the road. I considered that the road and the tyre are moving while the cavity is without motion(in the cell zone i specify V cavity fluid =0). For sliding mesh the interface is interface between the top wall of the cavity and the wall of the  road (the cavity is sliding on the road surface) and i defined the top,side,and bottom wall of cavity as moving in the boundary conditions relative to cell zone with  zero velocity. I got a solution. I used this solution as a starting solution for a transient case where i assigned a velocity now to the cavity Vcavityfluid=V in the cell zone panel (i assigned the velocity for the fluid zone). I got a solution. now i want to study a second case that is a sliding mesh and a dynamic mesh for the cavity it means i want to consider the cavity is moving along a direction x and also the bottom of the cavity is moving up and down in  addition to the sliding. So i kept the parameters and the conditions in the panel of boundary and cell zone conditions as they are in the sliding mesh case and i activate the dynamic mesh and fill the related parameters (layering). I want to consider that the bottom wall of the cavity is moving up and down so i defined the bottom wall as a dynamic zone. Type: user-defined using a udf describing at each time, the position of the bottom wall that i calculated using an external contact code(attached udf). I didn't assign any other dynamic zones. Only the bottom. but it didn't work!

• Konstantine Kourbatski
Ansys Employee

what specifically didn't work? Is it you don't see the motion? Have you checked what value does ytab have when you do the node update, i. e. is is correctly assigned from your array?

• mariannebassil
Subscriber

well, i don't see any up and down for the mesh cells! i tried to run the C code out of fluent (in Visual studio) and i got an array for the values of y tab that are right as the txt file so normally the array of nodes coordinates are right

• mariannebassil
Subscriber

Today i have read a message (i don't know if it as shown from the beginning! ): LINK : fatal error LNK1104: impossible d'ouvrir le fichier 'libudf.dll'

• mariannebassil
Subscriber

well, i tried to open only the cavity (without the tyre and the domain, because i have drawn the two meshes separately). When i apply the udf  and try to preview mesh motion, i got a black screen and the mesh disappears.

When the preview finished , i can re-see the cavity with the new length ( so i guess the udf is working properly but i dont know the error occuring when i have the whole system connected together and i don't know why the mesh disappers when previewing)!

• Konstantine Kourbatski
Ansys Employee

1) are you doing Preview Mesh Motion or Display Zone Motion? You should be doing Preview Mesh Motion

2) do you have Display Mesh on in Mesh Motion Panel? If you do, this could be some graphics related issue, e. g. an outdated graphics driver

3) when doing Preview Mesh Motion, do it one step at a time, and check the mesh after each step.

4) add some I/O statements into your UDF code, e.g. reporting calculated displacement. This will help you troubleshoot if the macro is properly called and displacements are correctly calculated.

• mariannebassil
Subscriber

Hello i fixed several issue related to my above problems, well i tried to open the mesh via fluent directly not via workbench and now i can visualise the up and down of the bottom so maybe it is a problem in workbench?

I have another question: I want to monitor the y coordinate of the bottom of the cavity in order to view the variation of y in time, so i made a report definition(area weighted average >mesh> y coordinate and chose bottom of cavity as a surface) but what i saw is the variation of y centroid or something else that is not fitting with  my required plot. So i tried a vertex average definition report for a point on the bottom but the problem is that this point is moving and at a certain time it will leave to bottom of the cavity( when it will move along the diameter) so i got y=-0.01 for a while then y went to zero because the point left the mesh! how can i monitor the y coordinate for the bottom ? (0.01 is the length of my cavity)

• Konstantine Kourbatski
Ansys Employee

indeed, this is a limitation of monitors not moving with the mesh in MDM. A workaround would be to separate a one-cell piece from the moving wall and define the monitor on this separated surface. This surface will need to be defined as moving using the same UDF.

Before separating, make sure the MDM is unchecked. The procedure will go along the following steps:

The procedure is as follows:

1. Adapt->Region Choose Inside under Options and Circle for Shapes

2. Enter the coordinate location of the monitor point

3. Specify the radius and click Mark

4. Select Manage then Option

5. Enable Draw Mesh and select a clear shape.

6. Enable Filled in Options

7. Mark the cell displayed when you click on Display in

8. Ensure that it is one cell is marked (If multiple cells are displayed in Region Adaption panel, change the radius and repeat the work so one cell is selected)

9. Mesh-> Separate-> Faces then select Mark in Options. Under Registers, select the what was marked above. In Zones, select the fluid region that contains the monitor point (In the example from above, zone 2). Click Separate.

• mariannebassil
Subscriber

i tried to follow the steps , i m working in 2D. i specified the point as the center of the bottom and the  radius as 2.5 mm ( radius of the cavity) is this right? ( see attached photos) but i got a warning when clicking separate (see warning) ! and the new zones created are interior type ! Do i have to assign the dynamic zone and udf to interior zones created?

• mariannebassil
Subscriber

And you said: a one-cell piece from the moving wall and define the monitor on this separated surface: what kind of monitors do you assign for a cell in order to get the y coordinate a node of the bottom ( because i want to follow the y of either a node or an edge (segment/line ) but here you are separting a cell !

• mariannebassil
Subscriber

and the udf is assigned in order to consider the dynamic zone as an edge (bottom of cavity) not a cell

• mariannebassil
Subscriber

I really need to solve this issue because the displacement of the bottom of my cavity affects the results! the shape of displacement is supposed to be different then the actual displacement shown by the monitor of area weighted average of the y coordiante of the bottom of the cavity (see photos)! i don't know if it's the monitor that is wrong or the method of layering!