title: R Matrix::expm(x), x is complex
body: <p>I am trying to compute the matrix exponential of a matrix M, such that <code>M = 1i*(pi/2)*Spin_Sx</code>, where <code>Spin_Sx</code> is a matrix with real values. I get the following error:</p>
  
  <pre><code>Matrix::expm(M)
  Error in expm(Matrix(x)) : 
  error in evaluating the argument 'x' in selecting a method for function'expm': Error in all0(object[lower.tri(object)]) : 
  Argument must be numeric-like atomic vector
  
  Spin_Sx &lt;- structure(c(0, 1.22474487139159, 0, 0, 0, 0, 0, 1.22474487139159, 
  0, 1.58113883008419, 0, 0, 0, 0, 0, 1.58113883008419, 0, 1.73205080756888, 
  0, 0, 0, 0, 0, 1.73205080756888, 0, 1.73205080756888, 0, 0, 0, 
  0, 0, 1.73205080756888, 0, 1.58113883008419, 0, 0, 0, 0, 0, 1.58113883008419, 
  0, 1.22474487139159, 0, 0, 0, 0, 0, 1.22474487139159, 0), .Dim = c(7L, 
  7L))
  </code></pre>