Skip to main content

Module fluids

Module fluids 

Source

Structs§

AccelerationVector
Acceleration vector (m/s²). Return type of momentum-equation RHS evaluators.
BodyForceDensity
Body force per unit volume (N/m³).
CauchyStress
Cauchy stress tensor (Pa). Symmetric, positive-in-tension sign convention.
Density
Density (kg/m^3).
KinematicViscosity
Kinematic Viscosity (m^2/s). Equals dynamic viscosity divided by density.
Pressure
Pressure (Pascals).
ReynoldsStress
Reynolds stress tensor R_ij = ⟨u'_i u'_j⟩ (Pa, after multiplication by ρ in caller; here a kinematic Reynolds stress in m²/s² is also acceptable). Symmetric. Diagonal entries are non-negative (variances) — not enforced by the newtype to keep the constructor cheap; callers passing a tensor that violates the diagonal-positivity property are responsible for downstream interpretation.
RotationRateTensor
Rate-of-rotation (spin) tensor Ω = 0.5·(∇u − ∇uᵀ). Antisymmetric: Ω_ji = −Ω_ij, with Ω_ii = 0. new checks the antisymmetry invariant by exact equality.
SpecificEnthalpy
Specific Enthalpy (J/kg). Reference-state dependent; may be negative.
StrainRateTensor
Strain-rate tensor S = 0.5·(∇u + ∇uᵀ). Symmetric: S_ij = S_ji. new checks the symmetry invariant by exact equality, matching what natural construction 0.5·(G + Gᵀ) produces in IEEE 754. Use new_unchecked to bypass the check in hot kernels where symmetry is guaranteed by the algebra.
Velocity3
Fluid velocity vector (m/s).
VelocityGradient
Velocity gradient tensor ∇u. Pinned to the Jacobian convention: value[i][j] = ∂u_i / ∂x_j. Construction-time check is finiteness only — any finite 3×3 matrix is a valid velocity gradient.
Viscosity
Dynamic Viscosity (Pa·s).
ViscousStress
Viscous (deviatoric) stress tensor τ (Pa). Symmetric. Distinct from the full Cauchy stress σ = −p I + τ — only the viscous part appears in the dissipation Φ = τ:∇u ≥ 0 and entropy-production guarantees.
VorticityVector
Vorticity vector ω = ∇ × u (1/s). Pseudovector under spatial reflection.
WallShearStress
Wall Shear Stress magnitude (Pa). Stored as magnitude; sign convention is carried by the calling context, not by this type.