turbo_moc.deprecated.meshing.wall_spacing module#
First-cell height for a target y+ from the Phase-1 MoC expansion.
A rough, pre-CFD estimate: local turbulent flat-plate skin friction at the blade chord, with the flow state taken from the nozzle’s own isentropic solution (wall_final: rho, T, M per station). Properties come from jaxprop at (rho, T), so a two-phase (wet) expansion uses the mixture viscosity and the equilibrium speed of sound. Accurate to roughly a factor of two – the usual precision of a y+ estimate; check the actual y+ in the CFD.
Re_c = rho U c / mu, U = M a C_f = 0.026 Re_c^(-1/7) (turbulent flat plate, local; White) tau_w = C_f rho U^2 / 2, u_tau = sqrt(tau_w / rho) y = y+ nu / u_tau, nu = mu / rho
The station with the highest wall shear (smallest y) governs, so the target is met everywhere along the expansion.
Fluids without a CoolProp viscosity model (e.g. Novec649, MDM) fall back to the Chung et al. (1988) dilute-gas correlation from the critical constants (within ~1% of CoolProp for non-polar vapours, ~10% for polar ones such as R245fa; dipole and dense-gas corrections are omitted). In a two-phase state that is the vapour-phase value at the local temperature.
- turbo_moc.deprecated.meshing.wall_spacing.blade_chord_mm(blade)[source]#
True chord [mm]: leading edge (axial maximum of the closed contour) to trailing edge (axial minimum), flow toward -y.
- turbo_moc.deprecated.meshing.wall_spacing.chung_dilute_gas_viscosity(fluid_name, temperature)[source]#
Chung et al. (1988) dilute-gas viscosity [Pa s], non-polar form.
- turbo_moc.deprecated.meshing.wall_spacing.estimate_first_layer_height(nozzle_result, chord_mm, y_plus, cell_centroid=True)[source]#
First wall-normal cell height [mm] giving y_plus at the most sheared station of the MoC expansion.
cell_centroid=True: y+ is measured at the first cell’s centroid (the convention Fluent reports), so the cell height is twice that distance. Returns a dict with first_height_mm and the governing station’s diagnostics (Re, C_f, wall shear, friction velocity, U, rho, mu, M, vapour quality).
- turbo_moc.deprecated.meshing.wall_spacing.inflation_stack(first_height, growth_ratio, num_layers)[source]#
Total thickness [mm] of num_layers geometric layers and the last layer’s height: h1 (r^N - 1) / (r - 1) and h1 r^(N-1).
- turbo_moc.deprecated.meshing.wall_spacing.rotor_wall_states(rotor_data)[source]#
The rotor’s relative-frame wall states, in estimate_first_layer_height’s nozzle_result layout: an isentropic expansion from (P0_rel, T0_rel) to each design Mach number (M_inlet, M_lower, M_upper, M_outlet – the uniform inlet/outlet flow and the constant-Mach pressure/suction arcs).
Static state at Mach M: the pressure on the stagnation isentrope where h0 - h(p, s0) = (M a(p, s0))^2 / 2 (CoolProp HEOS, single phase).