Affine particleincell method for twophase liquid simulation
1. Faculty of Science and Technology, University of Macau, Macao 999078, China
2. State Key Laboratory of Internet of Things for Smart City, University of Macau, Macao 999078, China
3. State Key Laboratory of Computer Science, Institute of Software, Chinese Academy of Sciences (CAS) & University of CAS, Beijing 100190, China
4. Guangzhou Greater Bay Area Virtual Reality Research Institute, Guangzhou 510700, China
Abstract
Keywords： Fluid simulation ; TwoPhase flow ; Affine particleincell method
Content
Algorithm 1 NBMultiFLIP vs. NBMultiAPIC 

Require: Steps are colored differently for NBMultiAPIC and NBMultiFLIP. Steps in red are unique to NBMultiAPIC, while steps in blue are unique to NBMultiFLIP. Other steps, which are not colored, are shared by both methods. 
1: Advect the position and velocities of gas and liquid particles 
2: Track and construct the gas–liquid interface based on the particles and previous interface 
3: Advect the velocities of gas and liquid on the Euler grid 
4: Map the velocities of gas and liquid particles to the grid [NBMultiAPIC] Transfer by mass weighted APIC [NBMultiFLIP] Transfer by FLIP 
5: Update the velocities on the grid 
6: Bump the particles near the interface and resample the particles 
7: Handle the escaped particles 
8: Add external forces 
9: Solve the variable Poisson equation to gain the divergencefree velocities 
10: Transport the velocities of the Euler grid to the gas and liquid particles [NBMultiAPIC] Transfer by APIC [NBMultiFLIP] Transfer by FLIP 
Method  Number of Particles (Thousand)  Avg. Time/Timestep (s)  

$Gas$

$Liquid$

$Total$


Tension  NBMultiPIC  133.45  101.97  235.42  2.22  
NBMultiFLIP  133.31  102.01  235.33  2.26  
NBMultiAPIC  126.98  126.03  253.01  2.23  
Drop  NBMultiPIC  539.50  509.24  1048.73  11.04  
NBMultiFLIP  562.15  550.19  1112.34  13.20  
NBMultiAPIC  528.33  516.71  1045.04  12.54  
Box glugging  NBMultiPIC  98.96  83.61  182.57  1.65  
NBMultiFLIP  112.88  101.66  214.54  2.10  
NBMultiAPIC  121.27  104.69  225.96  2.20  
Tube  NBMultiPIC  232.36  230.20  462.39  4.75  
NBMultiFLIP  271.23  255.65  526.88  5.13  
NBMultiAPIC  280.55  273.57  554.12  6.05  
Dam break  NBMultiPIC  250.15  234.90  485.05  4.41  
NBMultiFLIP  272.57  253.65  526.21  5.87  
NBMultiAPIC  261.21  241.19  502.39  5.00  
Bubble  NBMultiPIC  135.50  145.99  281.49  3.89  
NBMultiFLIP  140.66  159.68  300.34  4.28  
NBMultiAPIC  139.01  155.05  294.06  4.02 
Reference
Boyd L, Bridson R. MultiFLIP for energetic twophase fluid simulation. ACM Transactions on Graphics, 2012, 31(2): 1–12 DOI:10.1145/2159516.2159522
Jiang C, Schroeder C, Selle A, Teran J, Stomakhin A. The affine particleincell method. ACM Transactions on Graphics, 2015, 34(4): 1–10 DOI:10.1145/2766996
Ferstl F, Ando R, Wojtan C, Westermann R, Thuerey N. Narrow band FLIP for liquid simulations. Computer Graphics Forum, 2016, 35(2): 225–232 DOI:10.1111/cgf.12825
Foster N, Metaxas D. Realistic animation of liquids. Graphical Models and Image Processing, 1996, 58(5): 471–483 DOI:10.1006/gmip.1996.0039
Liu X D, Fedkiw R P, Kang M. A boundary condition capturing method for poisson's equation on irregular domains. Journal of Computational Physics, 2000, 160(1): 151–178 DOI:10.1006/jcph.2000.6444
Hong J M, Kim C H. Discontinuous fluids. ACM Transactions on Graphics, 2005, 24(3): 915–920 DOI:10.1145/1073204.1073283
Losasso F, Shinar T, Selle A, Fedkiw R. Multiple interacting liquids. ACM Transactions on Graphics, 2006, 25(3): 812–819 DOI:10.1145/1141911.1141960
Kim B, Liu Y J, Llamas I, Jiao X M, Rossignac J. Simulation of bubbles in foam with the volume control method. ACM Transactions on Graphics, 2007, 26(3): 98 DOI:10.1145/1276377.1276500
Ando R, Thuerey N, Wojtan C. A stream function solver for liquid simulations. ACM Transactions on Graphics, 2015, 34(4): 1–9 DOI:10.1145/2766935
Ren B, Li C F, Yan X, Lin M C, Bonet J, Hu S M. Multiplefluid SPH simulation using a mixture model. ACM Transactions on Graphics, 2014, 33(5): 1–11 DOI:10.1145/2645703
Yang T, Chang J, Ren B, Lin M C, Zhang J J, Hu S M. Fast multiplefluid simulation using Helmholtz free energy. ACM Transactions on Graphics, 2015, 34(6): 1–11 DOI:10.1145/2816795.2818117
Ma M, Lu J C, Tryggvason G. Using statistical learning to close twofluid multiphase flow equations for a simple bubbly system. Physics of Fluids, 2015, 27(9): 092101 DOI:10.1063/1.4930004
Edwards E, Bridson R. A highorder accurate particleincell method. International Journal for Numerical Methods in Engineering, 2012, 90(9): 1073–1088 DOI:10.1002/nme.3356
Cornelis J, Ihmsen M, Peer A, Teschner M. IISPHFLIP for incompressible fluids. Computer Graphics Forum, 2014, 33(2): 255–262 DOI:10.1111/cgf.12324
Fu C Y, Guo Q, Gast T, Jiang C, Teran J. A polynomial particleincell method. ACM Transactions on Graphics, 2017, 36(6): 1–2 DOI:10.1145/3130800.3130878
Sato T, Wojtan C, Thuerey N, Igarashi T, Ando R. Extended narrow band FLIP for liquid simulations. Computer Graphics Forum, 2018, 37(2): 169–177 DOI:10.1111/cgf.13351
Lyu L, Ren X H, Cao W, Zhu J, Wu E H. Adaptive narrow band MultiFLIP for efficient twophase liquid simulation. Science China Information Sciences, 2018, 61(11): 114101 DOI:10.1007/s1143201895183