Sie sind auf Seite 1von 164
‘Acquisitions Editor: Tin Cox ‘Breeuive Edtor= Dan Jorunstad Projects Manager: ‘Ray Kana Production Coordinator: Deen Celeia ‘Cover Design Yo Riezebos Design ‘Tes Design: Artae Opnwa, TEX Conslans Copy Eding: Blzabel Gebrman Proofreader: Hoe Rusick Marketing Manager: Mary Toot Compostion Services: Ken Sight Monsfactaring Coordinator I ane Weaver (©1996 by Ken Stiglitz |All ahs reserved. No prof his pulicaon may be reproduced, tre in a eieval system, ce tranamited in any form or by any means, electronic, mechanical photocopying. recording, of Shy chet media embodiment now known or hereafier to become known, without the prot ‘ween permision ofthe pblser, Pritd inthe Und Stats of America Many ofthe designations used by manufacturers an sellers to distinguish their produts are ‘lnmed as trademarks, Al och designations ar the property of each ademark's Owe. Inctroctonal Material Disclaimer “The cxamples presented in this book hve een inluded for heir nsrctonl vale. They have een tested with cae tare not guaranteed for any particular purpose. The pbliser docs not (fer any warrants ot represetatons, nor des i actep ny Habis with espect othe pro- ‘rams orexamples Library of Comrest Cataloging in-Publicaion Data steiglite, Ken, 1939 “A digival signal processing primer, with applications to digi~ tal audio and computer msic / 1. "Signal processing--digital techalques. 2. Computer sound processing. 3. Computer music i. Title, 3%5102.9.874 1995 95-25182 621.302°2--de20 cap ISBN 08053-16341 123456789 10-VG-99 98 97 96 95, eianaruns 10 " 2 3 Contents ‘Tuning Forks, Phasors / 1 Strings, Pipes, the Wave Equation / 21 ‘Sampling an Quantizing / 43 Feedforward Fitters / 61 Feedback Filters / 81 Comb and String Filters / 101 Periodic Sounds / 125 ‘The Discrete Fourier Transform and FFT / 149 ‘The z-Transform and Convolution / 173 Using the FFT / 197 ‘Aliasing and imaging /) 219 Designing Feedforward Fitters / 241 Designing Feedback Fitters / 263 ‘Audio and Musical Applications / 285 Index / 309 To my mom, Sadie Steigltz, who will read it during the commercials ClO PTER af & Preface Using computer technology to store, change, and manufacture sounds and pictures — Aigital signal processing — is one of the mos significant achievements of the late tweatieth century. This book isan informal, and I hope friendly, introduction to the feld, emphasizing digital audio and applications wo computer music. It will ll you how DSP works, how to use it, and what the intuition i behind its basic ideas. ‘By keeping the mathematics simple and selecting topics carefully, I hope to reach broad audience, including ‘beginning students of signal processing in engineering and computer ‘= composers of computer music and others who work with digital sound: ‘¢ World Wide Web and intemet practitioners, who willbe needing DSP more and more for multimedia applications; ‘+ general readers with a background in sience who want an introduction to the key ideas of modern digital signal processing. We'll start with sine waves. They are found everywhere in our world and for 3 ‘good reason: they arise in the very simplest vibrating physical systems. We'll se, in ‘Chapter 1 that sine wave can be viewed asa phasor, a point moving ina circle, This, representation is used throughout the book. and makes it much easier to understand the frequency response of digital fiers, aliasing, and other important frequency- ‘domain concepts. nthe second chapter we'll se how sine waves also aise very naturally in more ‘complicated systems — vibrating strings and organ pipes, for example — governed by the fundamental wave equation. This leads othe comerstone of signal processing: the idea that all signals can be expressed as sums of sine waves. From there we take up sampling and the simplest digital filters, then continue to Fourier series, the FFT algo- rithm, practical spectrum measurement, the z-transform, and the basics of the most ‘useful digital filter design algorithms. “The final chapter is a tour of some important applications, including the CD player, FM symbesis, and the phase vocoder. BE ie seven pons Tre to ideas to develop them mow fll. For example he ===> cya tiporaatpblem of alsin i tested fit Chapter 3 then in gener depth in Chater 1 Smiuty. digi herng I eexanined several tines wih ceasing [Not all books are mean oe read that way, but his ne definitely i Some commens about mechanic: All references to figures and equations refer to rent chap “unless stated otherwise. Absolutely fundamental results ae enclosed in bores. Each chapter ends witha Notes section, whic inlades historical ‘comments and references 1 more advanced books and papers, and ast of problems. Read the problems over, even if you don’t work them the fist ime around. They area’ dil exercises, bt instead mention generalizations, improvement, and wrinkles you will encounter in practice or in more advanced work. A few problems suggest ‘computer experiments. Ifyou have acess to a prcticlsigal-procesing laboraory, ‘seit. Hearing is believing. “Many peopl helped me with this book. First thank my wife Sandy, who suppors ‘e in all that do, and who helped me immeasurably by just being. For his generous help, both tangible and intangible, Iam indebted to Paul Lansky, professor of music and composer at Princeton. The course on computer misc thal We teach together was the original stimulus fr this book. Tam indebted to many others in many ways, Pemry Cook, Jains Smith, Tim ‘Snyser, and Richard Squier read drafts with erical acumen, and their comments significa improved the result. And I also thank, for assistance of varios favors, Steve Beck, Jack Gelfand, Jim Kaiser, Brian Kerighan, Jim McClellan, Gakushi "Nakamura, Mat Norcross, Chris Pirzzi, John Puerbaugh, Jim Rober, and Dan Wal laeb, Ken Stighte Princeton, NJ. a aE IS eet: 1 Where sp sxamimealeee BRRTOBEES ie i «ag salt 7 oe ge 3 Hit ¥ "Tuning Forks; aoe ee ‘““Phasors” : to begin + : We've reached the point where sound can be captured ahd reproduced almost per. ‘ecly. Furthermore, gil technology makes it possible to preserve what we have ‘absoluely perfectly. To paraphrase the composer Paul Lansky, we can grab a pce of ‘sound, play it and play with it, without having to worry about it crumbling in oar ‘hands. Iis simply a maar of having the sound toed inthe form of bis, which can Deremembered for eteity. Perfect preservation i a revolutionary achievement Fi, sil the most secure medium for storing images, disintegrates in just afew decades. Old sound-stoage media, — shellsc, vinyl, magnetic wire, magnetic tape — degrade quickly and sSeiiaily with use. But bits are bits, Abi faful ansferof a compar ic loss ny nohing. The maturing tctinology for digidning Sind makes he compuir an increasingly {leiible instrument for creating music and speech by bot generating and transforming Sound. This opens up exciting possibilities. In theory the computer can produce any sound its posible to hear. But ose the instrument with command we must under, “tnd te relationship between what happens inside the comper and what we bed.” aL “Fost The main goal ofthis book i to give you the asic mathematical toks fr understand this LOH a tc mgd in a gE ‘You should be abet follow everything we do ere with ir yearcalafus and bit of physics PI assume you know about derivatives, integral, and infinite series, but not much more. When we need something more advanced or ff the beaten path, we'll ake some time to develop snd explain i. This is especially tue of the comples| variables we use. Most students, even if they've studied tat materi at coe thé. “~ ave not realy used it much, and need to review it from serach. As far as physics

Das könnte Ihnen auch gefallen