You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/documentation/case.md
+58-24Lines changed: 58 additions & 24 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -276,6 +276,22 @@ Setup: Only requires specifying `files_dir` and filename pattern via `file_exten
276
276
Implementation: All variables and file handling are managed in the `case.py` file of the simulation.
277
277
Usage: Ideal for initializing simulations from lower-dimensional solutions, enabling users to add perturbations or modifications to the base extruded fields for flow instability studies.
278
278
279
+
The following parameters support hardcoded initial conditions that read interface data from files:
280
+
281
+
| Parameter | Type | Description |
282
+
| ---: | :---: | :--- |
283
+
|`interface_file`| String | Path to interface geometry data file |
284
+
|`normFac`| Real | Interface normalization factor |
285
+
|`normMag`| Real | Interface normal magnitude |
286
+
|`g0_ic`| Real | Gravitational acceleration for the interfacial IC pressure field |
287
+
|`p0_ic`| Real | Reference pressure at the interface |
288
+
289
+
These parameters are only read by the file-based hardcoded-IC patches (`hcid = 304` and `305` in `src/common/include/3dHardcodedIC.fpp`); they are ignored otherwise.
290
+
291
+
-`interface_file` gives the path to a text file that supplies the interface-position field \f$h(i,j)\f$ used to place the material interface. The run aborts if the file is not found.
292
+
-`normMag` and `normFac` rescale and offset the raw interface data, \f$h \leftarrow \texttt{normMag}\,h + \texttt{normFac}\f$. Each is applied only when set (defaults leave the data unchanged).
293
+
-`p0_ic` and `g0_ic` set the initial (hydrostatic) pressure field about the interface, \f$p = p_{0} + \rho\, g_{0}\,\big(h - x\big)\f$, where \f$x\f$ is the coordinate normal to the interface.
294
+
279
295
#### Parameter Descriptions
280
296
281
297
-`num_patches` defines the total number of patches defined in the domain.
@@ -930,23 +946,33 @@ When ``polytropic = 'F'``, the gas compression is modeled as non-polytropic due
930
946
931
947
#### 9.2 Volume-Averaged Bubble Model
932
948
933
-
| Parameter | Type | Description |
934
-
| ---: | :---: | :--- |
935
-
|`bubbles_lagrange`| Logical | Lagrangian subgrid bubble model switch |
936
-
|`nBubs_glb`| Integer | Global number of bubbles |
|`heatTransfer_model`| Logical | Activates the interface heat transfer model |
942
-
|`massTransfer_model`| Logical | Activates the interface mass transfer model |
943
-
|`write_bubbles`| Logical | Write files to track the bubble evolution each time step |
944
-
|`write_bubbles_stats`| Logical | Write the maximum and minimum radius of each bubble |
945
-
|`epsilonb`| Real | Standard deviation scaling for the gaussian function |
946
-
|`charwidth`| Real | Domain virtual depth (z direction, for 2D simulations) |
947
-
|`valmaxvoid`| Real | Maximum void fraction permitted |
948
-
949
-
-`nBubs_glb` Total number of bubbles. Their initial conditions need to be specified in the ./input/lag_bubbles.dat file. See the example cases for additional information.
949
+
| Parameter | Type | Description |
950
+
| ---: | :---: | :--- |
951
+
|`bubbles_lagrange`| Logical | Lagrangian subgrid bubble model switch |
952
+
|`nBubs_glb`| Integer | Global number of bubbles |
|`kahan_summation`| Logical | Use Kahan compensated summation when accumulating the void fraction |
972
+
973
+
-`nBubs_glb` Total number of bubbles. Their initial conditions are read from the file given by `input_path`.
974
+
975
+
-`input_path` Path to the bubble input file (default `./input/lag_bubbles.dat`). Each row specifies the initial state of one bubble, with columns `xPosition/x0 yPosition/x0 zPosition/x0 xVel/c0 yVel/c0 zVel/c0 radius/x0 interfaceVelocity/c0`. See `examples/3D_lagrange_shbubcollapse/input/lag_bubbles.dat` for a checked-in example, or the other Lagrange example cases (e.g. `examples/2D_lagrange_bubblescreen/case.py`), which generate this file programmatically.
950
976
951
977
-`solver_approach` Specifies the Euler-Lagrange coupling method: [1] enables a one-way coupling approach, where the bubbles do not influence the Eulerian field. [2] activates the two-way coupling approach based on \cite Maeda18, where the effect of the bubbles is added in the Eulerian field as source terms.
952
978
@@ -958,6 +984,14 @@ When ``polytropic = 'F'``, the gas compression is modeled as non-polytropic due
958
984
959
985
-`massTransfer_model` Activates the mass transfer model at the bubble's interface based on (\cite Preston07).
960
986
987
+
-`vel_model` activates translational motion of the bubbles (\cite Wilfong26): [1] tracer bubbles, which are advected with the local carrier velocity \f$\underline{u}\f$ so that \f$\dot{\underline{x}}_b = \underline{u}(\underline{x}_b)\f$; [2] Newton's second law, which integrates \f$m_b \ddot{\underline{x}}_b = \underline{F}_D + \underline{F}_p + \underline{F}_g\f$, where \f$m_b\f$ is the bubble mass and the right-hand side collects the drag, pressure, and gravity forces below. The carrier velocity at the bubble is interpolated with a Lagrange polynomial of order set by `fd_order`, which must be specified when `vel_model > 0`.
988
+
989
+
-`drag_model` selects the drag force \f$\underline{F}_D\f$ acting on the slip velocity \f$\underline{u}_{\rm rel} = \underline{u}_b - \underline{u}\f$, with bubble radius \f$a\f$ and Reynolds number \f$Re\f$: [0] no drag (default); [1] free-slip drag (clean-interface creeping-flow limit, \cite Hadamard1911, \cite Rybczynski1911), \f$\underline{F}_D = -4\pi a\,\underline{u}_{\rm rel}/Re\f$; [2] no-slip Stokes drag (rigid sphere, \cite Stokes1851), \f$\underline{F}_D = -6\pi a\,\underline{u}_{\rm rel}/Re\f$; [3] Levich drag (clean bubble at high \f$Re\f$, \cite Levich1962), \f$\underline{F}_D = -12\pi a\,\underline{u}_{\rm rel}/Re\f$. See \cite Magnaudet2000 for a review of these bubble-drag regimes.
990
+
-`pressure_force` (default true) enables the pressure-gradient force \f$\underline{F}_p = -V_b\,\nabla p\f$, where \f$V_b = \frac{4}{3}\pi a^3\f$ is the bubble volume.
991
+
-`gravity_force` (default false) enables the body force \f$\underline{F}_g = m_b\,\underline{g}\f$, with \f$\underline{g}\f$ the acceleration set by the body-force parameters.
992
+
993
+
-`kahan_summation` uses Kahan compensated summation when smearing the bubble contributions onto the Eulerian void fraction, reducing the round-off sensitivity of the accumulation to the summation order. It is not compatible with `--mixed` precision builds.
994
+
961
995
### 10. Velocity Field Setup {#sec-velocity-field-setup}
962
996
963
997
| Parameter | Type | Description |
@@ -1286,14 +1320,14 @@ Boundary is at polar angle \f$\theta = \mathrm{atan2}(y - y_{\mathrm{centroid}},
Copy file name to clipboardExpand all lines: docs/documentation/equations.md
+19Lines changed: 19 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -522,6 +522,25 @@ with \f$\sigma = \varepsilon_b \max(\Delta x^{1/3}_\text{cell},\;R_\text{bubble}
522
522
523
523
Each bubble is tracked individually with Keller-Miksis dynamics and 4th-order adaptive Runge-Kutta time integration.
524
524
525
+
**Translational motion (`vel_model > 0`):**
526
+
527
+
Bubbles may also translate through the carrier flow. Let \f$\mathbf{x}_b\f$ be the bubble position, \f$\mathbf{u}_b\f$ its velocity, \f$a\f$ its radius, and \f$\mathbf{u}_l(\mathbf{x}_b)\f$ the carrier velocity interpolated to the bubble location (a Lagrange polynomial of order `fd_order`, which must be set when `vel_model > 0`).
528
+
529
+
-**Tracer bubbles (`vel_model = 1`)** follow the local carrier velocity:
| Gravity \f$\mathbf{F}_g\f$ |`gravity_force`| \f$m_b\,\mathbf{g}\f$, with \f$\mathbf{g}\f$ the body-force acceleration |
541
+
542
+
Here \f$\text{Re}\f$ is the mixture Reynolds number — the same `fluid_pp%%Re(1)` that scales the viscous stress tensor (@ref sec-two-viscosities) — so the drag scales with the liquid viscosity. The three drag models increase in magnitude free-slip \f$<\f$ no-slip \f$<\f$ Levich; see \cite Magnaudet2000 for a review of these bubble-drag regimes.
0 commit comments