<?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:m="http://www.w3.org/1998/Math/MathML" xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:bib="http://bibtexml.sf.net/" id="interpolationfilter">

  <name>Polyphase Interpolation</name>

  <metadata>
  <md:version>2.11</md:version>
  <md:created>2002/01/04</md:created>
  <md:revised>2005/10/18 20:03:38.683 GMT-5</md:revised>
  <md:authorlist>
      <md:author id="schniter">
      <md:firstname>Phil</md:firstname>
      
      <md:surname>Schniter</md:surname>
      <md:email>schniter@ee.eng.ohio-state.edu</md:email>
    </md:author>
  </md:authorlist>

  <md:maintainerlist>
    <md:maintainer id="jago">
      <md:firstname>Adan</md:firstname>
      
      <md:surname>Galvan</md:surname>
      <md:email>jago@rice.edu</md:email>
    </md:maintainer>
    <md:maintainer id="emaloney">
      <md:firstname>Erin</md:firstname>
      
      <md:surname>Maloney</md:surname>
      <md:email>emaloney@rice.edu</md:email>
    </md:maintainer>
    <md:maintainer id="schniter">
      <md:firstname>Phil</md:firstname>
      
      <md:surname>Schniter</md:surname>
      <md:email>schniter@ee.eng.ohio-state.edu</md:email>
    </md:maintainer>
  </md:maintainerlist>
  
  <md:keywordlist>
    <md:keyword>interpolation</md:keyword>
    <md:keyword>polyphase</md:keyword>
  </md:keywordlist>

  <md:abstract>Implementation of a polyphase interpolation filter.</md:abstract>
</metadata>


  <content>
    <section id="implement">
      <name>Polyphase Interpolation Filter</name>
      <para id="para1">
	Recall the standard interpolation procedure illustrated in
	<cnxn target="fig1" strength="9"/>.

      </para>
      <figure id="fig1">
	<media type="image/png" src="m10431fig1.png"/>
      </figure>

      <para id="parafix1">
	Note that this procedure is computationally inefficient
	because the lowpass filter operates on a sequence that is
	mostly composed of zeros.  Through the use of the Noble
	identities, it is possible to rearrange the preceding block
	diagram so that operations on zero-valued samples are avoided.
      </para>
      
      <para id="para1.5">
	In order to apply the <cnxn target="fig1" document="m10432" strength="9">Noble identity for interpolation</cnxn>, we must
	transform <m:math>
	  <m:apply>
	    <m:ci type="fn">H</m:ci>
	    <m:ci>z</m:ci>
	  </m:apply>
	</m:math> into its upsampled polyphase components
	<m:math>
	  <m:apply>
	    <m:ci type="fn">
	      <m:msub>
		<m:mi>H</m:mi>
		<m:mi>p</m:mi>
	      </m:msub>
	    </m:ci>
	    <m:apply>
	      <m:power/>
	      <m:ci>z</m:ci>
	      <m:ci>L</m:ci>
	    </m:apply>
	  </m:apply>
	</m:math>, 
	<m:math>
	  <m:apply>
	    <m:eq/>
	    <m:ci>p</m:ci>
	    <m:set>
	      <m:cn>0</m:cn>
	      <m:ci>…</m:ci>
	      <m:apply>
		<m:minus/>
		<m:ci>L</m:ci>
		<m:cn>1</m:cn>
	      </m:apply>
	    </m:set>
	  </m:apply>
	</m:math>.

	<equation id="eq1">
	  <m:math display="block">
	    <m:apply>
	      <m:eq/>
	      <m:apply>
		<m:ci type="fn">H</m:ci>
		<m:ci>z</m:ci>
	      </m:apply>
	      <m:apply>
		<m:sum/>
		<m:bvar><m:ci>n</m:ci></m:bvar>
		<m:domainofapplication><m:ci>n</m:ci></m:domainofapplication>
		<m:apply>
		  <m:times/>
		  <m:apply>
		    <m:ci type="fn" class="discrete">h</m:ci>
		    <m:ci>n</m:ci>
		  </m:apply>
		  <m:apply>
		    <m:power/>
		    <m:ci>z</m:ci>
		    <m:apply>
		      <m:minus/>
		      <m:ci>n</m:ci>
		    </m:apply>
		  </m:apply>
		</m:apply>
	      </m:apply>

	      <m:apply>
		<m:sum/>
		<m:bvar><m:ci>k</m:ci></m:bvar>
		<m:domainofapplication><m:ci>k</m:ci></m:domainofapplication>
		<m:apply>
		  <m:sum/>
		  <m:bvar><m:ci>p</m:ci></m:bvar>
		  <m:lowlimit><m:cn>0</m:cn></m:lowlimit>
		  <m:uplimit>
		    <m:apply>
		      <m:minus/>
		      <m:ci>L</m:ci>
		      <m:cn>1</m:cn>
		    </m:apply>
		  </m:uplimit>
		  <m:apply>
		    <m:times/>
		    <m:apply>
		      <m:ci type="fn" class="discrete">h</m:ci>
		      <m:apply>
			<m:plus/>
			<m:apply>
			  <m:times/>
			  <m:ci>k</m:ci>
			  <m:ci>L</m:ci>
			</m:apply>
			<m:ci>p</m:ci>
		      </m:apply>
		    </m:apply>
		    <m:apply>
		      <m:power/>
		      <m:ci>z</m:ci>
		      <m:apply>
			<m:minus/>
			<m:apply>
			  <m:plus/>
			  <m:apply>
			    <m:times/>
			    <m:ci>k</m:ci>
			    <m:ci>L</m:ci>
			  </m:apply>
			  <m:ci>p</m:ci>
			</m:apply>
		      </m:apply>
		    </m:apply>
		  </m:apply>
		</m:apply>
	      </m:apply>
	    </m:apply>
	  </m:math>
	</equation>
	via <m:math>
	  <m:apply>
	    <m:ci><m:mo>≔</m:mo></m:ci>
	    <m:ci>k</m:ci>
	    <m:apply>
	      <m:floor/>
	      <m:apply>
		<m:divide/>
		<m:ci>n</m:ci>
		<m:ci>L</m:ci>
	      </m:apply>
	    </m:apply>
	  </m:apply>
	</m:math>, <m:math>
	  <m:apply>
	    <m:ci><m:mo>≔</m:mo></m:ci>
	    <m:ci>p</m:ci>
	    <m:apply>
	      <m:rem/>
	      <m:ci>n</m:ci>
	      <m:ci>L</m:ci>
	    </m:apply>
	  </m:apply>
	</m:math>

	<equation id="eq1.5">
	  <m:math display="block">
	    <m:apply>
	      <m:eq/>
	      <m:apply>
		<m:ci type="fn">H</m:ci>
		<m:ci>z</m:ci>
	      </m:apply>
	      <m:apply>
		<m:sum/>
		<m:bvar><m:ci>p</m:ci></m:bvar>
		<m:lowlimit><m:cn>0</m:cn></m:lowlimit>
		<m:uplimit><m:apply><m:minus/><m:ci>L</m:ci><m:cn>1</m:cn></m:apply></m:uplimit>
		<m:apply>
		  <m:times/>
		  <m:apply>
		    <m:sum/>
		    <m:bvar><m:ci>k</m:ci></m:bvar>
		    <m:domainofapplication>
		      <m:ci>k</m:ci>
		    </m:domainofapplication>
		    <m:apply>
		      <m:times/>
		      <m:apply>
			<m:ci type="fn" class="discrete">
			  <m:msub>
			    <m:mi>h</m:mi>
			    <m:mi>p</m:mi>
			  </m:msub>
			</m:ci>
			<m:ci>k</m:ci>
		      </m:apply>
		      <m:apply>
			<m:power/>
			<m:ci>z</m:ci>
			<m:apply>
			  <m:minus/>
			  <m:apply>
			    <m:times/>
			    <m:ci>k</m:ci>
			    <m:ci>L</m:ci>
			  </m:apply>
			</m:apply>
		      </m:apply>
		    </m:apply>
		  </m:apply>
		  <m:apply>
		    <m:power/>
		    <m:ci>z</m:ci>
		    <m:apply>
		      <m:minus/>
		      <m:ci>p</m:ci>
		    </m:apply>
		  </m:apply>
		</m:apply>
	      </m:apply>
	    </m:apply>
	  </m:math>
	</equation>

	via
	<m:math>
	  <m:apply>
	    <m:ci><m:mo>≔</m:mo></m:ci>
	    <m:apply>
	      <m:ci type="fn" class="discrete">
		<m:msub>
		  <m:mi>h</m:mi>
		  <m:mi>p</m:mi>
		</m:msub>
	      </m:ci>
	      <m:ci>k</m:ci>
	    </m:apply>
	    <m:apply>
	      <m:ci type="fn" class="discrete">h</m:ci>
	      <m:apply>
		<m:plus/>
		<m:apply>
		  <m:times/>
		  <m:ci>k</m:ci>
		  <m:ci>L</m:ci>
		</m:apply>
		<m:ci>p</m:ci>
	      </m:apply>
	    </m:apply>
	  </m:apply>
	</m:math>

	<equation id="eq1.6">
	  <m:math display="block">
	    <m:apply>
	      <m:eq/>
	      <m:apply>
		<m:ci type="fn">H</m:ci>
		<m:ci>z</m:ci>
	      </m:apply>
	      <m:apply>
		<m:sum/>
		<m:bvar><m:ci>p</m:ci></m:bvar>
		<m:lowlimit><m:cn>0</m:cn></m:lowlimit>
		<m:uplimit><m:apply><m:minus/><m:ci>L</m:ci><m:cn>1</m:cn></m:apply></m:uplimit>
		<m:apply>
		  <m:times/>
		  <m:apply>
		    <m:ci type="fn">
		      <m:msub>
			<m:mi>H</m:mi>
			<m:mi>p</m:mi>
		      </m:msub>
		    </m:ci>
		    <m:apply>
		      <m:power/>
		      <m:ci>z</m:ci>
		      <m:ci>L</m:ci>
		    </m:apply>
		  </m:apply>
		  <m:apply>
		    <m:power/>
		    <m:ci>z</m:ci>
		    <m:apply>
		      <m:minus/>
		      <m:ci>p</m:ci>
		    </m:apply>
		  </m:apply>
		</m:apply>
	      </m:apply>
	    </m:apply>
	  </m:math>
	</equation>


	Above, <m:math><m:apply><m:floor/><m:ci>·</m:ci></m:apply></m:math>
	denotes the floor operator and  
	<m:math>
	  <m:apply>
	    <m:rem/>
	    <m:ci>·</m:ci>
	    <m:ci>M</m:ci>
	  </m:apply>
	</m:math>
	the modulo-<m:math><m:ci>M</m:ci></m:math> operator. Note that the 
	<m:math><m:msup><m:mi>p</m:mi><m:mo>th</m:mo></m:msup></m:math>
	polyphase filter 
	<m:math>
	  <m:apply>
	    <m:ci type="fn" class="discrete"><m:msub>
		<m:mi>h</m:mi>
		<m:mi>p</m:mi>
	      </m:msub></m:ci>
	    <m:ci>k</m:ci>
	  </m:apply>
	</m:math> is 
	constructed by downsampling the "master filter"
	<m:math>
	  <m:apply>
	    <m:ci type="fn" class="discrete">h</m:ci>
	    <m:ci>n</m:ci>
	  </m:apply>
	</m:math> at offset <m:math><m:ci>p</m:ci></m:math>. Using the
	unsampled polyphase components, the <cnxn target="fig1" strength="9"/> diagram can be redrawn as in <cnxn target="fig3" strength="9"/>.
      </para>

      <figure id="fig3">
	<media type="image/png" src="m10431fig2.png"/>
	<caption>
	</caption>
      </figure>

      <para id="para5">
	Applying the Noble identity for interpolation to <cnxn target="fig2" strength="9"/> yields <cnxn target="fig3" strength="9"/>. The ladder of upsamplers and delays on the
	right <cnxn target="fig3">below</cnxn> accomplishes a form of
	parallel-to-serial conversion.
      </para>

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

    </section>
  </content>
</document>
