Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
1 change: 1 addition & 0 deletions AUTHORS.md
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@ JonathanSmith1936
Kedar Naik
LaSerpe
Lennaert Tol
Lisa Kusch
Matteo Pini
Max Aehle
Max Le
Expand Down
5 changes: 5 additions & 0 deletions Common/src/CConfig.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3375,6 +3375,11 @@ void CConfig::SetPostprocessing(SU2_COMPONENT val_software, unsigned short val_i
SU2_MPI::Error("A turbulence model must be specified with KIND_TURB_MODEL if SOLVER= INC_RANS", CURRENT_FUNCTION);
}

/*--- Check if turbulence model can be used for AXISYMMETRIC case---*/
if (Axisymmetric && Kind_Turb_Model != TURB_MODEL::NONE && Kind_Turb_Model != TURB_MODEL::SST && Kind_Turb_Model != TURB_MODEL::SST_SUST){
SU2_MPI::Error("Axisymmetry is currently only supported for KIND_TURB_MODEL chosen as SST or SST_SUST", CURRENT_FUNCTION);
}

/*--- Set the boolean Wall_Functions equal to true if there is a
definition for the wall founctions ---*/

Expand Down
5 changes: 3 additions & 2 deletions SU2_CFD/include/numerics/turbulent/turb_sources.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -599,9 +599,10 @@ class CSourcePieceWise_TurbSST final : public CNumerics {
if (Coord_i[1] < EPS) return;

AD::SetPreaccIn(Coord_i[1]);
AD::SetPreaccIn(V_i[idx.Velocity() + 1]);

const su2double yinv = 1.0 / Coord_i[1];
const su2double rhov = Density_i * V_i[2];
const su2double rhov = Density_i * V_i[idx.Velocity() + 1];
const su2double& k = ScalarVar_i[0];
const su2double& w = ScalarVar_i[1];

Expand All @@ -611,7 +612,7 @@ class CSourcePieceWise_TurbSST final : public CNumerics {

/*--- Production ---*/
const su2double pk_axi = max(
0.0, 2.0 / 3.0 * rhov * k * ((2.0 * yinv * V_i[2] - PrimVar_Grad_i[2][1] - PrimVar_Grad_i[1][0]) / zeta - 1.0));
0.0, 2.0 / 3.0 * rhov * k * ((2.0 * yinv * V_i[idx.Velocity() + 1] - PrimVar_Grad_i[idx.Velocity()+1][1] - PrimVar_Grad_i[idx.Velocity()][0]) / zeta - 1.0));
const su2double pw_axi = alfa_blended * zeta / k * pk_axi;

/*--- Convection-Diffusion ---*/
Expand Down
5 changes: 1 addition & 4 deletions TestCases/axisymmetric_rans/air_nozzle/air_nozzle.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,6 @@ SOLVER= RANS
% Specify turbulence model (NONE, SA, SA_NEG, SST, SA_E, SA_COMP, SA_E_COMP)
KIND_TURB_MODEL= SST
%
% Mathematical problem (DIRECT, CONTINUOUS_ADJOINT, DISCRETE_ADJOINT)
MATH_PROBLEM= DIRECT
%
% Restart solution (NO, YES)
RESTART_SOL= YES
%
Expand Down Expand Up @@ -208,4 +205,4 @@ SOLUTION_FILENAME= solution_flow.dat
OUTPUT_WRT_FREQ= 1000
%
% Screen output
SCREEN_OUTPUT= (INNER_ITER, RMS_DENSITY, RMS_ENERGY, RMS_TKE, RMS_DISSIPATION)
SCREEN_OUTPUT= (INNER_ITER, RMS_DENSITY, RMS_ENERGY, RMS_TKE, RMS_DISSIPATION, RMS_ADJ_DENSITY, RMS_ADJ_ENERGY, RMS_ADJ_TKE, RMS_ADJ_DISSIPATION)
16 changes: 16 additions & 0 deletions TestCases/parallel_regression_AD.py
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,22 @@ def main():
discadj_incomp_turb_NACA0012_sst.tol = 0.00001
test_list.append(discadj_incomp_turb_NACA0012_sst)

####################################################################
### Disc. Adj. Axisymmetric RANS ###
####################################################################

# Adjoint Axisymmetric RANS
discadj_axisymmetric_rans_nozzle = TestCase('discadj_axisymmetric_rans')
discadj_axisymmetric_rans_nozzle.cfg_dir = "axisymmetric_rans/air_nozzle"
discadj_axisymmetric_rans_nozzle.cfg_file = "air_nozzle.cfg"
discadj_axisymmetric_rans_nozzle.test_iter = 10
discadj_axisymmetric_rans_nozzle.test_vals = [-10.391857, -15.524696, -7.715907, -17.350541]
discadj_axisymmetric_rans_nozzle.su2_exec = "mpirun -n 2 SU2_CFD_AD"
discadj_axisymmetric_rans_nozzle.timeout = 1600
discadj_axisymmetric_rans_nozzle.tol = 0.00001
discadj_axisymmetric_rans_nozzle.no_restart = True
test_list.append(discadj_axisymmetric_rans_nozzle)

#######################################################
### Unsteady Disc. adj. compressible RANS ###
#######################################################
Expand Down