Dear DEVSIM developer,
I am new user of DEVSIM.
Could you give me more details about the definition of “absolute_error” and “relative_error” in solve()?
How to determine the values to make the solver converge?
# diode_1d.py
solve(type="dc", absolute_error=1e10, relative_error=1e-10, maximum_iterations=30)
# absolute_error=1e10 is very large number
The maximum value of aerr and rerr over all of the nodes is used for the convergence test. When carrier density is one of the solution variables, then 10^{10} is not so large compared to a carrier density of 10^{20}, and would be equivalent to a relative error of 10^{-10}.
A relative error of 10^{-15} is at the limit of double precision floating point accuracy. If you use the extended precision mode of DEVSIM, a relative error approaching 10^{-30} may be achieved, depending on the problems being solved.
I have been told that the terms absolute error and relative error are not the appropriate terms for these parameters, and the phrase “update norm” would be more appropriate.
Thanks for your reply!
I have another question about the error. As you mentioned in your reply, the “absolute_error” “relative_error” are corresponding to carrier density. But depends on the printed log information, like
Do they all need to compare with “absolute_error” “relative_error”?I find the “absolute_error” from Equation: “PotentialEquation” is small → 4.46912e-17.
And for my understanding, there are 3 variables that should be solved: \psi (potential), n (electron density), and p (hole density), but there is only one specification of “error” in solve().
You are correct that there is only the one error specification for all of the equations. It appears that the errors from each equation are summed become the error for the region. The device errors are than the maximum error of all of the regions. The device error is compared with the errors in the solve command. I usually use a “large” absolute error specification with a “small” relative error specification. I am open to suggestions to change the solver behavior.