Skip to content

Commit d03e11f

Browse files
committed
Merge branch 'feature_mz_turbomachinery_adjoint' of https://github.com/su2code/SU2 into feature_mz_turbomachinery_adjoint
2 parents 674545a + 1d7a125 commit d03e11f

File tree

64 files changed

+748
-607
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

64 files changed

+748
-607
lines changed

.github/workflows/code-style.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
- name: Checkout
1515
uses: actions/checkout@v5
1616
- name: Setup python
17-
uses: actions/setup-python@v5
17+
uses: actions/setup-python@v6
1818
with:
1919
python-version: '3.10'
2020
check-latest: true

.github/workflows/codeql.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,20 +37,20 @@ jobs:
3737
run: ./meson.py setup build --optimization=1
3838

3939
- name: Initialize CodeQL
40-
uses: github/codeql-action/init@v3
40+
uses: github/codeql-action/init@v4
4141
with:
4242
languages: ${{ matrix.language }}
4343
queries: +security-and-quality
4444

4545
- name: Autobuild
46-
uses: github/codeql-action/autobuild@v3
46+
uses: github/codeql-action/autobuild@v4
4747
if: ${{ matrix.language == 'python' }}
4848

4949
- name: Build cpp
5050
if: ${{ matrix.language == 'cpp' }}
5151
run: ./ninja -C build
5252

5353
- name: Perform CodeQL Analysis
54-
uses: github/codeql-action/analyze@v3
54+
uses: github/codeql-action/analyze@v4
5555
with:
5656
category: "/language:${{ matrix.language }}"

.github/workflows/regression-arm64.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ jobs:
1010
name: Run the jobs on Linux ARM64
1111
uses: './.github/workflows/regression.yml'
1212
with:
13-
runner: 'ARM64'
13+
runner: 'ubuntu-24.04-arm'

.github/workflows/regression.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ jobs:
6565
- name: Compress binaries
6666
run: tar -zcvf install_bin.tgz install/*
6767
- name: Upload Binaries
68-
uses: actions/upload-artifact@v4
68+
uses: actions/upload-artifact@v5
6969
with:
7070
name: ${{ matrix.config_set }}
7171
path: install_bin.tgz
@@ -76,7 +76,7 @@ jobs:
7676
args: -rf install install_bin.tgz src ccache ${{ matrix.config_set }}
7777
build_tsan:
7878
name: Build SU2 (tsan)
79-
if: inputs.runner != 'ARM64'
79+
if: ${{ !contains(inputs.runner, 'arm') }}
8080
strategy:
8181
fail-fast: false
8282
matrix:
@@ -108,7 +108,7 @@ jobs:
108108
- name: Compress binaries
109109
run: tar -zcvf install_bin.tgz install/*
110110
- name: Upload Binaries
111-
uses: actions/upload-artifact@v4
111+
uses: actions/upload-artifact@v5
112112
with:
113113
name: ${{ matrix.config_set }}
114114
path: install_bin.tgz
@@ -146,7 +146,7 @@ jobs:
146146
- name: Compress binaries
147147
run: tar -zcvf install_bin.tgz install/*
148148
- name: Upload Binaries
149-
uses: actions/upload-artifact@v4
149+
uses: actions/upload-artifact@v5
150150
with:
151151
name: ${{ matrix.config_set }}
152152
path: install_bin.tgz
@@ -218,7 +218,7 @@ jobs:
218218
entrypoint: /bin/rm
219219
args: -rf install install_bin.tgz src ccache ${{ matrix.config_set }}
220220
discadj_tape_tests:
221-
if: inputs.runner != 'ARM64'
221+
if: ${{ !contains(inputs.runner, 'arm') }}
222222
runs-on: ${{ inputs.runner || 'ubuntu-latest' }}
223223
name: Tape Tests
224224
needs: build
@@ -236,7 +236,7 @@ jobs:
236236
entrypoint: /bin/rm
237237
args: -rf install install_bin.tgz src ccache ${{ matrix.config_set }}
238238
- name: Download All artifacts
239-
uses: actions/download-artifact@v4
239+
uses: actions/download-artifact@v5
240240
- name: Uncompress and Move Binaries
241241
run: |
242242
BIN_FOLDER="$PWD/install/bin"
@@ -267,7 +267,7 @@ jobs:
267267
entrypoint: /bin/rm
268268
args: -rf install install_bin.tgz src ccache ${{ matrix.config_set }}
269269
thread_sanitizer_tests:
270-
if: inputs.runner != 'ARM64'
270+
if: ${{ !contains(inputs.runner, 'arm') }}
271271
runs-on: ${{ inputs.runner || 'ubuntu-latest' }}
272272
name: Thread Sanitizer Tests
273273
needs: build_tsan

.github/workflows/release-management.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ jobs:
4444
zip -r ../${{matrix.os_bin}}.zip bin/*
4545
# Uploads binaries as artifacts (just as a backup)
4646
- name: Upload Binaries
47-
uses: actions/upload-artifact@v4
47+
uses: actions/upload-artifact@v5
4848
with:
4949
name: ${{matrix.os_bin}}
5050
path: ${{matrix.os_bin}}.zip

Common/include/CConfig.hpp

Lines changed: 22 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -513,7 +513,7 @@ class CConfig {
513513
DIFFUSIVITYMODEL Kind_Diffusivity_Model; /*!< \brief Kind of the mass diffusivity Model */
514514
FREESTREAM_OPTION Kind_FreeStreamOption; /*!< \brief Kind of free stream option to choose if initializing with density or temperature */
515515
MAIN_SOLVER Kind_Solver; /*!< \brief Kind of solver: Euler, NS, Continuous adjoint, etc. */
516-
LIMITER Kind_SlopeLimit, /*!< \brief Global slope limiter. */
516+
LIMITER Kind_SlopeLimit, /*!< \brief Slope limiter (for the runtime eq. system). */
517517
Kind_SlopeLimit_Flow, /*!< \brief Slope limiter for flow equations.*/
518518
Kind_SlopeLimit_Turb, /*!< \brief Slope limiter for the turbulence equation.*/
519519
Kind_SlopeLimit_AdjTurb, /*!< \brief Slope limiter for the adjoint turbulent equation.*/
@@ -560,12 +560,12 @@ class CConfig {
560560
Kind_ConvNumScheme_AdjTurb, /*!< \brief Centered or upwind scheme for the adjoint turbulence model. */
561561
Kind_ConvNumScheme_Species, /*!< \brief Centered or upwind scheme for the species model. */
562562
Kind_ConvNumScheme_Template, /*!< \brief Centered or upwind scheme for the level set equation. */
563-
Kind_FEM, /*!< \brief Finite element scheme for the flow equations. */
563+
Kind_FEM, /*!< \brief Finite element scheme for the flow equations (for the runtime eq. system). */
564564
Kind_FEM_Flow, /*!< \brief Finite element scheme for the flow equations. */
565565
Kind_Matrix_Coloring; /*!< \brief Type of matrix coloring for sparse Jacobian computation. */
566566

567567
CENTERED
568-
Kind_Centered, /*!< \brief Centered scheme. */
568+
Kind_Centered, /*!< \brief Centered scheme (for the runtime eq. system). */
569569
Kind_Centered_Flow, /*!< \brief Centered scheme for the flow equations. */
570570
Kind_Centered_AdjFlow, /*!< \brief Centered scheme for the adjoint flow equations. */
571571
Kind_Centered_Turb, /*!< \brief Centered scheme for the turbulence model. */
@@ -582,7 +582,7 @@ class CConfig {
582582
bool Energy_Equation; /*!< \brief Solve the energy equation for incompressible flows. */
583583

584584
UPWIND
585-
Kind_Upwind, /*!< \brief Upwind scheme. */
585+
Kind_Upwind, /*!< \brief Upwind scheme (for the runtime eq. system). */
586586
Kind_Upwind_Flow, /*!< \brief Upwind scheme for the flow equations. */
587587
Kind_Upwind_AdjFlow, /*!< \brief Upwind scheme for the adjoint flow equations. */
588588
Kind_Upwind_Turb, /*!< \brief Upwind scheme for the turbulence model. */
@@ -591,13 +591,19 @@ class CConfig {
591591
Kind_Upwind_Heat, /*!< \brief Upwind scheme for the heat transfer model. */
592592
Kind_Upwind_Template; /*!< \brief Upwind scheme for the template model. */
593593

594-
bool MUSCL, /*!< \brief MUSCL scheme .*/
594+
bool MUSCL, /*!< \brief MUSCL scheme (for the runtime eq. system). */
595595
MUSCL_Flow, /*!< \brief MUSCL scheme for the flow equations.*/
596596
MUSCL_Turb, /*!< \brief MUSCL scheme for the turbulence equations.*/
597597
MUSCL_Heat, /*!< \brief MUSCL scheme for the (fvm) heat equation.*/
598598
MUSCL_AdjFlow, /*!< \brief MUSCL scheme for the adj flow equations.*/
599-
MUSCL_AdjTurb; /*!< \brief MUSCL scheme for the adj turbulence equations.*/
600-
bool MUSCL_Species; /*!< \brief MUSCL scheme for the species equations.*/
599+
MUSCL_AdjTurb, /*!< \brief MUSCL scheme for the adj turbulence equations.*/
600+
MUSCL_Species; /*!< \brief MUSCL scheme for the species equations.*/
601+
su2double MUSCL_Kappa, /*!< \brief Blending coefficient for U-MUSCL scheme (for the runtime eq. system). */
602+
MUSCL_Kappa_Flow, /*!< \brief Blending coefficient for U-MUSCL scheme for the flow equations.*/
603+
MUSCL_Kappa_Turb, /*!< \brief Blending coefficient for U-MUSCL scheme for the turbulence equations.*/
604+
MUSCL_Kappa_Heat, /*!< \brief Blending coefficient for U-MUSCL scheme for the (fvm) heat equation.*/
605+
MUSCL_Kappa_AdjFlow, /*!< \brief Blending coefficient for U-MUSCL scheme for the adj flow equations.*/
606+
MUSCL_Kappa_Species; /*!< \brief Blending coefficient for U-MUSCL scheme for the species equations.*/
601607
bool Use_Accurate_Jacobians; /*!< \brief Use numerically computed Jacobians for AUSM+up(2) and SLAU(2). */
602608
bool Use_Accurate_Turb_Jacobians; /*!< \brief Use numerically computed Jacobians for standard SA turbulence model. */
603609
bool EulerPersson; /*!< \brief Boolean to determine whether this is an Euler simulation with Persson shock capturing. */
@@ -2462,11 +2468,12 @@ class CConfig {
24622468
* \param[in] val_kind_upwind - If upwind scheme, kind of upwind scheme (Roe, etc.).
24632469
* \param[in] val_kind_slopelimit - If upwind scheme, kind of slope limit.
24642470
* \param[in] val_muscl - Define if we apply a MUSCL scheme or not.
2471+
* \param[in] val_muscl_kappa - Define the blending coefficient for the MUSCL scheme.
24652472
* \param[in] val_kind_fem - If FEM, what kind of FEM discretization.
24662473
*/
24672474
void SetKind_ConvNumScheme(unsigned short val_kind_convnumscheme, CENTERED val_kind_centered,
24682475
UPWIND val_kind_upwind, LIMITER val_kind_slopelimit,
2469-
bool val_muscl, unsigned short val_kind_fem);
2476+
bool val_muscl, su2double val_muscl_kappa, unsigned short val_kind_fem);
24702477

24712478
/*!
24722479
* \brief Get the value of limiter coefficient.
@@ -4622,54 +4629,30 @@ class CConfig {
46224629

46234630
/*!
46244631
* \brief Get if the upwind scheme used MUSCL or not.
4625-
* \note This is the information that the code will use, the method will
4626-
* change in runtime depending of the specific equation (direct, adjoint,
4627-
* linearized) that is being solved.
46284632
* \return MUSCL scheme.
46294633
*/
46304634
bool GetMUSCL_Flow(void) const { return MUSCL_Flow; }
46314635

4632-
/*!
4633-
* \brief Get if the upwind scheme used MUSCL or not.
4634-
* \note This is the information that the code will use, the method will
4635-
* change in runtime depending of the specific equation (direct, adjoint,
4636-
* linearized) that is being solved.
4637-
* \return MUSCL scheme.
4638-
*/
4639-
bool GetMUSCL_Heat(void) const { return MUSCL_Heat; }
4640-
4641-
/*!
4642-
* \brief Get if the upwind scheme used MUSCL or not.
4643-
* \note This is the information that the code will use, the method will
4644-
* change in runtime depending of the specific equation (direct, adjoint,
4645-
* linearized) that is being solved.
4646-
* \return MUSCL scheme.
4647-
*/
4648-
bool GetMUSCL_Turb(void) const { return MUSCL_Turb; }
4649-
46504636
/*!
46514637
* \brief Get if the upwind scheme used MUSCL or not.
46524638
* \return MUSCL scheme.
46534639
*/
4654-
bool GetMUSCL_Species(void) const { return MUSCL_Species; }
4640+
bool GetMUSCL_AdjFlow(void) const { return MUSCL_AdjFlow; }
46554641

46564642
/*!
4657-
* \brief Get if the upwind scheme used MUSCL or not.
4643+
* \brief Get the blending coefficient for the U-MUSCL scheme.
46584644
* \note This is the information that the code will use, the method will
46594645
* change in runtime depending of the specific equation (direct, adjoint,
46604646
* linearized) that is being solved.
4661-
* \return MUSCL scheme.
4647+
* \return Blending coefficient for the U-MUSCL scheme.
46624648
*/
4663-
bool GetMUSCL_AdjFlow(void) const { return MUSCL_AdjFlow; }
4649+
su2double GetMUSCL_Kappa(void) const { return MUSCL_Kappa; }
46644650

46654651
/*!
4666-
* \brief Get if the upwind scheme used MUSCL or not.
4667-
* \note This is the information that the code will use, the method will
4668-
* change in runtime depending of the specific equation (direct, adjoint,
4669-
* linearized) that is being solved.
4670-
* \return MUSCL scheme.
4652+
* \brief Get the blending coefficient for the MUSCL scheme.
4653+
* \return Blending coefficient for the MUSCL scheme.
46714654
*/
4672-
bool GetMUSCL_AdjTurb(void) const { return MUSCL_AdjTurb; }
4655+
su2double GetMUSCL_Kappa_Flow(void) const { return MUSCL_Kappa_Flow; }
46734656

46744657
/*!
46754658
* \brief Get whether to "Use Accurate Jacobians" for AUSM+up(2) and SLAU(2).

0 commit comments

Comments
 (0)