Skip to content
Snippets Groups Projects
Commit f37a9e15 authored by Oliver Sander's avatar Oliver Sander Committed by sander@PCPOOL.MI.FU-BERLIN.DE
Browse files

only divide by the old error if it is not zero

[[Imported from SVN: r2312]]
parent f9bef30d
Branches
Tags
No related merge requests found
...@@ -153,7 +153,7 @@ for i in range(fro,to): ...@@ -153,7 +153,7 @@ for i in range(fro,to):
error = sqrt(current_iterate*A*current_iterate.transpose()) error = sqrt(current_iterate*A*current_iterate.transpose())
# Compute the convergence rate # Compute the convergence rate
if (i!=fro): if (i!=fro and old_error != 0):
conv_rate = error / old_error conv_rate = error / old_error
conv_rate_product *= conv_rate conv_rate_product *= conv_rate
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment