Copyright | (c) Conal Elliott 2008 |
---|---|
License | BSD3 |
Maintainer | conal@conal.net |
Stability | experimental |
Safe Haskell | None |
Language | Haskell98 |
Cross products and normals
Documentation
class HasNormal v where Source
Thing with a normal vector (not necessarily normalized).
(Num s, VectorSpace s, HasBasis s, HasTrie (Basis s), HasNormal ((:>) (Two s) (Three s))) => HasNormal (Three ((:>) (Two s) s)) | |
(Num s, VectorSpace s, HasBasis s, HasTrie (Basis s), (~) * (Basis s) ()) => HasNormal (Two ((:>) (One s) s)) | |
(Num s, HasTrie (Basis (s, s)), HasBasis s, (~) * (Basis s) ()) => HasNormal ((:>) (Two s) (Three s)) | |
(HasBasis s, HasTrie (Basis s), (~) * (Basis s) ()) => HasNormal ((:>) (One s) (Two s)) |
normal :: (HasNormal v, InnerSpace v, Floating (Scalar v)) => v -> v Source
Normalized normal vector. See also cross
.