title: Get element from math.matrix in Javascript
body: <p>I'm using the matrix element from the <a href="https://mathjs.org/docs/datatypes/matrices.html" rel="nofollow noreferrer">math.js</a> library.</p>
  <p>I create a matrix:</p>
  <pre><code> let eye = math.matrix([
      [1, 0, 0],
      [0, 1, 0],
      [0, 0, 1]
      ]);
  </code></pre>
  <p>But when I try to access an element of the matrix, it is always undefined.</p>
  <pre><code>console.log(eye[0][0]) -&gt; undefined 
  console.log(eye[0])  -&gt; undefined 
  </code></pre>
  <p>Any suggestions? I have read through the documentation for the math.js library and I see nothing about how to access an individual element.</p>
  <p>And I do need to use this library, as I am doing matrix-based operations (matrix multiplication).</p>