title: Image manipulation code in MATLAB (corner detection)
body: <p>I'd like to know exactly how this line of code works</p>
  
  <pre><code>corners = (m==n)&amp;(n&gt;threshold);
  </code></pre>
  
  <p>It's in a piece of code I'm using and I want to understand it. Basically, m and n are both equal-sized images, and "threshold" is a decimal value.</p>
  
  <p>To understand the context, a segment of the code is below. </p>
  
  <pre><code>% compute the m cornerness measure
  m = (ix2s.*iy2s - ixys.^2) - 0.04*(ix2s+iy2s).^2;
  
  % perform non-maximal suppression using ordfilt2
  n = ordfilt2(m, radius^2, ones([radius radius]));
  
  % display corner spots
  corners = (m==n)&amp;(n&gt;threshold);
  
  % superimpose corners
  Q = corners+im;
  Q(Q&gt;1) = 1;
  C = repmat(im,[1 1 3]);
  C(:,:,1) = Q;
  </code></pre>