title: conversion of Eigen::matrixXd to Double
body: <p>I have been trying to reconstruct the input data fed to my RBM program written in C++ with the aid of Eigen library. But in order to keep the matrix elements of the reconstructed matrix into some specific range, i need to apply a sigmoid function to those. 
  When i do so i get a conversion error and i don't know the way round it.</p>
  
  <p>Here is my Sigmoid function computed in an header file:</p>
  
  <pre><code>       double sigmoid(double x) 
              {
                  return 1.0 / (1.0 + exp(-x));
              }
  </code></pre>
  
  <p>And here is how i compute the reconstruction:</p>
  
  <pre><code>         MatrixXd V;
           double well[36];
           Map&lt;MatrixXd&gt;( well, V.rows(), V.cols() ) = V;
           V = sigmoid(H * result3Eigen.transpose() + onesmat*result2Eigen.transpose());
  </code></pre>
  
  <p>At last here the error message i get when compiling the code:</p>
  
  <pre><code>        error C2664:'utils::sigmoid':cannot convert parameter 1 from 'Eigen::MatrixXd' 
          to 'double'
  </code></pre>
  
  <p>Thank you for any hints in solving the issue.</p>