mathlab interactive documentation

The documentation is live and interactive powered by the klipse plugin:

  1. Live: The code is executed in your browser
  2. Interactive: You can modify the code and it is evaluated as you type

Setup

First let's load mathlab from the mathlab github repository (It might take a couple of seconds...):


  Object.keys(mathlab)

Matrix Manipulation

Matrix inverse

inv calculates the inverse of a matrix.


mathlab.inv([[1,2],[3,4]])

And here is what happens when the matrix is not invertible:


mathlab.inv([[1,2],[1,2]])

Dot Product

dot calculates the dot product of a matrix.


 mathlab.dot([[1, 1], [2, 1]], [1, 2])