hgeometry-0.10.0.0: Geometric Algorithms, Data structures, and Data types.

Safe HaskellNone
LanguageHaskell2010

Data.Geometry.Duality

Contents

Synopsis

Standard Point-Line duality in R^2

dualLine :: Num r => Point 2 r -> Line 2 r Source #

Maps a line point (px,py) to a line (y=px*x - py)

dualPoint :: (Fractional r, Eq r) => Line 2 r -> Maybe (Point 2 r) Source #

Returns Nothing if the input line is vertical Maps a line l: y = ax + b to a point (a,-b)

dualPoint' :: (Fractional r, Eq r) => Line 2 r -> Point 2 r Source #

Pre: the input line is not vertical