|
[Sponsors] |
wrong transient solution in different time steps of Dynamic mesh |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
December 29, 2011, 10:00 |
wrong transient solution in different time steps of Dynamic mesh
|
#1 |
New Member
Esmail
Join Date: May 2009
Posts: 11
Rep Power: 17 |
Hello
Recently, I have tried to solve the dynamic mesh problem of a 2d moving object with the drag force of the fluid in one direction(x). I used the following UDF and after the steady simulation (for initial condition of transient) when i change the solver to unsteady (PISO) the direction of the x-force change after each time step. After 3 or 4 time steps, It reciprocate and lead to negative cells error. I have tried different boundary conditions, time steps, lower residual, different transient solver model, higher number of cells but still the contours of pressure totally change after each time step. Can any body tell me why this is happening? #include "udf.h" static real v_prev = 0.0; DEFINE_CG_MOTION(BodyDrag,dt,vel,omega,time,dtime) { Thread *t; face_t f; real NV_VEC(A); real force, dv; /* reset velocities */ NV_S(vel, =, 0.0); NV_S(omega, =, 0.0); if (!Data_Valid_P()) return; /* get the thread pointer for which this motion is defined */ t = DT_THREAD(dt); /* compute pressure force on body by looping through all faces */ force = 0.0; begin_f_loop(f,t) { F_AREA(A,f,t); force += F_P(f,t) * A[0]; } end_f_loop(f,t) /* compute change in velocity, i.e., dv = F * dt / mass velocity update using explicit Euler formula */ dv = dtime * force / 0.0005; v_prev += dv; Message ("time = %f, x_vel = %f, force = %f\n", time, v_prev, force); /* set x-component of velocity */ vel[0] = v_prev; } |
|
January 29, 2012, 14:00 |
|
#2 |
New Member
Esmail
Join Date: May 2009
Posts: 11
Rep Power: 17 |
Hey Guys,
Could you please look at my .cas and .dat files and also the UDF file, here http://www.mediafire.com/?4dirqdz25b5bxhq with different time steps, after several iterations it leads to Update-Dynamic-Mesh failed. Negative cell volume detected. Regards, Essi Last edited by esicia; February 26, 2012 at 14:29. |
|
February 11, 2012, 23:37 |
|
#3 |
New Member
Join Date: Feb 2012
Posts: 4
Rep Power: 14 |
Hi Esicia
According to my experience, merely smoothing should be able to complete the task if the parameters are set properly.(The spring constant should be around 0.1) However, this may cause degradation of the mesh. Then add 'resmeshing', check info. for parameters setting. Everything should be fine. Regards, Tony |
|
February 12, 2012, 10:39 |
Hello
|
#4 |
New Member
Esmail
Join Date: May 2009
Posts: 11
Rep Power: 17 |
Dear tony thanks for your response
I already checked both of 'smoothing' and 'remeshing' in dynamic mesh setting but it still lead to negative cells after 4 iterations. I can not see why it is not working. The problem is so simple. Could please download the .cas, .dat and udf file which uploaded here http://www.mediafire.com/?4dirqdz25b5bxhq and try it. Best Regards, Essi Last edited by esicia; February 26, 2012 at 14:29. |
|
February 18, 2012, 09:45 |
|
#5 |
Senior Member
Join Date: Mar 2009
Location: Indiana, US
Posts: 186
Rep Power: 17 |
Hi Essi,
Sorry cannot view your files right now. But hav you tried a preview mesh before running your simulation Regards Luke |
|
February 18, 2012, 11:33 |
|
#6 |
New Member
Esmail
Join Date: May 2009
Posts: 11
Rep Power: 17 |
Thanks Luke, for the response
In this problem the body move by drag force of the surrounding fluid and the preview mesh tools does not make sense here. This UDF works with constant velocity or time dependent velocity. Could you take a minute and run the simulation by yourself? |
|
February 24, 2012, 07:37 |
|
#7 |
Senior Member
Join Date: Mar 2009
Location: Indiana, US
Posts: 186
Rep Power: 17 |
I would suggest that you, give a translational velocity (instead of your drag UDF) to move the mesh and preview it. If all works ok then move on to the drag UDF for movement.
Post some pics of your case and dynamic mesh settings. Regards Luke |
|
February 26, 2012, 14:27 |
|
#8 |
New Member
Esmail
Join Date: May 2009
Posts: 11
Rep Power: 17 |
Thanks Luke, for the response
When I change the UDF to constant velocity of the body or time dependent velocity, It pretty works. However, for the drag force movement of the body, It leads to negative cells. Here I uploaded some pictures. link of .cas and udf file. http://www.mediafire.com/?4dirqdz25b5bxhq |
|
Tags |
dynamic mesh, transient |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
High Courant Number @ icoFoam | Artex85 | OpenFOAM Running, Solving & CFD | 11 | February 16, 2017 14:40 |
air bubble is disappear increasing time using vof | xujjun | CFX | 9 | June 9, 2009 08:59 |
fluent add additional zones for the mesh file | SSL | FLUENT | 2 | January 26, 2008 12:55 |
unsteady calcs in FLUENT | Sanjay Padhiar | Main CFD Forum | 1 | March 31, 1999 13:32 |
unstructured vs. structured grids | Frank Muldoon | Main CFD Forum | 1 | January 5, 1999 11:09 |