本文整理汇总了C++中COutput::SetConvergence_History方法的典型用法代码示例。如果您正苦于以下问题:C++ COutput::SetConvergence_History方法的具体用法?C++ COutput::SetConvergence_History怎么用?C++ COutput::SetConvergence_History使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类COutput
的用法示例。
在下文中一共展示了COutput::SetConvergence_History方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: main
//.........这里部分代码省略.........
case ADJ_EULER: case ADJ_NAVIER_STOKES: case ADJ_RANS:
AdjMeanFlowIteration(output, integration_container, geometry_container,
solver_container, numerics_container, config_container,
surface_movement, grid_movement, FFDBox);
break;
case ADJ_TNE2_EULER: case ADJ_TNE2_NAVIER_STOKES:
AdjTNE2Iteration(output, integration_container, geometry_container,
solver_container, numerics_container, config_container,
surface_movement, grid_movement, FFDBox);
break;
}
/*--- Synchronization point after a single solver iteration. Compute the
wall clock time required. ---*/
#ifndef NO_MPI
MPI::COMM_WORLD.Barrier();
#endif
StopTime = clock(); TimeUsed += (StopTime - StartTime);
/*--- For specific applications, evaluate and plot the equivalent area or flow rate. ---*/
if ((config_container[ZONE_0]->GetKind_Solver() == EULER) &&
(config_container[ZONE_0]->GetEquivArea() == YES)) {
output->SetEquivalentArea(solver_container[ZONE_0][MESH_0][FLOW_SOL],
geometry_container[ZONE_0][MESH_0], config_container[ZONE_0], ExtIter);
}
/*--- Update the convergence history file (serial and parallel computations). ---*/
output->SetConvergence_History(&ConvHist_file, geometry_container, solver_container,
config_container, integration_container, false, TimeUsed, ZONE_0);
/*--- Check whether the current simulation has reached the specified
convergence criteria, and set StopCalc to true, if so. ---*/
switch (config_container[ZONE_0]->GetKind_Solver()) {
case EULER: case NAVIER_STOKES: case RANS:
StopCalc = integration_container[ZONE_0][FLOW_SOL]->GetConvergence(); break;
case TNE2_EULER: case TNE2_NAVIER_STOKES:
StopCalc = integration_container[ZONE_0][TNE2_SOL]->GetConvergence(); break;
case WAVE_EQUATION:
StopCalc = integration_container[ZONE_0][WAVE_SOL]->GetConvergence(); break;
case HEAT_EQUATION:
StopCalc = integration_container[ZONE_0][HEAT_SOL]->GetConvergence(); break;
case LINEAR_ELASTICITY:
StopCalc = integration_container[ZONE_0][FEA_SOL]->GetConvergence(); break;
case ADJ_EULER: case ADJ_NAVIER_STOKES: case ADJ_RANS:
StopCalc = integration_container[ZONE_0][ADJFLOW_SOL]->GetConvergence(); break;
case ADJ_TNE2_EULER: case ADJ_TNE2_NAVIER_STOKES:
StopCalc = integration_container[ZONE_0][ADJTNE2_SOL]->GetConvergence(); break;
}
/*--- Solution output. Determine whether a solution needs to be written
after the current iteration, and if so, execute the output file writing
routines. ---*/
if ((ExtIter+1 == config_container[ZONE_0]->GetnExtIter()) ||
((ExtIter % config_container[ZONE_0]->GetWrt_Sol_Freq() == 0) && (ExtIter != 0) &&
!((config_container[ZONE_0]->GetUnsteady_Simulation() == DT_STEPPING_1ST) ||
(config_container[ZONE_0]->GetUnsteady_Simulation() == DT_STEPPING_2ND))) ||
(StopCalc) ||
(((config_container[ZONE_0]->GetUnsteady_Simulation() == DT_STEPPING_1ST) ||