title: How to calculate infinite series on MATLAB
body: <p>I'm having trouble calculating a series on MATLAB. I'm trying to use the symbolic toolbox, but MATLAB keeps busy and never returns my result. This is my code:</p>
  
  <pre><code>function Y = ProbCollision_S (n,tp,s,T)
  
     syms k;
  
     format long;
  
     Y = double(symsum(exp(-n.*s./T).*((n.*s./T).^k).*(1-(1-k.*tp./s).^k)./factorial(k),2,Inf));
  
  end
  </code></pre>
  
  <p>Please help?</p>
  
  <p>Thank you in advance.</p>