Adjustment of Computing Parameters at Run-time
Last updated
Last updated
TOUGH4 allows adjustment/change of several key computing parameters, options or temporary monitoring of variables at an element or connection during run-time. These parameters include: simulation end time (SimulationTimeEnd), maximum time-step size (MaxTimeStep), relative Newton iteration convergence criteria (rel_convergence_crit), absolute Newton iteration convergence criteria (abs_convergence_crit), maximum primary variable change criteria for Newton iteration convergence (pv_convergence_cr1, pv_convergence_cr2, pv_convergence_cr3), time-step cutting factor (dt_reduced_Factor), maximum number of time steps (Max_NumTimeSteps), maximum number of Newton iterations (Max_NumNRIterations), maximum number of Newton iterations for increasing time step size (MOP_16), frequency for writing SAVE file (SAVE_frequency), frequency for writing time-series output file (TimeSeries_frequency), options controlled by IE array, and monitoring of simulation results at a given element (monitoringElem) or connection (monitoringConn) by providing the element name and/or connection name. The simulation results of primary variables, phase state, fluxes at the connection will be written out for the provided monitoring element/connection. Elements of IE array provide many program options (see ). User may change these options at run-time through change of value of an element. Only one element value can be changed at each time by providing subscript of the IE array and it value.
The parameter changes or giving an element or connection name for monitoring are through a text file named "Parameter_Update_File". Figure 29 shows the contents of this file.
A template of this file was included in the software distribution package. Users need copy it to the working folder where the model input files are located. TOUGH4 will scan this file during run-time for every given time (scan frequency). If it was changed, the new parameters will be read and replace the original values. Only the file updated after the start of running simulation will take effect. Users may adjust the parameters multiple times in one simulation run. If a parameter does not change, one may leave the input parameter empty. As these computing parameters/options may be sensitive to the simulation performance, an error value may lead to unpredictable model running behavior. Users should make the parameter adjustments carefully.
The default frequency for scanning the file "Parameter_Update_File" is 10 minutes per scan. Users may use IE(30) to increase or decrease the scanning frequency.