# Single-Precision Linear Algebra

All the examples discussed in this guide so far use double precision floating-point numbers to store vector and matrix elements. In some situations, it may be desirable to use single-precision numbers. Matrices that use single-precision numbers only use half the memory of matrices with double-precision numbers, and so require only half the memory bandwidth. The drawback is the lower precision, which makes numerical problems much more common.

## Working with Single Precision Vectors and Matrices

All vector and matrix types are generic over the element type,
This means they work with single-precision floating point numbers as well.
However, by default single-precision operations will use the generic
implementation, which is very slow.
To use specialized implementations, add a reference to
the *Extreme.Numerics.SinglePrecision.dll* assembly.
This will cause the specialized implementation to be picked up automatically.

## Conversions to and from Double Precision

All single-precision vector and matrix types can be converted to double-precision. Although it would make sense from a purely logical standpoint to allow these conversions to be implicit, the large cost in terms of time and memory makes it more advisable that conversions are done explicitly.

Conversions from double precision vectors and matrices to single-precision vectors and matrices can cause a loss of information and must also be done explicitly.