How can I change the maximum number of iterations and residual target in CFX 11.0 from user Fortran?
This is possible by changing certain data areas in the memory management system (MMS). An example is provided which has the original target residual set to 1.0E-03 and the original max iterations set to 4. The user Fortran routine sets these to 1.0E-05 and max 50 iterations respectively. To run the example:
- create a shared library
cfx5mkext -name test usr_chg_target.F
- Run the solver:
cfx5solve -def h_cube1.def -ccl run.ccl
Notes on subsystems:
Each subsystem represents a coupled group of transport equations. In a solver output file, there is a section called 'The Equations Solved in This Calculation', which looks something like:
Subsystem : Momentum and Mass
Subsystem : TurbKE and Diss.K
These are actually 'subsystem groups', each of which contains one or more subsystems. Each subsystem can have its own target residual. When the target residual values for all subsystem groups are met, the solver terminates. The subsystems are not always the same in all calculations. The subsystems present depend on which equations are being solved. For example, if an additional variable transport equation is being solved, there will be another subsystem for this.
The example shows how to loop over all subsystems present and set the target residual for each of them. The subsystems called TKE and TED (k and epsilon equations) have been skipped, to be consistent with the default solver behaviour of not applying the target residual to the turbulence equations.
**** Entered By: dsclarke @ 12/29/2007 11:04 AM ****