yap-0.2: yet another prelude - a simplistic refactoring with algebraic classes

Portabilityportable
Stabilityprovisional
Maintainerross@soi.city.ac.uk
Safe HaskellSafe-Infered

Data.YAP.Vector

Description

An example instance of the new classes: vectors.

Synopsis

Documentation

newtype Vector a Source

Simple vector type.

Constructors

Vector [a] 

Instances

dot :: Ring a => Vector a -> Vector a -> aSource

Dot product of two vectors.

norm :: Ring a => Vector a -> aSource

Norm of a vector.