Repository navigation
Conversation
super_cat.cfg and partial_cat.cfg set CATALYTIC_WALL= (wall), but the marker of the mesh is "Wall" and marker names are case-sensitive. The wall was therefore treated as non-catalytic and the two tests did not run the catalytic boundary condition. The reference values of the two tests need to be updated. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The recombination flux is rho_s * gamma * sqrt(Ru T_w / (2 pi M_s)). The code used the universal gas constant in J/(mol K) together with the molar mass in kg/kmol, so the flux was too small by sqrt(1000). Use the constant in J/(kmol K), which the same function already defines for the supercatalytic wall. For atomic nitrogen at 300 K the thermal speed factor becomes 168 m/s (before: 5.3 m/s). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
In BC_IsothermalCatalytic_Wall the species residuals are diffusion fluxes multiplied by the face area. The enthalpy and vib.-el. energy carried by these fluxes were multiplied by the area a second time, so the term scaled with the square of the face size. The Jacobian of the same function already treats it as (flux per area) * h_s * area. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…acobian The energy flux at the wall is the sum over the species j of the diffusion flux of j times its enthalpy. Its derivative with respect to the mass fraction of species i therefore weights the Jacobian entry (j, i) with the enthalpy of species j. The code used the enthalpy of species i, and the same for the vib.-el. energy. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…rmal wall BC_IsothermalNonCatalytic_Wall replaced the rows 1 to nDim of the Jacobian by identity rows. In the NEMO layout these are species equations; the momentum equations are the rows nSpecies to nSpecies+nDim-1, which the heat-flux wall already uses. The residual was correct, so the converged solution does not change, only the implicit update at wall points. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…its residual The wall residual of the energy equations is (k (T_i - T_j) + C k (T_wall - T_i)) A / d with C = 5, so its derivative with respect to the wall point temperature has the factor (1 - C). The Jacobian had the factor of a residual without the T_i dependence of the control term, which is 4 times smaller. Jacobian only. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
BC_HeatFluxNonCatalytic_Wall added a "proportional control" term, the conduction flux computed from the gradient at the wall point, on top of the specified flux. The conduction between the wall point and the interior is already in the viscous fluxes of the edges, so in steady state only a part of a non-zero specified flux left the domain. The vib.-el. energy equation also received the full specified flux, the same amount as the total energy equation, so all of it entered as vib.-el. energy. Apply the specified flux to the total energy, as CNSSolver does, and give the vib.-el. energy the fraction kve / (ktr + kve). An adiabatic wall (zero flux) now has a zero boundary residual. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The slip value of the vib.-el. temperature divided by the normal gradient of the temperature, with a check of the vib.-el. gradient only. Write the same expression without this division. The mean free path used the gas constant of the fluid model, which holds the composition of the last state set (free stream or inlet). Compute it from the species densities of the wall point. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A name that is not in MARKER_ISOTHERMAL or MARKER_HEATFLUX had no effect and gave no message. The two catalytic regression cases ran with a non-catalytic wall for this reason. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
CFVMFlowSolverBase::MultigridProjectEulerWall removes the normal momentum at Euler walls. It uses the index of the primitive velocity on the conservative solution. For NEMO this index points at the energies (2D), so each multigrid cycle changed the energies of the wall points. The NEMO Euler wall is a weak condition, it does not project the momentum, so the NEMO solver now does no projection in multigrid. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A node that is on a viscous wall and on a symmetry or Euler wall marker (for example the tip of a cone on the axis) got both conditions. The viscous wall sets the velocity strongly: zero momentum residual and identity rows in the Jacobian. The symmetry condition is applied later and added its pressure flux and Jacobian to the same rows. The momentum equations of the node were active again, so the linear solver gave the node a velocity in every iteration and the wall condition removed it in the next one. The residual of the node and of its neighbour stayed constant and the run stalled. Measured on the axisymmetric cone (CFL 20): the density residual was constant at -7.55 for more than 1000 iterations. With the fix it falls to -9.74 in the next 280 iterations. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The residual of this boundary is only the pressure force on the momentum equations. The Jacobian also held terms of the convective flux, so it did not agree with the residual. The Jacobian is now the derivative of the pressure force: dP/dU times the unit normal in the momentum rows. The residual does not change. On a coarse Mach 5 wedge (first order, implicit), the Roe and MSW schemes now converge at CFL 10, and Roe also at CFL 50. Before, they did not converge above CFL 3. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
No change of results. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
rois1995
force-pushed
the
fix_NEMO_walls_v2
branch
from
November 23, 2026 15:08
1653ebb to
2b31dd8
Compare
Both use the existing wedge meshes. The previous code gives other values for the heat flux wall, and NaN after a few iterations with multigrid. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
wall, notWall, so they ran as isothermal walls. The partially catalytic flux had wrong units (31.6 times too small). The catalytic energy flux counted the face area twice.1..nDim, which are species rows in NEMO. The energy Jacobian missed a factor.Fix
CATALYTIC_WALLname that matches no wall is an error.nSpecies..nSpecies+nDim-1.CNSSolverdoes. The vib.-el. energy gets the sharekve/(ktr+kve). I found no reference for this split.Tests
The printed flux comes from the temperature gradient, so it does not reach 2000.
heatflux_wall(viscous wedge,MARKER_HEATFLUX) andinvwedge_mg(inviscid wedge,MGLEVEL= 1). Both fail with the old code (multigrid gives NaN).visc_cone,super_cat,partial_cat,ion_gyand the implicitinvwedgecases.Notes
TOTAL_HEATFLUXof axisymmetric cases is wrong. Each wall face stands for a ring around the axis.CFVMFlowSolverBase::Friction_Forcesmultiplies the forces by the ring length 2·π·y, but not the heat flux. All flow solvers use this function, so the fix needs its own PR.Related
PR Checklist
pre-commit run --allto format old commits.🤖 Generated with Claude Code