CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   ANSYS Meshing & Geometry (https://www.cfd-online.com/Forums/ansys-meshing/)
-   -   [Other] Negetive Volume during mesh motion (https://www.cfd-online.com/Forums/ansys-meshing/94354-negetive-volume-during-mesh-motion.html)

sanjeetlimbu April 9, 2015 22:04

5 Attachment(s)
I am trying to simluate the compression stroke by a piston using 2D axisymetric.
Currently i am trial s fo rthe 2D planner mesh using the dynamic mesh - profile mode, I created the profile by using the time and velocity for 1440 points from matlab taking time step as 0.000041667s.

But I am unable to get exact mesh motion. I got the zone motion correct.
The piston has crevice shape- I made two cellzone- body which defoems and crevice - as moving mesh.

I did the following: Cell zone- crevice .set as mesh motion type, and set write profile- having motion history points which also will be used for rigid bodies
Piston – as moving wall in boundary condition(piston is of two part its inteface with body and crevice both moving)
The dynamic mesh- piston as rigid body- profile selected,
Body- as deforming layering only, unchecked the remeshing and smoothening
Crevice as rigid body- profile selected.


Please tell how to do mesh also move with same distance .
I tried the UDF also but that also not working: sjows warning eror unable to read file:
#include "udf.h"
DEFINE_CG_MOTION(oscillate, dt, vel, omega, time, dtime)
{
Thread *t;
face_t f; /* define the variables */

t = DT_THREAD(dt); /* get the thread pointer for which the motion is defined */

/* if (!Data_Valid_P())
/* return; /* check if the values of the variables are accessible before you compute the function */

begin_f_loop(f, t) /* loop over each face in the zone to create an array of data */
{
if (time <= 0.02)
vel[0] = (673* time); /* define the velocity of the moving zone---*/
else if (0.02 < time < 0.027)
vel[0] = 14;
else if (0.027 < time < 0.03)
vel[0] = 3 - 2800*(time-0.03);
else if (0.03 < time)
vel[0] = 0;
}
end_f_loop(f, t)
}

sanjeetlimbu April 9, 2015 22:07

5 Attachment(s)
hi iam getting less dynamic motion than the zone motion preview

I am trying to simluate the compression stroke by a piston using 2D axisymetric.
Currently i am trial s fo rthe 2D planner mesh using the dynamic mesh - profile mode, I created the profile by using the time and velocity for 1440 points from matlab taking time step as 0.000041667s.

But I am unable to get exact mesh motion. I got the zone motion correct.
The piston has crevice shape- I made two cellzone- body which defoems and crevice - as moving mesh.

I did the following: Cell zone- crevice .set as mesh motion type, and set write profile- having motion history points which also will be used for rigid bodies
Piston – as moving wall in boundary condition(piston is of two part its inteface with body and crevice both moving)
The dynamic mesh- piston as rigid body- profile selected,
Body- as deforming layering only, unchecked the remeshing and smoothening
Crevice as rigid body- profile selected.


Please tell how to do mesh also move with same distance .
I tried the UDF also but that also not working: sjows warning eror unable to read file:
#include "udf.h"
DEFINE_CG_MOTION(oscillate, dt, vel, omega, time, dtime)
{
Thread *t;
face_t f; /* define the variables */

t = DT_THREAD(dt); /* get the thread pointer for which the motion is defined */

/* if (!Data_Valid_P())
/* return; /* check if the values of the variables are accessible before you compute the function */

begin_f_loop(f, t) /* loop over each face in the zone to create an array of data */
{
if (time <= 0.02)
vel[0] = (673* time); /* define the velocity of the moving zone---*/
else if (0.02 < time < 0.027)
vel[0] = 14;
else if (0.027 < time < 0.03)
vel[0] = 3 - 2800*(time-0.03);
else if (0.03 < time)
vel[0] = 0;
}
end_f_loop(f, t)
}


All times are GMT -4. The time now is 08:45.