Skip to content

luxbock/core.matrix

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

core.matrix

The central objective of core.matrix is to make matrix and array programming idiomatic, elegant and fast in Clojure.

(+ [[1 2]
    [3 4]]
   (* (identity-matrix 2) 3.0))

=> [[4.0 2.0]
    [3.0 7.0]]
    
;; Note: nested Clojure vectors can be used as matrices

Key goals of core.matrix:

  • Provide a clear, standard API / abstraction for matrix and array programming in Clojure
  • Enable plugable support for different underlying matrix library implementations
  • Provide a general purpose n-dimensional array implementation (NDArray)
  • Provide a foundation layer for other projects (e.g. Incanter)
  • Maintain high performance throughout

Getting Started

To use core.matrix, you can get the latest released version from Clojars:

For code examples see:

Documentation

For documentation and further examples see the Wiki:

Status

core.matrix is fully functional and usable in production applications. As well as supporting the standard Clojure data structures, multiple back end implementations exist that provide optimised matrix implementations. The most mature implementations are currently:

  • vectorz-clj : a fast pure-JVM matrix library for Clojure
  • Clatrix : native code matrix library using BLAS
  • NDArray : a general purpose pure Clojure N-dimensional array implementation, included as part of core.matrix itself

However the API is still subject to some changes at present (at least up until release 1.0.0), so users should be prepared to deal with potential breaking changes when updating to future releases.

The plan is to become an official Clojure Contrib language extension once the API has been well tested.

Build Status

Contributing

All contributions / ideas welcome!

There are a number of proposed enhancements listed as GitHub issues: these are a good place to start if you wish to contribute to core.matrix:

If you wish to contribute code, please ensure you have a Clojure Contributors Agreement signed and on file. For more information see:

Discussions related to core.matrix generally take place on the "Numerical Clojure" group:

If you are interested in writing a core.matrix implementation, see:

You can also find a protocol implementation summary here:

About

core.matrix : Matrix / Vector API for Clojure

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Clojure 99.4%
  • Other 0.6%