title: Integration numerical with variable limits
body: <p>I am trying to find a double integration numerically where the inner integral has variable
  limits while the outer integral scalar limits and not the other way round. 
  As I understand integral2 allows you do the reverse of what I want i.e you can have the outer variable limits non scalar while the inner should be scalar.</p>
  
  <pre><code>fxy=@(x,y)1/x+1/y
  xmin=0;
  xmax=@(y)2*y;
  ymin=0;
  ymax=+inf;
  integral2(fxy,xmin,xmax,ymin,ymax)
  </code></pre>
  
  <p>I get the following error 
  Error using integral2 (line 76)
  XMAX must be a floating point scalar.</p>
  
  <p>Please not that I cant reverse the order of the variable limits as:</p>
  
  <pre><code>integral2(fxy,ymin,ymax,xmin,xmax)
  </code></pre>
  
  <p>because I would be performing the integration over dx dy but with wrong limits</p>
  
  <p>Any help is much appreciated.</p>