diff options
author | Jaron Kent-Dobias <jaron@kent-dobias.com> | 2018-11-07 19:31:22 -0500 |
---|---|---|
committer | Jaron Kent-Dobias <jaron@kent-dobias.com> | 2018-11-07 19:31:22 -0500 |
commit | b8772d61229a68cf231286128d079ad9c7310357 (patch) | |
tree | 2ab7a9edd09f20d28557fd1930278f8be51f2866 | |
parent | ff7f1cea07f88346babda8a4987844fcc78587ce (diff) | |
download | fuse_networks-b8772d61229a68cf231286128d079ad9c7310357.tar.gz fuse_networks-b8772d61229a68cf231286128d079ad9c7310357.tar.bz2 fuse_networks-b8772d61229a68cf231286128d079ad9c7310357.zip |
changed the way that the cutoff is used to compare conductivity
-rw-r--r-- | lib/include/network.hpp | 2 | ||||
-rw-r--r-- | lib/src/network.cpp | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/include/network.hpp b/lib/include/network.hpp index abf88cd..5cbba0d 100644 --- a/lib/include/network.hpp +++ b/lib/include/network.hpp @@ -43,6 +43,6 @@ class network { void break_edge(unsigned int); void add_edge(unsigned int); std::pair<double, std::vector<double>> currents(); - void fracture(hooks&, double cutoff = 1e-13); + void fracture(hooks&, double cutoff = 1e-14); }; diff --git a/lib/src/network.cpp b/lib/src/network.cpp index 8af140b..9addfdd 100644 --- a/lib/src/network.cpp +++ b/lib/src/network.cpp @@ -249,7 +249,7 @@ void network::fracture(hooks& m, double cutoff) { while (true) { auto currents = this->currents(); - if (currents.first < cutoff) { + if (currents.first < cutoff * G.vertices.size()) { break; } |