<?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="m10788">

  <name>Reconstruction</name>

  <metadata>
  <md:version>2.4</md:version>
  <md:created>2002/08/05</md:created>
  <md:revised>2005/06/24 12:06:51.014 GMT-5</md:revised>
  <md:authorlist>
      <md:author id="jrom">
      <md:firstname>Justin</md:firstname>
      
      <md:surname>Romberg</md:surname>
      <md:email>jrom@rice.edu</md:email>
    </md:author>
  </md:authorlist>

  <md:maintainerlist>
    <md:maintainer id="prash">
      <md:firstname>Prashant</md:firstname>
      
      <md:surname>Singh</md:surname>
      <md:email>prash@ece.rice.edu</md:email>
    </md:maintainer>
    <md:maintainer id="richb">
      <md:firstname>Richard</md:firstname>
      <md:othername>G.</md:othername>
      <md:surname>Baraniuk</md:surname>
      <md:email>richb@rice.edu</md:email>
    </md:maintainer>
    <md:maintainer id="mariyah">
      <md:firstname>Mariyah</md:firstname>
      
      <md:surname>Poonawala</md:surname>
      <md:email>mariyah@rice.edu</md:email>
    </md:maintainer>
  </md:maintainerlist>
  
  <md:keywordlist>
    <md:keyword>interpolation</md:keyword>
    <md:keyword>reconstruction</md:keyword>
  </md:keywordlist>

  <md:abstract>This module describes reconstruction (a.k.a. interpolation).</md:abstract>
</metadata>

  <content>
    <section id="int">
      <name>Introduction</name>
      <para id="para1">
	The reconstruction process begins by taking a sampled signal,
	which will be in discrete time, and performing a few
	operations in order to convert them into continuous-time and,
	with any luck, into an exact copy of the original signal. A
	basic method used to reconstruct a
	<m:math>
	  <m:interval closure="closed-closed">
	    <m:apply>
	      <m:minus/>
	      <m:pi/>
	    </m:apply>
	    <m:pi/>
	  </m:interval>
	</m:math> bandlimited signal from its samples on the integer
	is to do the following steps:

	<list id="list1">
	  <item>
	    turn the sample sequence 
	    <m:math>
	      <m:apply>
		<m:ci type="fn" class="discrete">
		  <m:msub><m:mi>f</m:mi><m:mi>s</m:mi></m:msub>
		</m:ci>
		<m:ci>n</m:ci>
	      </m:apply>
	    </m:math> into an impulse train 
	    <m:math>
	      <m:apply>
		<m:ci type="fn">
		  <m:msub><m:mi>f</m:mi><m:mi>imp</m:mi></m:msub>
		</m:ci>
		<m:ci>t</m:ci>
	      </m:apply>
	    </m:math>
	  </item>
	  
	  <item>
	    lowpass filter 
	    <m:math>
	      <m:apply>
		<m:ci type="fn">
		  <m:msub><m:mi>f</m:mi><m:mi>imp</m:mi></m:msub>
		</m:ci>
		<m:ci>t</m:ci>
	      </m:apply>
	    </m:math> to get the reconstruction 
	    <m:math>
	      <m:apply>
		<m:ci type="fn">
		  <m:mover accent="true">
		    <m:mi>f</m:mi>
		    <m:mo>~</m:mo>
		  </m:mover>
		</m:ci>
		<m:ci>t</m:ci>
	      </m:apply>
	    </m:math> (cutoff freq. = π)
	  </item>
	</list>
      </para>
      
      <figure id="fig1">
	<media type="image/png" src="recon_blk.png"/>
	<caption>
	  Reconstruction block diagram with lowpass filter (LPF).
	</caption>
      </figure>       

      <para id="para2">
	The lowpass filter's impulse response is 
	<m:math>
	  <m:apply>
	    <m:ci type="fn">g</m:ci>
	    <m:ci>t</m:ci>
	  </m:apply>
	</m:math>.  The following equations allow us to reconstruct
	our signal (<cnxn target="fig2"/>),
	<m:math>
	  <m:apply>
	    <m:ci type="fn">
	      <m:mover accent="true">
		<m:mi>f</m:mi>
		<m:mo>~</m:mo>
	      </m:mover>
	    </m:ci>
	    <m:ci>t</m:ci>
	  </m:apply>
	</m:math>.

	<equation id="eq1">
	  <m:math>
	    <m:apply>
	      <m:eq/>
	      <m:apply>
		<m:ci type="fn">
		  <m:mover accent="true">
		    <m:mi>f</m:mi>
		    <m:mo>~</m:mo>
		  </m:mover>
		</m:ci>
		<m:ci>t</m:ci>
	      </m:apply>
	      <m:apply>
		<m:times/>
		<m:apply>
		  <m:ci type="fn">g</m:ci>
		  <m:ci>t</m:ci>
		</m:apply>
		<m:apply>
		  <m:ci type="fn">
		    <m:msub><m:mi>f</m:mi><m:mi>imp</m:mi></m:msub>
		  </m:ci>
		  <m:ci>t</m:ci>
		</m:apply>
	      </m:apply>
	      <m:apply>
		<m:times/>
		<m:apply>
		  <m:ci type="fn">g</m:ci>
		  <m:ci>t</m:ci>
		</m:apply>
		<m:apply>
		  <m:sum/>
		  <m:bvar><m:ci>n</m:ci></m:bvar>
		  <m:lowlimit>
		    <m:apply>
		      <m:minus/>
		      <m:infinity/>
		    </m:apply>
		  </m:lowlimit>
		  <m:uplimit>
		    <m:infinity/>
		  </m:uplimit>
		  <m:apply>
		    <m:times/>
		    <m:apply>
		      <m:ci type="fn" class="discrete">
			<m:msub><m:mi>f</m:mi><m:mi>s</m:mi></m:msub>
		      </m:ci>
		      <m:ci>n</m:ci>
		    </m:apply>
		    <m:apply>
		      <m:ci type="fn">δ</m:ci>
		      <m:apply>
			<m:minus/>
			<m:ci>t</m:ci>
			<m:ci>n</m:ci>
		      </m:apply>
		    </m:apply>
		  </m:apply>
		</m:apply>
	      </m:apply>
	      <m:apply>
		<m:ci type="fn">
		  <m:mover accent="true">
		    <m:mi>f</m:mi>
		    <m:mo>~</m:mo>
		  </m:mover>
		</m:ci>
		<m:ci>t</m:ci>
	      </m:apply>
	      <m:apply>
		<m:sum/>
		<m:bvar><m:ci>n</m:ci></m:bvar>
		<m:lowlimit>
		  <m:apply>
		    <m:minus/>
		    <m:infinity/>
		  </m:apply>
		</m:lowlimit>
		<m:uplimit>
		  <m:infinity/>
		</m:uplimit>
		<m:apply>
		  <m:times/>
		  <m:apply>
		    <m:ci type="fn" class="discrete">
		      <m:msub><m:mi>f</m:mi><m:mi>s</m:mi></m:msub>
		    </m:ci>
		    <m:ci>n</m:ci>
		  </m:apply>
		  <m:apply>
		    <m:times/>
		    <m:apply>
		      <m:ci type="fn">g</m:ci>
		      <m:ci>t</m:ci>
		    </m:apply>
		    <m:apply>
		      <m:ci type="fn">δ</m:ci>
		      <m:apply>
			<m:minus/>
			<m:ci>t</m:ci>
			<m:ci>n</m:ci>
		      </m:apply>
		    </m:apply>
		  </m:apply>
		</m:apply>
	      </m:apply>
	      <m:apply>
		<m:sum/>
		<m:bvar><m:ci>n</m:ci></m:bvar>
		<m:lowlimit>
		  <m:apply>
		    <m:minus/>
		    <m:infinity/>
		  </m:apply>
		</m:lowlimit>
		<m:uplimit>
		  <m:infinity/>
		</m:uplimit>
		<m:apply>
		  <m:times/>
		  <m:apply>
		    <m:ci type="fn" class="discrete">
		      <m:msub><m:mi>f</m:mi><m:mi>s</m:mi></m:msub>
		    </m:ci>
		    <m:ci>n</m:ci>
		  </m:apply>
		  <m:apply>
		    <m:ci type="fn">g</m:ci>
		    <m:apply>
		      <m:minus/>
		      <m:ci>t</m:ci>
		      <m:ci>n</m:ci>
		    </m:apply>
		  </m:apply>
		</m:apply>
	      </m:apply>
	    </m:apply>
	  </m:math>
	</equation>
      </para>

      
      <figure id="fig2">
	<media type="image/png" src="recon_blk2.png"/>
	<caption/>
      </figure> 
      

      <section id="sec2">
	<name>Examples of Filters g</name>

	<example id="example1">
	  <name>Zero Order Hold</name>
	  <para id="exam1para1">
	    This type "filter" is one of the most basic types of
	    reconstruction filters.  It simply holds the value that is
	    in 
	    <m:math> 
	      <m:apply>
		<m:ci type="fn" class="discrete">
		  <m:msub><m:mi>f</m:mi><m:mi>s</m:mi></m:msub>
		</m:ci>
		<m:ci>n</m:ci>
	      </m:apply>
	    </m:math> for <m:math><m:ci>τ</m:ci></m:math> seconds.
	    This creates a block or step like function where each
	    value of the pulse in 
	    <m:math> 
	      <m:apply>
		<m:ci type="fn" class="discrete">
		  <m:msub><m:mi>f</m:mi><m:mi>s</m:mi></m:msub>
		</m:ci>
		<m:ci>n</m:ci>
	      </m:apply>
	    </m:math> is simply dragged over to the next pulse.  The
	    equations and <cnxn target="fig3">illustrations
	    below</cnxn> depict how this reconstruction filter works
	    with the following <m:math><m:ci>g</m:ci></m:math>:

	    <m:math display="block">
	      <m:apply>
		<m:eq/>
		<m:apply>
		  <m:ci type="fn">g</m:ci>
		  <m:ci>t</m:ci>
		</m:apply>
		<m:apply>
		  <m:piecewise>
		    <m:piece>
		      <m:cn>1</m:cn>
		      <m:apply>
			<m:lt/>
			<m:apply>
			  <m:lt/>
			  <m:cn>0</m:cn>
			  <m:ci>t</m:ci>
			</m:apply>
			<m:ci>τ</m:ci>
		      </m:apply>
		    </m:piece>
		    <m:otherwise>
		      <m:cn>0</m:cn>
		    </m:otherwise>
		  </m:piecewise>
		</m:apply>
	      </m:apply>
	    </m:math>

	    <equation id="eq2">
	      <m:math> 
		<m:apply>
		  <m:eq/>
		  <m:apply>
		    <m:ci type="fn" class="discrete">
		      <m:msub><m:mi>f</m:mi><m:mi>s</m:mi></m:msub>
		    </m:ci>
		    <m:ci>n</m:ci>
		  </m:apply>
		  <m:apply>
		    <m:sum/>
		    <m:bvar><m:ci>n</m:ci></m:bvar>
		    <m:lowlimit>
		      <m:apply>
			<m:minus/>
			<m:infinity/>
		      </m:apply>
		    </m:lowlimit>
		    <m:uplimit>
		      <m:infinity/>
		    </m:uplimit>
		    <m:apply>
		      <m:times/>
		      <m:apply>
			<m:ci type="fn" class="discrete">
			  <m:msub><m:mi>f</m:mi><m:mi>s</m:mi></m:msub>
			</m:ci>
			<m:ci>n</m:ci>
		      </m:apply>
		      <m:apply>
			<m:ci type="fn">g</m:ci>
			<m:apply>
			  <m:minus/>
			  <m:ci>t</m:ci>
			  <m:ci>n</m:ci>
			</m:apply>
		      </m:apply>
		    </m:apply>
		  </m:apply>
		</m:apply>
	      </m:math>
	    </equation>
	  </para>
	  
	  <figure orient="horizontal" id="fig3">
	    <subfigure id="s1_fig3">
	      <media type="image/png" src="receg_f1.png"/>
	    </subfigure>
	    <subfigure id="s2_fig3">
	      <media type="image/png" src="receg_f2.png"/>
	    </subfigure>
	    <caption>
	      Zero Order Hold
	    </caption>
	  </figure> 

	  <para id="exam1para1a">
	    <note type="question">
	      How does 
	      <m:math>
		<m:apply>
		  <m:ci type="fn">
		    <m:mover accent="true">
		      <m:mi>f</m:mi>
		      <m:mo>~</m:mo>
		    </m:mover>
		  </m:ci>
		  <m:ci>t</m:ci>
		</m:apply>
	      </m:math> reconstructed with a zero order hold compare
	      to the original  
	      <m:math>
		<m:apply>
		  <m:ci type="fn">f</m:ci>
		  <m:ci>t</m:ci>
		</m:apply>
	      </m:math> in the frequency domain?
	    </note>
	  </para>	
	</example>

	<example id="example2">
	  <name>Nth Order Hold</name>
	  <para id="exam2para1">
	    Here we will look at a few quick examples of variances to
	    the Zero Order Hold filter discussed in the previous
	    example.
	  </para>
	  
	  <figure orient="vertical" id="fig4">
	    <subfigure id="s1_fig4">
	      <media type="image/png" src="recf_f1.png"/>
	      <caption>
		First Order Hold
	      </caption>
	    </subfigure>
	    <subfigure id="s2_fig4">
	      <media type="image/png" src="recf_f2.png"/>
	      <caption>
		Second Order Hold
	      </caption>
	    </subfigure>
	    <subfigure id="s3_fig4">
	      <media type="image/png" src="recf_f3.png"/>
	      <caption>
		∞ Order Hold
	      </caption>
	    </subfigure>
	    <caption>
	      Nth Order Hold Examples (nth order hold is equal to an
	      nth order B-spline)
	    </caption>
	  </figure> 
	</example>
      </section>
    </section>


    <section id="sec3">
      <name>Ultimate Reconstruction Filter</name>
      
      <para id="exe1para1">
	<note type="question">
	  What is the ultimate reconstruction filter?
	</note>
      </para>

      <para id="exe1para2">
	Recall that (see <cnxn target="fig8"/>)
      
      <figure id="fig8">
	<media type="image/png" src="recon_blk3.png"/>
	<caption>
	  Our current reconstruction block diagram.  Note that each of
	  these signals has its own corresponding CTFT or DTFT.
	</caption>
      </figure>
      </para>

      <para id="exe1para3">
	If 
	<m:math>
	  <m:apply>
	    <m:ci type="fn">G</m:ci>
	    <m:apply>
	      <m:times/>
	      <m:imaginaryi/>
	      <m:ci>ω</m:ci>
	    </m:apply>
	  </m:apply>
	</m:math> has the following shape (<cnxn target="fig9"/>):
      
      <figure id="fig9">
	<media type="image/png" src="square_wv.png"/>
	<caption>
	  Ideal lowpass filter
	</caption>
      </figure>
      </para>
      
      <para id="exe1para3a">
	then 
	<m:math display="block">
	  <m:apply>
	    <m:eq/>
	    <m:apply>
	      <m:ci type="fn">
		<m:mover accent="true">
		  <m:mi>f</m:mi>
		  <m:mo>~</m:mo>
		</m:mover>
	      </m:ci>
	      <m:ci>t</m:ci>
	    </m:apply>
	    <m:apply>
	      <m:ci type="fn">f</m:ci>
	      <m:ci>t</m:ci>
	    </m:apply>
	  </m:apply>
	</m:math>

	Therefore, an ideal lowpass filter will give us perfect
	reconstruction!
      </para>

      <para id="exe1para4">
	In the time domain, impulse response 
	<equation id="eq3">
	  <m:math>
	    <m:apply>
	      <m:eq/>
	      <m:apply>
		<m:ci type="fn">g</m:ci>
		<m:ci>t</m:ci>
	      </m:apply>
	      <m:apply>
		<m:divide/>
		<m:apply>
		  <m:sin/>
		  <m:apply>
		    <m:times/>
		    <m:pi/>
		    <m:ci>t</m:ci>
		  </m:apply>
		</m:apply>
		<m:apply>
		  <m:times/>
		  <m:pi/>
		  <m:ci>t</m:ci>
		</m:apply>
	      </m:apply>
	    </m:apply>
	  </m:math>
	</equation>

	<equation id="eq4">
	  <m:math>
	    <m:apply>
	      <m:eq/>
	      <m:apply>
		<m:ci type="fn">
		  <m:mover accent="true">
		    <m:mi>f</m:mi>
		    <m:mo>~</m:mo>
		  </m:mover>
		</m:ci>
		<m:ci>t</m:ci>
	      </m:apply>
	      <m:apply>
		<m:sum/>
		<m:bvar><m:ci>n</m:ci></m:bvar>
		<m:lowlimit>
		  <m:apply>
		    <m:minus/>
		    <m:infinity/>
		  </m:apply>
		</m:lowlimit>
		<m:uplimit>
		  <m:infinity/>
		</m:uplimit>
		<m:apply>
		  <m:times/>
		  <m:apply>
		    <m:ci type="fn" class="discrete">
		      <m:msub><m:mi>f</m:mi><m:mi>s</m:mi></m:msub>
		    </m:ci>
		    <m:ci>n</m:ci>
		  </m:apply>
		  <m:apply>
		    <m:ci type="fn">g</m:ci>
		    <m:apply>
		      <m:minus/>
		      <m:ci>t</m:ci>
		      <m:ci>n</m:ci>
		    </m:apply>
		  </m:apply>
		</m:apply>
	      </m:apply>
	      <m:apply>
		<m:sum/>
		<m:bvar><m:ci>n</m:ci></m:bvar>
		<m:lowlimit>
		  <m:apply>
		    <m:minus/>
		    <m:infinity/>
		  </m:apply>
		</m:lowlimit>
		<m:uplimit>
		  <m:infinity/>
		</m:uplimit>
		<m:apply>
		  <m:times/>
		  <m:apply>
		    <m:ci type="fn" class="discrete">
		      <m:msub><m:mi>f</m:mi><m:mi>s</m:mi></m:msub>
		    </m:ci>
		    <m:ci>n</m:ci>
		  </m:apply>
		  <m:apply>
		    <m:divide/>
		    <m:apply>
		      <m:sin/>
		      <m:apply>
			<m:times/>
			<m:pi/>
			<m:apply>
			  <m:minus/>
			  <m:ci>t</m:ci>
			  <m:ci>n</m:ci>
			</m:apply>
		      </m:apply>
		    </m:apply>
		    <m:apply>
		      <m:times/>
		      <m:pi/>
		      <m:apply>
			<m:minus/>
			<m:ci>t</m:ci>
			<m:ci>n</m:ci>
		      </m:apply>
		    </m:apply>
		  </m:apply>
		</m:apply>
	      </m:apply>
	      <m:apply>
		<m:ci type="fn">f</m:ci>
		<m:ci>t</m:ci>
	      </m:apply>
	    </m:apply>
	  </m:math>
	</equation>
      </para>      
    </section>


    <section id="sec4">
      <name>Amazing Conclusions</name>
      <para id="para9">
	If 
	<m:math>
	  <m:apply>
	    <m:ci type="fn">f</m:ci>
	    <m:ci>t</m:ci>
	  </m:apply>
	</m:math> is bandlimited to 
	<m:math>
	  <m:interval closure="closed-closed">
	    <m:apply>
	      <m:minus/>
	      <m:pi/>
	    </m:apply>
	    <m:pi/>
	  </m:interval>
	</m:math>, it can be reconstructed perfectly from its samples on
	the integers 
	<m:math>
	  <m:apply>
	    <m:eq/>
	    <m:apply>
	      <m:ci type="fn" class="discrete">
		<m:msub><m:mi>f</m:mi><m:mi>s</m:mi></m:msub>
	      </m:ci>
	      <m:ci>n</m:ci>
	    </m:apply>
	    <m:apply>
	      <m:csymbol definitionURL="http://cnx.rice.edu/cd/cnxmath.ocd#evaluateat"/>
	      <m:bvar><m:ci>t</m:ci></m:bvar>
	      <m:lowlimit><m:ci>n</m:ci></m:lowlimit>
	      <m:apply>
		<m:ci type="fn">f</m:ci>
		<m:ci>t</m:ci>
	      </m:apply>
	    </m:apply>
	  </m:apply>
	</m:math>

	<equation id="eq5">
	  <m:math>
	    <m:apply>
	      <m:eq/>
	      <m:apply>
		<m:ci type="fn">f</m:ci>
		<m:ci>t</m:ci>
	      </m:apply>
	      <m:apply>
		<m:sum/>
		<m:bvar><m:ci>n</m:ci></m:bvar>
		<m:lowlimit>
		  <m:apply>
		    <m:minus/>
		    <m:infinity/>
		  </m:apply>
		</m:lowlimit>
		<m:uplimit>
		  <m:infinity/>
		</m:uplimit>
		<m:apply>
		  <m:times/>
		  <m:apply>
		    <m:ci type="fn" class="discrete">
		      <m:msub><m:mi>f</m:mi><m:mi>s</m:mi></m:msub>
		    </m:ci>
		    <m:ci>n</m:ci>
		  </m:apply>
		  <m:apply>
		    <m:divide/>
		    <m:apply>
		      <m:sin/>
		      <m:apply>
			<m:times/>
			<m:pi/>
			<m:apply>
			  <m:minus/>
			  <m:ci>t</m:ci>
			  <m:ci>n</m:ci>
			</m:apply>
		      </m:apply>
		    </m:apply>
		    <m:apply>
		      <m:times/>
		      <m:pi/>
		      <m:apply>
			<m:minus/>
			<m:ci>t</m:ci>
			<m:ci>n</m:ci>
		      </m:apply>
		    </m:apply>
		  </m:apply>
		</m:apply>
	      </m:apply>
	    </m:apply>
	  </m:math>
	</equation>
      </para>

      <para id="para10"> 
	The above equation for perfect reconstruction deserves a <cnxn document="m10790" strength="9">closer look</cnxn>, which you
	should continue to read in the following section to get a
	better understanding of reconstruction.  Here are a few things
	to think about for now:
	  
	<list id="list3">
	  <item>
	    What does 
	    <m:math>
	      <m:apply>
		<m:divide/>
		<m:apply>
		  <m:sin/>
		  <m:apply>
		    <m:times/>
		    <m:pi/>
		    <m:apply>
		      <m:minus/>
		      <m:ci>t</m:ci>
		      <m:ci>n</m:ci>
		    </m:apply>
		  </m:apply>
		</m:apply>
		<m:apply>
		  <m:times/>
		  <m:pi/>
		  <m:apply>
		    <m:minus/>
		    <m:ci>t</m:ci>
		    <m:ci>n</m:ci>
		  </m:apply>
	      </m:apply>
	    </m:apply>
	  </m:math> equal at integers other than n? 
	</item>
	<item>
	  What is the support of 
	  <m:math>
	    <m:apply>
	      <m:divide/>
	      <m:apply>
		<m:sin/>
		<m:apply>
		  <m:times/>
		  <m:pi/>
		  <m:apply>
		    <m:minus/>
		    <m:ci>t</m:ci>
		    <m:ci>n</m:ci>
		  </m:apply>
		</m:apply>
	      </m:apply>
	      <m:apply>
		<m:times/>
		<m:pi/>
		<m:apply>
		  <m:minus/>
		  <m:ci>t</m:ci>
		  <m:ci>n</m:ci>
		</m:apply>
	      </m:apply>
	    </m:apply>
	  </m:math>?
	</item>
      </list>
      
      </para>
    </section>

  </content>
  
</document>
