⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 213-219.html

📁 dshfghfhhgsfgfghfhfghgfhfghfgh fg hfg hh ghghf hgf hghg gh fg hg hfg hfh f hg hgfh gkjh kjkh g yj f
💻 HTML
字号:
<HTML>
<HEAD>
<META name=vsisbn content="1558515682"><META name=vstitle content="Java Digital Signal Processing"><META name=vsauthor content="Douglas A. Lyon"><META name=vsimprint content="M&T Books"><META name=vspublisher content="IDG Books Worldwide, Inc."><META name=vspubdate content="11/01/97"><META name=vscategory content="Web and Software Development: Programming, Scripting, and Markup Languages: Java"><TITLE>Java Digital Signal Processing:Digital Audio Processing</TITLE>
<!-- HEADER --><STYLE type="text/css">  <!-- A:hover  { 	color : Red; } --></STYLE><META NAME="ROBOTS" CONTENT="NOINDEX, NOFOLLOW">
<!--ISBN=1558515682//-->
<!--TITLE=Java Digital Signal Processing//-->
<!--AUTHOR=Douglas A. Lyon//-->
<!--PUBLISHER=IDG Books Worldwide, Inc.//-->
<!--IMPRINT=M & T Books//-->
<!--CHAPTER=5//-->
<!--PAGES=213-219//-->
<!--UNASSIGNED1//-->
<!--UNASSIGNED2//-->

<CENTER>
<TABLE BORDER>
<TR>
<TD><A HREF="../ch04/211-212.html">Previous</A></TD>
<TD><A HREF="../ewtoc.html">Table of Contents</A></TD>
<TD><A HREF="219-224.html">Next</A></TD>
</TR>
</TABLE>
</CENTER>
<P><BR></P>
<H2><A NAME="Heading1"></A><FONT COLOR="#000077">Chapter 5<BR>Digital Audio Processing
</FONT></H2>
<P ALIGN="RIGHT">Thy voice sounds like a prophet&#146;s word;<BR>And in its hollow tones are heard</P>
<P ALIGN="RIGHT"><I>--Fitz-Greene Halleck. 1790-1867</I>.</P>
<H3><A NAME="Heading2"></A><FONT COLOR="#000077">What Is Digital Signal Processing?</FONT></H3>
<P><I>Sound</I> is a pressure wave that traverses a medium. Sound pressure waves in air are the objective cause of human hearing. Sound will not travel through a vacuum, but it will travel through various phases of matter (solid, liquid, and gas).</P>
<P>A <I>transducer</I> is a device that takes power from one system and supplies power to another system. For example, a microphone is a transducer that takes sound power and supplies electrical power. The electrical power supplied by the microphone forms an analog signal. An analog signal is continuous.</P>
<P><I>Digitization</I> is a process that converts continuous signals into a digital form. Digitization (also known as analog-to-digital conversion) is performed by sampling and quantization. <I>Sampling</I> is the process of converting a continuous signal into a set of voltages. <I>Quantization</I> is the process of converting the sampled voltages into a countable set of digital values. Analog data that is converted to digital data is said to be PCM-encoded. PCM stands for pulse code modulation and is a broad term that can refer to any type of digital encoding of analog data. Figure 5.1 depicts a PCM encoder.</P>
<P><A NAME="Fig1"></A><A HREF="javascript:displayWindow('images/05-01.jpg',478,48 )"><IMG SRC="images/05-01t.jpg"></A>
<BR><A HREF="javascript:displayWindow('images/05-01.jpg',478,48)"><FONT COLOR="#000077"><B>Figure 5.1</B></FONT></A>&nbsp;&nbsp;Block diagram of a PCM encoder.</P>
<P>A <I>low-pass</I> filter (called an anti-aliasing filter) is typically set to attenuate frequencies at or above one-half the analog-to-digital converter&#146;s sampling rate (this is known as the Nyquest frequency).</P>
<P>To transform the PCM signal back into the analog domain, we couple a digital-to-analog converter with another low-pass filter. A block diagram of the PCM decoder is shown in Figure 5.2.</P>
<P><A NAME="Fig2"></A><A HREF="javascript:displayWindow('images/05-02.jpg',439,48 )"><IMG SRC="images/05-02t.jpg"></A>
<BR><A HREF="javascript:displayWindow('images/05-02.jpg',439,48)"><FONT COLOR="#000077"><B>Figure 5.2</B></FONT></A>&nbsp;&nbsp;Block diagram of a PCM decoder.</P>
<P>Digital signal processing is a kind of data processing that operates on PCM data. Thus, broadly speaking, audio, image, and image sequence processing are one-dimensional, two-dimensional, and three-dimensional digital signal processing.
</P>
<P>In common usage, <I>digital signal processing</I> refers to one-dimensional signals, <B><I>V</I></B>(<I>t</I>). In image processing we often speak about two-dimensional signals, <B><I>I</I></B>(<I>x</I>,<I>y</I>). This chapter deals only with one-dimensional digital signal processing in Java.</P>
<H3><A NAME="Heading3"></A><FONT COLOR="#000077">Why Do We Need Digital Signal Processing?</FONT></H3>
<P>A digital signal stream may come from any energy (sound, measurement, temperature, speed, pressure, radiation, and so on). Non-physical phenomena can also produce a digital stream of data (financial data, statistical data, network traffic, and so on).
</P>
<P>In short, digital signal processing can be performed on any recordable event. Digital signal processing is a kind of data processing.</P>
<P>In this chapter we treat only the restricted domain of audio digital signal processing in Java. There are several reasons for this:</P>
<DL>
<DD><B>&#149;</B>&nbsp;&nbsp;Java can already play audio files.
<DD><B>&#149;</B>&nbsp;&nbsp;The techniques can be extended to other types of data.
<DD><B>&#149;</B>&nbsp;&nbsp;We can hear the results.
<DD><B>&#149;</B>&nbsp;&nbsp;It is fun!
</DL>
<H3><A NAME="Heading4"></A><FONT COLOR="#000077">What Is the Spectrum of a Signal?</FONT></H3>
<P>The harmonic content of a signal is called its <I>spectrum</I>. The spectrum of a signal consists of a series of sin and cosine waves. A French mathematician, Jean Baptiste Joseph de Fourier (1768-1830), showed that harmonic waves (sine and cosine waves) can be summed in a series to form any periodic waveform. The summation (called the <I>superposition principle</I>) fails to approximate a waveform when the equations governing the waveform are nonlinear (shock waves, turbulence, chaos, and so on) [Halliday]. The series was first formulated by, and is used in, harmonic analysis (also called Fourier analysis). Harmonic analysis is the process that determines the harmonic components of a complex wave. The series can be written as</P>
<P ALIGN="CENTER"><IMG SRC="images/05-01d.jpg"></P>
<P>(5.1)
</P>
<P>where <I>a</I>0, <I>a</I>1, <I>b</I>1, <I>a</I>1, <I>b</I>2, are constants called Fourier coefficients.</P>
<P>For example, a sawtooth wave can be computed by letting <I>k</I> in the following go to infinity:</P>
<P ALIGN="CENTER"><IMG SRC="images/05-02d.jpg"></P>
<P>When <I>k</I> = 10, the waveform of Figure 5.3 results.</P>
<P><A NAME="Fig3"></A><A HREF="javascript:displayWindow('images/05-03.jpg',442,289 )"><IMG SRC="images/05-03t.jpg"></A>
<BR><A HREF="javascript:displayWindow('images/05-03.jpg',442,289)"><FONT COLOR="#000077"><B>Figure 5.3</B></FONT></A>&nbsp;&nbsp;Sawtooth waveform with k = 10</P>
<P>When <I>k</I> = 100, the waveform of Figure 5.4 is produced.</P>
<P><A NAME="Fig4"></A><A HREF="javascript:displayWindow('images/05-04.jpg',442,290 )"><IMG SRC="images/05-04t.jpg"></A>
<BR><A HREF="javascript:displayWindow('images/05-04.jpg',442,290)"><FONT COLOR="#000077"><B>Figure 5.4</B></FONT></A>&nbsp;&nbsp;Sawtooth waveform with <I>k</I>=100.
</P>
<P>When the waveform to be approximated is not periodic, the summation is replaced by the Fourier transform:
</P>
<P ALIGN="CENTER"><IMG SRC="images/05-03d.jpg"></P>
<P>(5.2)
</P>
<P ALIGN="CENTER"><IMG SRC="images/05-04d.jpg"></P>
<P>(5.3)
</P>
<P>Where <I>ei</I>( is given by Euler&#146;s identity:</P>
<P ALIGN="CENTER"><IMG SRC="images/05-05d.jpg"></P>
<P>(5.4)
</P>
<P>Euler&#146;s identity can lead to several equivalent representations for the Fourier series. For example, there is the sine-cosine representation:</P>
<P ALIGN="CENTER"><IMG SRC="images/05-06d.jpg"></P>
<P>where <I>f</I><SUB>0</SUB>=frequency and <I>f</I><SUB>0</SUB> = nth harmonic of <I>f</I><SUB>0</SUB>. The constants, known as Fourier coefficients, are found by correlating the time dependent function, <I>x(t)</I>, with an Nth harmonic sine-cosine pair:</P>
<P ALIGN="CENTER"><IMG SRC="images/05-07d.jpg"></P>
<P>Another common representation of the Fourier series is the amplitude-phase representation. This is also a result of Euler&#146;s identity:
</P>
<P ALIGN="CENTER"><IMG SRC="images/05-08d.jpg"></P>
<P>In general, the use of the representation of the Fourier transform is a matter of preference, because the various representations are equivalent. The Fourier transform has some interesting properties, and although it is beyond our scope to state them all (or prove any of them), we give some of them here.
</P>
<P>A Fourier transform representation of a periodic signal has discrete spectral components at <I>f</I>0 and <I>nf</I>0, as shown by Equation 5.1. An a periodic signal has a continuous and infinite spectrum, as shown by Equations 5.2 and 5.3. This means that time-limited signals (which are, by definition, aperiodic) have infinite bandwidth.</P>
<P>The effective bandwidth of a signal is the width of the spectrum that contains the most power. The average power in a given interval of time is computed by</P>
<P ALIGN="CENTER"><IMG SRC="images/05-09d.jpg"></P>
<P>To compute the average power in a periodic signal whose period is <I>T</I>, we use</P>
<P ALIGN="CENTER"><IMG SRC="images/05-10d.jpg"></P>
<P>The PSD (power spectral density) is the power at a specific frequency, <I>S</I> (<I>f</I>). Chapter 6 will discuss the computation of the PSD in more detail.</P>
<P>The Fourier transforms are important because they permit computation in either the time domain or the frequency domain. Some relations with Fourier transforms follow.</P>
<P>Superposition states that linear combinations in the time domain become linear combinations in the frequency domain:</P>
<P ALIGN="CENTER"><IMG SRC="images/05-11d.jpg"></P>
<P>(5.5)
</P>
<P>Delay in the time domain causes a phase shift in the frequency domain:</P>
<P ALIGN="CENTER"><IMG SRC="images/05-12d.jpg"></P>
<P>(5.6)
</P>
<P>Scale change in the time domain causes a reciprocal scale change in the frequency domain:</P>
<P ALIGN="CENTER"><IMG SRC="images/05-13d.jpg"></P>
<P>(5.7)
</P>
<P>The convolution theorem states that multiplication in the time domain causes convolution in the frequency domain:</P>
<P ALIGN="CENTER"><IMG SRC="images/05-14d.jpg"></P>
<P>(5.8)
</P>
<P>Where convolution between two functions of the same variable is defined by</P>
<P ALIGN="CENTER"><IMG SRC="images/05-15d.jpg"></P>
<P>(5.9)
</P>
<P>For proofs of these results, see [Carlson].</P><P><BR></P>
<CENTER>
<TABLE BORDER>
<TR>
<TD><A HREF="../ch04/211-212.html">Previous</A></TD>
<TD><A HREF="../ewtoc.html">Table of Contents</A></TD>
<TD><A HREF="219-224.html">Next</A></TD>
</TR>
</TABLE>
</CENTER>

<hr width="90%" size="1" noshade><div align="center"><font face="Verdana,sans-serif" size="1">Copyright &copy; <a href="/reference/idgbooks00001.html">IDG Books Worldwide, Inc.</a></font></div>
<!-- all of the reference materials (books) have the footer and subfoot reveresed --><!-- reference_subfoot = footer --><!-- reference_footer = subfoot --></BODY></HTML><!-- END FOOTER -->

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -