lib.rs 1.1 KB

12345678910111213141516171819202122232425
  1. //! This is a LINEar ALgebra library.
  2. //!
  3. //! Most stuff works with the traits `Float`, `Numeric` and `Primitive` in some combination.
  4. //!
  5. //! The combination `Float + Numeric` allows `f32`, `f64`, `Complex<f32>` and `Complex<f64>`,
  6. //! whereas `Float + Numeric + Primitive` would only allow `f32` and `f64`.
  7. //! This trick is used to prevent e.g. `Complex<Complex<f32>>`, as that would not make sense.
  8. //!
  9. //! There are no complex numbers with integral types, as these would be rather impractical
  10. //! when calculating basically anything.
  11. //!
  12. //! As a consequence the complex types `Complex<f32>` and `Complex<f64>` are also considered
  13. //! `Float` in our context.
  14. pub use self::traits::{Float, Numeric, Primitive};
  15. #[cfg(feature = "matrix")]
  16. pub use self::types::{ColumnVector, GenericMatrix, Matrix, MatrixMut, RowVector, SquareMatrix, View, ViewMut};
  17. #[cfg(feature = "angular")]
  18. pub use self::types::{Angular, Degree, Radiant};
  19. #[cfg(feature = "complex")]
  20. pub use self::types::Complex;
  21. #[cfg(feature = "quaternion")]
  22. pub use self::types::Quaternion;
  23. mod traits;
  24. mod types;