Calculate Residuals for sub-domian of problem

  • Last Post 24 January 2019
chrisbarrow posted this 24 January 2019

The particular solution we are trying to calculate is a natural convection problem in an enclosed space. We are primarily concerned with solution convergence in a sub-region/sub-domain of the solution which is around the area of interest. I have been trying to follow the equations given in the Definition of Residuals for the Pressure-Based Solver section ( in ANSYS 18.2), and exporting the relevant data to post-process in another application. It appears, however, that in order to calculate the globally scaled residuals, I need the cell center coefficient for each cell. I have been unable to find a way to export this coefficient or export the variables that calculate it (a_nb, b). What is the best way to either get this cell center coefficient value from Fluent or to generally calculate the scaled residual for a sub-region of the solution?

Using ANSYS 18.2 on Windows 10, 64-bit machine.

Order By: Standard | Newest | Votes
abenhadj posted this 24 January 2019

No real workaround to reconstruct the central and neighbouring coefficients. Just enable residual for post processing under solve set expert.

Best regards,


chrisbarrow posted this 24 January 2019

Amine, thank you for the quick response. In trying to perform the analysis, I was able to export the residual data using the solve/set/expert settings. This gives the cell residuals for the case. Following the equations in the Fluent User Guide under section, the unscaled residual for a variable is calculated as the sum of the absolute value of the residuals over all cells ( R^\phi = sum(abs(cell residuals)) ). In order to "globally" scale these residuals to better judge the convergence, the unscaled residual is divided by the sum of the absolute values of a_p * \phi_p for all cells p. For momentum equations, such as determining the x,y,z velocity residuals, a_p * \phi_p is instead a_p * v_p, where v_p is the velocity magnitude of cell p. I can export the velocity magnitude with the residuals, but am still missing a_p. Calculating the "locally scaled" residual would also require knowing a_p.

After reading further in the documentation, under section for Controlling Normalization and Scaling, it states that

Normalization can be used with both scaled and unscaled residuals. Note that if normalization is enabled, the convergence criterion may need to be adjusted appropriately. See Judging Convergence for information about judging convergence based on the different types of residual reports. (Both the raw residuals and scaling factors are stored in the data file, so you can switch between scaled and unscaled residuals.)

Is the scaling factors referred to in this paragraph on a per-cell basis, or is it a global scaling factor? Is there a way that this scaling factor(s) can be exported?