Skip to content

Commit

Permalink
logging of newtons to ensure period
Browse files Browse the repository at this point in the history
  • Loading branch information
f4hy committed Feb 12, 2016
1 parent 4167959 commit 93fccd7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions newton.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ def f(m):
try:
result = scipy.optimize.newton(f, guess, tol=1.48e-6)
except RuntimeError:
logging.error("Newtons failed to converge using standard for {},{}".format(i, j))
logging.error("Newtons failed to converge (T={}) using standard for {},{}".format(T, i, j))
logging.error("Newtons failed, fallback is {}".format(guess))
return guess
logging.debug("newtons method converged to {} from {}".format(result, guess))
Expand All @@ -38,7 +38,7 @@ def f(m):
try:
result = scipy.optimize.newton(f, guess)
except RuntimeError:
logging.error("Newtons failed to converge using standard for {},{}".format(i, j))
logging.error("Newtons failed to converge (T={}) using standard for {},{}".format(T, i, j))
logging.error("Newtons failed, fallback is {}".format(guess))
return guess
logging.debug("newtons method converged to {}".format(result))
Expand Down

0 comments on commit 93fccd7

Please sign in to comment.