diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/net_notch.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/net_notch.c b/src/net_notch.c index 608d0b5..c0ab9d7 100644 --- a/src/net_notch.c +++ b/src/net_notch.c @@ -20,7 +20,7 @@ void net_notch(net_t *net, double notch_len, cholmod_common *c) { crosses_center = (v1y >= 0.5 && v2y <= 0.5) || (v1y <= 0.5 && v2y >= 0.5); not_wrapping = fabs(dy) < 0.5; - correct_length = v1x + dx / dy * (v1y - 0.5) <= notch_len; + correct_length = 0 <= v1x + dx / dy * (v1y - 0.5) <= notch_len; if (crosses_center && not_wrapping && correct_length) { break_edge(net, i, c); |