Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
74 commits
Select commit Hold shift + click to select a range
a7136d3
- Just copied the CTransLMSolver header and source to commit
Jan 27, 2023
e9226db
- Start of implementation of Simplified LM transition model
Jan 27, 2023
d03742a
- Modify number of variables if SLM option is used
Jan 27, 2023
e17872d
- Updates on the transition model.
Jan 31, 2023
4b9c615
- Added Cross flow effects for SLM
Jan 31, 2023
04cd56d
- Fixed Intermittency_Sep computation for SLM.
Feb 2, 2023
e29b4df
- Added computation for normals of grid points
Feb 24, 2023
0319d62
Fixed normal extraction from structure
Feb 24, 2023
b1edf61
Added computation of wall normals to the CPoint structure
Feb 24, 2023
7eee4ab
Check For changes
Apr 27, 2023
c461518
Removing changes for SA-R
Apr 27, 2023
e68a9e4
Fixed vertex indexing for wall normal computation
Apr 27, 2023
bcdd671
Removed a cout
Apr 27, 2023
9bb2435
Fixed division by zero with Corr_Rec
Apr 27, 2023
a9a6ce4
Removed cout
Apr 27, 2023
86b068c
Fixed Max Velocity-Z output for Incompressible flow
Apr 27, 2023
73c0a4b
Fixed output of Normals in volume
Apr 27, 2023
8d5148e
- Added Simplified Langtry Menter model
Jul 1, 2024
9db7301
- corrected bu in output
Jul 1, 2024
1e7e7a3
Merge branch 'develop' into feature_Trans_SLM_v8
Sep 12, 2024
ab2d71b
Merge remote-tracking branch 'origin/feature_Trans_SLM_v8' into featu…
Sep 13, 2024
a6fe9bc
- finish update
Sep 13, 2024
284e841
Merge remote-tracking branch 'origin/develop' into feature_Trans_SLM
Mar 3, 2025
266cbd7
Correct muT computation in SST
Mar 3, 2025
881b574
- Remove debug options
Mar 3, 2025
5aa683f
- Reformat some lines
Mar 3, 2025
4276ff8
Merge remote-tracking branch 'origin/develop' into feature_Trans_SLM
Mar 4, 2025
a5a73aa
Fix compilation bug
Mar 6, 2025
abc9d49
Remove StrainMag from outputs
Mar 6, 2025
1b1bc8a
- Fix compilation bugs on Github Part 1
Mar 6, 2025
30b4c14
Update codiPack version to 2.0
Mar 6, 2025
7d1c612
Revert "Update codiPack version to 2.0"
Mar 6, 2025
a4f9268
Trying fixing the CodiPack bug
Mar 6, 2025
82c7b1f
CoDiPack sha
Mar 7, 2025
c8f3fe7
- align externals and submodules to develop
Mar 7, 2025
4904165
- align codi with develop
Mar 7, 2025
831d95d
- fix compilation reverse AD bug
Mar 7, 2025
4134667
- Fix DG problems when normal computation
Mar 7, 2025
90efb40
Merge remote-tracking branch 'origin/develop' into feature_Trans_SLM
Mar 10, 2025
4076c81
Merge remote-tracking branch 'origin/develop' into feature_Trans_SLM
Mar 10, 2025
583bdf3
Merge remote-tracking branch 'origin/develop' into feature_Trans_SLM
Mar 11, 2025
f717ed5
- Modify screen output in SU2 header
Mar 12, 2025
0f3f412
- Fix bugs in crossflow correction
Mar 13, 2025
1ef2081
- Revert to use of dimensional vorticity
Mar 13, 2025
bb3b066
- Fix bug from paper in crossflow
Mar 14, 2025
d2791b0
- fixed formatting errors
Mar 19, 2025
41291a4
Merge remote-tracking branch 'origin/develop' into feature_Trans_SLM
Mar 25, 2025
24785c2
Merge remote-tracking branch 'origin/develop' into feature_Trans_SLM
Apr 8, 2025
5fb0cb9
Merge remote-tracking branch 'origin/develop' into feature_Trans_SLM
Apr 8, 2025
b1147bd
Merge remote-tracking branch 'origin/develop' into feature_Trans_SLM
Apr 23, 2025
0f06f3b
- Improved notation for freestream conditions on ReThetaT
Apr 23, 2025
25fb369
Merge remote-tracking branch 'origin/develop' into feature_Trans_SLM
Jul 7, 2025
651af7c
- Added comments
Oct 2, 2025
e8e2284
Merge remote-tracking branch 'origin/develop' into feature_Trans_SLM
Oct 2, 2025
48a36be
Merge branch 'develop' into feature_Trans_SLM
Sep 23, 2026
2c0255e
Use the codi and medi submodules of develop
Sep 23, 2026
4d4b0af
Remove debug and whitespace changes unrelated to the simplified LM model
Sep 23, 2026
1693fd3
Fix uninitialized AuxVar and missing AD inputs in the simplified LM s…
Sep 23, 2026
e502fed
Read only nDim components of the vertex normals for the wall normals
Sep 23, 2026
6228cc6
Warn when the Menter one-equation model is used without Kato-Launder …
Sep 23, 2026
aaee5bf
Make the LM and simplified LM restarts consistent
Sep 23, 2026
72388fc
Limit the turbulence intensity in both terms of the freestream Re_the…
Sep 23, 2026
c955ea0
Reject simplified LM combinations that are not in the literature
Sep 23, 2026
75d666c
Couple the simplified LM model with SA as in Lee and Baeder (AIAA 202…
Sep 23, 2026
fc979ed
Register the intermittencies as preaccumulation inputs of the SA source
Sep 23, 2026
55fe05d
Limit the roughness height in the Langtry cross-flow correlation
Sep 23, 2026
3958556
Cite the equations of Vallinayagam Pillai and Lardeau (2017) in the S…
Sep 23, 2026
53c15bb
Limit the cross-flow roughness height to 1e-8 and print it at startup
Sep 23, 2026
aefa3c9
Fix the AD build of the cross-flow vorticity direction
Sep 23, 2026
56a6d92
Stop with an error for discrete adjoints with a transition model
Sep 23, 2026
b2a24aa
Add regression tests for the simplified LM model on the prolate spheroid
Sep 23, 2026
c5b1ea6
Run the regression tests with the feature_Trans_SLM branch of TestCases
Sep 24, 2026
5478002
Accept LM2015 as the old name of CROSSFLOW, remove PRODLIM, output F_…
Sep 28, 2026
7a88694
Fix the LM inlet values, the SA intensity limit, the AD inputs and TU…
Sep 28, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .github/workflows/regression.yml
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ jobs:
uses: docker://ghcr.io/su2code/su2/test-su2:260405-0054
with:
# -t <Tutorials-branch> -c <Testcases-branch>
args: -b ${{github.ref}} -t develop -c develop -s ${{matrix.testscript}}
args: -b ${{github.ref}} -t develop -c feature_Trans_SLM -s ${{matrix.testscript}}
- name: Cleanup
uses: docker://ghcr.io/su2code/su2/test-su2:260405-0054
with:
Expand Down Expand Up @@ -282,7 +282,7 @@ jobs:
uses: docker://ghcr.io/su2code/su2/test-su2:260405-0054
with:
# -t <Tutorials-branch> -c <Testcases-branch>
args: -b ${{github.ref}} -t develop -c develop -s ${{matrix.testscript}} -a "--tapetests"
args: -b ${{github.ref}} -t develop -c feature_Trans_SLM -s ${{matrix.testscript}} -a "--tapetests"
- name: Cleanup
uses: docker://ghcr.io/su2code/su2/test-su2:260405-0054
with:
Expand Down Expand Up @@ -330,7 +330,7 @@ jobs:
PMIX_MCA_gds: hash
with:
# -t <Tutorials-branch> -c <Testcases-branch>
args: -b ${{github.ref}} -t develop -c develop -s ${{matrix.testscript}} -a "--tsan"
args: -b ${{github.ref}} -t develop -c feature_Trans_SLM -s ${{matrix.testscript}} -a "--tsan"
- name: Cleanup
uses: docker://ghcr.io/su2code/su2/test-su2-tsan:260405-0054
with:
Expand Down Expand Up @@ -375,7 +375,7 @@ jobs:
uses: docker://ghcr.io/su2code/su2/test-su2-asan:260405-0054
with:
# -t <Tutorials-branch> -c <Testcases-branch>
args: -b ${{github.ref}} -t develop -c develop -s ${{matrix.testscript}} -a "--asan"
args: -b ${{github.ref}} -t develop -c feature_Trans_SLM -s ${{matrix.testscript}} -a "--asan"
- name: Cleanup
uses: docker://ghcr.io/su2code/su2/test-su2-asan:260405-0054
with:
Expand Down
54 changes: 54 additions & 0 deletions Common/include/geometry/dual_grid/CPoint.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,7 @@ class CPoint {
su2activevector Curvature; /*!< \brief Value of the surface curvature (SU2_GEO). */
su2activevector MaxLength; /*!< \brief The maximum cell-center to cell-center length. */
su2activevector RoughnessHeight; /*!< \brief Roughness of the nearest wall. */
su2activematrix Normals; /*!< \brief Normal of the nearest wall element. */

su2matrix<AD::Identifier>
AD_InputIndex; /*!< \brief Indices of Coord variables in the adjoint vector before solver iteration. */
Expand Down Expand Up @@ -484,6 +485,27 @@ class CPoint {
}
inline void SetWall_Distance(unsigned long iPoint, su2double distance) { Wall_Distance(iPoint) = distance; }

/*!
* \brief Get the index of the closest wall element.
* \param[in] iPoint - Index of the point.
* \param[out] ClosestWall_Elem - ID of the closest element on a wall boundary.
*/
inline unsigned long GetClosestWall_Elem(unsigned long iPoint) { return ClosestWall_Elem(iPoint); }

/*!
* \brief Get the marker of the closest wall marker.
* \param[in] iPoint - Index of the point.
* \param[out] ClosestWall_Marker - MarkerID of the closest wall boundary.
*/
inline unsigned long GetClosestWall_Marker(unsigned long iPoint) { return ClosestWall_Marker(iPoint); }

/*!
* \brief Get the rank of the closest wall marker.
* \param[in] iPoint - Index of the point.
* \param[out] ClosestWall_Rank - RankID of the closest wall boundary.
*/
inline unsigned long GetClosestWall_Rank(unsigned long iPoint) { return ClosestWall_Rank(iPoint); }

/*!
* \brief Get the value of the distance to the nearest wall.
* \param[in] iPoint - Index of the point.
Expand All @@ -506,6 +528,23 @@ class CPoint {
*/
inline su2double GetRoughnessHeight(unsigned long iPoint) const { return RoughnessHeight(iPoint); }

/*!
* \brief Set the value of the normal of the nearest wall element.
* \param[in] iPoint - Index of the point.
* \param[in] normal - Value of the normal.
*/
template <typename Normals_type>
inline void SetNormal(unsigned long iPoint, Normals_type const& normal) {
for (unsigned long iDim = 0; iDim < nDim; iDim++) Normals(iPoint, iDim) = normal[iDim];
}

/*!
* \brief Set the value of the normal of the nearest wall element.
* \param[in] iPoint - Index of the point.
* \return normal to the normal of the nearest wall element.
*/
inline su2double* GetNormal(unsigned long iPoint) { return Normals[iPoint]; }

/*!
* \brief Set the value of the distance to a sharp edge.
* \param[in] iPoint - Index of the point.
Expand Down Expand Up @@ -885,4 +924,19 @@ class CPoint {
}
}
}

/*!
* \brief Set wall normal according to stored closest wall information.
* \param[in] normals - Mapping [rank][zone][marker][element] -> normal
*/
template <typename Normals_type>
void SetWallNormals(Normals_type const& normals) {
for (unsigned long iPoint = 0; iPoint < GlobalIndex.size(); ++iPoint) {
auto rankID = ClosestWall_Rank[iPoint];
auto zoneID = ClosestWall_Zone[iPoint];
auto markerID = ClosestWall_Marker[iPoint];
auto elementID = ClosestWall_Elem[iPoint];
if (rankID >= 0) SetNormal(iPoint, normals[rankID][zoneID][markerID][elementID]);
}
}
};
80 changes: 67 additions & 13 deletions Common/include/option_structure.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -1374,27 +1374,36 @@ static const MapType<std::string, TURB_TRANS_MODEL> Trans_Model_Map = {
* \brief LM Options
*/
enum class LM_OPTIONS {
NONE, /*!< \brief No option / default. */
LM2015, /*!< \brief Cross-flow corrections. */
MALAN, /*!< \brief Kind of transition correlation model (Malan). */
SULUKSNA, /*!< \brief Kind of transition correlation model (Suluksna). */
KRAUSE, /*!< \brief Kind of transition correlation model (Krause). */
KRAUSE_HYPER, /*!< \brief Kind of transition correlation model (Krause hypersonic). */
MEDIDA_BAEDER,/*!< \brief Kind of transition correlation model (Medida-Baeder). */
MEDIDA, /*!< \brief Kind of transition correlation model (Medida). */
MENTER_LANGTRY, /*!< \brief Kind of transition correlation model (Menter-Langtry). */
DEFAULT /*!< \brief Kind of transition correlation model (Menter-Langtry if SST, MALAN if SA). */
NONE, /*!< \brief No option / default. */
CROSSFLOW, /*!< \brief Cross-flow corrections. */
SLM, /*!< \brief Simplified version. */
MALAN, /*!< \brief Kind of transition correlation model (Malan). */
SULUKSNA, /*!< \brief Kind of transition correlation model (Suluksna). */
KRAUSE, /*!< \brief Kind of transition correlation model (Krause). */
KRAUSE_HYPER, /*!< \brief Kind of transition correlation model (Krause hypersonic). */
MEDIDA_BAEDER, /*!< \brief Kind of transition correlation model (Medida-Baeder). */
MEDIDA, /*!< \brief Kind of transition correlation model (Medida). */
MENTER_LANGTRY, /*!< \brief Kind of transition correlation model (Menter-Langtry). */
MENTER_SLM, /*!< \brief Kind of transition correlation model (Menter Simplified LM model). */
CODER_SLM, /*!< \brief Kind of transition correlation model (Coder Simplified LM model). */
MOD_EPPLER_SLM, /*!< \brief Kind of transition correlation model (Modified Eppler Simplified LM model). */
DEFAULT /*!< \brief Kind of transition correlation model (Menter-Langtry if SST, MALAN if SA). */
};

static const MapType<std::string, LM_OPTIONS> LM_Options_Map = {
MakePair("NONE", LM_OPTIONS::NONE)
MakePair("LM2015", LM_OPTIONS::LM2015)
MakePair("CROSSFLOW", LM_OPTIONS::CROSSFLOW)
MakePair("LM2015", LM_OPTIONS::CROSSFLOW) // name of the option before the one-equation model was added
MakePair("SLM", LM_OPTIONS::SLM)
MakePair("MALAN", LM_OPTIONS::MALAN)
MakePair("SULUKSNA", LM_OPTIONS::SULUKSNA)
MakePair("KRAUSE", LM_OPTIONS::KRAUSE)
MakePair("KRAUSE_HYPER", LM_OPTIONS::KRAUSE_HYPER)
MakePair("MEDIDA_BAEDER", LM_OPTIONS::MEDIDA_BAEDER)
MakePair("MENTER_LANGTRY", LM_OPTIONS::MENTER_LANGTRY)
MakePair("MENTER_SLM", LM_OPTIONS::MENTER_SLM)
MakePair("CODER_SLM", LM_OPTIONS::CODER_SLM)
MakePair("MOD_EPPLER_SLM", LM_OPTIONS::MOD_EPPLER_SLM)
MakePair("DEFAULT", LM_OPTIONS::DEFAULT)
};

Expand All @@ -1412,13 +1421,34 @@ enum class TURB_TRANS_CORRELATION {
DEFAULT /*!< \brief Kind of transition correlation model (Menter-Langtry if SST, MALAN if SA). */
};

/*!
* \brief Types of transition correlations for Simplified LM model
*/
enum class TURB_TRANS_CORRELATION_SLM {
MENTER_SLM, /*!< \brief Kind of transition correlation model (Menter Simplified LM model). */
CODER_SLM, /*!< \brief Kind of transition correlation model (Coder Simplified LM model). */
MOD_EPPLER_SLM, /*!< \brief Kind of transition correlation model (Modified Eppler Simplified LM model). */
DEFAULT /*!< \brief Kind of transition correlation model. */
};

/*!
* \brief Lower limit of the roughness height (HROUGHNESS, same units) in the cross-flow corrections of the LM models,
* where it enters a logarithm (Langtry et al., log(h/theta_t)) or a ratio (Vallinayagam Pillai and Lardeau,
* h/h0). The papers give no calibration limit for small heights, so a small value keeps these terms finite
* for smooth surfaces (h = 0). h and theta_t are both in mesh length units (the reference length of the
* non-dimensionalization is 1), so log(h/theta_t) is consistent for any REF_DIMENSIONALIZATION.
*/
constexpr double LM_CROSSFLOW_MIN_ROUGHNESS = 1e-8;

/*!
* \brief Structure containing parsed LM options.
*/
struct LM_ParsedOptions {
LM_OPTIONS version = LM_OPTIONS::NONE; /*!< \brief LM base model. */
bool LM2015 = false; /*!< \brief Use cross-flow corrections. */
bool SLM = false; /*!< \brief Use simplified version. */
bool CrossFlow = false; /*!< \brief Use cross-flow corrections. */
TURB_TRANS_CORRELATION Correlation = TURB_TRANS_CORRELATION::DEFAULT;
TURB_TRANS_CORRELATION_SLM Correlation_SLM = TURB_TRANS_CORRELATION_SLM::DEFAULT;
};

/*!
Expand All @@ -1436,7 +1466,9 @@ inline LM_ParsedOptions ParseLMOptions(const LM_OPTIONS *LM_Options, unsigned sh
return std::find(LM_Options, lm_options_end, option) != lm_options_end;
};

LMParsedOptions.LM2015 = IsPresent(LM_OPTIONS::LM2015);
LMParsedOptions.SLM = IsPresent(LM_OPTIONS::SLM);

LMParsedOptions.CrossFlow = IsPresent(LM_OPTIONS::CROSSFLOW);

int NFoundCorrelations = 0;
if (IsPresent(LM_OPTIONS::MALAN)) {
Expand Down Expand Up @@ -1468,10 +1500,28 @@ inline LM_ParsedOptions ParseLMOptions(const LM_OPTIONS *LM_Options, unsigned sh
NFoundCorrelations++;
}

int NFoundCorrelations_SLM = 0;
if (IsPresent(LM_OPTIONS::MENTER_SLM)) {
LMParsedOptions.Correlation_SLM = TURB_TRANS_CORRELATION_SLM::MENTER_SLM;
NFoundCorrelations_SLM++;
}
if (IsPresent(LM_OPTIONS::CODER_SLM)) {
LMParsedOptions.Correlation_SLM = TURB_TRANS_CORRELATION_SLM::CODER_SLM;
NFoundCorrelations_SLM++;
}
if (IsPresent(LM_OPTIONS::MOD_EPPLER_SLM)) {
LMParsedOptions.Correlation_SLM = TURB_TRANS_CORRELATION_SLM::MOD_EPPLER_SLM;
NFoundCorrelations_SLM++;
}

if (NFoundCorrelations > 1) {
SU2_MPI::Error("Two correlations selected for LM_OPTIONS. Please choose only one.", CURRENT_FUNCTION);
}

if (NFoundCorrelations_SLM > 1) {
SU2_MPI::Error("Two SLM correlations selected for LM_OPTIONS. Please choose only one.", CURRENT_FUNCTION);
}

if (LMParsedOptions.Correlation == TURB_TRANS_CORRELATION::DEFAULT){
if (Kind_Turb_Model == TURB_MODEL::SST) {
LMParsedOptions.Correlation = TURB_TRANS_CORRELATION::MENTER_LANGTRY;
Expand All @@ -1480,6 +1530,10 @@ inline LM_ParsedOptions ParseLMOptions(const LM_OPTIONS *LM_Options, unsigned sh
}
}

if (LMParsedOptions.Correlation_SLM == TURB_TRANS_CORRELATION_SLM::DEFAULT){
LMParsedOptions.Correlation_SLM = TURB_TRANS_CORRELATION_SLM::MENTER_SLM;
}

return LMParsedOptions;
}

Expand Down
Loading
Loading