Skip to content

Commit b3a7a00

Browse files
committed
Add Iter and Residual output for turbulence linear solver.
Note though that we can get the output but ITER and ERROR are controlled by the same config options as for the mean flow.
1 parent c99162d commit b3a7a00

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

SU2_CFD/src/output/CFlowIncOutput.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -214,6 +214,10 @@ void CFlowIncOutput::SetHistoryOutputFields(CConfig *config){
214214
/// DESCRIPTION: Linear solver iterations
215215
AddHistoryOutput("LINSOL_ITER", "LinSolIter", ScreenOutputFormat::INTEGER, "LINSOL", "Number of iterations of the linear solver.");
216216
AddHistoryOutput("LINSOL_RESIDUAL", "LinSolRes", ScreenOutputFormat::FIXED, "LINSOL", "Residual of the linear solver.");
217+
if (turb_model) {
218+
AddHistoryOutput("LINSOL_ITER_TURB", "LinSolIterTurb", ScreenOutputFormat::INTEGER, "LINSOL", "Number of iterations of the linear solver for turbulence solver.");
219+
AddHistoryOutput("LINSOL_RESIDUAL_TURB", "LinSolResTurb", ScreenOutputFormat::FIXED, "LINSOL", "Residual of the linear solver for turbulence solver.");
220+
}
217221

218222
AddHistoryOutput("MIN_DELTA_TIME", "Min DT", ScreenOutputFormat::SCIENTIFIC, "CFL_NUMBER", "Current minimum local time step");
219223
AddHistoryOutput("MAX_DELTA_TIME", "Max DT", ScreenOutputFormat::SCIENTIFIC, "CFL_NUMBER", "Current maximum local time step");
@@ -333,6 +337,10 @@ void CFlowIncOutput::LoadHistoryData(CConfig *config, CGeometry *geometry, CSolv
333337

334338
SetHistoryOutputValue("LINSOL_ITER", flow_solver->GetIterLinSolver());
335339
SetHistoryOutputValue("LINSOL_RESIDUAL", log10(flow_solver->GetResLinSolver()));
340+
if (turb_model) {
341+
SetHistoryOutputValue("LINSOL_ITER_TURB", turb_solver->GetIterLinSolver());
342+
SetHistoryOutputValue("LINSOL_RESIDUAL_TURB", log10(turb_solver->GetResLinSolver()));
343+
}
336344

337345
if (config->GetDeform_Mesh()){
338346
SetHistoryOutputValue("DEFORM_MIN_VOLUME", mesh_solver->GetMinimum_Volume());

0 commit comments

Comments
 (0)