<?xml version="1.0" encoding="utf-8" standalone="no"?>
<!DOCTYPE document PUBLIC "-//CNX//DTD CNXML 0.5 plus MathML//EN" "http://cnx.rice.edu/cnxml/0.5/DTD/cnxml_mathml.dtd">
<document xmlns="http://cnx.rice.edu/cnxml" xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="None">
  <name xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">Orthogonal Projections and the Orthogonality Principle</name>
  <metadata xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
  <md:version xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">**new**</md:version>
  <md:created xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">2004/06/15 16:33:37.047 GMT-5</md:created>
  <md:revised xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">2004/06/15 16:34:28.050 GMT-5</md:revised>
  <md:authorlist xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
      <md:author xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="richb">
      <md:firstname xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">Richard</md:firstname>
      <md:othername xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">G.</md:othername>
      <md:surname xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">Baraniuk</md:surname>
      <md:email xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">richb@rice.edu</md:email>
    </md:author>
  </md:authorlist>

  <md:maintainerlist xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
    <md:maintainer xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="richb">
      <md:firstname xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">Richard</md:firstname>
      <md:othername xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">G.</md:othername>
      <md:surname xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">Baraniuk</md:surname>
      <md:email xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">richb@rice.edu</md:email>
    </md:maintainer>
    <md:maintainer xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="gpicazo">
      <md:firstname xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">Genaro</md:firstname>
      
      <md:surname xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">Picazo</md:surname>
      <md:email xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">picazo@rice.edu</md:email>
    </md:maintainer>
  </md:maintainerlist>
  
  

  <md:abstract xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/"/>
</metadata>

  <content xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
    <para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="keyproblem">
      A key problem in DSP:
    </para>   
    <para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="problem">
      Given a signal
      <m:math>
	<m:ci type="vector">y</m:ci>
      </m:math>
      find the signal
      <m:math>
	<m:ci type="vector">x</m:ci>
      </m:math>
      from a subspace <m:math><m:ci>S</m:ci></m:math> that is the
      closest to
      <m:math>
	<m:ci type="vector">y</m:ci>
      </m:math>.
    </para>
    
    <example xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="exam1">
      <para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="exam1para1">
	<m:math>
	  <m:ci type="vector">y</m:ci>
	</m:math>
	is a noisy signal and all
	<m:math>
	  <m:apply>
	    <m:in/>
	    <m:ci type="vector">x</m:ci>
	    <m:ci>S</m:ci>
	  </m:apply>
	</m:math>
	are smooth.
	
	<figure xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="fig1">
	  <media xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" type="image/png" src="ortho1.png"/>
	</figure>
	
	Finding an
	<m:math>
	  <m:ci type="vector">x</m:ci>
	</m:math>
	close to
	<m:math>
	  <m:ci type="vector">y</m:ci>
	</m:math>
	will approximate it by a noise-free version.
      </para>
    </example>
    
    <para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="geometry">
      Geometry of the situation via linear algebra.
      
      <m:math>
	<m:apply>
	  <m:implies/>
	  <m:apply>
	    <m:in/>
	    <m:ci type="vector">x</m:ci>
	    <m:ci>S</m:ci>
	  </m:apply>
	  <m:apply>
	    <m:eq/>
	    <m:ci type="vector">x</m:ci>
	    <m:apply>
	      <m:sum/>
	      <m:bvar>
		<m:ci>k</m:ci>
	      </m:bvar>
	      <m:lowlimit>
		<m:cn>0</m:cn>
	      </m:lowlimit>
	      <m:uplimit>
		<m:apply>
		  <m:minus/>
		  <m:ci>M</m:ci>
		  <m:cn>1</m:cn>
		</m:apply>
	      </m:uplimit>
	      <m:apply>
		<m:times/>
		<m:ci>
		  <m:msub>
		    <m:mi>α</m:mi>
		    <m:mi>k</m:mi>
		  </m:msub>
		</m:ci>
		<m:ci type="vector">
		  <m:msub>
		    <m:mi>b</m:mi>
		    <m:mi>k</m:mi>
		  </m:msub>
		</m:ci>
	      </m:apply>
	    </m:apply>
	  </m:apply>
	</m:apply>
      </m:math>
      where
      <m:math>
	<m:set>
	  <m:ci type="vector">
	    <m:msub>
	      <m:mi>b</m:mi>
	      <m:mi>k</m:mi>
	    </m:msub>
	  </m:ci>
	</m:set>
      </m:math>
      are a basis for the subspace
      <m:math>
	<m:ci>S</m:ci>
      </m:math> (We assume it is an ONB).

      <figure xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="figure2">
	<media xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" type="image/png" src="ortho2.png"/>
	<caption xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
	  <m:math>
	    <m:ci>S</m:ci>
	  </m:math>
	  is an M-dim hyperplane thru the origin of
	  <m:math>
	    <m:apply>
	      <m:power/>
	      <m:reals/>
	      <m:ci>N</m:ci>
	    </m:apply>
	  </m:math>
	</caption>
      </figure>
      
      In general,
      <m:math>
	<m:ci type="vector">y</m:ci>
      </m:math>
      is not
      <m:math>
	<m:apply>
	  <m:in/>
	  <m:ci/>
	  <m:ci>S</m:ci>
	</m:apply>
      </m:math>
    </para>
    
    <para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="goal">
      The goal is to find
      <m:math>
	<m:apply>
	  <m:in/>
	  <m:ci type="vector">x</m:ci>
	  <m:ci>S</m:ci>
	</m:apply>
      </m:math>
      close to
      <m:math>
	<m:ci type="vector">y</m:ci>
      </m:math>,
      which is equivalent to finding
      <m:math>
	<m:ci type="vector">
	  <m:msub>
	    <m:mi>α</m:mi>
	    <m:mi>k</m:mi>
	  </m:msub>
	</m:ci>
      </m:math>.
    </para>
    
    <para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="norm">
      We can also measure how close
      <m:math>
	<m:ci type="vector">x</m:ci>
      </m:math>
      is to 
      <m:math>
	<m:ci type="vector">y</m:ci>
      </m:math>
      by
      <m:math>
	<m:ci>
	  <m:msub>
	    <m:mi>l</m:mi>
	    <m:mn>2</m:mn>
	  </m:msub>
	</m:ci>
      </m:math>
      norm error in
      <m:math>
	<m:apply>
	  <m:power/>
	  <m:reals/>
	  <m:ci>N</m:ci>
	</m:apply>
      </m:math>:
      
      <m:math display="block">
	<m:apply>
	  <m:eq/>
	  <m:apply>
	    <m:power/>
	    <m:apply>
	      <m:csymbol definitionURL="http://cnx.rice.edu/cd/cnxmath.ocd#norm"/>
	      <m:domainofapplication>
		<m:cn>2</m:cn>
	      </m:domainofapplication>
	      <m:apply>
		<m:minus/>
		<m:ci type="vector">y</m:ci>
		<m:ci type="vector">x</m:ci>
	      </m:apply>
	    </m:apply>
	    <m:cn>2</m:cn>
	  </m:apply>
	  <m:apply>
	    <m:sum/>
	    <m:bvar>
	      <m:ci>n</m:ci>
	    </m:bvar>
	    <m:lowlimit>
	      <m:cn>0</m:cn>
	    </m:lowlimit>
	    <m:uplimit>
	      <m:apply>
		<m:minus/>
		<m:ci>N</m:ci>
		<m:cn>1</m:cn>
	      </m:apply>
	    </m:uplimit>
	    <m:apply>
	      <m:power/>
	      <m:apply>
		<m:minus/>
		<m:apply>
		  <m:ci type="fn" class="discrete">y</m:ci>
		  <m:ci>n</m:ci>
		</m:apply>
		<m:apply>
		  <m:ci type="fn" class="discrete">x</m:ci>
		  <m:ci>n</m:ci>
		</m:apply>
	      </m:apply>
	      <m:cn>2</m:cn>
	    </m:apply>
	  </m:apply>
	</m:apply>
      </m:math>
      
      Define
      <m:math display="block">
	<m:apply>
	  <m:eq/>
	  <m:ci type="vector">e</m:ci>
	  <m:apply>
	    <m:minus/>
	    <m:ci type="vector">y</m:ci>
	    <m:ci type="vector">x</m:ci>
	  </m:apply>
	</m:apply>
      </m:math>
      as the error vector and minimize
      <m:math>
	<m:ci>
	  <m:msub>
	    <m:mi>l</m:mi>
	    <m:mn>2</m:mn>
	  </m:msub>
	</m:ci>
      </m:math>
      strength of
      <m:math>
	<m:ci type="vector">e</m:ci>
      </m:math>.
    </para>
    
    <section xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="geom">
      <name xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">Geometry</name>
      <para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="geom1">
	<figure xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="fig3">
	  <media xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" type="image/png" src="ortho3.png"/>
	</figure>
      </para>
      
      <exercise xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="exer1">
	<problem xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
	  <para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="exer1para1">
	    How close to choose - to minimize
	    <m:math>
	      <m:apply>
		<m:csymbol definitionURL="http://cnx.rice.edu/cd/cnxmath.ocd#norm"/>
		<m:domainofapplication>
		  <m:cn>2</m:cn>
		</m:domainofapplication>
		<m:ci type="vector">x</m:ci>
	      </m:apply>
	    </m:math>?
	  </para>
	</problem>
	<solution xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
	  <para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="solution1">
	    Choose
	    <m:math>
	      <m:ci type="vector">x</m:ci>
	    </m:math>
	    so that error
	    <m:math>
	      <m:ci type="vector">e</m:ci>
	    </m:math>
	    is ⊥ to
	    <m:math>
	      <m:ci type="vector">x</m:ci>
	    </m:math>
	    and ⊥
	    to the entire subspace
	    <m:math>
	      <m:ci>S</m:ci>
	    </m:math>.
	    <figure xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="fig4">
	      <media xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" type="image/png" src="ortho4.png"/>
	    </figure>
	  </para>
	</solution>
      </exercise>
      
      <section xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="ortho">
	<name xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">Orthogonality Principle</name>
	<para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="ortho1">
	  <m:math>
	    <m:apply>
	      <m:csymbol definitionURL="http://cnx.rice.edu/cd/cnxmath.ocd#norm"/>
	      <m:domainofapplication>
		<m:cn>2</m:cn>
	      </m:domainofapplication>
	      <m:ci type="vector">e</m:ci>
	    </m:apply>
	  </m:math>
	  is minimum when
	  <m:math display="block">
	    <m:apply>
	      <m:eq/>
	      <m:apply>
		<m:scalarproduct/>
		<m:ci type="vector">e</m:ci>
		<m:ci type="vector">x</m:ci>
	      </m:apply>
	      <m:cn>0</m:cn>
	    </m:apply>
	  </m:math>
	  Also have
	  <m:math display="block">
	    <m:apply>
	      <m:forall/>
	      <m:bvar>
		<m:ci type="vector">s</m:ci>
	      </m:bvar>
	      <m:condition>
		<m:apply>
		  <m:in/>
		  <m:ci type="vector">s</m:ci>
		  <m:ci>S</m:ci>
		</m:apply>
	      </m:condition>
	      <m:apply>
		<m:eq/>
		<m:apply>
		  <m:scalarproduct/>
		  <m:ci type="vector">e</m:ci>
		  <m:ci type="vector">s</m:ci>
		</m:apply>
		<m:cn>0</m:cn>
	      </m:apply>
	    </m:apply>
	  </m:math>
	  
	  <note xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
	    Linear algebra lets us convert a distance problem
	    (minimize
	    <m:math>
	      <m:ci>
		<m:msub>
		  <m:mi>l</m:mi>
		  <m:mn>2</m:mn>
		</m:msub>
	      </m:ci>
	    </m:math>
	    distance between 2 vectors) into an angle problem
	    (minimize the inner product between error and subspace).
	  </note>
	</para>
      </section>
    </section>
    
    <para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="terminology">
      We perform an <term xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">orthogonal projection</term> of
      <m:math>
	<m:ci type="vector">y</m:ci>
      </m:math>
      onto
      <m:math>
	<m:ci>S</m:ci>
      </m:math>
      to obtain
      <m:math>
	<m:ci type="vector">x</m:ci>
      </m:math>
      closest to
      <m:math>
	<m:ci type="vector">y</m:ci>
      </m:math>
      in
      <m:math>
	<m:ci>S</m:ci>
      </m:math>.
    </para>
    
    <para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="optimal">
      Now apply the OP to find the optimal approximant
      <m:math>
	<m:apply>
	  <m:in/>
	  <m:ci type="vector">x</m:ci>
	  <m:ci>S</m:ci>
	</m:apply>
      </m:math>
      to
      <m:math>
	<m:ci type="vector">y</m:ci>
      </m:math>.
    </para>

    <para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="recall">
      Recall:
      <m:math display="block">
	<m:apply>
	  <m:in/>
	  <m:ci type="vector">y</m:ci>
	  <m:apply>
	    <m:power/>
	    <m:complexes/>
	    <m:ci>n</m:ci>
	  </m:apply>
	</m:apply>
      </m:math>
      
      <m:math display="block">
	<m:apply>
	  <m:in/>
	  <m:ci type="vector">x</m:ci>
	  <m:apply>
	    <m:subset/>
	    <m:ci>S</m:ci>
	    <m:apply>
	      <m:power/>
	      <m:complexes/>
	      <m:cn>N</m:cn>
	    </m:apply>
	  </m:apply>
	</m:apply>
      </m:math>

      <m:math display="block">
	<m:apply>
	  <m:eq/>
	  <m:ci type="vector">x</m:ci>
	  <m:apply>
	    <m:sum/>
	    <m:bvar>
	      <m:ci>k</m:ci>
	    </m:bvar>
	    <m:lowlimit>
	      <m:cn>0</m:cn>
	    </m:lowlimit>
	    <m:uplimit>
	      <m:apply>
		<m:minus/>
		<m:ci>M</m:ci>
		<m:cn>1</m:cn>
	      </m:apply>
	    </m:uplimit>
	    <m:apply>
	      <m:times/>
	      <m:ci>
		<m:msub>
		  <m:mi>α</m:mi>
		  <m:mi>k</m:mi>
		</m:msub>
	      </m:ci>
	      <m:ci type="vector">
		<m:msub>
		  <m:mi>b</m:mi>
		  <m:mi>k</m:mi>
		</m:msub>
	      </m:ci>
	    </m:apply>
	  </m:apply>
	</m:apply>
      </m:math>
      where 
      <m:math>
	<m:ci type="vector">
	  <m:msub>
	    <m:mi>b</m:mi>
	    <m:mi>k</m:mi>
	  </m:msub>
	</m:ci>
      </m:math>
      is an ONB for
      <m:math>
	<m:ci>S</m:ci>
      </m:math>.
    </para>

    <section xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="purpose">
      <name xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">Purpose</name>
      <para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="purpose1">
	The goal is that given
	<m:math>
	  <m:ci type="vector">y</m:ci>
	</m:math>,
	we must find 
	<m:math>
	  <m:ci>
	    <m:msub>
	      <m:mi>α</m:mi>
	      <m:mi>k</m:mi>
	    </m:msub>
	  </m:ci>
	</m:math>'s.
      </para>

      <section xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="sol">
	<name xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">Solution</name>
	<para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="sol1">
	  Apply OP: Define
	  <m:math display="block">
	    <m:apply>
	      <m:eq/>
	      <m:ci type="vector">e</m:ci>
	      <m:apply>
		<m:minus/>
		<m:ci type="vector">y</m:ci>
		<m:ci type="vector">x</m:ci>
	      </m:apply>
	      <m:apply>
		<m:minus/>
		<m:ci type="vector">y</m:ci>
		<m:apply>
		  <m:sum/>
		  <m:bvar>
		    <m:ci>k</m:ci>
		  </m:bvar>
		  <m:lowlimit/>
		  <m:uplimit/>
		  <m:apply>
		    <m:times/>
		    <m:ci>
		      <m:msub>
			<m:mi>α</m:mi>
			<m:mi>k</m:mi>
		      </m:msub>
		    </m:ci>
		    <m:ci>
		      <m:msub>
			<m:mi>b</m:mi>
			<m:mi>k</m:mi>
		      </m:msub>
		    </m:ci>
		  </m:apply>
		</m:apply>
	      </m:apply>
	    </m:apply>
	  </m:math>
	  Then:
	  <m:math display="block">
	    <m:apply>
	      <m:eq/>
	      <m:cn>0</m:cn>
	      <m:apply>
		<m:scalarproduct/>
		<m:ci type="vector">e</m:ci>
		<m:ci type="vector">x</m:ci>
	      </m:apply>
	      <m:apply>
		<m:scalarproduct/>
		<m:apply>
		  <m:minus/>
		  <m:ci type="vector">y</m:ci>
		  <m:apply>
		    <m:sum/>
		    <m:bvar>
		      <m:ci>k'</m:ci>
		    </m:bvar>
		    <m:lowlimit/>
		    <m:uplimit/>
		    <m:apply>
		      <m:times/>
		      <m:ci>
			<m:msub>
			  <m:mi>α</m:mi>
			  <m:mi>k'</m:mi>
			</m:msub>
		      </m:ci>
		      <m:ci type="vector">
			<m:msub>
			  <m:mi>b</m:mi>
			  <m:mi>k'</m:mi>
			</m:msub>
		      </m:ci>
		    </m:apply>
		  </m:apply>
		</m:apply>
		<m:apply>
		  <m:sum/>
		  <m:bvar>
		    <m:ci>k'</m:ci>
		  </m:bvar>
		  <m:lowlimit/>
		  <m:uplimit/>
		  <m:apply>
		    <m:times/>
		    <m:ci>
		      <m:msub>
			<m:mi>α</m:mi>
			<m:mi>k</m:mi>
		      </m:msub>
		    </m:ci>
		    <m:ci type="vector">
		      <m:msub>
			<m:mi>b</m:mi>
			<m:mi>k</m:mi>
		      </m:msub>
		    </m:ci>
		  </m:apply>
		</m:apply>
	      </m:apply>
	    </m:apply>
	  </m:math>
	  by linearity of OP,
	  <equation xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="eq1">
	    <m:math>
	      <m:apply>
		<m:eq/>
		<m:cn>0</m:cn>
		<m:apply>
		  <m:minus/>
		  <m:apply>
		    <m:scalarproduct/>
		    <m:ci type="vector">y</m:ci>
		    <m:apply>
		      <m:sum/>
		      <m:bvar>
			<m:ci>k'</m:ci>
		      </m:bvar>
		      <m:lowlimit/>
		      <m:uplimit/>
		      <m:apply>
			<m:times/>
			<m:ci>
			  <m:msub>
			    <m:mi>α</m:mi>
			    <m:mi>k</m:mi>
			  </m:msub>
			</m:ci>
			<m:ci type="vector">
			  <m:msub>
			    <m:mi>b</m:mi>
			    <m:mi>k</m:mi>
			  </m:msub>
			</m:ci>
		      </m:apply>
		    </m:apply>
		  </m:apply>
		

		  <m:apply>
		    <m:scalarproduct/>
		    <m:apply>
		      <m:sum/>
		      <m:bvar>
			<m:ci>k'</m:ci>
		      </m:bvar>
		      <m:lowlimit/>
		      <m:uplimit/>
		      <m:apply>
			<m:times/>
			<m:ci>
			  <m:msub>
			    <m:mi>α</m:mi>
			    <m:mi>k'</m:mi>
			  </m:msub>
			</m:ci>
			<m:ci type="vector">
			  <m:msub>
			    <m:mi>b</m:mi>
			    <m:mi>k'</m:mi>
			  </m:msub>
			</m:ci>
		      </m:apply>
		    </m:apply>
		    <m:apply>
		      <m:sum/>
		      <m:bvar>
			<m:ci>k'</m:ci>
		      </m:bvar>
		      <m:lowlimit/>
		      <m:uplimit/>
		      <m:apply>
			<m:times/>
			<m:ci>
			  <m:msub>
			    <m:mi>α</m:mi>
			    <m:mi>k</m:mi>
			  </m:msub>
			</m:ci>
			<m:ci type="vector">
			  <m:msub>
			    <m:mi>b</m:mi>
			    <m:mi>k</m:mi>
			  </m:msub>
			</m:ci>
		      </m:apply>
		    </m:apply>
		  </m:apply>
		</m:apply>
		
		<m:apply>
		  <m:minus/>
		  <m:apply>
		    <m:times/>
		    <m:apply>
		      <m:sum/>
		      <m:bvar>
			<m:ci>k'</m:ci>
		      </m:bvar>
		      <m:lowlimit/>
		      <m:uplimit/>
		      <m:apply>
			<m:conjugate/>
			<m:ci>
			  <m:msub>
			    <m:mi>α</m:mi>
			    <m:mi>k</m:mi>
			  </m:msub>
			</m:ci>
		      </m:apply>
		    </m:apply>
		    <m:apply>
		      <m:scalarproduct/>
		      <m:ci type="vector">y</m:ci>
		      <m:ci type="vector">
			<m:msub>
			  <m:mi>b</m:mi>
			  <m:mi>k</m:mi>
			</m:msub>
		      </m:ci>
		    </m:apply>
		  </m:apply>
		  <m:apply>
		    <m:times/>
		    <m:apply>
		      <m:sum/>
		      <m:bvar>
			<m:ci>k'</m:ci>
		      </m:bvar>
		      <m:lowlimit/>
		      <m:uplimit/>
		      <m:apply>
			<m:conjugate/>
			<m:ci>
			  <m:msub>
			    <m:mi>α</m:mi>
			    <m:mi>k</m:mi>
			  </m:msub>
			</m:ci>
		      </m:apply>
		    </m:apply>
		    <m:apply>
		      <m:scalarproduct/>
		      <m:apply>
			<m:sum/>
			<m:bvar>
			  <m:ci>k'</m:ci>
			</m:bvar>
			<m:lowlimit/>
			<m:uplimit/>
			<m:apply>
			  <m:times/>
			  <m:ci>
			    <m:mi>α</m:mi>
			    <m:mi>k'</m:mi>
			  </m:ci>
			  <m:ci type="vector">
			    <m:mi>b</m:mi>
			    <m:mi>k'</m:mi>
			  </m:ci>
			</m:apply>
		      </m:apply>
		      <m:ci type="vector">
			<m:msub>
			  <m:mi>b</m:mi>
			  <m:mi>k</m:mi>
			</m:msub>
		      </m:ci>
		    </m:apply>
		  </m:apply>
		</m:apply>
		
		<m:apply>
		  <m:times/>
		  <m:apply>
		    <m:sum/>
		    <m:bvar>
		      <m:ci>k'</m:ci>
		    </m:bvar>
		    <m:lowlimit/>
		    <m:uplimit/>
		    <m:apply>
		      <m:conjugate/>
		      <m:ci>
			<m:msub>
			  <m:mi>α</m:mi>
			  <m:mi>k</m:mi>
			</m:msub>
		      </m:ci>
		    </m:apply>
		  </m:apply>
		  <m:apply>
		    <m:minus/>
		    <m:apply>
		      <m:scalarproduct/>
		      <m:ci type="vector">y</m:ci>
		      <m:ci type="vector">
			<m:msub>
			  <m:mi>b</m:mi>
			  <m:mi>k</m:mi>
			</m:msub>
		      </m:ci>
		    </m:apply>
		    <m:apply>
		      <m:scalarproduct/>
		      <m:apply>
			<m:sum/>
			<m:bvar>
			  <m:ci>k'</m:ci>
			</m:bvar>
			<m:lowlimit/>
			<m:uplimit/>
			<m:apply>
			  <m:times/>
			  <m:ci>
			    <m:msub>
			      <m:mi>α</m:mi>
			      <m:mi>k'</m:mi>
			    </m:msub>
			  </m:ci>
			  <m:ci type="vector">
			    <m:msub>
			      <m:mi>b</m:mi>
			      <m:mi>k'</m:mi>
			    </m:msub>
			  </m:ci>
			</m:apply>
		      </m:apply>
		      <m:ci type="vector">
			<m:msub>
			  <m:mi>b</m:mi>
			  <m:mi>k</m:mi>
			</m:msub>
		      </m:ci>
		    </m:apply>
		  </m:apply>
		</m:apply>

		<m:apply>
		  <m:times/>
		  <m:apply>
		    <m:sum/>
		    <m:bvar>
		      <m:ci>k'</m:ci>
		    </m:bvar>
		    <m:lowlimit/>
		    <m:uplimit/>
		    <m:apply>
		      <m:conjugate/>
		      <m:ci>
			<m:msub>
			  <m:mi>α</m:mi>
			  <m:mi>k</m:mi>
			</m:msub>
		      </m:ci>
		    </m:apply>
		  </m:apply>
		  <m:apply>
		    <m:minus/>
		    <m:apply>
		      <m:scalarproduct/>
		      <m:ci type="vector">y</m:ci>
		      <m:ci type="vector">
			<m:msub>
			  <m:mi>b</m:mi>
			  <m:mi>k</m:mi>
			</m:msub>
		      </m:ci>
		    </m:apply>
		    <m:apply>
		      <m:times/>
		      <m:apply>
			<m:sum/>
			<m:bvar>
			  <m:ci>k</m:ci>
			</m:bvar>
			<m:lowlimit/>
			<m:uplimit/>
			<m:ci>
			  <m:msub>
			    <m:mi>α</m:mi>
			    <m:mi>k'</m:mi>
			  </m:msub>
			</m:ci>
		      </m:apply>
		      <m:apply>
			<m:scalarproduct/>
			<m:ci type="vector">
			  <m:msub>
			    <m:mi>b</m:mi>
			    <m:mi>k'</m:mi>
			  </m:msub>
			</m:ci>
			<m:ci type="vector">
			  <m:msub>
			    <m:mi>b</m:mi>
			    <m:mi>k</m:mi>
			  </m:msub>
			</m:ci>
		      </m:apply>
		    </m:apply>
		  </m:apply>
		</m:apply>

		<m:apply>
		  <m:times/>
		  <m:apply>
		    <m:sum/>
		    <m:bvar>
		      <m:ci>k'</m:ci>
		    </m:bvar>
		    <m:lowlimit/>
		    <m:uplimit/>
		    <m:apply>
		      <m:conjugate/>
		      <m:ci>
			<m:msub>
			  <m:mi>α</m:mi>
			  <m:mi>k</m:mi>
			</m:msub>
		      </m:ci>
		    </m:apply>
		  </m:apply>
		  <m:apply>
		    <m:minus/>
		    <m:apply>
		      <m:scalarproduct/>
		      <m:ci type="vector">y</m:ci>
		      <m:ci type="vector">
			<m:msub>
			  <m:mi>b</m:mi>
			  <m:mi>k</m:mi>
			</m:msub>
		      </m:ci>
		    </m:apply>
		    <m:ci>
		      <m:msub>
			<m:mi>α</m:mi>
			<m:mi>k</m:mi>
		      </m:msub>
		    </m:ci>
		  </m:apply>
		</m:apply>
	      </m:apply>
	    </m:math>
	  </equation>
	  
	  There are 2 ways to set to zero:
	  <list xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="setzero" type="enumerated">
	    <item xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
	      All
	      <m:math>
		<m:apply>
		  <m:eq/>
		  <m:ci>
		    <m:msub>
		      <m:mi>α</m:mi>
		      <m:mi>k</m:mi>
		    </m:msub>
		  </m:ci>
		  <m:cn>0</m:cn>
		</m:apply>
	      </m:math>.
	    </item>

	    <item xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
	      <m:math>
		<m:apply>
		  <m:eq/>
		  <m:apply>
		    <m:minus/>
		    <m:apply>
		      <m:scalarproduct/>
		      <m:ci type="vector">y</m:ci>
		      <m:ci type="vector">
			<m:msub>
			  <m:mi>b</m:mi>
			  <m:mi>k</m:mi>
			</m:msub>
		      </m:ci>
		    </m:apply>
		    <m:ci>
		      <m:msub>
			<m:mi>α</m:mi>
			<m:mi>k</m:mi>
		      </m:msub>
		    </m:ci>
		  </m:apply>
		  <m:cn>0</m:cn>
		</m:apply>
	      </m:math>
	      for all <m:math><m:ci>k</m:ci></m:math> chosen.
	    </item>
	  </list>
	  The solution to (2) is simple:
	  <m:math>
	    <m:apply>
	      <m:eq/>
		  <m:apply>
		<m:minus/>
		<m:apply>
		  <m:scalarproduct/>
		  <m:ci type="vector">y</m:ci>
		  <m:ci type="vector">
		    <m:msub>
		      <m:mi>b</m:mi>
		      <m:mi>k</m:mi>
		    </m:msub>
		  </m:ci>
		</m:apply>
		<m:ci>
		  <m:msub>
		    <m:mi>α</m:mi>
		    <m:mi>k</m:mi>
		  </m:msub>
		</m:ci>
	      </m:apply>
	      <m:cn>0</m:cn>
	    </m:apply>
	  </m:math>
	  or
	  <m:math>
	    <m:apply>
	      <m:eq/>
	      <m:ci>
		<m:msub>
		  <m:mi>α</m:mi>
		  <m:mi>k</m:mi>
		</m:msub>
	      </m:ci>
	      <m:apply>
		<m:scalarproduct/>
		<m:ci type="vector">y</m:ci>
		<m:ci type="vector">
		  <m:msub>
		    <m:mi>b</m:mi>
		    <m:mi>k</m:mi>
		  </m:msub>
		</m:ci>
	      </m:apply>
	    </m:apply>
	  </m:math>.
	</para>
      </section>
      
      <section xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="summary">
	<name xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">Summary</name>
	<para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="summary1">
	  The optimal
	  <m:math>
	    <m:ci>
	      <m:msub>
		<m:mi>l</m:mi>
		<m:mn>2</m:mn>
	      </m:msub>
	    </m:ci>
	  </m:math>
	  approximation
	  <m:math>
	    <m:apply>
	      <m:eq/>
	      <m:ci type="vector">x</m:ci>
	      <m:apply>
		<m:sum/>
		<m:bvar>
		  <m:ci>k</m:ci>
		</m:bvar>
		<m:lowlimit/>
		<m:uplimit/>
		<m:apply>
		  <m:times/>
		  <m:ci>
		    <m:msub>
		      <m:mi>α</m:mi>
		      <m:mi>k</m:mi>
		    </m:msub>
		  </m:ci>
		  <m:ci type="vector">
		    <m:msub>
		      <m:mi>b</m:mi>
		      <m:mi>k</m:mi>
		    </m:msub>
		  </m:ci>
		</m:apply>
	      </m:apply>
	    </m:apply>
	  </m:math>
	  to
	  <m:math>
	    <m:ci type="vector">y</m:ci>
	  </m:math>
	  has
	  <m:math display="block">
	    <m:apply>
	      <m:eq/>
	      <m:ci>
		<m:msub>
		  <m:mi>α</m:mi>
		  <m:mi>k</m:mi>
		</m:msub>
	      </m:ci>
	      <m:apply>
		<m:scalarproduct/>
		<m:ci type="vector">y</m:ci>
		<m:ci type="vector">
		  <m:msub>
		    <m:mi>b</m:mi>
		    <m:mi>k</m:mi>
		  </m:msub>
		</m:ci>
	      </m:apply>
	    </m:apply>
	  </m:math>
	  when
	  <m:math>
	    <m:set>
	      <m:ci type="vector">
		<m:msub>
		  <m:mi>b</m:mi>
		  <m:mi>k</m:mi>
		</m:msub>
	      </m:ci>
	    </m:set>
	  </m:math>
	  are an ONB for the subspace.
	</para>
	
	<section xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="summprojections">
	  <name xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">Projections</name>
	  <para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="projections1">
	    <figure xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="fig5">
	      <media xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" type="image/png" src="ortho5.png"/>
	    </figure>

	    In <cnxn xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" target="fig5"/>,
	    <m:math>
	      <m:apply>
		<m:eq/>
		<m:ci type="vector">e</m:ci>
		<m:apply>
		  <m:minus/>
		  <m:ci type="vector">y</m:ci>
		  <m:ci type="vector">x</m:ci>
		</m:apply>
	      </m:apply>
	    </m:math>,
	    <m:math>
	      <m:apply>
		<m:eq/>
		<m:apply>
		  <m:scalarproduct/>
		  <m:ci type="vector">e</m:ci>
		  <m:ci type="vector">x</m:ci>
		</m:apply>
		<m:cn>0</m:cn>
	      </m:apply>
	    </m:math>,
	    <m:math>
	      <m:apply>
		<m:eq/>
		<m:apply>
		  <m:scalarproduct/>
		  <m:ci type="vector">e</m:ci>
		  <m:ci>S</m:ci>
		</m:apply>
		<m:cn>0</m:cn>
	      </m:apply>
	    </m:math>
	    
	    <m:math display="block">
	      <m:apply>
		<m:eq/>
		<m:ci type="vector">x</m:ci>
		<m:apply>
		  <m:sum/>
		  <m:bvar>
		    <m:ci>k</m:ci>
		  </m:bvar>
		  <m:lowlimit>
		    <m:cn>0</m:cn>
		  </m:lowlimit>
		  <m:uplimit>
		    <m:cn>1</m:cn>
		  </m:uplimit>
		  <m:apply>
		    <m:times/>
		    <m:ci>
		      <m:msub>
			<m:mi>α</m:mi>
			<m:mi>k</m:mi>
		      </m:msub>
		    </m:ci>
		    <m:ci type="vector">
		      <m:msub>
			<m:mi>b</m:mi>
			<m:mi>k</m:mi>
		      </m:msub>
		    </m:ci>
		  </m:apply>
		</m:apply>
	      </m:apply>
	    </m:math>
	    where
	    <m:math>
	      <m:ci type="vector">
		<m:msub>
		  <m:mi>b</m:mi>
		  <m:mi>k</m:mi>
		</m:msub>
	      </m:ci>
	    </m:math>
	    is an ONB for <m:math><m:ci>S</m:ci></m:math>
	    <m:math display="block">
	      <m:apply>
		<m:eq/>
		<m:ci>
		  <m:msub>
		    <m:mi>α</m:mi>
		    <m:mi>k</m:mi>
		  </m:msub>
		</m:ci>
		<m:apply>
		  <m:scalarproduct/>
		  <m:ci type="vector">y</m:ci>
		  <m:ci type="vector">
		    <m:msub>
		      <m:mi>b</m:mi>
		      <m:mi>k</m:mi>
		    </m:msub>
		  </m:ci>
		</m:apply>
	      </m:apply>
	    </m:math>

	    <m:math>
	      <m:apply>
		<m:csymbol definitionURL="http://cnx.rice.edu/cd/cnxmath.ocd#norm"/>
		<m:domainofapplication>
		  <m:cn>2</m:cn>
		</m:domainofapplication>
		<m:ci type="vector">e</m:ci>
	      </m:apply>
	    </m:math>
	    is minimized.
	  </para>
	  
	  <example xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="exam2">
	    <para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="exam2para1">
	      <m:math>
		<m:apply>
		  <m:power/>
		  <m:reals/>
		  <m:cn>2</m:cn>
		</m:apply>
	      </m:math>.
	      Find the closest
	      <m:math>
		<m:ci type="vector">x</m:ci>
	      </m:math>
	      to
	      <m:math>
		<m:apply>
		  <m:in/>
		  <m:ci type="vector">y</m:ci>
		  <m:apply>
		    <m:power/>
		    <m:reals/>
		    <m:cn>2</m:cn>
		  </m:apply>
		</m:apply>
	      </m:math>
	      where
	      <m:math>
		<m:ci type="vector">x</m:ci>
	      </m:math>
	      lies on a 45° angled line.
	      
	      <figure xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="fig6">
		<media xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" type="image/png" src="ortho6.png"/>
	      </figure>

	      <list xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="steps" type="enumerated">
		<item xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
		  Find an ONB for <m:math><m:ci>S</m:ci></m:math>,
		  <m:math>
		    <m:apply>
		      <m:eq/>
		      <m:ci>S</m:ci>
		      <m:set>
			<m:apply>
			  <m:forall/>
			  <m:bvar>
			    <m:ci>a</m:ci>
			  </m:bvar>
			  <m:condition>
			    <m:apply>
			      <m:in/>
			      <m:ci>a</m:ci>
			      <m:reals/>
			    </m:apply>
			  </m:condition>
			  <m:apply>
			    <m:eq/>
			    <m:ci type="vector">x</m:ci>
			    <m:vector>
			      <m:ci>a</m:ci>
			      <m:ci>a</m:ci>
			    </m:vector>
			  </m:apply>
			</m:apply>
		      </m:set>
		    </m:apply>
		  </m:math>.
		  ONB:
		  <m:math>
		    <m:apply>
		      <m:eq/>
		      <m:ci>
			<m:msub>
			  <m:mi>b</m:mi>
			  <m:mn>0</m:mn>
			</m:msub>
		      </m:ci>
		      <m:apply>
			<m:divide/>
			<m:vector>
			  <m:cn>1</m:cn>
			  <m:cn>1</m:cn>
			</m:vector>
			<m:apply>
			  <m:root/>
			  <m:degree/>
			  <m:cn>2</m:cn>
			</m:apply>
		      </m:apply>
		    </m:apply>
		  </m:math>.
		</item>
		
		<item xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
		  Optimal
		  <m:math display="block">
		    <m:apply>
		      <m:eq/>
		      <m:ci type="vector">x</m:ci>
		      <m:apply>
			<m:sum/>
			<m:bvar>
			  <m:ci>k</m:ci>
			</m:bvar>
			<m:lowlimit>
			  <m:cn>0</m:cn>
			</m:lowlimit>
			<m:uplimit>
			  <m:cn>0</m:cn>
			</m:uplimit>
			<m:apply>
			  <m:times/>
			  <m:ci>
			    <m:msub>
			      <m:mi>α</m:mi>
			      <m:mi>k</m:mi>
			    </m:msub>
			  </m:ci>
			  <m:ci type="vector">
			    <m:msub>
			      <m:mi>b</m:mi>
			      <m:mi>k</m:mi>
			    </m:msub>
			  </m:ci>
			</m:apply>
		      </m:apply>
		      <m:apply>
			<m:times/>
			<m:ci>
			  <m:msub>
			    <m:mi>α</m:mi>
			    <m:mn>0</m:mn>
			  </m:msub>
			</m:ci>
			<m:ci type="vector">
			  <m:msub>
			    <m:mi>b</m:mi>
			    <m:mn>0</m:mn>
			  </m:msub>
			</m:ci>
		      </m:apply>
		    </m:apply>
		  </m:math>

		  <m:math display="block">
		    <m:apply>
		      <m:eq/>
		      <m:ci>
			<m:msub>
			  <m:mi>α</m:mi>
			  <m:mn>0</m:mn>
			</m:msub>
		      </m:ci>
		      <m:apply>
			<m:scalarproduct/>
			<m:ci type="vector">y</m:ci>
			<m:ci type="vector">
			  <m:msub>
			    <m:mi>b</m:mi>
			    <m:mn>0</m:mn>
			  </m:msub>
			</m:ci>
		      </m:apply>
		    </m:apply>
		  </m:math>
		</item>
	      </list>
	      For example,
	      <figure xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="fig7">
		<media xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" type="image/png" src="ortho7.png"/>
	      </figure>
	      in <cnxn xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" target="fig7"/>,
	      
	      <m:math display="block">
		<m:apply>
		  <m:eq/>
		  <m:ci type="vector">y</m:ci>
		  <m:vector>
		    <m:cn>3</m:cn>
		    <m:cn>7</m:cn>
		  </m:vector>
		</m:apply>
	      </m:math>

	      <m:math display="block">
		<m:apply>
		  <m:eq/>
		  <m:ci>
		    <m:msub>
		      <m:mi>α</m:mi>
		      <m:mn>0</m:mn>
		    </m:msub>
		  </m:ci>
		  <m:apply>
		    <m:times/>
		    <m:apply>
		      <m:divide/>
		      <m:cn>1</m:cn>
		      <m:apply>
			<m:root/>
			<m:degree/>
			<m:cn>2</m:cn>
		      </m:apply>
		    </m:apply>
		    <m:matrix>
		      <m:matrixrow>
			<m:cn>1</m:cn>
			<m:cn>1</m:cn>
		      </m:matrixrow>
		    </m:matrix>
		    <m:vector>
		      <m:cn>3</m:cn>
		      <m:cn>7</m:cn>
		    </m:vector>
		  </m:apply>
		  <m:apply>
		    <m:divide/>
		    <m:cn>10</m:cn>
		    <m:apply>
		      <m:root/>
		      <m:degree/>
		      <m:cn>2</m:cn>
		    </m:apply>
		  </m:apply>
		</m:apply>
	      </m:math>

	      <m:math display="block">
		<m:apply>
		  <m:eq/>
		  <m:ci type="vector">x</m:ci>
		  <m:apply>
		    <m:times/>
		    <m:apply>
		      <m:divide/>
		      <m:cn>10</m:cn>
		      <m:apply>
			<m:root/>
			<m:degree/>
			<m:cn>2</m:cn>
		      </m:apply>
		    </m:apply>
		    <m:apply>
		      <m:divide/>
		      <m:vector>
			<m:cn>1</m:cn>
			<m:cn>1</m:cn>
		      </m:vector>
		      <m:apply>
			<m:root/>
			<m:degree/>
			<m:cn>2</m:cn>
		      </m:apply>
		    </m:apply>
		  </m:apply>
		  <m:vector>
		    <m:cn>5</m:cn>
		    <m:cn>5</m:cn>
		  </m:vector>
		</m:apply>
	      </m:math>
	    </para>
	  </example>

	  <example xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="exam3">
	    <para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="exam3para1">
	      Given an ecg signal,
	      <m:math>
		<m:apply>
		  <m:in/>
		  <m:ci type="vector">y</m:ci>
		  <m:apply>
		    <m:power/>
		    <m:complexes/>
		    <m:ci>N</m:ci>
		  </m:apply>
		</m:apply>
	      </m:math>
	      that is a smooth signal contaminated by noise

	      <figure xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="fig8">
		<media xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" type="image/png" src="ortho8.png"/>
	      </figure>
	      
	      we would like to make an estimate
	      <m:math>
		<m:ci type="vector">
		  <m:mover accent="true">
		    <m:mi>y</m:mi>
		    <m:mo>̂</m:mo>
		  </m:mover>
		</m:ci>
	      </m:math>
	      that is smooth.

	      <list xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="stepsol" type="named-item">
		<item xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
		  <name xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">Step1</name>
		  Signal model:
		  <m:math display="block">
		    <m:apply>
		      <m:eq/>
		      <m:ci type="vector">y</m:ci>
		      <m:apply>
			<m:plus/>
			<m:ci type="vector">x</m:ci>
			<m:ci type="vector">n</m:ci>
		      </m:apply>
		    </m:apply>
		  </m:math>
		  
		  <m:math>
		    <m:apply>
		      <m:in/>
		      <m:ci type="vector">x</m:ci>
		      <m:ci>S</m:ci>
		    </m:apply>
		  </m:math>,
		  subspace of smooth functions. Find an appropriate
		  subspace. For example,
		  <m:math>
		    <m:apply>
		      <m:in/>
		      <m:ci type="vector">x</m:ci>
		      <m:ci>S</m:ci>
		    </m:apply>
		  </m:math>
		  spanned by the 1st M≪N DCT basis vectors (lowest
		  frequencies).
		  
		  <m:math display="block">
		    <m:apply>
		      <m:eq/>
		      <m:ci type="vector">x</m:ci>
		      <m:apply>
			<m:sum/>
			<m:bvar>
			  <m:ci>k</m:ci>
			</m:bvar>
			<m:lowlimit>
			  <m:cn>0</m:cn>
			</m:lowlimit>
			<m:uplimit>
			  <m:apply>
			    <m:minus/>
			    <m:ci>M</m:ci>
			    <m:cn>1</m:cn>
			  </m:apply>
			</m:uplimit>
			<m:apply>
			  <m:times/>
			  <m:ci>
			    <m:msub>
			      <m:mi>α</m:mi>
			      <m:mi>k</m:mi>
			    </m:msub>
			  </m:ci>
			  <m:ci type="vector">
			    <m:msub>
			      <m:mi>b</m:mi>
			      <m:mi>k</m:mi>
			    </m:msub>
			  </m:ci>
			</m:apply>
		      </m:apply>
		    </m:apply>
		  </m:math>
		  
		  <figure xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="fig9">
		    <media xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" type="image/png" src="ortho9.png"/>
		    <caption xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
		      <m:math>
			<m:ci type="vector">
			  <m:msub>
			    <m:mi>b</m:mi>
			    <m:mi>k</m:mi>
			  </m:msub>
			</m:ci>
		      </m:math>
		      in <m:math><m:ci>S</m:ci></m:math>
		    </caption>
		  </figure>

		  <figure xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="fig10">
		    <media xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" type="image/png" src="ortho10.png"/>
		    <caption xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
		      <m:math>
			<m:ci type="vector">
			  <m:msub>
			    <m:mi>b</m:mi>
			    <m:mi>k</m:mi>
			  </m:msub>
			</m:ci>
		      </m:math>
		      not in <m:math><m:ci>S</m:ci></m:math>
		    </caption>
		  </figure>
		  
		  Noise model: Assume for example, that
		  <m:math>
		    <m:ci type="vector">n</m:ci>
		  </m:math>
		  is zero-mean Gaussian noise (i.i.d.).
		  
		  <figure xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="fig11">
		    <media xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" type="image/png" src="ortho11.png"/>
		    <caption xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
		      Note that there is more resemblence with a
		      vector not in <m:math><m:ci>S</m:ci></m:math>
		      that to one that is.
		      </caption>
		  </figure>
		</item>

		<item xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
		  <name xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">Step2</name>
		  ⊥ project
		  <m:math>
		    <m:ci type="vector">y</m:ci>
		  </m:math>
		  onto <m:math><m:ci>S</m:ci></m:math> to get estimate
		  <m:math>
		    <m:ci type="vector">
		      <m:mover accent="true">
			<m:mi>y</m:mi>
			<m:mo>̂</m:mo>
		      </m:mover>
		    </m:ci>
		  </m:math> (In statistical DSP, this is called the
		  inear minimum mean squared error estimate - LMMSE
		  est.).
		  
		  <m:math display="block">
		    <m:apply>
		      <m:eq/>
		      <m:ci type="vector">
			<m:mover accent="true">
			  <m:mi>y</m:mi>
			  <m:mo>̂</m:mo>
			</m:mover>
		      </m:ci>
		      <m:apply>
			<m:sum/>
			<m:bvar>
			  <m:ci>k</m:ci>
			</m:bvar>
			<m:lowlimit>
			  <m:cn>0</m:cn>
			</m:lowlimit>
			<m:uplimit>
			  <m:apply>
			    <m:minus/>
			    <m:ci>N</m:ci>
			    <m:cn>1</m:cn>
			  </m:apply>
			</m:uplimit>
			<m:apply>
			  <m:times/>
			  <m:ci>
			    <m:msub>
			      <m:mi>β</m:mi>
			      <m:mi>k</m:mi>
			    </m:msub>
			  </m:ci>
			  <m:ci type="vector">
			    <m:msub>
			      <m:mi>b</m:mi>
			      <m:mi>k</m:mi>
			    </m:msub>
			  </m:ci>
			</m:apply>
		      </m:apply>
		    </m:apply>
		  </m:math>
		  
		  <m:math display="block">
		    <m:apply>
		      <m:eq/>
		      <m:ci>
			<m:msub>
			  <m:mi>β</m:mi>
			  <m:mi>k</m:mi>
			</m:msub>
		      </m:ci>
		      <m:apply>
			<m:scalarproduct/>
			<m:ci type="vector">y</m:ci>
			<m:ci type="vector">
			  <m:msub>
			    <m:mi>b</m:mi>
			    <m:mi>k</m:mi>
			  </m:msub>
			</m:ci>
		      </m:apply>
		    </m:apply>
		  </m:math>

		  <figure xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="fig12">
		    <media xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" type="image/png" src="ortho12.png"/>
		    <caption xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
		      <m:math>
			<m:apply>
			  <m:eq/>
			  <m:ci type="vector">y</m:ci>
			  <m:apply>
			    <m:plus/>
			    <m:ci type="vector">x</m:ci>
			    <m:ci type="vector">n</m:ci>
			  </m:apply>
			</m:apply>
		      </m:math>
		    </caption>
		  </figure>
		</item>
	      </list>
	    </para>
	  </example>
	  
	  <exercise xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="exer2">
	    <problem xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/">
	      <section xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="a">
		<para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="a1">
		  Why is
		  <m:math>
		    <m:apply>
		      <m:neq/>
		      <m:ci type="vector">
			<m:mover accent="true">
			  <m:mi>y</m:mi>
			  <m:mo>̂</m:mo>
			</m:mover>
		      </m:ci>
		      <m:ci type="vector">x</m:ci>
		    </m:apply>
		  </m:math>?
		</para>
	      </section>
	      <section xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="b">
		<para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="b1">
		  Is
		  <m:math>
		    <m:ci type="vector">
		      <m:mover accent="true">
			<m:mi>y</m:mi>
			<m:mo>̂</m:mo>
		      </m:mover>
		    </m:ci>
		  </m:math>
		  closer to <m:math><m:ci type="vector">x</m:ci></m:math> than <m:math><m:ci type="vector">y</m:ci></m:math> is?
		</para>
	      </section>
	      <section xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="c">
		<para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="c1">
		  Using the DCT basis, could you solve this problem in matlab?
		</para>
	      </section>
	      <section xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="d">
		<para xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="d1">
		  How do you choose the subspace and the ONB?
		</para>
	      </section>
	    </problem>
	  </exercise>
	</section>
      </section>
    </section>
  </content>
</document>
