壁関数

Category: 流体解析(CFD) | Integrated 2026-04-06
CAE visualization for wall function theory - technical simulation diagram
壁関数

Theory and Physics

Overview

🧑‍🎓

Professor, I often hear people say "make sure y+ is above 30" when talking about wall functions. Why is such a condition necessary in the first place?


🎓

The turbulent boundary layer near a wall has a distinct structure consisting of the viscous sublayer, buffer layer, and log-law layer. Wall functions are a technique that utilizes the velocity profile of this log-law layer to compute with coarse cells near the wall. Since it avoids directly resolving the viscous sublayer, it can significantly reduce the number of mesh cells.


🧑‍🎓

So you're skipping the viscous sublayer?


🎓

To be precise, it's not "skipping" but approximating the velocity, temperature, and turbulence quantities near the wall using semi-empirical functions. That's the essence of wall functions.


Wall Boundary Layer Structure

🧑‍🎓

First, please explain the structure of the boundary layer.


🎓

There are three regions in order of proximity to the wall.


Region$y^+$ RangeDominant EffectVelocity Profile
Viscous Sublayer$y^+ < 5$Molecular viscosity dominates$u^+ = y^+$ (linear)
Buffer Layer$5 < y^+ < 30$Viscosity and turbulence coexistTransition region (no explicit formula)
Log-law Layer$30 < y^+ < 300$Turbulent stress dominates$u^+ = \frac{1}{\kappa}\ln(y^+) + B$
🎓

The definitions of the dimensionless quantities are as follows.


$$ y^+ = \frac{y\, u_\tau}{\nu}, \quad u^+ = \frac{U}{u_\tau}, \quad u_\tau = \sqrt{\frac{\tau_w}{\rho}} $$

$u_\tau$ is the friction velocity, $\tau_w$ is the wall shear stress, and $\nu$ is the kinematic viscosity.


Log-law (Law of the Wall)

🧑‍🎓

Please explain the log-law formula in detail.


🎓

The velocity profile in the log-law layer is expressed by the following equation.


$$ u^+ = \frac{1}{\kappa}\ln(E\, y^+) $$

Here, $\kappa \approx 0.41$ (von Karman constant) and $E \approx 9.793$ (integration constant for smooth walls). Rewriting this gives,


$$ u^+ = \frac{1}{\kappa}\ln(y^+) + B, \quad B = \frac{1}{\kappa}\ln(E) \approx 5.5 $$

🧑‍🎓

What about for rough walls?


🎓

For rough surfaces, the constants are modified according to the roughness height $k_s$.


$$ u^+ = \frac{1}{\kappa}\ln\left(\frac{y^+}{f(k_s^+)}\right) + B $$

Here, $k_s^+ = k_s u_\tau / \nu$ is the roughness Reynolds number. If $k_s^+ < 2.25$, it's classified as hydraulically smooth; if $k_s^+ > 90$, it's fully rough.


Types of Wall Functions

🧑‍🎓

Are there different types of wall functions?


🎓

They can be broadly categorized into three types.


Wall Function TypeCharacteristics$y^+$ Requirement
Standard Wall FunctionStrictly applies the log-law. Launder-Spalding (1974)$30 < y^+ < 300$
Scalable Wall FunctionSwitches to the viscous sublayer formula when $y^+ < 11.225$No restriction (internally corrected)
Enhanced Wall TreatmentBlends Low-Re damping with wall functions$y^+ \approx 1$ is ideal
🎓

The Standard Wall Function is the most classical and assumes the $y^+$ of the first cell falls within the 30 to 300 range. Accuracy degrades significantly outside this range.


🧑‍🎓

I see, that's why they say "make sure $y^+$ is above 30." Conversely, for low Reynolds number models, $y^+ \approx 1$ is required.

Coffee Break Trivia

The Discovery of the Log-law – Prandtl and His Students' Meticulous Experiments

The discovery of the "logarithmic law (log-law)," which forms the basis of wall functions, originated from the meticulous turbulent pipe flow experiments conducted by Ludwig Prandtl and his students in the early 20th century. The fact that the velocity profile in the turbulent region away from the wall follows a logarithmic function was empirically found from data analysis at the time, with theoretical derivation coming later. That this log-law is used daily as the foundation for wall functions in millions of CFD calculations today is a testament to the remarkable longevity of experimental data from 100 years ago.

Physical Meaning of Each Term
  • Time Term $\partial(\rho\phi)/\partial t$: Imagine the moment you turn on a faucet. At first, water comes out in an unstable, spluttering manner, but after a while, it becomes a steady flow, right? This "period of change" is described by the time term. The pulsation of blood flow from a heartbeat, or the flow fluctuation each time an engine valve opens and closes, are all unsteady phenomena. So what is steady-state analysis? It looks only at "after sufficient time has passed and the flow has settled down"—meaning this term is set to zero. Since computational cost drops significantly, solving first with a steady-state approach is a basic CFD strategy.
  • Convection Term $\nabla \cdot (\rho \mathbf{u} \phi)$: What happens if you drop a leaf into a river? It gets carried downstream by the flow, right? This is "convection"—the effect where fluid motion transports things. Warm air from a heater reaching the far corner of a room is also because the "carrier," air, transports heat via convection. Here's the interesting part—this term contains "velocity × velocity," making it nonlinear. That is, as the flow becomes faster, this term rapidly strengthens, making control difficult. This is the root cause of turbulence. A common misconception: "Convection and conduction are similar things" → They are completely different! Convection is carried by flow, conduction is transmitted by molecules. There's an order of magnitude difference in efficiency.
  • Diffusion Term $\nabla \cdot (\Gamma \nabla \phi)$: Have you ever put milk in coffee and left it? Even without stirring, after a while it naturally mixes, right? That's molecular diffusion. Now a question—honey and water, which flows more easily? Obviously water, right? Honey has high viscosity ($\mu$), so it flows poorly. When viscosity is large, the diffusion term becomes strong, and the fluid moves in a "thick, sluggish" manner. In low Reynolds number flows (slow, viscous), diffusion dominates. Conversely, in high Re number flows, convection overwhelms and diffusion plays a minor role.
  • Pressure Term $-\nabla p$: When you push the plunger of a syringe, liquid shoots out forcefully from the needle tip, right? Why? Because the piston side is high pressure, the needle tip is low pressure—this pressure difference provides the force that pushes the fluid. Dam discharge works on the same principle. On a weather map, where isobars are tightly packed? That's right, strong winds blow. "Flow is generated where there is a pressure difference"—this is the physical meaning of the pressure term in the Navier-Stokes equations. A common point of confusion here: The "pressure" in CFD is often gauge pressure, not absolute pressure. When you switch to compressible analysis and suddenly get strange results, it might be due to mixing up absolute/gauge pressure.
  • Source Term $S_\phi$: Warmed air rises—why? Because it becomes lighter (lower density) than its surroundings, so it's pushed upward by buoyancy. This buoyancy is added to the equation as a source term. Other examples: chemical reaction heat generated by a gas stove flame, Lorentz force acting on molten metal in a factory's electromagnetic pump... These are all actions that "inject energy or force into the fluid from the outside," expressed by source terms. What happens if you forget a source term? In a natural convection analysis, if you forget to include buoyancy, the fluid doesn't move at all—a physically impossible result where warm air doesn't rise in a room with the heater on in winter.
Assumptions and Applicability Limits
  • Continuum Assumption: Valid for Knudsen number Kn < 0.01 (mean free path ≪ characteristic length)
  • Newtonian Fluid Assumption: Shear stress and strain rate have a linear relationship (non-Newtonian fluids require viscosity models)
  • Incompressibility Assumption (for Ma < 0.3): Density is treated as constant. For Mach numbers above 0.3, compressibility effects must be considered.
  • Boussinesq Approximation (Natural Convection): Density variation is considered only in the buoyancy term; constant density is used in other terms.
  • Non-applicable Cases: Rarefied gases (Kn > 0.1), supersonic/hypersonic flow (shock capturing required), free surface flow (VOF/Level Set, etc., required)
Dimensional Analysis and Unit Systems
VariableSI UnitNotes / Conversion Memo
Velocity $u$m/sWhen converting from volumetric flow rate for inlet conditions, pay attention to cross-sectional area units.
Pressure $p$PaDistinguish between gauge and absolute pressure. Use absolute pressure for compressible analysis.
Density $\rho$kg/m³Air: approx. 1.225 kg/m³ @20°C, Water: approx. 998 kg/m³ @20°C
Viscosity Coefficient $\mu$Pa·sBe careful not to confuse with kinematic viscosity $\nu = \mu/\rho$ [m²/s]
Reynolds Number $Re$Dimensionless$Re = \rho u L / \mu$. Criterion for laminar/turbulent transition.
CFL NumberDimensionless$CFL = u \Delta t / \Delta x$. Directly related to time step stability.

Numerical Methods and Implementation

Numerical Implementation of Wall Functions

🧑‍🎓

How are wall functions specifically implemented inside the solver?


🎓

Wall functions are implemented as wall boundary conditions. They calculate wall shear stress, heat flux, and turbulence quantities from the values at the center (centroid) of the cell adjacent to the wall. In FVM (Finite Volume Method) based CFD solvers, wall functions are interposed in the calculation of wall fluxes.


Momentum Wall Function

🧑‍🎓

How is the wall function for the velocity field calculated?


🎓

The relationship between the velocity at the wall-adjacent cell center $U_P$ and the wall shear stress $\tau_w$ is back-calculated from the log-law.


$$ \frac{U_P}{u_\tau} = \frac{1}{\kappa}\ln(E\, y_P^+) $$

Solving this for $\tau_w$ gives,


$$ \tau_w = \frac{\rho\, \kappa\, U_P\, u_\tau}{\ln(E\, y_P^+)} $$

🎓

However, since $u_\tau = \sqrt{\tau_w/\rho}$, $\tau_w$ is implicitly included. In implementation, iterative methods like Newton's method or simple substitution are used, or a method defining an equivalent eddy viscosity is employed.


$$ \mu_{t,\text{wall}} = \frac{\rho\, \kappa\, u_\tau\, y_P}{\ln(E\, y_P^+)} - \mu $$

k and epsilon Wall Boundary Conditions

🧑‍🎓

What boundary conditions are applied to the turbulence quantities $k$ and $\varepsilon$?


🎓

$k$ and $\varepsilon$ at the wall-adjacent cell are set as follows.


$$ k_P = \frac{u_\tau^2}{\sqrt{C_\mu}}, \quad \varepsilon_P = \frac{u_\tau^3}{\kappa\, y_P} $$

Here, $C_\mu = 0.09$. $\varepsilon$ is often directly assigned (fixed value) as the cell center value. For $k$, some solvers solve the transport equation up to the wall-adjacent cell, while others fix it using the above formula.


🧑‍🎓

So the handling differs by solver.


🎓

Exactly. In Ansys Fluent, $k$ is solved via the transport equation while modifying the production term at the wall with a wall function, and $\varepsilon$ is forced to the value from the above formula at the wall-adjacent cell. OpenFOAM's epsilonWallFunction has a similar implementation.


Temperature Wall Function

🧑‍🎓

Is there also a thermal wall function?


🎓

Of course. There is also a wall function for the temperature field, similar to the log-law. The form using Jayatilleke's (1969) P-function is standard.


$$ T^+ = \text{Pr}_t \left[ \frac{1}{\kappa}\ln(E\, y^+) + P(\text{Pr})\right] $$

$$ P(\text{Pr}) = 9.24 \left[ \left(\frac{\text{Pr}}{\text{Pr}_t}\right)^{3/4} - 1\right]\left[1 + 0.28\, e^{-0.007\text{Pr}/\text{Pr}_t}\right] $$

🎓

Here, $\text{Pr}_t \approx 0.85$ (turbulent Prandtl number) and $\text{Pr}$ is the molecular Prandtl number. For air ($\text{Pr} \approx 0.71$), the P-function correction is small, but for high Prandtl number fluids like oil ($\text{Pr} > 100$), it has a significant effect.


y+ Pre-estimation

🧑‍🎓

Is there a way to estimate $y^+$ before creating the mesh?


🎓

Using empirical formulas for flat-plate boundary layers is the standard approach for estimation.


$$ C_f \approx 0.058\, Re_L^{-0.2} $$
$$ \tau_w = \frac{1}{2} C_f \rho U_\infty^2 $$
$$ u_\tau = \sqrt{\tau_w / \rho} $$
$$ y = \frac{y^+ \nu}{u_\tau} $$

🧑‍🎓

So from the target $y^+$ and representative Reynolds number, you can back-calculate the first layer thickness $y$. This allows you to set up the inflation layer.

Coffee Break Trivia

The True Value of y+ Calculation Tools – The Culture of "Pre-estimation"

Nowadays, if you search for "y+ calculator," countless online tools appear, but these only became widespread after the 2010s. Before that, CFD engineers used boundary layer analytical solutions (like the Blasius equation) in hand calculations or spreadsheets to estimate the first layer thickness. The culture was not "create a mesh, run a calculation, and then check y+," but rather "calculate y+ and then design the mesh."

関連シミュレーター

この分野のインタラクティブシミュレーターで理論を体感しよう

シミュレーター一覧

関連する分野

熱解析V&V・品質保証構造解析
この記事の評価
ご回答ありがとうございます!
参考に
なった
もっと
詳しく
誤りを
報告
参考になった
0
もっと詳しく
0
誤りを報告
0
Written by NovaSolver Contributors
Anonymous Engineers & AI — サイトマップ
About the Authors