TAGGED: dynamic-mesh, fluent, udf-fluent, wall-motion
-
-
January 11, 2021 at 3:48 pm
Luigi0
SubscriberHi,
I have a simple channel with length = 2 mm, Height = 150 um. Inlet is a mass-flow inlet and the outlet is a pressure outlet. The liquid is water and the flow is laminar. The bottomwall (see picture) need to move up and down (along y) in order to generate pressure waves that propagate in y direction.
January 11, 2021 at 4:04 pmYasserSelima
SubscriberCheck that you selected angles in rad.nJanuary 11, 2021 at 4:05 pmYasserSelima
SubscriberYou can check mesh movement before starting the simulation.nJanuary 11, 2021 at 4:10 pmYasserSelima
SubscriberOne thing I would like to add. the frequency is very high ... to capture this fast movement, the time step should be 1e-07 or lessnJanuary 11, 2021 at 4:37 pmLuigi0
SubscriberThanks nThe time step is 1e-08. I have difficulties to check the mesh movement, because the displacement are very small. nI have checked the angles and they are in rad, but rotation are not present in my model.nJanuary 11, 2021 at 5:41 pmYasserSelima
SubscriberZoom on the wall while checking the moving mesh.nJanuary 11, 2021 at 5:49 pmDrAmine
Ansys EmployeeCheck averaged mesh y coordinate at bottom wall within a report definition nJanuary 11, 2021 at 5:55 pmYasserSelima
SubscriberNo I understand the reason. nThe amplitude is equal to (v0 / 2 pi f) ... hmmm 0.1 by almost 35 millions. I know the channels width is in microns, but does this amplitude sound right? nJanuary 11, 2021 at 9:09 pmLuigi0
SubscriberThe amplitude should be right, it is in the order of nanometres. I am confused regarding the dynamic mesh settings: I treated my wall with a rigid body motion, is it reasonable? nRegarding the report, I can create the report but I don't find the option averaged mesh y coordinate.nJanuary 11, 2021 at 9:51 pmYasserSelima
Subscriberfirst, used double precision. second define all your variables as double instead of real. This increases the number of digits saved for any numbernthird define a global variable double my_bondary_location=0;n fourth add this at the end of your current function my_boundary_location += vely*dtime ;nfinally add this function to your codenDEFINE_REPORT_DEFINITION_FN(my_location)n{n treturn my_boundary_location;n}nNow you can find my_boundary_location to monitornJanuary 11, 2021 at 9:52 pmYasserSelima
Subscribermake it nreturn 10e09* my_boundary_location; nJanuary 12, 2021 at 8:34 amLuigi0
SubscriberThanks for replying. I am new to Udf coding, after define_report_definition, what should I put in the parentesis?nI update my udf:n#include udf.hn#include dynamesh_tools.hnn#define freq = 5000000;n#define v0 = 0.1;ndouble my_boundary_location = 0;nnDEFINE_CG_MOTION(wall, dt, vel, omega, time, dtime)Â n{nNV_S (vel, =, 0.0);nNV_S (omega, =, 0.0);nnvely = v0*sin(2*M_PI*f*time);nvel[1] = vely;nmy_boundary_location += vely*dtime;Â n}nnDEFINE_REPORT_DEFINITION_FN(my_location)n{nreturn 10e-09*my_boundary_location;n}nJanuary 12, 2021 at 1:53 pmYasserSelima
Subscriberreport plot the variable my_location .. you should be able to monitor your wall location in manometers now,nJanuary 12, 2021 at 2:38 pmJanuary 12, 2021 at 3:15 pmYasserSelima
Subscribertry using cosine function instead of the sine. So, you get higher velocity at the beginning nJanuary 12, 2021 at 3:25 pmYasserSelima
SubscriberYou can add this to the function as well nMessage(
velocity = %f, displacement = %f, 1000*vely , 1e9*my_boundary_location);nThis should print the velocity and displacement every timestepnViewing 15 reply threads- The topic ‘Udf for wall motion (dynamic mesh)’ is closed to new replies.
Ansys Innovation SpaceTrending discussionsTop Contributors-
3487
-
1057
-
1051
-
945
-
912
Top Rated Tags© 2025 Copyright ANSYS, Inc. All rights reserved.
Ansys does not support the usage of unauthorized Ansys software. Please visit www.ansys.com to obtain an official distribution.
-
The Ansys Learning Forum is a public forum. You are prohibited from providing (i) information that is confidential to You, your employer, or any third party, (ii) Personal Data or individually identifiable health information, (iii) any information that is U.S. Government Classified, Controlled Unclassified Information, International Traffic in Arms Regulators (ITAR) or Export Administration Regulators (EAR) controlled or otherwise have been determined by the United States Government or by a foreign government to require protection against unauthorized disclosure for reasons of national security, or (iv) topics or information restricted by the People's Republic of China data protection and privacy laws.