Write function named bell that creates actual sound signal

Assignment Help Other Subject
Reference no: EM131261670

Introduction to Signal Analysis Lab: AM & FM Signals

The objective of this lab is to generate samples of frequency modulated sound signals that mimic musical instruments such as bell. We will study the effect of modulation by listening to the signal converted to audio via the MATLAB command sound. This set of instructions is adapted from your textbook (DSP First - A Multimedia Approach), Section C.4.4.

I. Generating the Bell Envelopes

1. Write a function named bell_env that generates the bell's amplitude envelope, A(t), and modulation index envelope, I(t), which are both decaying exponentials given by the following equations:

A(t) = A0e-t/τ

I(t) = I0e-t/τ

The function should have the following input and output parameters:

Inputs:

  • A0: scale factor for amplitude envelope (real and positive)
  • I0: scale factor for modulation index (real and positive)
  • tau: time constant (real and positive)
  • dur: duration of the envelope (real and positive)
  • fsamp: sampling rate (integer and positive)

Outputs:

  • t: time vector ranging from 0 to dur with the sampling rate of fsamp
  • At: vector containing samples of the amplitude envelope
  • It: vector containing samples of the modulation index envelope

2. An error message should be generated if any of the inputs does not meet the specified conditions.

3. The function should define the time vector based on fsamp and dur in the first step, and use it in the second step to generate the decaying exponentials.

II. Parameters for the Bell

1. Write a function named bell that creates the actual sound signal for the bell by specifying the parameters in the FM synthesis formula given below:

X(t) = A(t) cos(2πfct + I(t) cos(2πfmt - π/2) - π/2)

The function should have the following input and output parameters:

Inputs:

  • ff: frequency vector containing fc and fm (1 × 2 matrix with real elements)
  • A0: scale factor for amplitude envelope (real and positive)
  • I0: scale factor for modulation index (real and positive)
  • tau: time constant (real and positive)
  • dur: duration of the envelope (real and positive)
  • fsamp: sampling rate (integer and positive)

Output:

  • X: vector containing samples of the bell signal

2. An error message should be generated if any of the inputs does not meet the specified conditions.

3. The first and second elements of the input vector ff should be stored in variables named fc and fm respectively.

4. In order to calculate the time vector, t, as well as the bell envelopes, At and  It,  the function bell_env should be called with input arguments A0, I0, tau, dur, and fsamp.

5. The bell function should use the FM synthesis formula to generate samples of the bell signal and store them in the output variable,  X.

6. The function should convert the bell signal to sound using the MATLAB function sound. It should also compute and plot the spectrogram of the bell signal using the MATLAB function spectrogram with the following syntax:

win=2048; noverlap=1024;           nfft=2048;

spectrogram(X , win, noverlap, nfft , fsamp)

7. The function should plot about 300 samples from the middle of the signal in a second figure window with proper axis labels and  title.

8. Call the function in the command window for the following input sets:

CASE

fc(Hz)

fm(Hz)

A0

I0

τ(sec)

Tdur(sec)

fsamp(Hz)

1

110

220

1

10

2

6

11025

2

110

220

1

10

12

3

11025

3

110

220

1

10

0.3

3

11025

4

220

440

1

5

2

6

11025

5

250

350

1

5

2

5

11025

6

250

350

1

3

1

5

11025

Listen to the signal. What comments can you make regarding the sound quality? Describe how the frequency content changes, and how that change is related to I0, τ, and Tdur.

Questions

1. Try to find a closed form expression for the instantaneous frequency of the bell signal, fi(t). The equation for the bell signal is provided in part II. What is the frequency of the signal at t = 0?

2. Try to find the fundamental frequency of the bell sound signal, denoted by f0, from the second plot generated for each input set in part II (Hint: find the fundamental period from the plot and invert it to obtain the fundamental frequency).  Try to verify if the value you obtained for fundamental frequency is correct by listening to the sound. What is the relationship between f0 and the input frequencies, fc and fm? Is the lowest frequency component in the spectrogram of the sound signal always equal to the fundamental frequency? Provide a brief discussion of your results in each one of the above six cases.

3. Try to express the harmonic pattern of the bell signal in terms of the fundamental frequency, f0, carrier frequency, fc, and modulating frequency, fm (Hint: consider at least 7 frequency components in the spectrogram of each input set and study their relationship). Feel free to test your function with other combinations of fc and fm.

Attachment:- Project Report Format.rar

Reference no: EM131261670

Questions Cloud

Define disease management programs : Identify challenges in DM programs. Examine a successful DM program from real life and address (a) What is its accreditation status? (b) Why is this program successful? and (c) Can it be replicated in other settings?
What do you think city of phoenix did best in its process : From what you read, what do you think the City of Phoenix did best in its process? Develop 2-3 potential performance measures that could help leaders track the effectiveness of a program after implementation.
Find the optimal temperature versus time profile for reactor : Find the optimal temperature versus time profile for the reactor and determine how long the process should be operated before the catalyst is changed out.
Describe the current media situation in south africa : Write a Digital Report on Media Trends in a country of your choice. - Describe the current media situation in South Africa.
Write function named bell that creates actual sound signal : ECE 201 - Introduction to Signal Analysis Fall 2016 Lab: AM & FM Signals. Write a function named bell that creates the actual sound signal for the bell by specifying the parameters in the FM synthesis formula given below: X(t) = A(t) cos(2πfct + I(..
Prepare a description of the agency : Prepare a description of the agency, the population it serves, and the services it provides. Identify the person you are going to interview by title and provide a brief description of this person's duties and/or role in the agency or organization.
Find the final solution volume and the shaft work : Calculate the final solution volume and the shaft work in kW that the pump must deliver, assuming that the surface of the stored solution and the pipe outlet are both at 1 atm. Data. PH2O = 1.00 kg/L, Pgly = 1.26 kg/L. (Use to estimate solution de..
How are these models used to identify system parameters : How are these models used to identify system parameters and recognize, in turn, the symptoms, problems, and causes that result in ineffective organizations?
Identify what done well weaknesses and areas for improvement : Primary Task Response: Your first task is to post your own Key Assignment Outline to the discussion area so that other students are able to review your plan. Attach your document to the main discussion post, and include any notes you feel are appr..

Reviews

len1261670

11/1/2016 1:54:19 AM

Please follow the lab report format that was attached. The objective of this lab is to generate samples of frequency modulated sound signals that mimic musical instruments such as bell. We will study the effect of modulation by listening to the signal converted to audio via the MATLAB command sound. This set of instructions is adapted from your textbook (DSP First - A Multimedia Approach), Section C.4.4.

Write a Review

Other Subject Questions & Answers

  What are the central theses of the texts at hand

What are the central theses of the texts at hand? What is the main idea of the passage? Note key terms or issues. What quote(s) from the reading capture(s) the main idea.

  Find the approximate return to the fifth year of experience

At what value of exper does the additional experience actually lower predicted log (wage)? How many people have more experience in this sample?

  Identify the factors that affect toxicity in a population

Identify the factors that affect toxicity in a population. Pick three of the factors and provide a brief discussion on how that factor can affect the health of a population.

  Explain the best type of the floor surface for a baby room

What is the best type of the floor surface for a baby room and a hospital?

  Ethical perspectives in the global organization.

Describe a viable solution for this issue that could be acceptable by all stakeholders.

  What is the highest concentration of dissolved fluoride

A water supply has very hard water with calcium ion (Ca2+) concentration of 200 mg/L. With such hard water, what is the highest concentration of dissolved fluoride (in mg/L) that could be provided in the finished water if no softening is performed..

  Relationship between psychopathy and criminal behavior

Explain the relationship between psychopathy, criminal behavior, and recidivism. Can age, gender, or socioeconomic status influence the psychopathy or diagnosis of antisocial personality disorder?

  Explain the role of the nervous system

Explain the role of the nervous system - Describe the effect of fear, aggression, or anxiety on the specified behavior.

  How does the theory of psychological egoism fit within the

find a contemporary article showing how the theory of psychological egoism in a corporation resulted in an ethical

  Define what it means for something to be natural

On first glance, how would you define what it means for something to be "natural"? According to Called to Care, the textbook, what does the Bible tell us about natural creation or the "natural" world?

  Explain behavior using humanistic and social perspectives

Jasper, often become overly critical of others. Use psychoanalytic, humanistic and social -cognitive perspectives to give three contrasting description of his behavior.

  What advantages have you benefitted from why havent they

1.what advantages have you benefitted from? why havent they been enough to catapult you to an outlier level of success?

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd