@@ -1087,8 +1087,13 @@ void CConfig::SetConfig_Options() {
10871087 addBoolOption (" MULTIZONE" , Multizone_Problem, NO);
10881088 /* !\brief PHYSICAL_PROBLEM \n DESCRIPTION: Physical governing equations \n Options: see \link Solver_Map \endlink \n DEFAULT: NO_SOLVER \ingroup Config*/
10891089 addEnumOption (" MULTIZONE_SOLVER" , Kind_MZSolver, Multizone_Map, MZ_BLOCK_GAUSS_SEIDEL);
1090+ #ifdef CODI_REVERSE_TYPE
1091+ const bool discAdjDefault = true ;
1092+ #else
1093+ const bool discAdjDefault = false ;
1094+ #endif
10901095 /* !\brief MATH_PROBLEM \n DESCRIPTION: Mathematical problem \n Options: DIRECT, ADJOINT \ingroup Config*/
1091- addMathProblemOption (" MATH_PROBLEM" , ContinuousAdjoint, false , DiscreteAdjoint, false , Restart_Flow, false );
1096+ addMathProblemOption (" MATH_PROBLEM" , ContinuousAdjoint, false , DiscreteAdjoint, discAdjDefault , Restart_Flow, discAdjDefault );
10921097 /* !\brief KIND_TURB_MODEL \n DESCRIPTION: Specify turbulence model \n Options: see \link Turb_Model_Map \endlink \n DEFAULT: NO_TURB_MODEL \ingroup Config*/
10931098 addEnumOption (" KIND_TURB_MODEL" , Kind_Turb_Model, Turb_Model_Map, NO_TURB_MODEL);
10941099 /* !\brief KIND_TRANS_MODEL \n DESCRIPTION: Specify transition model OPTIONS: see \link Trans_Model_Map \endlink \n DEFAULT: NO_TRANS_MODEL \ingroup Config*/
@@ -4856,6 +4861,10 @@ void CConfig::SetPostprocessing(unsigned short val_software, unsigned short val_
48564861 }
48574862#endif
48584863
4864+ /* --- Use the same linear solver on the primal as the one used in the adjoint. ---*/
4865+ Kind_Linear_Solver = Kind_DiscAdj_Linear_Solver;
4866+ Kind_Linear_Solver_Prec = Kind_DiscAdj_Linear_Prec;
4867+
48594868 /* --- Disable writing of limiters if enabled ---*/
48604869 Wrt_Limiters = false ;
48614870
0 commit comments