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
2 changes: 0 additions & 2 deletions Common/include/option_structure.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -820,7 +820,6 @@ enum class UPWIND {
MSW, /*!< \brief Modified Steger-Warming method. */
TURKEL, /*!< \brief Roe-Turkel's upwind numerical method. */
SLAU, /*!< \brief Simple Low-Dissipation AUSM numerical method. */
CUSP, /*!< \brief Convective upwind and split pressure numerical method. */
CONVECTIVE_TEMPLATE, /*!< \brief Template for new numerical method . */
L2ROE, /*!< \brief L2ROE numerical method . */
LMROE, /*!< \brief Rieper's Low Mach ROE numerical method . */
Expand All @@ -844,7 +843,6 @@ static const MapType<std::string, UPWIND> Upwind_Map = {
MakePair("HLLC", UPWIND::HLLC)
MakePair("SW", UPWIND::SW)
MakePair("MSW", UPWIND::MSW)
MakePair("CUSP", UPWIND::CUSP)
MakePair("SCALAR_UPWIND", UPWIND::SCALAR_UPWIND)
MakePair("BOUNDED_SCALAR", UPWIND::BOUNDED_SCALAR)
MakePair("CONVECTIVE_TEMPLATE", UPWIND::CONVECTIVE_TEMPLATE)
Expand Down
42 changes: 28 additions & 14 deletions Common/src/CConfig.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1909,7 +1909,7 @@ void CConfig::SetConfig_Options() {
* \n DESCRIPTION: Convective numerical method for the adjoint solver.
* \n OPTIONS: See \link Upwind_Map \endlink , \link Centered_Map \endlink. Note: not all methods are guaranteed to be implemented for the adjoint solver. \ingroup Config */
addConvectOption("CONV_NUM_METHOD_ADJFLOW", Kind_ConvNumScheme_AdjFlow, Kind_Centered_AdjFlow, Kind_Upwind_AdjFlow);
/*!\brief MUSCL_FLOW \n DESCRIPTION: Check if the MUSCL scheme should be used \ingroup Config*/
/*!\brief MUSCL_ADJFLOW \n DESCRIPTION: Check if the MUSCL scheme should be used \ingroup Config*/
addBoolOption("MUSCL_ADJFLOW", MUSCL_AdjFlow, true);
/*!\brief SLOPE_LIMITER_ADJFLOW
* DESCRIPTION: Slope limiter for the adjoint solution. \n OPTIONS: See \link Limiter_Map \endlink \n DEFAULT VENKATAKRISHNAN \ingroup Config*/
Expand All @@ -1920,7 +1920,7 @@ void CConfig::SetConfig_Options() {
/*!\brief LAX_SENSOR_COEFF \n DESCRIPTION: 1st order artificial dissipation coefficients for the adjoint Lax-Friedrichs method. \ingroup Config*/
addDoubleOption("ADJ_LAX_SENSOR_COEFF", Kappa_1st_AdjFlow, 0.15);

/*!\brief MUSCL_FLOW \n DESCRIPTION: Check if the MUSCL scheme should be used \ingroup Config*/
/*!\brief MUSCL_TURB \n DESCRIPTION: Check if the MUSCL scheme should be used \ingroup Config*/
addBoolOption("MUSCL_TURB", MUSCL_Turb, false);
/*!\brief SLOPE_LIMITER_TURB
* \n DESCRIPTION: Slope limiter \n OPTIONS: See \link Limiter_Map \endlink \n DEFAULT VENKATAKRISHNAN \ingroup Config*/
Expand All @@ -1929,7 +1929,7 @@ void CConfig::SetConfig_Options() {
* \n DESCRIPTION: Convective numerical method \ingroup Config*/
addConvectOption("CONV_NUM_METHOD_TURB", Kind_ConvNumScheme_Turb, Kind_Centered_Turb, Kind_Upwind_Turb);

/*!\brief MUSCL_FLOW \n DESCRIPTION: Check if the MUSCL scheme should be used \ingroup Config*/
/*!\brief MUSCL_ADJTURB \n DESCRIPTION: Check if the MUSCL scheme should be used \ingroup Config*/
addBoolOption("MUSCL_ADJTURB", MUSCL_AdjTurb, false);
/*!\brief SLOPE_LIMITER_ADJTURB
* \n DESCRIPTION: Slope limiter \n OPTIONS: See \link Limiter_Map \endlink \n DEFAULT VENKATAKRISHNAN \ingroup Config */
Expand All @@ -1944,7 +1944,7 @@ void CConfig::SetConfig_Options() {
/*!\brief CONV_NUM_METHOD_SPECIES \n DESCRIPTION: Convective numerical method for species transport \ingroup Config*/
addConvectOption("CONV_NUM_METHOD_SPECIES", Kind_ConvNumScheme_Species, Kind_Centered_Species, Kind_Upwind_Species);

/*!\brief MUSCL_FLOW \n DESCRIPTION: Check if the MUSCL scheme should be used \ingroup Config*/
/*!\brief MUSCL_HEAT \n DESCRIPTION: Check if the MUSCL scheme should be used \ingroup Config*/
addBoolOption("MUSCL_HEAT", MUSCL_Heat, false);
/*!\brief SLOPE_LIMITER_HEAT \n DESCRIPTION: Slope limiter \n OPTIONS: See \link Limiter_Map \endlink \n DEFAULT NONE \ingroup Config*/
addEnumOption("SLOPE_LIMITER_HEAT", Kind_SlopeLimit_Heat, Limiter_Map, LIMITER::NONE);
Expand Down Expand Up @@ -3560,6 +3560,21 @@ void CConfig::SetPostprocessing(SU2_COMPONENT val_software, unsigned short val_i
SetScalarDefaults(MUSCL_Heat, Kind_ConvNumScheme_Heat, Kind_Upwind_Heat, Kind_SlopeLimit_Heat);
SetScalarDefaults(MUSCL_Species, Kind_ConvNumScheme_Species, Kind_Upwind_Species, Kind_SlopeLimit_Species);

if (MUSCL_Flow && (Kind_ConvNumScheme_Flow == SPACE_CENTERED)) {
if (OptionIsSet("MUSCL_FLOW")) {
SU2_MPI::Error("Centered schemes do not use MUSCL reconstruction (use MUSCL_FLOW= NO).", CURRENT_FUNCTION);
} else {
MUSCL_Flow = false;
}
}
if (MUSCL_AdjFlow && (Kind_ConvNumScheme_AdjFlow == SPACE_CENTERED)) {
if (OptionIsSet("MUSCL_ADJFLOW")) {
SU2_MPI::Error("Centered schemes do not use MUSCL reconstruction (use MUSCL_ADJFLOW= NO).", CURRENT_FUNCTION);
} else {
MUSCL_AdjFlow = false;
}
}

if (!MUSCL_Flow || (Kind_ConvNumScheme_Flow == SPACE_CENTERED)) Kind_SlopeLimit_Flow = LIMITER::NONE;
if (!MUSCL_AdjFlow || (Kind_ConvNumScheme_AdjFlow == SPACE_CENTERED)) Kind_SlopeLimit_AdjFlow = LIMITER::NONE;
if (!MUSCL_AdjTurb || (Kind_ConvNumScheme_AdjTurb == SPACE_CENTERED)) Kind_SlopeLimit_AdjTurb = LIMITER::NONE;
Expand Down Expand Up @@ -5142,8 +5157,7 @@ void CConfig::SetPostprocessing(SU2_COMPONENT val_software, unsigned short val_i
Mesh_Box_Size[1] = 33;
Mesh_Box_Size[2] = 33;
} else if (nMesh_Box_Size != 3) {
SU2_MPI::Error(string("MESH_BOX_SIZE specified without 3 values.\n"),
CURRENT_FUNCTION);
SU2_MPI::Error("MESH_BOX_SIZE specified without 3 values.\n", CURRENT_FUNCTION);
}

/* Force the lowest memory preconditioner when direct solvers are used. */
Expand All @@ -5160,8 +5174,8 @@ void CConfig::SetPostprocessing(SU2_COMPONENT val_software, unsigned short val_i
if (DiscreteAdjoint) {
#if !defined CODI_REVERSE_TYPE
if (Kind_SU2 == SU2_COMPONENT::SU2_CFD) {
SU2_MPI::Error(string("SU2_CFD: Config option MATH_PROBLEM= DISCRETE_ADJOINT requires AD support!\n") +
string("Please use SU2_CFD_AD (configuration/compilation is done using the preconfigure.py script)."),
SU2_MPI::Error("SU2_CFD: Config option MATH_PROBLEM= DISCRETE_ADJOINT requires AD support!\n"
"Please use SU2_CFD_AD (configuration/compilation is done using the preconfigure.py script).",
CURRENT_FUNCTION);
}
#endif
Expand All @@ -5175,8 +5189,8 @@ void CConfig::SetPostprocessing(SU2_COMPONENT val_software, unsigned short val_i
Restart_Flow = false;

if (Unst_AdjointIter- long(nTimeIter) < 0){
SU2_MPI::Error(string("Invalid iteration number requested for unsteady adjoint.\n" ) +
string("Make sure EXT_ITER is larger or equal than UNST_ADJOINT_ITER."),
SU2_MPI::Error("Invalid iteration number requested for unsteady adjoint.\n"
"Make sure EXT_ITER is larger or equal than UNST_ADJOINT_ITER.",
CURRENT_FUNCTION);
}

Expand Down Expand Up @@ -5235,8 +5249,7 @@ void CConfig::SetPostprocessing(SU2_COMPONENT val_software, unsigned short val_i
turbulence model. */

if (MUSCL_AdjTurb) {
SU2_MPI::Error(string("MUSCL_ADJTURB= YES not currently supported.\n") +
string("Please select MUSCL_ADJTURB= NO (first-order)."),
SU2_MPI::Error("MUSCL_ADJTURB= YES not currently supported.\nPlease select MUSCL_ADJTURB= NO (first-order).",
CURRENT_FUNCTION);
}

Expand All @@ -5257,9 +5270,11 @@ void CConfig::SetPostprocessing(SU2_COMPONENT val_software, unsigned short val_i
we also want to avoid recomputation. */

ReconstructionGradientRequired = false;
Kind_Gradient_Method_Recon = Kind_Gradient_Method;
Kind_Gradient_Method_Recon = Kind_Gradient_Method;
}

} else {
ReconstructionGradientRequired = false;
}

if (ReconstructionGradientRequired && GetFluidProblem() && Kind_ConvNumScheme_Flow == SPACE_CENTERED)
Expand Down Expand Up @@ -6642,7 +6657,6 @@ void CConfig::SetOutput(SU2_COMPONENT val_software, unsigned short val_izone) {
if (Kind_Upwind_Flow == UPWIND::HLLC) cout << "HLLC solver for the flow inviscid terms."<< endl;
if (Kind_Upwind_Flow == UPWIND::SW) cout << "Steger-Warming solver for the flow inviscid terms."<< endl;
if (Kind_Upwind_Flow == UPWIND::MSW) cout << "Modified Steger-Warming solver for the flow inviscid terms."<< endl;
if (Kind_Upwind_Flow == UPWIND::CUSP) cout << "CUSP solver for the flow inviscid terms."<< endl;
if (Kind_Upwind_Flow == UPWIND::L2ROE) cout << "L2ROE Low Mach ROE solver for the flow inviscid terms."<< endl;
if (Kind_Upwind_Flow == UPWIND::LMROE) cout << "Rieper Low Mach ROE solver for the flow inviscid terms."<< endl;
if (Kind_Upwind_Flow == UPWIND::SLAU) cout << "Simple Low-Dissipation AUSM solver for the flow inviscid terms."<< endl;
Expand Down
20 changes: 2 additions & 18 deletions QuickStart/inv_NACA0012.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -146,17 +146,9 @@ MG_DAMP_PROLONGATION= 1.0

% -------------------- FLOW NUMERICAL METHOD DEFINITION -----------------------%
%
% Convective numerical method (JST, LAX-FRIEDRICH, CUSP, ROE, AUSM, HLLC,
% TURKEL_PREC, MSW)
CONV_NUM_METHOD_FLOW= JST
%
% Monotonic Upwind Scheme for Conservation Laws (TVD) in the flow equations.
% Required for 2nd order upwind schemes (NO, YES)
MUSCL_FLOW= YES
% Convective numerical method
%
% Slope limiter (NONE, VENKATAKRISHNAN, VENKATAKRISHNAN_WANG,
% BARTH_JESPERSEN, VAN_ALBADA_EDGE)
SLOPE_LIMITER_FLOW= VENKATAKRISHNAN_WANG
CONV_NUM_METHOD_FLOW= JST
%
% 2nd and 4th order artificial dissipation coefficients
JST_SENSOR_COEFF= ( 0.5, 0.02 )
Expand All @@ -169,14 +161,6 @@ TIME_DISCRE_FLOW= EULER_IMPLICIT
% Convective numerical method (JST, LAX-FRIEDRICH, ROE)
CONV_NUM_METHOD_ADJFLOW= JST
%
% Monotonic Upwind Scheme for Conservation Laws (TVD) in the adjoint flow equations.
% Required for 2nd order upwind schemes (NO, YES)
MUSCL_ADJFLOW= YES
%
% Slope limiter (NONE, VENKATAKRISHNAN, BARTH_JESPERSEN, VAN_ALBADA_EDGE,
% SHARP_EDGES, WALL_DISTANCE)
SLOPE_LIMITER_ADJFLOW= NONE
%
% Reduction factor of the CFL coefficient in the adjoint problem
CFL_REDUCTION_ADJFLOW= 0.01
%
Expand Down
69 changes: 0 additions & 69 deletions SU2_CFD/include/numerics/flow/convection/cusp.hpp

This file was deleted.

15 changes: 0 additions & 15 deletions SU2_CFD/src/drivers/CDriver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@
#include "../../include/numerics/flow/convection/roe.hpp"
#include "../../include/numerics/flow/convection/fds.hpp"
#include "../../include/numerics/flow/convection/fvs.hpp"
#include "../../include/numerics/flow/convection/cusp.hpp"
#include "../../include/numerics/flow/convection/hllc.hpp"
#include "../../include/numerics/flow/convection/ausm_slau.hpp"
#include "../../include/numerics/flow/convection/centered.hpp"
Expand Down Expand Up @@ -1783,13 +1782,6 @@ void CDriver::Numerics_Preprocessing(CConfig *config, CGeometry **geometry, CSol
}
break;

case UPWIND::CUSP:
for (iMGlevel = 0; iMGlevel <= config->GetnMGLevels(); iMGlevel++) {
numerics[iMGlevel][FLOW_SOL][conv_term] = new CUpwCUSP_Flow(nDim, nVar_Flow, config);
numerics[iMGlevel][FLOW_SOL][conv_bound_term] = new CUpwCUSP_Flow(nDim, nVar_Flow, config);
}
break;

default:
SU2_MPI::Error("Invalid upwind scheme or not implemented.", CURRENT_FUNCTION);
break;
Expand Down Expand Up @@ -2048,13 +2040,6 @@ void CDriver::Numerics_Preprocessing(CConfig *config, CGeometry **geometry, CSol
}
break;

case UPWIND::CUSP:
for (iMGlevel = 0; iMGlevel <= config->GetnMGLevels(); iMGlevel++) {
numerics[iMGlevel][FLOW_SOL][conv_term] = new CUpwCUSP_Flow(nDim, nVar_Flow, config);
numerics[iMGlevel][FLOW_SOL][conv_bound_term] = new CUpwCUSP_Flow(nDim, nVar_Flow, config);
}
break;

default:
SU2_MPI::Error("Riemann solver not implemented.", CURRENT_FUNCTION);
break;
Expand Down
1 change: 0 additions & 1 deletion SU2_CFD/src/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,6 @@ su2_cfd_src += files(['numerics/CNumerics.cpp',
'numerics/flow/convection/roe.cpp',
'numerics/flow/convection/fds.cpp',
'numerics/flow/convection/fvs.cpp',
'numerics/flow/convection/cusp.cpp',
'numerics/flow/convection/hllc.cpp',
'numerics/flow/convection/ausm_slau.cpp',
'numerics/flow/convection/centered.cpp',
Expand Down
Loading