Compressive VOF Module

The compressive_vof module is an algebraic VOF module that transports liquid volume fractions in incompressible, isothermal flow. Liquid and gas densities and viscosities are constant and mixture properties vary with composition. The gas occupies the fraction left over after summing the liquids.

Setup

The example below shows how to load the compressive_vof module. At least one liquid and exactly one gas must be specified. The example below transports water through a filled channel.

Water-channel setup
loadModule: compressive_vof
{

// Grid
grid_file_info: <Lref=1 m>

// Boundaries
boundary_conditions: <
  inlet=incompressibleInlet(v=[1 m/s, 0 m/s, 0 m/s], vof=[water=1]),
  outlet=fixedPressureOutlet(p=101325 Pa),
  y_min=slip,
  y_max=slip,
  z_min=slip,
  z_max=slip
>

// Initial conditions
initialCondition: <p=101325 Pa, v=1 m/s, vof=[water=1]>

// Flow properties
flowRegime: laminar
flowCompressibility: incompressible
transport_model: module

// Time stepping
timeIntegrator: BDF
timeStep: 0.001
numTimeSteps: 10
maxIterationsPerTimeStep: 100
convergenceAbsoluteTolerance: <default=1e-8, vof=1e-8>

// Fluxes and equation solvers
inviscidFlux: FOU

momentumEquationOptions: <linearSolver=SGS, relaxationFactor=0.7, maxIterations=5>

pressureCorrectionEquationOptions: <linearSolver=HYPRE, relaxationFactor=0.4, maxIterations=20, incompressibleForm>
  pressureBasedMethod: SIMPLEC

vofEquationOptions: <relaxationFactor=0.7, maxIterations=5>

// VOF settings
liquidPhases: <water=incompressible(rho=1000 kg/m/m/m, mu=0.001 kg/m/s)>
gasPhase: <air=incompressible(rho=1.225 kg/m/m/m, mu=1.8e-5 kg/m/s)>
vofInviscidFlux: MIG

// Output
print_freq: 1
plot_freq: 5
plot_output: vofResidual

}

Phase Properties

Each entry in liquidPhases and gasPhase uses a syntax of the form: incompressible(rho=..., mu=...). Values accept compatible units or bare SI numbers (kg/m/m/m and kg/m/s). The gas and liquid names must differ.

The density and laminar viscosity values are arithmetic volume-weighted mixtures.

Initialization and Boundaries

Use vof=[phase=value, ...] in initialCondition or the states in initialConditionRegions. Omitted liquids have zero fraction. Each value must be in [0,1] and their sum must not exceed one, allowing 1e-12 roundoff. The gas is implicit and must not appear in the list. For regional initialization, replace initialCondition with, for example:

initialConditionRegions: <
  default=state(p=101325 Pa, u=[1 m/s, 0 m/s, 0 m/s], vof=[water=0]),
  slug=state(p=101325 Pa, u=[1 m/s, 0 m/s, 0 m/s], vof=[water=1]),
  regions=[inBox(p1=[0, 0, 0], p2=[0.02, 0.1, 0.1], composition=slug)]
>

incompressibleInlet, subsonicInlet, totalPressureInlet, inflow, and farfield require a vof list. Outlet fractions are extrapolated from the adjacent cell, including during reverse flow. Wall fractions are also extrapolated. For incompressible VOF, subsonicInlet requires T, but its value is ignored:

inlet=subsonicInlet(mdot=0.144 lbm/s, T=68 F, vof=[water=1])

incompressibleInlet does not require T.

For specifying periodic boundaries, the module uses the standard translational or rotational setup.

Advection and Boundedness

vofInviscidFlux selects FOU (default), IG, MIG, FBIC, or TVD. FOU uses upwind fractions; the other choices reconstruct face values.

With overUnderFillingCorrection: off (default), each VOF linear solve clips liquid fractions to [0,1] and rescales them if their sum exceeds one. This projection can change phase inventory. Setting the option to on disables that projection and enables the older face correction for IG, MIG, and FBIC. FOU and TVD have no such face correction. Keep the default unless specifically evaluating that alternative.

vofViscosity defaults to zero. It is a nonnegative implicit stabilization coefficient in kg/(m s), with a compensating source contribution. It changes the iterative solve, not the converged transport equation or physical mixture viscosity.

Set vofCompressionLimiting: on to reduce compression as the outgoing volume Courant number increases. The default is off. This number is the timestep times the total outward volumetric flow rate, divided by the cell volume. Limiting can broaden interfaces. Use it with overUnderFillingCorrection: off.

For fixed-step BDF2, reduce the timestep if this number exceeds 0.5. The limiter uses upwind fractions at 0.5 and above. Timestep growth lowers the allowable value.

Equation Solvers and Convergence

vofEquationOptions controls the inner linear iterations:

VOF linear solver

Entry

Default

Meaning

linearSolver

SGS

SGS is the only supported solver.

relaxationFactor

0.5

Finite value in (0,1].

maxIterations

5

Nonnegative integer inner-iteration limit; zero skips the linear updates.

Add vof to either convergence-tolerance list to include every liquid in the nonlinear stopping criterion:

convergenceAbsoluteTolerance: <default=1e-8, vof=1e-8>
convergenceRelativeTolerance: <vof=1e-4>

Every liquid must satisfy its absolute or relative tolerance, along with the other active equations. Absolute tolerances use the RV: residuals in kg/s. Relative tolerances use each liquid’s first positive residual in the current time step.

Once enabled, vof overrides default in each list. A missing entry uses 1e-30. An active legacy convergenceTolerance overrides the absolute tolerance and sets the relative tolerance to 1e-30. Omit it when using the lists above.

Without an explicit vof entry, VOF residuals do not affect stopping. Reaching maxIterationsPerTimeStep still advances the solution and warns for each liquid that has not met its requested tolerance.

Interface Turbulence Damping

For turbulent flow, set interfaceTurbDamping: on to reduce turbulent momentum diffusion in mixed-phase cells. The default is off. The turbulence equations use the original model viscosity.

interfaceTurbDampingFactor sets the damping strength (default 10). It is a dimensionless and nonnegative factor. Larger values give stronger damping and zero gives undamped diffusion. Pure-phase viscosity is unchanged by this factor.

interfaceTurbDamping: on
interfaceTurbDampingFactor: 10

Surface Tension

Surface tension uses one liquid and one gas.

Set sigma_ij in N/m using the names from liquidPhases and gasPhase:

momentumEquationOptions: <pressureReconstruction=CD>
  momentumInterpolationOptions: <form=new, conservativePressure>
sigma_ij: <water__air=0.072 N/m>

Alternatively, use momentumInterpolationOptions: <form=Denner> with the same CD pressure setting. Omitting sigma_ij or setting its coefficient to zero disables surface tension.

Curvature is positive for a convex drop of the first phase in sigma_ij.

Curvature

Two methods are supported for computing curvature. vof_curvature_type: direct (default) computes curvature from the VOF field.

vof_curvature_type: nodalDivergence computes curvature from nodal normals of a smoothed VOF copy. The transported VOF field is unchanged. vof_curvature_smoothing_passes sets the number of smoothing passes (default 2). Zero skips these passes.

For either method, curvatureOptions: <normalFloor=1e-5> controls the contribution from weak gradients. The value is dimensionless and defaults to 1e-5. Larger values reduce the contribution from weak gradients.

An example of specifying a constant prescribed curvature(in 1/m) is shown below.

vof_curvature_type: analytical
kappaAnalytical: 100

kappaAnalytical defaults to zero. Add kappa to plot_output to write the selected curvature.

Wall Contact

With direct or nodalDivergence, set a static contact angle on a slip or no-slip wall via the syntax shown below.

boundary_conditions: <
  wall=noslip(contactAngleModel=static, contactAngle=60 deg)
>

contactAngle is measured through the first phase in sigma_ij. Alternatively, contactAngles=[water__air=60 deg] measures the angle through the first phase in its own pair. This is equivalent to contactAngles=[air__water=120 deg].

vof_contact_angle_model: static applies a static angle to all walls. vof_contact_angle_deg sets the angle in degrees through the first phase in sigma_ij (default 90). Wall settings override these defaults. The default model, none, imposes no contact angle.

Adaptive Mesh Refinement

Load amr and follow Basic Setup and Solution Transfer.

Select VOFerror as an interface sensor for scaledError:

adaptRequestSources: scaledError
adaptSensor: VOFerror

VOFerror measures the largest adjacent-face jump among liquid and gas volume fractions, including inlet-to-cell differences. It is dimensionless and uses the same statistical thresholds as other sensors. See Coarsening Tolerances.

Output and Diagnostics

At plot times, the module writes vof_<phaseName> scalar fields for every liquid and the gas. output/liquidVolume.dat records cycle, time, and the volume of each liquid at print_freq. Liquid columns are sorted by phase name (case-sensitive).

Add vofResidual to plot_output to write all liquid residual fields:

plot_output: vofResidual

Enable vofBoundednessDiagnostics: on to write output/vofBoundedness.dat (default off). Each nonlinear iteration records one row per liquid and the implicit gas:

Boundedness diagnostics

Columns

Meaning

n, it, phase

Time-step index, nonlinear-iteration index, and phase name.

rawMin, rawMax

Cell-fraction extrema before the boundedness projection.

changedCells

Number of cells changed by clipping or rescaling.

deltaVolume, absDeltaVolume

Signed and absolute volume changes due to the projection, in m³.

These are changes from one linear solve’s projection, not cumulative time-step mass errors. With overUnderFillingCorrection: on, projection changes are zero even when raw fractions exceed their bounds.