CN110457798B - Self-adaptive vorticity limiting force method based on vorticity loss - Google Patents

Self-adaptive vorticity limiting force method based on vorticity loss Download PDF

Info

Publication number
CN110457798B
CN110457798B CN201910689474.4A CN201910689474A CN110457798B CN 110457798 B CN110457798 B CN 110457798B CN 201910689474 A CN201910689474 A CN 201910689474A CN 110457798 B CN110457798 B CN 110457798B
Authority
CN
China
Prior art keywords
vorticity
field
omega
convection
adaptive
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910689474.4A
Other languages
Chinese (zh)
Other versions
CN110457798A (en
Inventor
李思隆
朱鉴
曾荣达
陈炳丰
蔡瑞初
郝志峰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangdong University of Technology
Original Assignee
Guangdong University of Technology
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangdong University of Technology filed Critical Guangdong University of Technology
Priority to CN201910689474.4A priority Critical patent/CN110457798B/en
Publication of CN110457798A publication Critical patent/CN110457798A/en
Application granted granted Critical
Publication of CN110457798B publication Critical patent/CN110457798B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The invention discloses a self-adaptive vorticity limiting force method based on vorticity loss, which comprises the following steps of: solving a fluid control equation based on an Euler grid method, and solving the fluid control equation in each frame; before calculating the convection step for each frame, the current velocity field u is measurednCalculating the vorticity to obtain a vorticity field omegan(ii) a Finding its next state omega by convectionn+1And recording the vorticity field as omega'; for the velocity field u of the current framenCarrying out convection to obtain a velocity field u after convectionn+1For the velocity field u after convectionn+1Calculating the vorticity to obtain the vorticity field omega*(ii) a And calculating a vorticity loss factor delta omega, and constructing an adaptive vortex limiting force model according to the vorticity loss factor. The invention constructs the self-adaptive vortex limiting force f by introducing the vorticity loss factor delta omega, wherein the magnitude of the vorticity loss factor is dynamically changed along with the magnitude of the speed loss, and combining the vorticity loss factor with the vortex limiting forceavcIt has the ideal characteristic of dynamically compensating the numerical dissipation effect.

Description

Self-adaptive vorticity limiting force method based on vorticity loss
Technical Field
The invention relates to the technical field of fluid simulation, in particular to a self-adaptive vorticity limiting force method based on vorticity loss.
Background
The fluid simulation technology has rich application in industries such as movies, games and the like. The fluid pictures of the motion picture and the smoke, the sea and the like in the game cannot be realized in a direct shooting or advanced modeling mode due to the large shooting difficulty, the controllable flow or the interaction with a player and the like, and a physically real fluid must be obtained in a computer simulation mode, namely a fluid simulation technology in computer graphics.
In the field of fluid simulation research, there is often a need to balance two fundamental issues: lower performance overhead and richer fluid visual effects. The fluid simulation technology has certain numerical dissipation due to insufficient solving precision, and visually represents the loss of turbulence details, and the abundant turbulence details play an important role in improving the visual effect of fluid simulation and visual reality of the fluid simulation. In order to obtain richer details, the most direct method is to increase the resolution of the analog field, but this will bring an exponential increase in the amount of computation. Therefore, how to reasonably compensate the precision loss in the solution process and obtain turbulence details as much as possible with a small calculation amount is an important problem for fluid simulation research.
Solving fluid control equations based on euler grids is the most common fluid simulation method, and a great deal of work has been done on this method by predecessors. For example, the method for solving the self-convection of the velocity in the control equation by the semi-Lagrangian method is unconditionally stable, but the problem of insufficient precision in solving the convection term caused by numerical dissipation always exists, and the method is visually represented as weakened fluid details. In order to weaken the influence on the numerical dissipation in the flow item, a vortex limiting force method is provided, the detail richness of the simulated fluid is effectively improved by using smaller calculation overhead, and the method is widely applied. However, the effect of the method is still limited due to the constraint of factors such as accuracy. On the other hand, because the method adopts globally uniform detail enhancement coefficients when calculating the vortex limiting force, the method has the contradiction that is difficult to reconcile when simulating a complex vortex field: for regions with severe numerical dissipation, coefficients large enough to compensate for the loss of detail must be used, but large coefficients tend to create fluid instability and distortion.
Considering that the velocity field of the fluid ignores the incompressibility of the fluid when performing the above-mentioned self-convection step, a projection step must be performed thereafter to eliminate, and therefore the resulting velocity divergence is non-zero. Although this method guarantees unconditional stability of the fluid simulation, eliminating divergence entails a loss of velocity. Therefore, how to compensate the speed loss, reduce the numerical dissipation caused by the speed loss and improve the richness of the fluid details has important research significance.
Disclosure of Invention
The invention mainly researches the problem of how to evaluate the precision loss of a speed field in the self-convection process through the vorticity of the speed field, and provides a vorticity loss-based self-adaptive vorticity force limiting method which can accurately make up the numerical dissipation in the convection process.
In order to achieve the purpose of the invention, the technical scheme is as follows: an adaptive vorticity limiting force method based on vorticity loss, comprising the steps of:
s1: solving a fluid control equation based on an Euler grid method, and solving the fluid control equation in each frame;
s2: before calculating the convection step for each frame, the current velocity field u is measurednCalculating the vorticity to obtain the vorticity field omegan(ii) a The next state omega is obtained by convectionn+1And the vorticity field is ω'
S3: for the velocity field u of the current framenCarrying out convection to obtain a velocity field u after convectionn+1For the velocity field u after convectionn+1Calculating the vorticity to obtain the vorticity field omega*
S4: calculating the vorticity loss factor, wherein the calculation formula is as follows:
Figure BDA0002147429690000021
wherein the content of the first and second substances,
Figure BDA0002147429690000022
in the formula, δ ω represents a vorticity loss factor, and ω represents fluid vorticity;
s5: constructing an adaptive vortex limiting force model according to the vorticity loss factor, wherein the model expression is as follows:
favc=ε′·δω(N×ω)
wherein, the first and the second end of the pipe are connected with each other,
Figure BDA0002147429690000023
in the formula (f)avcRepresenting the self-adaptive vortex limiting force, and epsilon' representing the detail enhancement coefficient of the vortex limiting force; n represents the gradient direction of vorticity magnitude, and ω represents fluid vorticity.
Preferably, in step S1, the expression of the fluid control equation is as follows:
Figure BDA0002147429690000024
in the formula: u represents the velocity of the fluid, t represents the time of flow of the fluid, ρ represents the density of the fluid, p represents the pressure of the fluid, and f represents the external force to which the fluid is subjected.
Further, in step S2, the current velocity field unVorticity field omeganThe calculation formula of (c) is as follows:
Figure BDA0002147429690000031
in the formula (I), the compound is shown in the specification,
Figure BDA0002147429690000032
in order to be a rotation operator, the rotation operator,
Figure BDA0002147429690000033
is a gradient operator.
Still further, step S2, according to the vorticity field ωnThe next state omega is obtained by convectionn+1The method comprises the following steps:
Figure BDA0002147429690000034
Figure BDA0002147429690000035
vorticity field omega after recording convectionn+1Is ω'.
Further, in the step S3, the velocity field un of the current frame is convected to obtain a velocity field u after convectionn+1Namely:
un+1=Advect(un)
according to the velocity field u after convectionn+1Calculating the vorticity to obtain a vorticity field omega*The calculation formula is as follows:
Figure BDA0002147429690000036
the obtained vorticity field omegan+1Is recorded as omega*
Still further, step S6, adding the adaptive vortex limiting force to the velocity field, and continuing to perform frame-by-frame simulation, wherein the calculation formula is as follows:
un+1=un+1+Δtfavc
in the formula, Δ t represents an interval time between two adjacent frames;
and updating the simulation field to obtain the simulation fluid changing along with time.
The invention has the following beneficial effects: according to the invention, the vorticity loss factor delta omega is introduced, the magnitude of the vorticity loss factor is dynamically changed along with the magnitude of the speed loss, the vorticity loss factor is combined with the vortex limiting force to construct the self-adaptive vortex limiting force, and the self-adaptive vortex limiting force has an ideal characteristic of dynamically compensating the numerical dissipation influence.
Drawings
FIG. 1 is a flow chart illustrating the steps of the method of the present embodiment.
Fig. 2 is a diagram of the effect obtained by the method of the embodiment.
Fig. 3 is a diagram of the effect obtained by the method of the prior art in this embodiment.
Detailed Description
The invention is described in detail below with reference to the drawings and the detailed description.
Example 1
As shown in fig. 1, an adaptive vorticity limiting method based on vorticity loss includes the following steps:
step S1: creating a fluid model, initializing parameters, and solving a fluid control equation in each frame: the mesh system is first built for fluid simulation, and the initialization parameters include, but are not limited to, initial velocity u, density ρ, temperature, external force f, and detail enhancement factor ε' of vortex restriction. And solving the fluid control equation frame by frame according to each fluid parameter, and continuously obtaining and updating the next frame state of the fluid. The operations performed per frame are the same. In this example, smoke is set to rise vertically only by the fixed buoyancy, and one frame is taken as shown in the figure 2 by the subplot.
Wherein the expression of the fluid governing equation is as follows:
Figure BDA0002147429690000041
in the formula: u represents the velocity of the fluid, t represents the time between two adjacent frames of fluid, ρ represents the density of the fluid, p represents the pressure of the fluid, and f represents the external force applied to the fluid.
The fluid control equation, namely the NS equation, described in this embodiment describes the basic law of fluid motion. Given a series of initial fluid states (velocity, density, temperature, external force, etc.), substituting the NS equation, one can solve for the next fluid state over a fixed time interval Δ t. By repeating the process, a time-varying fluid sequence, i.e. a process of fluid movement over time, can be obtained.
The state of the fluid needs to be stored in a certain form, and the euler grid method is to divide the simulation space into a large number of fine grid cells uniformly. Each grid cell stores physical information such as speed, vorticity, etc. of the location.
Step S2: the convective velocity field and vorticity field are synchronized. First, the current velocity field u is measured before the convection step is calculated for each framenCalculating the vorticity to obtain the vorticity field omegan. Therein, the vortexDegree field omeganThe calculation formula of (c) is as follows:
Figure BDA0002147429690000042
in the formula (I), the compound is shown in the specification,
Figure BDA0002147429690000043
is a rotation operator, and is characterized in that,
Figure BDA0002147429690000044
is a gradient operator.
Then, unlike the conventional single velocity field convection method, the present embodiment synchronously convects the current velocity field unAnd vorticity field ωnThe next state omega is obtained by convectionn+1The vorticity field after convection is denoted as ω'.
The method comprises the following specific steps:
Figure BDA0002147429690000045
Figure BDA0002147429690000046
synchronously convecting the speed field and vorticity field, and recording the vorticity field omega after convectionn+1Is omega'.
And step S3: then, for the velocity field u of the current framenCarrying out convection to obtain a velocity field u after convectionn+1
Namely:
un+1=Advect(un)
for the velocity field u after convectionn+1Calculating the vorticity to obtain the vorticity field omega*The calculation formula is as follows:
Figure BDA0002147429690000051
taking into account vortexesThe vorticity field is always free of dispersion, so that after the convection step is performed, the unpressurized nature of the fluid only causes a loss of the velocity field, but not the vorticity field, and thus, the accuracy of the vorticity field ω' can be considered to be better than ω*
And step S4: calculating a vorticity loss factor delta omega by the following calculation formula:
Figure BDA0002147429690000052
in the formula, δ ω represents a vorticity loss factor.
Ideally, the vorticity field ω*And ω' should be exactly equal. However, in the process of solving the speed self-convection, the influence of pressure factors is obviously not considered, namely the unpressurized property of the fluid is neglected, so that the vorticity fields solved by the two methods are different. This difference is actually the accuracy error that occurs in the self-convection of velocity, and is more pronounced as the time step of the simulation is larger. The embodiment calculates the vorticity loss factor δ ω as a standard for measuring the error of the precision.
Step S5: the loss of accuracy is compensated for using an adaptive vortex limiting force. The vorticity loss factor delta omega provides the precision loss condition of the velocity field in the convection process, so that the vorticity loss factor delta omega can be used as a measurement index of the precision loss to guide various precision compensation methods to more accurately and adaptively compensate the precision loss.
Constructing an adaptive vortex limiting force model according to the vorticity loss factor, wherein the model expression is as follows:
favc=ε′·δω(N×ω)
wherein the content of the first and second substances,
Figure BDA0002147429690000053
Figure BDA0002147429690000054
in the formula (f)avcShowing adaptive vortex limiting force, ε' tableShowing the detail enhancement factor of the vortex restriction force; n represents the gradient direction of the vorticity magnitude. And ω represents the fluid vorticity.
Obtaining an adaptive vortex limiting force f from the above equationavcBy introducing the above-mentioned loss factor δ ω into the original vortex limit force method. Unlike the constant detail enhancement factor epsilon, the convective vorticity loss delta omega is not a fixed value throughout the simulated field, but there are losses of varying magnitude depending on the local physical characteristics. Therefore, by combining δ ω with the original swirl confining force method, a swirl confining force with self-adaptability can be obtained.
According to the loss amount, the larger the area of delta omega, the compensated self-adaptive vortex limiting force favcThe larger the size, otherwise favcThe smaller. The method of the embodiment has the self-adaptability to the precision loss, and can compensate the fluid details more reasonably. The method for calculating the vorticity loss factor δ ω is independent of each step of solving the fluid control equation, so that the method can be well combined with various existing solving methods, and the solving process is not influenced while self-adaptive detail compensation is exerted.
Step S6: adaptive vortex confining force was added to the velocity field and frame-by-frame simulation was continued. The formula for adding the adaptive vortex restriction force to the velocity field is as follows:
un+1=un+1+Δtfavc
and updating the simulation field to obtain the simulation fluid changing along with time.
According to the embodiment, the self-adaptive factor delta omega is introduced, so that the vortex limiting force can be dynamically changed according to the speed loss conditions before and after convection of each grid unit, and the numerical dissipation in the convection process can be more accurately compensated.
Compared with the original method, the adaptive vortex limiting force method described in the embodiment is shown in fig. 2, and a method in the prior art is shown in fig. 3. As can be seen from fig. 2 and 3, the method described in this embodiment more accurately compensates for the loss of precision, and thus obtains richer visual details. As a whole, the adaptive swirl limiting force method described in this embodiment produces more swirl detail; locally, the plume top simulated using the adaptive vortex limit force method described in this example retains a richer vortex hierarchy, whereas the same area of the prior art method is more severely affected by numerical dissipation. This is because the prior art vorticity limiting force method is not adaptive to compensate and thus visual details are relatively blurred.
It should be understood that the above-described embodiments of the present invention are merely examples for clearly illustrating the present invention, and are not intended to limit the embodiments of the present invention. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present invention should be included in the protection scope of the claims of the present invention.

Claims (6)

1. A self-adaptive vorticity limiting force method based on vorticity loss is characterized by comprising the following steps of: the method comprises the following steps:
s1: solving a fluid control equation based on an Euler grid method, and solving the fluid control equation in each frame;
s2: the velocity field u of the current frame is calculated before the convection step is calculated for each framenCalculating the vorticity to obtain the vorticity field omegan(ii) a Finding its next state omega by convectionn+1Recording the vorticity field as omega';
s3: for the velocity field u of the current framenCarrying out convection to obtain a velocity field u after convectionn+1For the velocity field u after convectionn+1Calculating the vorticity to obtain the vorticity field omega*
S4: calculating the vorticity loss factor, wherein the calculation formula is as follows:
Figure FDA0002147429680000011
wherein the content of the first and second substances,
Figure FDA0002147429680000012
in the formula, δ ω represents a vorticity loss factor; ω represents fluid vorticity;
s5: constructing an adaptive vortex limiting force model according to the vorticity loss factor, wherein the model expression is as follows:
favc=ε′·δω(N×ω)
wherein the content of the first and second substances,
Figure FDA0002147429680000013
in the formula (f)avcShowing the self-adaptive vortex limiting force, and epsilon' showing the detail enhancement coefficient of the vortex limiting force; n represents the gradient direction of the vorticity magnitude.
2. The adaptive vorticity-loss-based vorticity-limiting method of claim 1, comprising: step S1, the expression of the fluid control equation is as follows:
Figure FDA0002147429680000014
in the formula: u represents the velocity of the fluid, t represents the time between two adjacent frames of fluid, ρ represents the density of the fluid, p represents the pressure of the fluid, and f represents the external force applied to the fluid.
3. The adaptive vorticity-loss-based vorticity-limiting method of claim 2, wherein: step S2, current velocity field unVorticity field omeganThe calculation formula of (c) is as follows:
Figure FDA0002147429680000015
in the formula (I), the compound is shown in the specification,
Figure FDA0002147429680000016
in order to be a rotation operator, the rotation operator,
Figure FDA0002147429680000017
is a gradient operator.
4. The adaptive vorticity-loss-based vorticity-limiting method of claim 3, wherein: step S2, according to the vorticity field omeganThe next state omega is obtained by convectionn+1The method comprises the following steps:
Figure FDA0002147429680000021
Figure FDA0002147429680000022
vorticity field omega after recording convectionn+1Is ω'.
5. The adaptive vorticity-loss-based method according to claim 4, wherein: said step S3, wherein, for the velocity field u of the current framenCarrying out convection to obtain a velocity field u after convectionn+1Namely:
un+1=Advect(un)
according to the velocity field u after convectionn+1Calculating the vorticity to obtain the vorticity field omega*The calculation formula is as follows:
Figure FDA0002147429680000023
the obtained vorticity field omegan+1Is recorded as omega*
6. The adaptive vorticity-limited force method based on vorticity loss according to any one of claims 2 to 5, wherein: after step S5, the adaptive swirl limiting force f is adjustedavcAdding the mixture into a velocity field, and continuing to perform simulation frame by frame, wherein the calculation formula is as follows:
un+1=un+1+Δtfavc
in the formula, Δ t represents an interval time between two adjacent frames;
and updating the simulation field to obtain the simulation fluid changing along with time.
CN201910689474.4A 2019-07-29 2019-07-29 Self-adaptive vorticity limiting force method based on vorticity loss Active CN110457798B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910689474.4A CN110457798B (en) 2019-07-29 2019-07-29 Self-adaptive vorticity limiting force method based on vorticity loss

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910689474.4A CN110457798B (en) 2019-07-29 2019-07-29 Self-adaptive vorticity limiting force method based on vorticity loss

Publications (2)

Publication Number Publication Date
CN110457798A CN110457798A (en) 2019-11-15
CN110457798B true CN110457798B (en) 2022-11-01

Family

ID=68483818

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910689474.4A Active CN110457798B (en) 2019-07-29 2019-07-29 Self-adaptive vorticity limiting force method based on vorticity loss

Country Status (1)

Country Link
CN (1) CN110457798B (en)

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7565276B2 (en) * 2006-04-05 2009-07-21 Seoul National University Industry Foundation Method of simulating detailed movements of fluids using derivative particles
KR101267627B1 (en) * 2011-06-13 2013-05-27 한국과학기술원 SPH Fluid simulation method and system for Multi-Level Vorticity, recording medium for the same
CN102682146B (en) * 2011-11-30 2014-01-15 天津空中代码工程应用软件开发有限公司 Method for simulating numerical value of compressible vortex flow field
DE102012113045B4 (en) * 2012-12-21 2023-03-23 Endress+Hauser SE+Co. KG Method for determining and/or monitoring at least one parameter in automation technology
CN103914602A (en) * 2012-12-30 2014-07-09 西安远景动力模拟技术有限公司 Numerical value simulating method for compressible vortex flow field
CN103823916B (en) * 2013-10-23 2016-09-14 沈智军 A kind of arbitary Lagrangian-Eularian based on multidimensional Riemann Solution
CN107085629B (en) * 2017-03-28 2020-05-12 华东师范大学 Fluid simulation method based on coupling of video reconstruction and Euler model
CN109977431B (en) * 2017-12-25 2021-04-27 中国科学院沈阳自动化研究所 Smoke modeling method in large-scene environment
CN108536940A (en) * 2018-03-29 2018-09-14 北京工业大学 A kind of method for building up of indoor smog diffusion model

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
一种改进的自适应漩涡限制实时烟雾模拟;唐勇等;《小型微型计算机系统》;20121215(第12期);全文 *
基于涡粒子的真实感烟雾快速模拟;朱鉴等;《广东工业大学学报》;20190531;第25页-第31页 *

Also Published As

Publication number Publication date
CN110457798A (en) 2019-11-15

Similar Documents

Publication Publication Date Title
CN108269299B (en) Viscous fluid modeling method based on approximate solution of SPH (particle-spray-drying) method
Losasso et al. Simulating water and smoke with an octree data structure
Macklin et al. Position based fluids
Scovazzi Lagrangian shock hydrodynamics on tetrahedral meshes: A stable and accurate variational multiscale approach
US7479963B2 (en) Method and system for performing computer graphic simulation of a fluid using target-driven control
Monaghan Implicit SPH drag and dusty gas dynamics
US6266071B1 (en) Method of producing fluid-like animations using a rapid and stable solver for the Navier-Stokes equations
CN110717269B (en) Fluid surface detail protection method based on grid and particle coupling
CN104268943A (en) Fluid simulation method based on Eulerian-Lagrangian coupling method
US8055490B2 (en) Semi-Lagrangian CIP fluid solver without dimensional splitting
CN106340053A (en) Fluid dynamics framework for animated special effects
CN109344450B (en) Fluid sets analogy method and system based on PBF
KR101328739B1 (en) Apparatus and method for simulating multiphase fluids and controlling the fluids's shape
CN111104753B (en) Viscous incompressible fluid simulation method based on SPH
Dehghan et al. Numerical analysis of fully discrete energy stable weak Galerkin finite element Scheme for a coupled Cahn-Hilliard-Navier-Stokes phase-field model
CN110457798B (en) Self-adaptive vorticity limiting force method based on vorticity loss
CN111859529A (en) Multi-grid disturbance domain updating acceleration method for aircraft streaming numerical simulation
Yoshizawa Subgrid‐scale modeling with a variable length scale
Kuhn et al. An all-Mach, low-dissipation strategy for simulating multiphase flows
KR100779993B1 (en) Method for simulating fluid with applying contol value to pressure field, recording medium and apparatus thereof
Liu et al. Turbulent details simulation for SPH fluids via vorticity refinement
Lu et al. A Rigging‐Skinning Scheme to Control Fluid Simulation
Gao et al. An efficient FLIP and shape matching coupled method for fluid–solid and two-phase fluid simulations
Chai et al. An efficient stabilized finite element scheme for simulating viscoelastic flows
Wu et al. Improved divergence‐free smoothed particle hydrodynamics via priority of divergence‐free solver and SOR

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant