- Premium Academic Help From Professionals
- +1 301 710 0002
- support@usaelitewriters.com

Finance Upper Division

Solve and send answers numerically! Need it ASAP! Finance and Valuation. Advanced!

Matlab-Spice Project – EE-310

This is a practical project that uses circuitry and signal processing to analyze evidence for a jury

trial.

You must work in groups of two to four on this project. (Each group member should submit the

report individually, where the page after cover page should state the contribution each group

member.) Your report should have a professional appearance and be created in Microsoft Word

or LaTeX. You can also include handwritten equations in an appendix, but they must be properly

referenced and clearly written. Equations in the body of the report should be created with an

equation editor (e.g. https://codecogs.com/latex/eqneditor.php, or the one included in Word).

For this project you will need MATLAB and LTSpice. You can download a copy of LTSpice from

the Analog Devices website. MATLAB is available through the University. You may refer to the

separate tutorials given in the lecture on them for your references.

Introduction

In this project, you are to serve as an expert witness in a courtroom trial. The defense has

submitted as evidence a 10-second audio snippet from a recorded telephone call. The prosecutor

suspects that the recording has been altered to add or omit words, and has hired you to review

the recording and assess its authenticity.

You suspect that the recording was made in an office environment lit by fluorescent lighting, and

experience tells you that these lights emit a weak 60 Hz humming sound that would be

captured on the recording. The amplitude of the captured 60 Hz hum will fluctuate with time,

but its phase should be perfectly continuous – unless, of course, the recording was altered. Your

strategy is to examine the phase trajectory of the 60 Hz hum by extracting it from the person

speaking and the ambient room noise. If the phase exhibits discontinuities, you will conclude

that the recording has been altered and is therefore tainted evidence.

Discussion

The signal processing steps are shown in Figure 1. The input on the left, “Evidence File,” is a .wav

file containing the audio evidence sample. The circuit simulator, LTSpice will be used to filter

the audio sample with the 60 Hz bandpass filter shown in Figure 2. This filter removes the

speech and most of the noise from the sample, leaving only the 60 Hz hum from the fluorescent

lighting. It is tempting to think that any discontinuity could easily be seen on a plot of the

bandpass filtered output. But there are two problems:

1) The amplitude of the hum will change with time even though the phase may not. You

need to differentiate between amplitude and phase changes.

2) The bandpass filter is narrowband and will therefore smooth out any phase discontinuity

thereby making it difficult to see without additional processing.

To unmistakably assess the phase continuity, the phase of the incoming signal must be

compared with a known reference signal with the exact same frequency. In other words, the

phase of the incoming hum must be compared to the phase of a perfect sinewave. This is shown

on the right of Figure 1 and done using a MATLAB script.

Figure 1 – Signal Processing

The upper input to the multiplier block, !!!!!!(“”), comes from the “Filtered Evidence” signal and

contains the 60 Hz hum:

(1)

Where #!n is the amplitude of the hum, and ∅!n is its phase offset.

The second signal entering the multiplier block is the reference signal and is:

(2)

The multiplier block output is !!n(“) · !$ef(“). Using the trigonometric identity for multiplying

sinewaves ( ) allows the product to be expressed as:

(3)

If %!n = %$ef = % then this expression becomes:

(4)

The first term in this expression will have frequency equal to 2% or 120 Hz and is removed by the

lowpass filter following the multiplier leaving an output of:

(5)

It is known that #!n will exhibit fluctuations with time. Also, ∅!n would have a step change if there

was a phase discontinuity. This time dependence is captured in Equation 6.

Bandpass

filter

Evidence

File.wav

Filtered

Evidence.wav

LTSpice

MATLAB

Cos 60 Hz

44 kHz 16-bit

mono

44 kHz 16-bit

mono

Lowpass

filter

Plot

Phase

difference

s in ( t )

sr ef ( t )

(6)

Equation 6 shows that fluctuations in Ain will cause fluctuations in the output signal. If the signal

has a phase discontinuity, the *os(∅!n) term will change abruptly, and the result will be evident in

the output.

Summary of Steps and Grading Rubric

- Download the file “EvidenceFile.wav” and listen to it. Describe whether you can hear

hum from the fluorescent lights and whether you hear any gaps. If you suspect gaps, at

what time in the file do they occur? (0.5 points) - Use MATLAB and mesh/node analysis to plot the frequency response of the filter shown

in Figure 2. Your frequency axis should be linear and cover the range 10 to 110 Hz in 1 Hz

steps. Your vertical axis should cover from 0 to -40 dB. Determine the filter Q from your

plot using the center frequency/3 dB bandwidth formula. Include a listing of the

MATLAB code in the appendix of your report. (1 points) - Implement the filter from Figure 2 using LTSpice. Use AC analysis to plot the frequency

response. Include your schematic in your report. Your plot axes should be the same as in

the previous step. (1 points) - Feed your LTSpice circuit with the file “Evidence.wav.” Include a plot of the filter output

in your report. Comment on whether you see anything suggesting the audio has been

altered. Write the filter output to the file “Filtered Evidence.wav.” (2 points) - Use MATLAB and the properties of the Laplace transform to compute the frequency

response of the averaging FIR filter shown in Figure 3. Include a frequency response plot

in your report. Your frequency axis should be linear and cover the range 0 to 150 Hz in 1

Hz steps. Your vertical axis should cover from 0 to -40 dB. Observe your plot and

determine whether the filter will remove the undesired 120 Hz artifact from the

multiplier. (1.5 points) - Write a MATLAB script that accepts the file “FilteredEvidence.wav” and performs the

signal processing operations shown on the right of Figure 1. Include a listing of the

MATLAB code in the appendix of your report. (1 points) - Plot the output from the MATLAB script and include it in your report. (1 points)
- Prepare a one-paragraph statement to the court indicating your expert opinion on

whether you believe the evidence is tainted and the basis for your conclusions. (1 points) - Your report should have a professional appearance and be created in Microsoft Word,

LaTeX, or a similar publishing program. You may include handwritten equations in an

appendix, but they must be properly referenced and clearly written. Equations in the

body of the report should be created with an equation editor such as the one included in

Word. (1.5 points)

Procedure – Details for Selected Steps

Step 2

You can use Node or Mesh analysis. You can also employ ladder analysis if you will, but it is not

necessary. We covered MATLAB code for similar resistive circuits that can be generalized to this

bandpass filter.

Step 3

Implement this filter in LTSpice. Compute frequency response by setting the simulation

command for AC analysis. AC analysis plots dBV or dB with respect to 1 Vpk. Set your voltage

source to provide 1 V for Small signal AC analysis and then the plot will show dB from the input

and output. Please configure your simulation as shown below:

Figure 3 – Simulation configuration for frequency response

+- C 1

C 2

L 1

L 2

C 3 L 3

R S C 4 L 4

1 k Ω

R L

1 k Ω

11.65 μF 0.6039 H

250.1 nF 28.13 H

28.13 μF 0.2501 H

Output

Input

Figure 2 – Analog bandpass filter

This filter is an N=4 Butterworth bandpass with 3 dB frequencies of 55.0 and 65.45 Hz. There

are lots of active filter design websites (including on the Analog Devices website). If you want

more of a challenge, design this filter as an active filter and use your op-amp filter instead of this

one.

Step 4

Do the following to use the wave file Evidence File.wav, as a circuit input:

1) Make sure your wavefile is in the same directory as the schematic file.

2) Instantiate a voltage source at the circuit input.

3) Note that the voltage source will have a reference designator and a value. Value is below

the reference designator.

4) Right click on the value field. You will see a selection box where you can change the

value. (if you get a selection box with more parameters, you clicked on the voltage source

– not its value field

5) In the value field, enter the text: “wavefile=Evidence File.wav” (no quotes)

Do the following to write the circuit output to a wave file, Output.wav.

1) Right click the output node and give it the label “Out”. (no quotes)

2) Include the Spice Directive “.wave output.wav 16 44.1K Out Out” on the schematic.

Please configure your simulation as shown below:

Figure 4 – Simulation configuration for transient response

Step 5

Figure 5 shows the low pass filter in the MATLAB block. This is a Finite Impulse Response (FIR)

averaging filter. It consists of exactly 3675 register locations. Input data is shifted left to right

through the register at the sample rate of 44.1 kHz. The output sample is created by summing all

the registers and then scaling by 1/3675.

Figure 5 – Lowpass filter

Close examination of Figure 5 shows that it is a discrete convolver. Since the sample rate is high

relative to the signal bandwidth, we will analyze this filter by treating the register locations as

delays as shown in Figure 4.

Figure 6 – Lowpass filter represented as a continuous-time filter. There will be 3675 delays in your filter

With the filter represented as shown in Figure 6, its impulse response can be determined by

inspection using the delay property of Laplace transforms. It is:

(7)

and, using the delay property of Laplace transforms, the transfer function is:

Σ

1 2 3 9 …

3675

OUT

1/3675

From

multiplier

block

τ =1 /F S τ =1 /F S τ =1 /F S

Σ

OUT

Input

- (8)

The frequency response is obtained by substituting ! = ./ into Equation 8.

Step 6

The MATLAB processing shown on the right of Figure 1 can be realized with the lines of code

below:

Figure 7 – MATLAB code for demodulator structure

Hint: There are three files provided as a curtesy of Prof. Dorr that could be used if you wish.

Ladder.pdf and the .m file for the script – It can help with step 2 if you decided to leverage

ladder analysis.

Are you busy and do not have time to handle your assignment? Are you scared that your paper will not make the grade? Do you have responsibilities that may hinder you from turning in your assignment on time? Are you tired and can barely handle your assignment? Are your grades inconsistent?

Whichever your reason may is, it is valid! You can get professional academic help from our service at affordable rates. We have a team of professional academic writers who can handle all your assignments.

Our essay writers are graduates with diplomas, bachelor, masters, Ph.D., and doctorate degrees in various subjects. The minimum requirement to be an essay writer with our essay writing service is to have a college diploma. When assigning your order, we match the paper subject with the area of specialization of the writer.

- Plagiarism free papers
- Timely delivery
- Any deadline
- Skilled, Experienced Native English Writers
- Subject-relevant academic writer
- Adherence to paper instructions
- Ability to tackle bulk assignments
- Reasonable prices
- 24/7 Customer Support
- Get superb grades consistently

PLACE THIS ORDER OR A SIMILAR ORDER WITH USA ELITE WRITERS TODAY AND GET AN AMAZING DISCOUNT