CS101 Lecture 18: Audio Encoding. What You ll Learn Today

Similar documents
CS Lecture 10:

CS101 Lecture 12: Digital Images. What You ll Learn Today

Fundamentals of Digital Audio *

Byte = More common: 8 bits = 1 byte Abbreviation:

Media Devices: Audio. CTEC1465/2018S Computer System Support

Digital Audio. Lecture-6

MUS 302 ENGINEERING SECTION

CS 262 Lecture 01: Digital Images and Video. John Magee Some material copyright Jones and Bartlett

SOME PHYSICAL LAYER ISSUES. Lecture Notes 2A

UNIT 7B Data Representa1on: Images and Sound. Pixels. An image is stored in a computer as a sequence of pixels, picture elements.

Overview. Lecture 3. Terminology. Terminology. Background. Background. Transmission basics. Transmission basics. Two signal types

CS101 Lecture 19: Digital Images. John Magee 18 July 2013 Some material copyright Jones and Bartlett. Overview/Questions

Continuous vs. Discrete signals. Sampling. Analog to Digital Conversion. CMPT 368: Lecture 4 Fundamentals of Digital Audio, Discrete-Time Signals

ECE 556 BASICS OF DIGITAL SPEECH PROCESSING. Assıst.Prof.Dr. Selma ÖZAYDIN Spring Term-2017 Lecture 2

Revision Guide for Chapter 3

Digitizing Color. Place Value in a Decimal Number. Place Value in a Binary Number. Chapter 11: Light, Sound, Magic: Representing Multimedia Digitally

! Where are we on course map? ! What we did in lab last week. " How it relates to this week. ! Sampling/Quantization Review

Fundamentals of Data and Signals

2: Audio Basics. Audio Basics. Mark Handley

In this lecture. System Model Power Penalty Analog transmission Digital transmission

Music 270a: Fundamentals of Digital Audio and Discrete-Time Signals

Chapter 8. Representing Multimedia Digitally

5/17/2009. Digitizing Color. Place Value in a Binary Number. Place Value in a Decimal Number. Place Value in a Binary Number

CMPT 318: Lecture 4 Fundamentals of Digital Audio, Discrete-Time Signals

Adding some light to computing. Lawrence Snyder University of Washington, Seattle

Pulse Code Modulation

Chapter 4. Digital Audio Representation CS 3570

Lecture 4: Digital representation and data analysis

Chapter 3 Data and Signals

describe sound as the transmission of energy via longitudinal pressure waves;

Advanced Audiovisual Processing Expected Background

UNIT 7C Data Representation: Images and Sound Principles of Computing, Carnegie Mellon University CORTINA/GUNA

CHAPTER 2 - DIGITAL DATA REPRESENTATION AND NUMBERING SYSTEMS

UNIT 7C Data Representation: Images and Sound

Laboratory Assignment 2 Signal Sampling, Manipulation, and Playback

MULTIMEDIA SYSTEMS

Chapter Two. Fundamentals of Data and Signals. Data Communications and Computer Networks: A Business User's Approach Seventh Edition

Terminology (1) Chapter 3. Terminology (3) Terminology (2) Transmitter Receiver Medium. Data Transmission. Direct link. Point-to-point.

Q A bitmap file contains the binary on the left below. 1 is white and 0 is black. Colour in each of the squares. What is the letter that is reve

15110 Principles of Computing, Carnegie Mellon University

Chapter 2: Fundamentals of Data and Signals

Waveform Encoding - PCM. BY: Dr.AHMED ALKHAYYAT. Chapter Two

CS101 Lecture 01: Introduction. What You ll Learn Today

SGN Audio and Speech Processing

E40M Sound and Music. M. Horowitz, J. Plummer, R. Howe 1

CSCD 433 Network Programming Fall Lecture 5 Physical Layer Continued

Chapter 3 Data and Signals 3.1

Speech Processing. Undergraduate course code: LASC10061 Postgraduate course code: LASC11065

Surround: The Current Technological Situation. David Griesinger Lexicon 3 Oak Park Bedford, MA

Introduction to Communications Part Two: Physical Layer Ch3: Data & Signals

Chapter 2. Meeting 2, Measures and Visualizations of Sounds and Signals

Psychological psychoacoustics is needed to perceive sound to extract features and meaning from them -human experience

2. By convention, the minimum and maximum values of analog data and signals are presented as voltages.

Data Communication. Chapter 3 Data Transmission

Sound/Audio. Slides courtesy of Tay Vaughan Making Multimedia Work

EE 421L Digital Electronics Laboratory. Laboratory Exercise #9 ADC and DAC


Computer Audio. An Overview. (Material freely adapted from sources far too numerous to mention )

Terminology (1) Chapter 3. Terminology (3) Terminology (2) Transmitter Receiver Medium. Data Transmission. Simplex. Direct link.

Chapter 5: Signal conversion

Advantages of Analog Representation. Varies continuously, like the property being measured. Represents continuous values. See Figure 12.

Click on the numbered steps below to learn how to record and save audio using Audacity.

CSCD 433 Network Programming Fall Lecture 5 Physical Layer Continued

Basic Concepts in Data Transmission

Chapter 12. Preview. Objectives The Production of Sound Waves Frequency of Sound Waves The Doppler Effect. Section 1 Sound Waves

Chapter 3 Data Transmission COSC 3213 Summer 2003

Chapter 3. Data Transmission

15110 Principles of Computing, Carnegie Mellon University

What is Sound? Simple Harmonic Motion -- a Pendulum

6. has units of bits/second. a. Throughput b. Propagation speed c. Propagation time d. (b)or(c)

ICT Elementary for Embedded Systems Signal/Electronic Fundamental. Fourier Transform and Communication Systems. Asst. Prof. Dr.

CHAPTER ONE SOUND BASICS. Nitec in Digital Audio & Video Production Institute of Technical Education, College West

AUDL Final exam page 1/7 Please answer all of the following questions.

Introduction to signals and systems

Digital Sampling. This Lecture. Engr325 Instrumentation. Dr Curtis Nelson. Digital sampling Sample rate. Bit depth. Other terms. Types of conversion.

Voice Transmission --Basic Concepts--

Sound recording & playback

CS 591 S1 Computational Audio -- Spring, 2017

Figure 1: Block diagram of Digital signal processing

Design IV. E232 Spring 07

6. An oscillator makes four vibrations in one second. What is its period and frequency?

Psychology of Language

Final Exam Study Guide: Introduction to Computer Music Course Staff April 24, 2015

Sound waves. septembre 2014 Audio signals and systems 1

Fundamentals of Music Technology

Analogue Signals. M J Brockway. February 5, 2018

Set-up. Equipment required: Your issued Laptop MATLAB ( if you don t already have it on your laptop)

SGN Audio and Speech Processing

Recording your Voice Tutorials 2 - Setting the Computer Setting Audacity Wayne B. Dickerson

Chapter-15. Communication systems -1 mark Questions

Variations in Waveforms and Energy Spectra between Musical Instruments

Q15.9. Monday, May 2, Pearson Education, Inc.

CHAPTER 4. PULSE MODULATION Part 2

Lecture Fundamentals of Data and signals

ANALOG-TO-DIGITAL CONVERTERS

Analog-Digital Interface

Chapter 2: Digitization of Sound

Chapter 2. Physical Layer

Introduction of Audio and Music

CSE481i: Digital Sound Capstone

Transcription:

CS101 Lecture 18: Audio Encoding Sampling Quantizing Aaron Stevens (azs@bu.edu) with special guest Wayne Snyder (snyder@bu.edu) 16 October 2012 What You ll Learn Today How do we hear sounds? How can audio information (sounds) be stored on a computer? How to reproduce the sounds from the binary data? 2 1

Hearing We hear sound when a series of air compressions vibrate a membrane in our ear. The inner ear sends signals to our brain. The rate of this vibration is measured in Hertz, and the human ear can hear sounds in the range of roughly 20Hz - 20KHz. 3 Sound Wave Properties Wavelength: distance between waves (affects pitch -- high or low sounds) Amplitude: strength of power of waves (volume) Frequency: the number of times a wave occurs in a second measured in Hertz. 4 2

Music Concepts Pitch is the human perception of sounds as musical notes Microphones and Speakers Microphones convert acoustical energy (sound waves) into electrical energy (the audio signal). Speakers do the same thing in reverse: convert electrical energy into acoustical energy. 6 3

Audio Playback A stereo sends an electrical signal to a speaker to produce sound. This signal is an analog representation of the sound wave. The voltage in the signal varies in direct proportion to the sound wave. 7 Important Note about Electronic Signals An analog signal continually fluctuates in voltage up and down. A digital signal has only a high or low state, which we model as binary digits. 8 4

Recall: Digitizing an Image Sampling: Taking measurements (of color) at discrete locations within the image. Sampling rate: 16 samples per inch (in each direction) Recall: Digitizing an Image Sampling: Measure the color for each pixel, and record that color. 16 pixels per inch Quantization: determine a discrete value for each pixel. 5

Digitizing Audio Information How can we store this continuous information in a finite machine? Digitize the signal by sampling: periodically measure the voltage record the numeric value 11 Sampling Audio Information Sampling: periodically measure the voltage and record the numeric value. Some data is lost, but a reasonable sound is reproduced. 12 6

From Sound Wave to Sample In this case, we are measuring the amplitude of the sound wave with 3 bits of precision (8 possible values, Y axis), at a sampling rate determined along the X axis. We record the values for each sample. 13 Sampling: 3-bit depth For each sample, we need to select a discrete value for the amplitude. These values are recorded in 3 bits (right hand side). 14 7

10/12/12 From Sample to Sound Wave Using the recorded information, the computer must re-recreate the sound wave. Some of the original information was lost by the sampling process! 15 Increasing Quality To increate the quality of the recording, we can change 2 dimensions (independently): 1 - increase the sample rate (more points of measurement on X/time axis) 16 2 - increase the bit depth (more discrete levels of measurement on Y/amplitude axis). 8

How Good is Good Enough? How would you determine the required: Sampling rate Bit depth (quantization of sound wave) to recreate the best sensory audio experience? Choosing a Sampling Rate Consider this waveform. What sampling rate should we choose? 9

Choosing a Sampling Rate How about this sampling rate? (6 samples) Choosing a Sampling Rate How about this sampling rate? (11 samples) 10

Choosing a Sampling Rate How about this sampling rate? (21 samples) Choosing a Sampling Rate Consider this waveform, and these two sampling strategies. What s going on here? A. B. 11

Nyquist Theorem The Nyquist Theorem states that the sampling rate must be greater than twice the value of the highest frequency component of the analog signal. Consider this waveform and sampling rate: Waveform Audio File Format (.WAV Files) These files store a bitstream of the audio samples: compatible with Window, MAC, Linux typically uncompressed What are the benefits of an uncompressed format? What are the drawbacks? 12

Recording a.wav file. Example: using Audacity to record a.wav file. Recall: a speaker has an electromagnet, just like a microphone Representing Audio Information Compact Disc audio is encoded by sampling: 44,100 samples per second 16 bits per sample per channel (2 channels) thus: 44,100 * 16 * 2 = 1,411,200 bps Or about 10,600,000 bytes per minute CD Audio uses about 10 megabytes of data per minute of audio. 26 13

What You Learned Today Hearing Sound waves Sampling, Sampling Rates Quantizing, Bit Depth Data storage requirements 27 Announcements and To Do Readings: Wong ch 4, pp 102-117 (this week) YouTube: History of Sony music technology http://www.youtube.com/watch?v=v5i41pdak0y (6 minutes) Homework 6 due Tuesday 10/16 28 14