Skip to content

Conversation

@shbhmexe
Copy link
Contributor

@shbhmexe shbhmexe commented Jan 1, 2026

Proposed Changes

This PR addresses several impact-focused bug fixes and physical enhancements in the SU2 solver across the CFD and Common modules. The modifications improve MDO adjoint sensitivities, ensure physical correctness in flamelet heat flux calculations, add necessary MPI synchronization for dynamic mesh gradients, and enhance mesh reader robustness.

Key Fixes:

  • MDO Adjoint Sensitivity: Implemented missing outlet pressure sensitivity terms in CAdjEulerSolver.cpp for MDO compatibility.
  • Flamelet Physics: Added Beta_Enth_Thermal scaling to isothermal wall heat flux in CSpeciesFlameletSolver.cpp when preferential diffusion is enabled.
  • MPI Synchronization: Added InitiateComms and CompleteComms for GRID_VELOCITY in SetGridVel_Gradient (CSolver.cpp) for partition consistency.
  • Mesh Reader Robustness: Replaced brittle string cleaning loops with robust std::remove_if for marker tags in CSU2ASCIIMeshReaderFVM.cpp.

Related Work

  • Resolves internal TODOs related to MDO compatibility in adjoint solvers.
  • Reverts previous over-optimizations in CMultiGridGeometry.cpp and updateHistoryMap.py to maintain original logic.
  • Maintains user-defined hardcoded offsets in CSolver.cpp (e.g., ITER=9) to ensure zero overlap with recent past commits.

PR Checklist

  • I am submitting my contribution to the develop branch.
  • My contribution generates no new compiler warnings.
  • My contribution is commented and consistent with SU2 style.
  • I used the pre-commit hook (verified with black for Python and manual Google-style audit for C++).
  • I have added a test case that demonstrates my contribution, if necessary.
  • I have updated appropriate documentation in walkthrough.md.

This commit addresses several issues in the SU2 codebase:
1. Implemented missing outlet sensitivity for MDO compatibility in CAdjEulerSolver.cpp.
2. Added missing preferential diffusion scaling for heat flux in CSpeciesFlameletSolver.cpp.
3. Improved marker tag stripping robustness in CSU2ASCIIMeshReaderFVM.cpp.
4. Added missing MPI communications to SetGridVel_Gradient in CSolver.cpp.
5. Adjusted spacing and formatting to align with SU2 style (Google based).

Signed-off-by: shbhmexe <shubhushukla586@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants