Immersed Boundary Surface Method In Foam-extend - FSB

Transcription

Immersed Boundary Surface Method infoam-extendHrvoje JasakWikki and University of ZagrebOpenFOAM in Hydraulic Engineering ConferenceBAW Karlsruhe, 21-22/Nov/2018Wikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 1

OutlineObjective Present the new (stabilised) formulation of the Immersed Boundary Method infoam-extend: Immersed Boundary Surface (IBS) Provide examples from hydraulic engineeringTopics Background: Immersed Boundary Method in foam-extend New algorithm: Immersed Boundary Surface (IBS) Method Imposition of boundary conditions Validation: Simple static mesh cases Handling IBS motion: Dynamic IBS Validation: Dynamic mesh cases Hydraulic engineering example: ONR Tumblehome SummaryWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 2

BackgroundImmersed Boundary Method in foam-extend Implementation of the Immersed Boundary Method (IBM) is based on polynomialfitting of the solution with respect to the boundary conditionφP φib C0 (xP xib ) C1 (yP yib ) C2 (xP xib )(yP yib ) C3 (xP xib )2 C4 (yP yib 011100110001110011000111000111ibPFluid cellsSolid cellsIB cellsIB points11000011Extended stencil The IBM performs satisfactorily in single-phase flows, but carries some drawbacks:handling of Neumann boundary conditions, wall function implementation In free surface flows, the solver shows strong instability due to matching ofgradients next to the IB surfaceWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 3

BackgroundProject Objective Objective: provide a robust and efficient Immersed Boundary capability for navalhydrodynamics simulations, specifically for motion of floating objects in confinedspacesFunctional Analysis While functionally correct, the idea of polynomial fitting is adequate for smoothlyvarying solution variables in single-phase flows Handling of Neumann boundary conditions at the IB was unsatisfactory: fittingcondition cannot be fully implicit, yielding instability Wall function implementation carries some uncertainty due to log-law fitting A free surface indicator such as Volume-of-Fluid cannot be adequately fitted andleads to instability Attempts to use the Level Set free surface capturing and the Ghost Fluid Methodfor interface handling proved superior over the original method, but was notcompletely satisfactory: alternative solution is sought Immersed surface data is evaluated on the STL: resolution-dependentConclusion: further improvement in robustness and accuracy is sought regardingthe precision and stability of discretisation at the IB surfaceWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 4

Immersed Boundary SurfaceImmersed Boundary Surface IB implementation relies on the imposition of the boundary condition in the bulk ofthe mesh: this is built into the discretisation matrix Old implementation loses information in the cut cell: reduction in volume; loss ofprecision at the intersection Objective: implement the influence of the presence of a boundary within the meshas if the mesh is body-fitted: Introduce the “new” IB face in the cut cell Account for the partial cell volume without loss of accuracy Account for partial face areas without loss of accuracy Calculate face and cell centre consistent with cell cut . . . without changing the geometric mesh at all!Wikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 5

Immersed Boundary SurfaceImmersed Boundary Surface: Finite Volume Support The FVM method operates on the following geometrical data1. Cell-to-face connectivity: owner/neighbour addressing2. Cell volumes and face area vectors3. Interpolation factors and delta-coefficients (1/distance) . . . and nothing else!!! All data contained in fvMesh classImplementation Rationale Introduce new IBS faces: intersected cells via distance functions Cell-to-face addressing, face area and face centre calculated from intersection For affected cells, FV data (above) is adjustedNotes Underlying mesh connectivity remains the same after cutting Cut cell re-uses discretisation matrix slot of the original cell New faces created as 1-per-cut-cell and contained in the immersed patch:face-cell addressing identifies cut cellsWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 6

Immersed Boundary SurfaceImmersed Boundary Surface: Old and New Methodology \n Fluid cellsSolid cellsIB cellsIB pointsFluid cells: untouchedSolid cells: deactivatedIBS: intersected cellsAdjusted IBS centresCharacteristics of IBS Implementation Immersed boundary patch is included into the mesh via the distance function: allcells that straddle the immersed boundary remain active STL resolution or quality is not important: only using nearest distance As the immersed boundary sweeps the cell, the “live” part of the cell remains welldefined: positive face-to-cell distance Convex cell cut by a zero-distance plane remains convex: no discretisation issuesWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 7

Immersed Boundary SurfaceImmersed Boundary Surface: Modified Immersed Boundary CellsBackground cellBackground cellCorrected face centreCorrected cell centreImmersed face centre Nearest distance calculated for vertices of all affected cells Intersection is calculated for all faces and cells: replace original data withcentres/areas/volumes of the “live part” Immersed intersection calculated based on point distance All faces and cells are cut by a distance plane Simple planar cutting provides robustness: no feature edges Near-wall distance calculated from live cell centre to immersed face Delta coefficients and interpolation factors corrected for centre positionWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 8

Immersed Boundary SurfaceImmersed Boundary Surface: Imposition of Boundary Conditions Immersed boundary is represented in the mesh by STL intersection with cells Therefore, conventional boundary condition implementation suffice on theimmersed patch for a static mesh and IB surface Immersed boundary motion involves change in intersection: number of IB faceschanges! Evaluation of immersed properties is performed without interpolation orsimplification STL surface is automatically refined/coarsened to comply with the backgroundmesh: automatic coarsening and refinementWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 9

Immersed Boundary SurfaceCalculation of IB Intersection: Degenerate Surface Cutting Cases “Regular intersection” occurs between a cell and STL surface Due to finite accuracy, STL regularly coincides with faces or does not provideaccurate intersection Direct face intersection between Dry and Wet cell: face becomes IB face Inaccurate intersection of STL feature edges/points may yield a geometricallyopen cell, with possible robustness issues Using the Marooney Maneouvre to guarantee a closed cell after cuttingXXsf 0for a regular cellγf sf sf IB 0for an intersected cellCCwhere γf is the area correction, obtained by cutting Corrected IB face area sf IB is:sf IB Xγf sfCWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 10

Static Mesh ValidationStatic Mesh Immersed Boundary: Laplace Equation, Potential FlowWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 11

Static Mesh ValidationStatic Mesh Immersed Boundary Cases: Laminar and Turbulent FlowWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 12

Static Mesh ValidationStatic Mesh Immersed Boundary Cases: Free Surface Flow Free surface flow with the Ghost Fluid Method Cylindrical Immersed Boundary obstacle at the bottom, intersecting with boundaryWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 13

Moving Immersed BoundaryMoving Immersed Boundary Surface Support Moving mesh Finite Volume Method uses a compensated form of the transportequationZV φdV tIφ [n (u ub )] dS SIγ(n φ) dS SZqv dVVwhere ub is the boundary velocity Motion consistency requires auxiliary “Conservation of Space” conditionZV V tI(n ub ) dS 0S Discretised space conservation law yieldsXVn Vo Fb 0 tfWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 14

Moving Immersed BoundaryCalculation of Cell Volumes and Motion Fluxes For Immersed Cells Volume swept by immersed face is calculated from new IB face and motiondistance.Vb xb sf n volume swept in redwhere xb is geometrical motion distance from old to new STL As the intersected area changes, swept volume must be distributed: Cell A: expand from cut volume to full volume: no IB face in new configuration Cell B: cut both at new and old configuration: IB face present Cell C: expand from zero volume to partial volume: IB face present (Cell D): expand from zero to full volume (cell fully swept by IB): no IB faceVol oldCELL BCELL CVol newvolume swept byimmersed faceCELL CNew PositionCELL AOld PositionWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 15

Dynamic Mesh ValidationDynamic Mesh Validation: Single-Phase Flow Moving immersed boundary within a static mesh Laminar Flow, Re 50 Some noise in viscous force signal in small cut volumesWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 16

Dynamic Mesh ValidationDynamic Mesh Validation: Moving Mesh Free Surface Flow Free surface capturing, VOF equation, Ghost Fluid Method Floating body described by Immersed Boundary Surface Prescribed motion: heave and sway motion Small oscillation in force related to viscous terms. This can be adjusted with meshrefinementWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 17

Adaptive Refinement, Load BalanceExample: 6-DOF Free Floating with Adaptive Refinement and Load Balancing Force spikes caused by sharp corners on STL geometry: not a good ideaWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 18

Verification: Resistance ForcesONR Tumblehome Ship Hull: Body-Fitted vs Immersed Boundary ONR Tumblehome Ship from the Tokyo 2015 Workshop on Naval Hydrodynamics Bare hull in full scale at Fr 0.2 Comparison of a body fitted mesh simulation and immersed boundary No dynamic sinkage and trim, and no turbulence modelling (still working on that) Result: Resistance comparisonMesh structureResistance [kN]Body Fitted MeshImmersed Boundary98.0 kN92.0 kN Notes The complete hull is modelled as Immersed Boundary No near-wall prismatic layers: wall functions see fluctuating y Immersed boundary solver significantly faster: no small cells for CFL limit Intended use for IB patches are appendage geometries, not the complete hullWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 19

Verification: Resistance ForcesONR Tumblehome Ship Hull: Body-Fitted vs Immersed BoundaryWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 20

Verification: Resistance ForcesONR Tumblehome Ship Hull: Body-Fitted vs Immersed BoundaryWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 21

Verification: Resistance ForcesONR Tumblehome Ship Hull: Body-Fitted vs Immersed BoundaryWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 22

SummarySummary: Immersed Boundary Surface New implementation of Immersed Boundary Surface performed within the project Immersed Boundary created as a set of cell-to-STL intersection faces, capturingall effects of the STL on underlying mesh: no simplifications! Significant improvement in robustness, accuracy, boundedness of the solution andstability of the code For static mesh cases, conventional boundary conditions can be used Automatic adaptation of the triangular mesh: conforming with background meshintersectionSummary: Validation and Verification Validation and verification on static mesh and moving immersed boundarypresented for single-phase and free surface flowsSummary: Adaptive Refinement and Dynamic Load Balancing Adaptive refinement uses a newly developed refinement class operating onpolyhedral cells Refinement criterion: distance from immersed boundary; limited to 2-3 levels Dynamic load balancing: improved efficiency on massively parallel casesWikki Ltd. Proprietary and Confidential: Do not copy or re-distribute. Tracking: 43145000342Immersed Boundary Surface Method in foam-extend – p. 23

Inaccurate intersection of STL feature edges/points may yield a geometrically open cell, with possible robustness issues Using the Marooney Maneouvre to guarantee a closed cell after cutting X C sf 0 for a regular cell X C γ fsf sfIB 0 for an intersected cell where γ f is the area correction, obtained by cutting Corrected IB face area .