Cs 101 ( Module 21-30)
40 Questions
0 Views

Choose a study mode

Play Quiz
Study Flashcards
Spaced Repetition
Chat to lesson

Podcast

Play an AI-generated podcast conversation about this lesson

Questions and Answers

What is the sound amplitude experienced as?

  • The loudness of sound (correct)
  • The pitch of sound
  • The speed of sound
  • The frequency of sound
  • How many samples per second are recorded in today's CD's?

  • 16000
  • 8000
  • 44100 (correct)
  • 64000
  • What is the main purpose of MIDI encoding?

  • To encode directions for producing music (correct)
  • To store music itself
  • To store music in a compressed format
  • To improve the quality of sound recordings
  • What is the quantity associated with each position in binary notation compared to the position to its right?

    <p>Twice the quantity</p> Signup and view all the answers

    How many bits are required to record data from each sample in high fidelity music recordings?

    <p>16 bits</p> Signup and view all the answers

    What is the binary representation of 32?

    <p>10000000</p> Signup and view all the answers

    What is the purpose of the radix point in fractional binary numbers?

    <p>To separate the whole number and fractional parts</p> Signup and view all the answers

    How do you convert a positive decimal number to its binary representation?

    <p>By using the algorithm in Figure 24</p> Signup and view all the answers

    What is the purpose of the leftmost bit in 2's complement notation?

    <p>To indicate the sign of the number</p> Signup and view all the answers

    What is the method to convert between positive and negative representations in 2's complement notation?

    <p>By starting from the rightmost bit and copying until the first 1 is reached</p> Signup and view all the answers

    What is the maximum positive number that can be represented using 4 bits?

    <p>7</p> Signup and view all the answers

    What is the issue with the 4-bit representation of a number?

    <p>It may result in overflow</p> Signup and view all the answers

    What is the purpose of the sign bit in floating-point notation?

    <p>To determine the sign of the number</p> Signup and view all the answers

    What is the advantage of using excess notation?

    <p>It can represent both positive and negative numbers</p> Signup and view all the answers

    What is the purpose of the exponent field in floating-point notation?

    <p>To determine the position of the radix point</p> Signup and view all the answers

    What is the primary difference between lossless and lossy relative encoding?

    <p>The precision of encoding differences between consecutive data units</p> Signup and view all the answers

    What is the typical size of a dictionary in a word processor?

    <p>Around 25,000 entries</p> Signup and view all the answers

    What is a common problem when using floating-point notation to store and manipulate dollars and cents?

    <p>The value of a dime cannot be stored accurately.</p> Signup and view all the answers

    Which data compression technique is useful when the data being compressed consists of long sequences of the same value?

    <p>Run-length encoding</p> Signup and view all the answers

    What happens to the dictionary in an adaptive dictionary encoding system?

    <p>It grows as larger units are found in the message</p> Signup and view all the answers

    What is the purpose of using normalized form in floating-point representation?

    <p>To eliminate the possibility of multiple representations for the same value</p> Signup and view all the answers

    What is the main advantage of lossy data compression schemes over lossless schemes?

    <p>They provide more compression.</p> Signup and view all the answers

    What is the purpose of Lempel-Ziv-Welch (LZW) encoding?

    <p>To encode messages using a growing dictionary</p> Signup and view all the answers

    What is the purpose of adding small quantities together first in intelligent processing for handling truncation errors?

    <p>To reduce the chance of truncation errors</p> Signup and view all the answers

    What happens when the mantissa field is not large enough to store a value in floating-point notation?

    <p>The value is truncated, resulting in a loss of precision</p> Signup and view all the answers

    What happens to the dictionary during the decoding process in LZW encoding?

    <p>It is reset to the original small dictionary</p> Signup and view all the answers

    What is the name of the algorithm commonly used for developing frequency-dependent codes?

    <p>Huffman algorithm</p> Signup and view all the answers

    What is the significance of the sign bit in a floating-point representation?

    <p>It indicates whether the value is positive or negative</p> Signup and view all the answers

    What is the effect of using a longer mantissa field in floating-point notation?

    <p>It reduces the significance of truncation errors</p> Signup and view all the answers

    What is the result of encoding the value 25⁄8 in a one-byte floating-point system?

    <p>The value is truncated, resulting in a loss of precision</p> Signup and view all the answers

    What is the approach used by GIF to tackle the compression problem?

    <p>Reducing the number of colors that can be assigned to a pixel</p> Signup and view all the answers

    What is the main advantage of using GIF in simple animation applications?

    <p>Transparency option and relative simplicity</p> Signup and view all the answers

    What is the purpose of averaging chrominance values in JPEG's baseline standard?

    <p>To take advantage of the human eye's limitations</p> Signup and view all the answers

    What is the limitation of GIF in terms of color representation?

    <p>Limited to 256 colors</p> Signup and view all the answers

    What is the main difference between JPEG's lossless mode and its baseline standard?

    <p>Level of precision required</p> Signup and view all the answers

    What is the purpose of applying the discrete cosine transform to each eight-by-eight-pixel block during JPEG compression?

    <p>To convert the original block into another block reflecting pixel relationships</p> Signup and view all the answers

    What is the typical compression factor achieved by JPEG's baseline standard?

    <p>At least 10, and often as much as 30</p> Signup and view all the answers

    What is the primary use of TIFF in the photography community?

    <p>As a standardized format for storing photographs along with related information</p> Signup and view all the answers

    What happens to values below a predetermined threshold in the new block after applying the discrete cosine transform?

    <p>They are replaced by zeros</p> Signup and view all the answers

    What type of encoding techniques are used to obtain additional compression in JPEG after applying the discrete cosine transform?

    <p>Run-length encoding and variable-length encoding</p> Signup and view all the answers

    Study Notes

    Representing Sound

    • Sound amplitude is experienced as loudness of sound
    • To encode sound, sample amplitude at regular intervals and record the values
    • For long-distance telephone communication, 8000 samples per second are recorded
    • For high-fidelity music recordings, 44,100 samples per second are recorded
    • Each sample is recorded in 16 bits (or 32 bits for stereo)

    Alternative Method: MIDI

    • Musical Instrument Digital Interface (MIDI) encodes directions for producing music instead of storing music itself
    • 2 seconds of sound can be stored in 3 bytes instead of 2 million bits
    • MIDI recordings can be different when performed on different synthesizers

    Binary Notation

    • In binary notation, each position can have a value of 0 or 1
    • Each position represents a power of 2 (2^0, 2^1, 2^2, etc.)
    • To represent a decimal number in binary, convert each digit to its binary equivalent
    • Example: 375 in decimal is 101110111 in binary

    Binary Addition

    • There are 4 possibilities when adding two binary digits: 0+0, 0+1, 1+0, and 1+1
    • When adding two binary numbers, perform addition from right to left, carrying over any 1's
    • Example: 101 + 110 = 1001

    Fraction in Binary

    • A radix point separates the whole number part from the fractional part
    • The whole number part is represented in binary, and the fractional part is represented as a series of binary digits
    • Example: 10.011 in binary represents the decimal number 2.75

    2's Complement Notation

    • A popular system for representing integers in computers
    • Fixed number of bits are used to represent each value (e.g. 32 bits)
    • Positive numbers are represented as is, while negative numbers are represented as the 2's complement of their absolute value
    • The leftmost bit is the sign bit (0 for positive, 1 for negative)
    • Example: 0111 in 2's complement notation represents the decimal number 7

    Excess Notation

    • Another method of representing integer values
    • A fixed number of bits are used to represent each value (e.g. 8 bits)
    • Each value is represented as an excess of its original value in binary
    • Example: 1011 in excess notation represents the decimal number 11

    Floating-Point Notation

    • A way of storing values with fractional parts
    • The value is stored as a mantissa, exponent, and sign bit
    • The mantissa is a fractional part represented in binary
    • The exponent is a power of 2 represented in excess notation
    • Example: 01101011 in floating-point notation represents the decimal number 23/4

    Truncation Errors in Floating-Point Notation

    • Occur when the mantissa field is not large enough to store the value accurately
    • Can be reduced by using a longer mantissa field
    • Another source of truncation errors is nonterminating expansions, such as 1/3 in decimal notation
    • Can be handled by using longer formats, or by using intelligent processing techniques

    Data Compression: Generic Techniques

    • Data compression schemes can be lossless or lossy

    • Run-length encoding is a lossless technique that replaces sequences of identical data elements with a code

    • Frequency-dependent encoding is a lossless technique that uses variable-length codes based on frequency of use

    • Huffman codes are a type of frequency-dependent encoding

    • Relative encoding, also known as differential encoding, records the differences between consecutive data units

    • Dictionary encoding techniques use a collection of building blocks to construct the message being compressed### LZW Encoding

    • LZW encoding is a dictionary-based encoding method that starts with a basic dictionary and adds new entries as larger units are found in the message.

    • As the dictionary grows, more words or recurring patterns of words can be encoded as single references to the dictionary.

    • The decoding process can start with the original small dictionary and add new entries as it encounters them, just like the encoding process.

    Example of LZW Encoding

    • Consider the message "xyx xyx xyx xyx" with a starting dictionary containing "x", "y", and a space.
    • The encoding process would add "xyx" to the dictionary as a new entry and continue to encode the message as "121343434".
    • The decoding process would start with the original dictionary, decode "1213" as "xyx" followed by a space, and add "xyx" to the dictionary as a new entry, and so on.

    Data Compression: Compressing Images

    • GIF (Graphic Interchange Format) is a dictionary encoding system that reduces the number of colors to 256, each represented by a single byte.
    • The system uses a palette of 256 colors, and each pixel is represented by a single byte indicating its color in the palette.
    • GIF can be extended to an adaptive dictionary system using LZW techniques, adding patterns of pixels to the dictionary for more efficient encoding.

    GIF Features

    • GIF is a lossy compression system when applied to arbitrary images.
    • One of the colors in the GIF palette is usually set to "transparent", allowing the background to show through.
    • GIF is suitable for simple animation applications, but not for high-precision applications like photography.

    JPEG Compression

    • JPEG (Joint Photographic Experts Group) is a standard for compressing color photographs.
    • JPEG has a lossless mode, but it is rarely used due to its limited compression.
    • The JPEG baseline standard is the most widely used, which provides a good balance between compression and quality.

    JPEG Baseline Standard

    • The first step is to average the chrominance values over 2x2 pixel squares, reducing the size of the chrominance information by a factor of four.
    • The image is then divided into 8x8 pixel blocks, and each block is compressed using the discrete cosine transform.
    • Values below a predetermined threshold are replaced by zeros, reflecting the limitations of the human eye.
    • Traditional run-length, relative, and variable-length encoding techniques are then applied to obtain additional compression.

    JPEG Compression Ratio

    • The JPEG baseline standard normally compresses color images by a factor of at least 10, and often by as much as 30, without noticeable loss of quality.

    TIFF Compression

    • TIFF (Tagged Image File Format) is primarily used as a standardized format for storing photographs with related information.
    • The image itself is normally stored without compression, but the TIFF standards include data compression techniques for compressing images of text documents in facsimile applications.
    • The color image compression option in TIFF is based on techniques similar to those used by GIF and is not widely used in the photography community.

    Studying That Suits You

    Use AI to generate personalized quizzes and flashcards to suit your learning preferences.

    Quiz Team

    Description

    Learn about the representation of sound and alternative methods like MIDI. Understand how sound amplitude is experienced and how it's encoded for communication and music recordings.

    More Like This

    Sound and Light Flashcards
    24 questions

    Sound and Light Flashcards

    LuminousGadolinium avatar
    LuminousGadolinium
    Sound Devices Flashcards
    8 questions
    Use Quizgecko on...
    Browser
    Browser