(skin_friction_ibm)= # Skin friction (IBM) Wall skin friction is the quantity that separates a drag estimate into its viscous and pressure parts and sets the near-wall mesh requirement through $y^{+}$. Nassu samples it directly on every immersed body from the resolved stress, reusing the {ref}`IBM combine interpolation `, so the friction reported on a body does not depend on the boundary condition that body actually runs - a plain no-slip IBM body with no wall model reports a friction just the same. ## The wall shear stress The primitive quantity is the wall shear stress, the tangential viscous traction the fluid exerts on the surface. For a wall whose outward normal is $\mathbf{n}$ and whose local tangential flow direction is $\mathbf{t}$, it is set by the wall-normal gradient of the tangential velocity: $$ \tau_{\mathrm{w}} = \mu\,\frac{\partial u_{t}}{\partial n}\bigg|_{\mathrm{w}} = 2\,\rho\,\nu\,S_{nt}\big|_{\mathrm{w}} $$ (skinfric_tau_w) where $\mu = \rho\nu$ is the dynamic viscosity and $S_{nt}$ is the wall-normal-tangential component of the rate-of-strain tensor at the wall. The second form is exact in incompressible flow and is the one the lattice Boltzmann method recovers naturally, because $S_{\alpha\beta}$ is carried by the non-equilibrium part of the populations rather than reconstructed from velocity differences ({footcite:t}`Kruger2016-cv`). From $\tau_{\mathrm{w}}$ follow the quantities reported per body: $$ C_{f} = \frac{\tau_{\mathrm{w}}}{\tfrac{1}{2}\rho U_{\infty}^{2}}, \qquad u_{\tau} = \sqrt{\frac{\tau_{\mathrm{w}}}{\rho}}, \qquad y^{+} = \frac{u_{\tau}\,y}{\nu} $$ (skinfric_derived) the skin-friction coefficient $C_{f}$, the friction velocity $u_{\tau}$, and the wall-unit distance $y^{+}$ of the first sampled point. ## How Nassu measures it At the export frequency a read-only **friction-sampling pass** runs for every immersed body. It is independent of the body's boundary condition: a body running plain no-slip IBM, a wall-modeled body, and a moving body all report friction computed the same way, so a single field is comparable across the whole domain. The pass reuses the IBM machinery already in place. Along each Lagrangian node's outward normal it samples the fluid at the wall-model reference distance with the same Euler-to-Lagrange combine interpolation used to build the immersed-boundary forcing (see {ref}`combine_and_spread`). It spreads no force back to the fluid, so it never perturbs the solution. ### Viscous traction from the resolved stress Everything is built from the viscous traction vector, formed from the interpolated rate-of-strain $S_{\alpha\beta}$, which the lattice Boltzmann method carries in the non-equilibrium part of the populations and Nassu stores at every node (and corrects for the IBM body force): $$ \mathrm{traction}_{\alpha} = 2\,\rho\,\nu_{\mathrm{total}}\,S_{\alpha\beta}\,n_{\beta}, \qquad \nu_{\mathrm{total}} = \nu_{0} + \nu_{\mathrm{SGS}} $$ (skinfric_traction) The total viscosity carries the subgrid contribution $\nu_{\mathrm{SGS}}$ from the {ref}`Smagorinsky model `, so the traction reflects the modeled stress wherever the LES adds eddy viscosity near the wall (with LES off, $\nu_{\mathrm{total}} = \nu_{0}$). ### Friction velocity from the wall shear stress The wall shear stress $\tau_{\mathrm{w}}$ is the magnitude of the tangential part of the traction, splitting it against the wall normal $n_{\alpha}$ at each sampled point: $$ \tau_{\mathrm{w}} = \left|\,\mathrm{traction}_{\alpha} - (\mathrm{traction}_{\beta} n_{\beta})\,n_{\alpha}\,\right|, \qquad u_{\mathrm{friction}} = \sqrt{\frac{\tau_{\mathrm{w}}}{\rho}} $$ (skinfric_u_friction) and the $C_{f}$, $u_{\mathrm{friction}}$ and $y^{+}$ of {eq}`skinfric_derived` follow from it directly. Because the wall shear comes entirely from the resolved stress, the friction velocity and $y^{+}$ are defined for **any** body - a plain no-slip IBM body with no wall model, a wall-modeled body, or a moving body - with no dependence whatsoever on the body's boundary condition. This is the figure reported per node. ## Aggregation onto the source geometry The runtime IBM node set subdivides each source triangle, so it can hold millions of Lagrangian nodes that do not map one-to-one onto the geometry's faces. Reporting per-node would be unwieldy and tied to a resolution-dependent mesh. The pass therefore aggregates the per-node traction back onto the **source-geometry triangles** by an area-weighted mean, collapsing the runtime nodes (order $10^{6}$) onto the original faces (order $10^{4}$) while preserving the integral. On the host the aggregated traction at each triangle is split against the exact triangle normal into a normal and a tangential part: $$ \mathbf{traction}_{n} = \left(\mathbf{traction}\cdot\mathbf{n}\right)\mathbf{n}, \qquad \mathbf{traction}_{t} = \mathbf{traction} - \mathbf{traction}_{n} $$ (skinfric_split) The tangential part is the skin-friction stress, giving the local $C_{f}$ from {math:numref}`skinfric_derived`. The normal part is the **viscous normal** traction, not the mechanical pressure: the exported traction is purely viscous ($2\rho\nu\,\mathbf{S}\cdot\mathbf{n}$) and carries no $\rho c_{s}^{2}$ pressure term. The reader therefore labels its body-integrated coefficients `Cd_normal_viscous` and `Cd_friction`, and `Cd_total` is the body's total *viscous* force. For a bluff body the dominant **form drag** is the surface-pressure contribution. The same friction pass samples the wall pressure at the reference point (co-located with the reference velocity), through the equation of state $p = \rho\,(1 + \theta)\,c_{s}^{2}$, and stores it per node as `pressure`. The $\theta$ (temperature-deviation) term folds in the fluid temperature when it carries one and is $0$ for isothermal flow ($p = \rho\,c_{s}^{2}$). The host builds the surface pressure coefficient $C_{p} = (p - p_{\text{ref}}) / (\tfrac{1}{2}\rho_{\text{ref}} U_{\text{ref}}^{2})$ and integrates $-C_{p}\,\mathbf{n}$ over the body for the form-drag coefficient. Because drag projects linearly onto the flow direction, the full bluff-body drag is the exact sum $C_{d} = C_{d,\text{pressure}} + C_{d,\text{viscous}}$. ## Validity The traction comes from the resolved and interpolated stress, so its fidelity tracks the near-wall resolution: at a well-resolved wall it is the viscous stress directly, while at a marginally-resolved wall the subgrid viscosity $\nu_{\mathrm{SGS}}$ carries part of the shear and the reported traction includes that modeled contribution. The friction velocity follows the equilibrium thin-boundary-layer closure, which is exact for an attached equilibrium boundary layer and degrades gracefully where the wall-model assumptions weaken (see the {ref}`wall-model limits `). Local $C_{f}$ is an instantaneous, per-triangle quantity and benefits from time averaging; for bodies of revolution, azimuthal averaging further smooths the distribution and sharpens the comparison against reference data. ```{eval-rst} .. footbibliography:: ```