114
© Fluent Inc. 11/7/2005 2 - 1 FLUENT Software Training DM Model March 2003 Fluent User Services Center www.fluentusers.com Dynamic Mesh Model FLUENT v6.1

Fluent Dynamic Mesh Training

Embed Size (px)

DESCRIPTION

Dynamic Mesh Model

Citation preview

Page 1: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 1

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Dynamic Mesh Model FLUENT v6.1

Page 2: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 2

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Agenda9:00 Overview of Dynamic Mesh (DM)

9:30 Global Controls

10:00 Dynamic Zones

10:30 Motion Specification

11:00 Step-by-Step Procedure

11:15 Tutorial 1

12:00 Lunch

1:00 Step-by-Step Procedure

1:30 Tutorial 2

2:30 Examples

3:00 Tips-and-Tricks and Technical Discussion Session

Page 3: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 3

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Overview of DM

Page 4: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 4

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Dynamic Mesh Overview

New feature in FLUENT 6.1 Built-in, no additional fee

A general purpose model targeted for moving boundary problemsIC enginesValvesFuel injectors HVAC modules and much much more…

Can also be used for steady-state parametric studiesCompatible with all physical models and solver types in FLUENT 6.1Compatible with any pre-processorFully parallelized

Page 5: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 5

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Mesh Motion Schemes

Fluent offers three mesh schemesSpring analogyLocal remeshingDynamic layering

Mesh motion may be applied to individual zonesDifferent zones may use different schemes for mesh motion Connectivity between adjacent deforming zones may be non-conformal

Page 6: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 6

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Spring Analogy

Interior nodes behave like a spring or spongeConnectivity remains unchangedLimited to relatively small deformation when used as a stand-alone meshing schemeAvailable for tri, tet, quad, hex and wedge mesh element types

Page 7: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 7

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Local Remeshing

As user-specified skewness and size limits are exceeded, local nodes and cells are added or deletedAs cells are added or deleted, connectivity changesAvailable only for tri and tet mesh elements

Page 8: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 8

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Dynamic Layering

Cells are added or deleted as the zone grows and shrinksAs cells are added or deleted, connectivity changesAvailable for quad, hex and wedge mesh elements

Page 9: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 9

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Combination of ApproachesInitial mesh needs proper decompositionLayering

Valve travel region Lower cylinder region

RemeshingUpper cylinder region

Non-conformal interface between zones

Page 10: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 10

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Combination of Approaches

Page 11: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 11

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Motion Specification

Internal node positions are automatically calculated based on user specified boundary motionMesh motion scheme in each zone is automatically chosen based onelement type in that zonePrescribed mesh motion

Position or velocity versus time i.e. ‘profile’ text fileUDF with expression for position or velocity

Flow dependant motionMesh motion is coupled with the flow solution through a UDFCan integrate forces (pressure, gravity and viscous etc)Six degree of freedom UDF providedUDF readily customized for desired mesh motion

Page 12: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 12

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Mesh Preview

Mesh motion can be previewed without calculating flow variablesAllows user to quickly check mesh quality throughout the simulation cycleApplicable to any dynamic mesh simulation

Page 13: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 13

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Global Controls

Page 14: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 14

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Overview

Define > Dynamic Mesh > ParametersMethods

toggle spring analogy, layering, remeshing approachesGUI dynamically changes to reflect selected methods

Dynamic Mesh model enables generic functionalityIn-Cylinder option adds specific functionality

definition of RPM, starting crank angle, crank period, etc...option enables IC specific profile format for valve motion

Page 15: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 15

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Overview

Smoothing (spring) parameters‘stiffness’boundary node relaxation convergence tolerance(max) number of iterations

Layering parameterssplit/collapse factor

Remeshing parametersmin/max volumemax skewness

Page 16: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 16

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Smoothing

Edges between any two mesh nodes are idealized as a network of interconnected springs. A set of linear equations are derived based on force balance at the nodes. The node positions at each time-step are solved iteratively. By default smoothing is applied on tet/tri mesh. To apply smoothing for all type of mesh use:

(rpsetvar 'dynamesh/spring/all-element-type? #t)Spring Constant Factor: It adds “damping” to the springs [1,0]Boundary Node Relaxation: Under-relaxation used for the boundary nodes. Use a value of 0 if no smoothing on the boundaries

A default value of 1.0 is used for interior nodesConvergence Tolerance: Used when solving for node positions.Number of Iterations: Max number of iterations.

Page 17: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 17

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Spring Constant Factor = 1.0

Smoothing

Page 18: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 18

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Spring Constant Factor = 0.1

Smoothing

Page 19: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 19

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Spring Constant Factor = 0.05

Smoothing

Page 20: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 20

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Smoothing

Spring Constant Factor = 0

Page 21: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 21

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Smoothing

Smoothing on Quads(rpsetvar 'dynamesh/spring/all-element-type? #t)

Page 22: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 22

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Smoothing

The rpsetvar command is not used here. Smoothing is not applied automatically on quad/hex meshes.

Page 23: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 23

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

LayeringConstant Height

Useful for uniform layer heightConstant Ratio:

Maintain a constant ratio of cell heights between layersUseful when layering is done in curved domains (e.g. cylindrical geometry).

Split if:Collapse if:

Page 24: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 24

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Layering

Page 25: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 25

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Layering

Page 26: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 26

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Remeshing

Sizing Function Controls:Resolution: determines the size of the background bins used to evaluate the size distribution with respect to the minimum characteristic length of the current mesh.Sizing Function Variation Rate: How the background mesh increases in size (from the boundary to the interior) [-1,+inf]Distance Threshold: Is the degree of polynomial that handles the size variation of the background cell size. (values in [-1,1]).Size Remesh Interval: How often the remeshing is done based on min and max cell volume.

Page 27: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 27

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

RemeshingMeaning of Variation Rate:

A value of -0.5 means that the minimum mesh size (cell edge length) in the interior is half of the mesh size at the boundary,A value of 50 means that the maximum mesh size in the interior can be 50 times higher than the mesh size at the boundary.

Meaning of Distance Threshold: The higher the value, the slower the change of the mesh size close to the boundary.A threshold value of 0 corresponds to linear in-/de-crease from the boundary. Negative threshold values enforce a faster (than linear) in-/de-crease at the boundary.Default Values work fine most of the time.

Page 28: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 28

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

RemeshingMinimum Cell Volume: mark cells for remeshing if their size gets smaller than this valueMaximum Cell Volume: mark cells for remeshing if their size gets larger than this valueMaximum Skewness: mark cells if their skewness increases this value

Use 0.9 for tet mesh and 0.75 for tris

Page 29: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 29

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

RemeshingNo SmoothingEffect of Size RemeshInterval (SRI)

SRI = 10Note that cells adjacent to moving wall get stretched.

Page 30: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 30

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

RemeshingNo SmoothingEffect of Size Remesh Interval (SRI)

SRI = 1Note cells adjacent to wall don’t get stretched as much.

Page 31: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 31

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Dynamic Zones

Page 32: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 32

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Dynamic Zones - Stationary

Sets the nodes on a zone (either fluid or face zone) as stationary.Cell height:

Used for face zonesFor the remeshing of tet/tri, this height is used for boundary node distance.If layering, it will be used for ideal height.It should be roughly the same size as the initial mesh

Page 33: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 33

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Dynamic Zones – Rigid Body

Moves all nodes associated with that zone (cell or face zone)Nodes do not move relative to each otherMotion Attributes: Motion can be specified by Profile or UDF.Center of Gravity (CG) and its location: specify if

Profile uses position x, y, z. The position is measured relative to the CG location.Profile/UDF uses rotation

Page 34: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 34

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Dynamic Zones – Rigid Body

Mesh OptionsCell height:

For the remeshing of tet/tri, this height is used for boundary node distance.For layering, it will be used for ideal height.It should be roughly the same size as the initial mesh

Page 35: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 35

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Geometry DefinitionRequired for remeshing and smoothingA simple Cylinder and Plane is built in.

Cylinder requires Origin and AxisPlane requires any point on the plane and a normal vector

Normal vector can point either direction

User-Defined for other geometriesDeforming is NOT required if the adjacent cell is layering.

Dynamic Zones - Deforming

Page 36: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 36

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Meshing OptionsSmooth: If smoothing is requiredRemeshing: If remeshing is requiredExpand untilContract until

Dynamic Zones - Deforming

Page 37: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 37

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Smoothing andRemeshingapplied on deformed face zones.

Dynamic Zones - Deforming

deforming

deforming

deforming

Page 38: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 38

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Dynamic Zones - Deforming

Smoothing is not selectedOnly Remeshing is applied.This looks much better.In some 2d cases, like this one, it may be necessary not to select Smoothing.In 3d cases, Maximum Skewnessis also used, which prevents this problem.

Page 39: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 39

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Dynamic Zones – User-Defined

If nodes move relative to each other, will need UDF

Page 40: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 40

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Motion Specification

Page 41: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 41

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

For any simple sinusoidal (single-degree, rigid-body, and prescribed) motion, we can use the built-in piston motion:

In-Cylinder Motion

AL

θc

L

A

ps

Valve/Piston Axis

Page 42: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 42

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Table Profile

where,{“time”,“angle”};{ "x", "y", "z"}; {"v_x", "v_y", "v_z"};

{"theta_x", "theta_y", "theta_z"}; {"omega_x", "omega_y", "omega_z"};

((profile_name_1 3 point) (time 0 1 2)

(x 2 3 4) (v_y 0 -5 0))

((profile_name_2 3 point) (time 0 1 2)

(omega_x 2 3 4))

For any type of rigid-body, single-degree, and prescribed motion, you can use a profile table having the following format:

Angle = crank angle

Page 43: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 43

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

UDFs

Fluent also provides the following macros for DM calculations:DEFINE_CG_MOTIONDEFINE_GEOMDEFINE_GRID_MOTION

Page 44: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 44

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

DEFINE_CG_MOTION Macro

Used to define the motion of the center of gravity for rigid body motionUsed for un-prescribed and prescribed motionMultiple-Degree of freedom

Macro: DEFINE_CG_MOTION ( name, dt, vel, omega, time, dtime)Argument types:

void *dt (dynamic thread pointer; common in all macros)real vel[] (array that returns the CG velocity)real omega[] (array that returns the ω of the CG)real time (time)real dtime (time step)

Function returns: void

Page 45: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 45

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

DEFINE_CG_MOTION Example#include "udf.h"#include "dynamesh_tools.h"

static real v_prev = 0.0;

DEFINE_CG_MOTION(piston, 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 ((Dynamic_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) * NV_MAG (A);

}end_f_loop (f, t)

/* compute change in velocity, i.e., dv = F * dt / massvelocity update using explicit euler formula */

dv = dtime * force / 50.0;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;

}

Page 46: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 46

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

DEFINE_GEOM Macro

The DEFINE_GEOM macro is used to define geometry in a deforming zoneMacro: DEFINE_GEOM ( name, d, dt, position)Argument types:

char name Domain *d void *dtreal *position (this matrix is overwritten with the node position on the

boundary) Function returns: void

Page 47: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 47

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

DEFINE_GEOM Example/************************************************************** defining parabola through points (0, 1), (1/2, 5/4), (1, 1)*************************************************************/#include "udf.h"

DEFINE_GEOM(parabola, domain, dt, position){/* set y = -x^2 + x + 1 */position[1] = - position[0]*position[0] + position[0] + 1;

}

The new position (after projection to the geometry defining the zone) is returned to FLUENT by overwriting the position array

Page 48: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 48

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

DEFINE_GRID_MOTION Macro

Useful when defining the position of the nodes individually, e.g. fluid-structure interaction.DEFINE_GRID_MOTION ( name, d, dt, time, dtime)Argument types:

char nameDomain *d void *dtreal time real dtime

Function returns: void

Page 49: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 49

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

DEFINE_GRID_MOTION Example

Case: Specify the deflection of a beam based on local coordinate x and time t according to

Node position is updated based on:

02.0,002.0),178.27sin(4.10{),(

<>−

=x

xtxtxω

trrr nnn Δ×Ω+=+1

Page 50: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 50

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

DEFINE_GRID_MOTION Example

/************************************************************ node motion based on simple beam deflection equation* compiled UDF***********************************************************/

#include "udf.h"

DEFINE_GRID_MOTION(beam, domain, dt, time, dtime){

Thread *tf = DT_THREAD (dt);face_t f;Node *v;real NV_VEC (omega), NV_VEC (axis), NV_VEC (dx);real NV_VEC (origin), NV_VEC (rvec);real sign;int n;

/* set deforming flag on adjacent cell zone */SET_DEFORMING_THREAD_FLAG (THREAD_T0 (tf));

sign = -5.0 * sin (26.178 * time);

Message ("time = %f, omega = %f\n", time, sign);

NV_S (omega, =, 0.0);NV_D (axis, =, 0.0, 1.0, 0.0);NV_D (origin, =, 0.0, 0.0, 0.152);

begin_f_loop (f, tf){f_node_loop (f, tf, n){v = F_NODE (f, tf, n);

/* update node if x position is greater than 0.02and that the current node has not been previouslyvisited when looping through previous faces */

if (NODE_X (v) > 0.020 && NODE_POS_NEED_UPDATE (v)){/* indicate that node position has been update

so that it's not updated more than once */NODE_POS_UPDATED (v);

omega[1] = sign * pow (NODE_X (v)/0.230, 0.5);NV_VV (rvec, =, NODE_COORD (v), -, origin);NV_CROSS (dx, omega, rvec);NV_S (dx, *=, dtime);NV_V (NODE_COORD (v), +=, dx);

}}

}end_f_loop (f, tf);

}

Page 51: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 51

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Summary

Mesh schemes availableSpring SmoothingLayeringRemeshing

If there is relative motion between the boundary and its adjacent cell zone, Fluent will automatically choose the appropriate mesh scheme

If the adjacent cell type is hex/quad, or wedge, it will use layering.If the adjacent cell type is tet/tri, it will use Spring Smoothing and Remeshing

The initial mesh needs to be decomposed according to the mesh scheme desired.Motion can be specified to face zones as well as to cell zones.Motion can be defined using profile, built-in in-cylinder piston profile, or UDFMotion can be prescribed or un-prescribe

Page 52: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 52

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Step-by-Step Setup Procedure

Page 53: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 53

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Simple Remeshing & Smoothing

Page 54: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 54

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Simple Remeshing & Smoothing

V_y (m/s)

0 .005 .01 .015 .02

Time (s)

1

0

-1

V_y

bot

cells-tri

sides

1cm

1cm

0.07cm

Page 55: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 55

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Step 1: Select Unsteady SolverDefine Solver

Simple Remeshing & Smoothing

Page 56: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 56

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Step 2: Activate Dynamic Mesh and Select Mesh MethodsDefine Dynamic Mesh Parameters

Simple Remeshing & Smoothing

Page 57: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 57

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Step 3: Define Load ProfileWrite a profile file

Read the profileDefine Profile

Simple Remeshing & Smoothing

((v_y 5 point)(time 0 .005 .01 .015 .02)(v_y 0 1 0 -1 0))

V_y (m/s)

0 .005 .01 .015 .02

Time (s)

1

0

-1

Page 58: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 58

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Simple Remeshing & Smoothing

0.07cm

V_y

bot

cells-tri

Step 4: Define Dynamic ZonesRigid Body motion

Page 59: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 59

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Simple Remeshing & Smoothing

0.07cm

sides

Step 4: Define Dynamic ZonesDeforming side walls

Page 60: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 60

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Step 5: File Write CaseStep 6: Mesh Motion

Solve Mesh Motion

Simple Remeshing & Smoothing

Page 61: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 61

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Simple Remeshing & Layering -1

Layering takes place at the interface between tri and quad.

Page 62: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 62

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

V_y (m/s)

0 .005 .01 .015 .02

Time (s)

1

0

-1 cells-tri

cells-quad

V_y int

1cm

1cm

0.1cm

.033cm

sides

x

y

.07cm

Simple Remeshing & Layering -1

Page 63: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 63

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Define Dynamic Mesh ParametersDefault parameters for layering is fine

Simple Remeshing & Layering -1

Page 64: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 64

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

0.033

cells-tri

cells-quad

V_y

int.033cm

x

y

.07cm

Define Dynamic ZonesRigid Body Motion applied to the interface between tri and quad.

Simple Remeshing & Layering -1

Page 65: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 65

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

sides

x

y

.07cm

Simple Remeshing & Layering -1Define Dynamic Zones

Deforming sidesNo need to assign Deforming for sides attached to quad

Page 66: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 66

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Simple Remeshing & Layering -1

Final mesh motion.

Page 67: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 67

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Simple Remeshing & Layering -2

How to setup up when layering starts from bottom wall?This requires motion of quad cells and use of stationary on the bottom wall.

Page 68: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 68

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Define Dynamic ZonesRigid Body Motion to Quad Cell Zone

cells-quad

V_y

x

y

Simple Remeshing & Layering -2

Page 69: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 69

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

cells-quad

.033cm

x

y

bot

Simple Remeshing & Layering -2

Define Dynamic ZoneALL nodes on quad moves unless declared as stationary. When declared as stationary, there will be relative motion between boundaries of the quad; therefore, layering will take place.

Page 70: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 70

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

cells-tri

cells-quad

V_y

int

x

y

.07cm

Simple Remeshing & Layering -2Dynamic Mesh Zone Assignment

IF control of height for the tri is desired, specify Rigid Body motion to the interface and specify ideal height.

Page 71: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 71

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

sides-tri

x

y

.07cm

Simple Remeshing & Layering -2Dynamic Mesh Zone Assignment

Deforming sides attached to tris.

Page 72: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 72

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Simple Remeshing & Layering -2

Final mesh motion.

Page 73: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 73

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Simple Remeshing & Layering -3

How to setup if layering and remeshing starts and stops at different times?This requires two profiles, one for the quad and another one for the interface.

Page 74: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 74

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Simple Remeshing & Smoothing

cells_quad(m/s)

int(m/s)

1

0

-10 .005 .01 .015 .02

Time (s)

0 .005 .01 .015 .02

Time (s)

-1

-1

-0

((cells-quad 5 point)

(time 0 .005 .01 .015 .02)

(v_y 0 -1 0 1 0))

((int 7 point)

(time 0 .005 .005 .01 .015 .015 .02)

(v_y 0 -1 0 0 0 1 0))

Profile File

Need to specify two profiles.

Note: Details of setup not shown

cells-quad

int

Page 75: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 75

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Simple Non-Conformal

What if we have non-conformal interface?

It is used for:Closing valves.Must have it between layering and remeshing.

Page 76: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 76

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

cells-quad cells-tri

int-triint-quad

Define Grid InterfacesSelect int_quad under Interface Zone 1Select int_tri under Interface Zone 2Specify name under Grid InterfaceClick on Create

Note: Motion Specification to the bottom walls are not shown.

Simple Non-Conformal

Page 77: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 77

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

cells-quad cells-tri

int-triint-quad

Simple Non-ConformalDefine Dynamic Zones

Only the sides that is part of the tri should be declared as Deforming.

Page 78: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 78

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

cells-tri

side-tri

Simple Non-ConformalDefine Dynamic Zones

Define sides as Deforming

Page 79: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 79

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Simple Inserting a Layer

How to insert a new layer?

Page 80: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 80

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Inserting Boundary Layer

Events is used to insert layering at crank-angle of 40 degrees and removed at crank angle of –40 (320 degrees).

cyl-side: deforming

piston: rigid-body piston motion

Page 81: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 81

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Tips and Tricks

Page 82: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 82

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Completely Closing a Valve

There are two ways to completely close a valve.The most common method is to delete non-conformal interface.Changing cell type from fluid to solid.

The above can be performed via the Events (Define Dynamic Mesh Events)

But since events were implemented mainly to open and close valves in IC applications, it is in terms of Crank Angle!But it is easy to translate or transform our time into Crank Angle.

Page 83: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 83

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Completely Closing a Valve

How to close a valve as shown on the right?You need to create the mesh with the non-conformal interface as shown.

0 .005 .01 .015 .02

Time (s)

v_y(m/s)

-1

-1

-0

interface-2

v_y

interface-1

valve

High pressure

Low pressure

Page 84: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 84

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Completely Closing a Valve

Define Global Controls and Motion SpecificationFor ease, get 1-to-1 correspondence between Crank Angle (degrees) and time (seconds).

To do this, specify Crank Shaft Speed of 0.1666667 rmp

Specify the period for the oscillation, which is 0.02 seconds, as Crank Period = 0.02 degThe simulation will be run at time step size of 5e-5, so enter 5e-5 for Crank Angle Step SizePut any number > 0 for Piston Stroke andConnecting Rod Length

Page 85: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 85

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Completely Closing a Valve

After setting up Global Parameters and defined Dynamic Zones, you need to define events in Define Dynamic Mesh EventsIn this example, at initial mesh, the valve is assumed closed, so enter 0 under At Crank Angle (deg)We will keep it closed for about 0.0001 second to make sure we get at least one step while it is closed.

Page 86: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 86

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Completely Closing a Valve

HVAC RegisterTemperature plot

Page 87: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 87

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Completely Closing a Valve

HVAC DuctNon-Conformal Interface is used

Page 88: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 88

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Completely Closing a Valve

Another example of valve

Page 89: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 89

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Min and Max Volumes - 1

For the remeshing scheme, what is the best way to determine Minimum and Maximum Cell Volume?Plot histogram of cell volume.

Plot Histogram

Select Min and Max roughly as shown on the right figure.But this will give plot of all cells zones.

Min Max

%

Page 90: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 90

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

To find min and max volume in a given cell zone,

Select the cell zone under Zones Name in Dynamic Zones panelClick on Zone Size Info..But don’t click on create!

For Minimum Volume in the remeshing parameters use a value slightly larger than reported above.For Maximum Volume in the remeshing parameters use a value slightly smaller that reported above.

Min and Max Volumes - 2

Page 91: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 91

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Can’t have two deforming face zones attached.For deforming face zone, one need to have complete edge-loopYou may also need to use deforming on a face zone if the adjacent cell zone is only being smoothed.

Current Limitations

Page 92: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 92

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Examples

Page 93: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 93

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Passing Cars

Page 94: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 94

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Passing Cars

Prism layers move with the car.

Page 95: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 95

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Check Valves

Fluid-structure interactionSpring loaded valve.Determine ball position as a function of flow forces

Implemented through a UDF

Page 96: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 96

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Check Valves

The max displacement of the ball was known to be small. So only smoothing is used.

Page 97: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 97

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Flow Control Valves

Page 98: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 98

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Fuel InjectorsTransient flow ratesCavitationFlow forces

Pure Layering

Page 99: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 99

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.comFuel Injectors

Fuel Injectors

Velocity Contours

Page 100: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 100

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Compressors

Spring loaded valvesValve motion coupled to the flow solution via a UDF

Page 101: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 101

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Compressors

As the piston moves to BDC, intake valve opens and exhaust valve closesAs the piston moves to TDC, intake valve closes and exhaust valve opens

Page 102: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 102

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

2-Stroke Engines

Mesh motion

Premixed combustion

Page 103: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 103

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

4-Stroke Engines

Page 104: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 104

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Positive Displacement Pumps

Page 105: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 105

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Gear Pumps

Page 106: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 106

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Volumetric Pump

Pump diameter of 6 cmWaterEccentric (offset) rotor

Blades move in and out of the rotor

All-hex grid100,000 cells

Mesh motion specified via user-defined function

Constant RPM of 1,500

Page 107: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 107

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Volumetric Pump

Geometry and motion

Page 108: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 108

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Volumetric Pump

Pressure contours

Page 109: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 109

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Vibromixer

Contours of Velocity

Page 110: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 110

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Vibromixer

Pure Layering

Page 111: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 111

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Store Separation

Fluent Versus Wind Tunnel

Page 112: Fluent Dynamic Mesh Training

© Fluent Inc. 11/7/20052 - 112

FLUENT Software TrainingDM Model March 2003

Fluent User Services Center

www.fluentusers.com

Store Separation

Contours of pressureNote partition interface move.

Dynamic partitioning is performed.

Page 113: Fluent Dynamic Mesh Training

Swimming Dolphin!

Page 114: Fluent Dynamic Mesh Training

Flying Fly!