rintf(1,<span class="string">'\nOptimum half beam-width for given specs is %d.\n'</span>,halfbeam);

<span class="comment">% compute the minimum noise design for the optimal beamwidth</span>
ind = find(theta &lt;= (theta_tar-halfbeam) | <span class="keyword">...</span>
           theta &gt;= (theta_tar+halfbeam) );
As = A(ind,:);
cvx_begin <span class="string">quiet</span>
  variable <span class="string">w(n)</span> <span class="string">complex</span>
  minimize( norm( w ) )
  subject <span class="string">t