title: Armadillo complex sparse matrix inverse
body: <p>I'm writing a program with Armadillo C++ (4.400.1)</p>
  
  <p>I have a matrix that has to be sparse and complex, and I want to calculate the inverse of such matrix. Since it is sparse it could be the pseudoinverse, but I can guarantee that the matrix has the full diagonal.</p>
  
  <p>In the API documentation of Armadillo, it mentions the method <code>.i()</code> to calculate the inverse of any matrix, but <code>sp_cx_mat</code> members do not contain such method, and the <code>inv()</code> or <code>pinv()</code> functions cannot handle the <code>sp_cx_mat</code>  type apparently.</p>
  
  <pre><code>sp_cx_mat Y;
  
  /*Fill Y ensuring that the diagonal is full*/
  
  sp_cx_mat Z = Y.i();
  </code></pre>
  
  <p>or</p>
  
  <pre><code>sp_cx_mat Z = inv(Y);
  </code></pre>
  
  <p>None of them work.</p>
  
  <p>I would like to know how to compute the inverse of matrices of <code>sp_cx_mat</code> type.</p>