diff options
Diffstat (limited to 'catenary.lua')
-rw-r--r-- | catenary.lua | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/catenary.lua b/catenary.lua index abe18e1..70e128c 100644 --- a/catenary.lua +++ b/catenary.lua @@ -71,6 +71,11 @@ local function catenary(x1,y1, x2,y2, L) y1,y2 = y2,y1 end + if math.abs(x1-x2) < 0.0001 then + x1 = x1 - 0.01 + x2 = x2 + 0.01 + end + local f = catenary0(x1,y1,x2,y2,L) return plot(f, x1,x2) end |