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

dynamic mesh layering changed after run calculate

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By AlexanderZ

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   December 19, 2022, 11:20
Smile dynamic mesh layering changed after run calculate
  #1
New Member
 
zhubin
Join Date: Dec 2022
Posts: 8
Rep Power: 3
zhu-jsut is on a distinguished road
hello, everyone
I have a question about the dynamic mesh. The initial 2D mesh is very simple, two layers of 10mm height quad mesh. One edge moves with a velocity defined by UDF:

DEFINE_CG_MOTION(dm_top, dt, vel, omega, time, dtime)
{
NV_S(vel,=, 0.0);
NV_S(omega,=, 0.0);

real time;
time = CURRENT_TIME;
if(time <= 320)
vel[0] = 0.0;
else if(time > 320 && time <= 480)
vel[0] = 0.000125;
else if(time > 480 && time <= 1000)
vel[0] = 0.0002;
else
vel[0] = 0.0;
}

As shown here, the velocity is 0 in the first 320 seconds, and then the edge starts to move. The dynamic mesh setting, preview mesh motion, every thing is OK. As shown in preview mesh motion, the mesh has two layers until 320s, and then the layering starts.

However, the initial mesh (from 0s to 320s) became 4 layers after the initialization and run calculation, as shown in the mesh animation. Still, the simulation results conform to the logic, and the layering starts just after 320s. And if I extend time steps, the number of grid layers continue to increase but keep unchanged from 0s to 320s.

So, if anyone has ever encountered this problem, please tell me the possible reasons.

zhu-jsut is offline   Reply With Quote

Old   December 19, 2022, 20:59
Default supplement image
  #2
New Member
 
zhubin
Join Date: Dec 2022
Posts: 8
Rep Power: 3
zhu-jsut is on a distinguished road
[IMG][/IMG]

fig1.png.jpg
zhu-jsut is offline   Reply With Quote

Old   December 20, 2022, 00:12
Default
  #3
Senior Member
 
Alexander
Join Date: Apr 2013
Posts: 2,363
Rep Power: 34
AlexanderZ will become famous soon enoughAlexanderZ will become famous soon enough
compile your code, so you will avoid such problems later

variable time is already defined as a parameter of function, you don;t nee to redefine it
remove
Code:
real time;
time = CURRENT_TIME;
zhu-jsut likes this.
__________________
best regards


******************************
press LIKE if this message was helpful
AlexanderZ is offline   Reply With Quote

Old   December 20, 2022, 06:55
Smile problem solved
  #4
New Member
 
zhubin
Join Date: Dec 2022
Posts: 8
Rep Power: 3
zhu-jsut is on a distinguished road
Quote:
Originally Posted by AlexanderZ View Post
compile your code, so you will avoid such problems later

variable time is already defined as a parameter of function, you don;t nee to redefine it
remove
Code:
real time;
time = CURRENT_TIME;
Thanks for your kind reply. I have solved this problem. it is caused by a misoperation. I always conduct preview mesh motion before initialization.

It is my first post on this forum. thanks again
zhu-jsut is offline   Reply With Quote

Reply

Tags
dynamic mesh; layering


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
[snappyHexMesh] SnappyHexMesh/splitMeshRegion : region1 in zone "-1" GuiMagyar OpenFOAM Meshing & Mesh Conversion 3 August 4, 2023 12:38
Mesh Disappering with Dynamic Mesh FaroukH FLUENT 0 February 23, 2021 18:26
Interfoam and dynamic mesh with layering (OF1906) nkalkote OpenFOAM Running, Solving & CFD 0 July 17, 2019 01:57
dynamic mesh interDyMFoam parallel run and processor boundaries lukasfischer OpenFOAM Running, Solving & CFD 0 August 12, 2009 06:36
Icemcfd 11: Loss of mesh from surface mesh option? Joe CFX 2 March 26, 2007 18:10


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