Work on crab feet
This commit is contained in:
@@ -67,6 +67,12 @@ angleVV a b
|
||||
d = a `dotV` b
|
||||
in acos $ d / (ma * mb)
|
||||
|
||||
-- returns the angle opposite length a
|
||||
angleThreeSides :: Float -> Float -> Float -> Float
|
||||
angleThreeSides a b c = acos $ (f b + f c - f a) / (2*b*c)
|
||||
where
|
||||
f = (^ (2 ::Int))
|
||||
|
||||
-- | Safe version of 'angleVV' that returns 0 if either vector is null.
|
||||
safeAngleVV :: Point2 -> Point2 -> Float
|
||||
{-# INLINE safeAngleVV #-}
|
||||
|
||||
Reference in New Issue
Block a user