Consider vectors of N time samples. In the time domain, the basis vectors , for n...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
Consider vectors of N time samples. In the time domain, the basis vectors , for n = {0, 1,..., N-1} have a 1 in the n'h slot and a zero elsewhere. In that basis, a signal x[n] is written as an N-vector = x[n]n. V-1 n=0 Let's consider sinusoidal basis vectors b, for k (0, 1,..., N-1}. In order to write the vector in this new basis, we'll need to know the projection of these basis vectors onto the original basis vectors. Please assume that the projection of the new basis vector of index k onto the original basis vector with index n equals (n|bx) = e/2 and the projection the other way (from old basis vector to new basis vector) equals its complex conjugate (bxln) = te 2x#. We can use these projections to write by, the new basis vector with index k, in the original basis as the N-vector of time samples e/2x4 for n (0, 1,..., N 1}. Likewise, we can write original basis vector , as an N-vector in the new basis ase for k (0,1,..., N 1}. (a) Given a value of N, write a Python function that returns an NX N numpy array (matrix) where the kth column is the basis vector written as an N- vector in the original basis. (Note that this will be a matrix of complex numbers.) I will refer to this below as the inverse matrix. (b) Write a Python function that takes an N X N inverse matrix (where the columns are the new basis vectors as vectors in the original basis) and returns an NX N numpy array where the element in the kth row and ph column is the inner product (1)=bb. Examining the results for N = 4, are the sinusoidal basis vectors orthonormal? Explain. (c) Write another function that returns an Nx N numpy array where the column is the basis vector , written as an N-vector in the new, sinusoidal basis. (Note that this will be a matrix of complex numbers.) I will refer to this below as the forward matrix. Explain how the forward matrix is related to the inverse matrix. Examining the results for N = 4, what do you get when you matrix multiply these two matrices? (d) Let's take a time signal in the original basis and see what it looks like in the sinusoidal basis. Take N = 1024 samples of a 1 kHz sine wave with Amplitude A = 1, sampled at F, = 44, 100 Hz. Matrix multiply this signal by the forward matrix for N = 1024. The result will be a complex N-vector iva -convert it to dB using 20. * np. log10 ( np.abs(v)) and plot the result. Also pass the signal to np.fft.fft() to get the DFT of the signal to S and plot it using the same dB measure. Discuss what you find. Try using f = np.arange (N) * Fs/N in a plot of f (x-axis) vs. dB (y-axis). What do you find? What happens if you subract 10 np. log10 (N) from your dB curve computed using np.fft.fft() ? Consider vectors of N time samples. In the time domain, the basis vectors , for n = {0, 1,..., N-1} have a 1 in the n'h slot and a zero elsewhere. In that basis, a signal x[n] is written as an N-vector = x[n]n. V-1 n=0 Let's consider sinusoidal basis vectors b, for k (0, 1,..., N-1}. In order to write the vector in this new basis, we'll need to know the projection of these basis vectors onto the original basis vectors. Please assume that the projection of the new basis vector of index k onto the original basis vector with index n equals (n|bx) = e/2 and the projection the other way (from old basis vector to new basis vector) equals its complex conjugate (bxln) = te 2x#. We can use these projections to write by, the new basis vector with index k, in the original basis as the N-vector of time samples e/2x4 for n (0, 1,..., N 1}. Likewise, we can write original basis vector , as an N-vector in the new basis ase for k (0,1,..., N 1}. (a) Given a value of N, write a Python function that returns an NX N numpy array (matrix) where the kth column is the basis vector written as an N- vector in the original basis. (Note that this will be a matrix of complex numbers.) I will refer to this below as the inverse matrix. (b) Write a Python function that takes an N X N inverse matrix (where the columns are the new basis vectors as vectors in the original basis) and returns an NX N numpy array where the element in the kth row and ph column is the inner product (1)=bb. Examining the results for N = 4, are the sinusoidal basis vectors orthonormal? Explain. (c) Write another function that returns an Nx N numpy array where the column is the basis vector , written as an N-vector in the new, sinusoidal basis. (Note that this will be a matrix of complex numbers.) I will refer to this below as the forward matrix. Explain how the forward matrix is related to the inverse matrix. Examining the results for N = 4, what do you get when you matrix multiply these two matrices? (d) Let's take a time signal in the original basis and see what it looks like in the sinusoidal basis. Take N = 1024 samples of a 1 kHz sine wave with Amplitude A = 1, sampled at F, = 44, 100 Hz. Matrix multiply this signal by the forward matrix for N = 1024. The result will be a complex N-vector iva -convert it to dB using 20. * np. log10 ( np.abs(v)) and plot the result. Also pass the signal to np.fft.fft() to get the DFT of the signal to S and plot it using the same dB measure. Discuss what you find. Try using f = np.arange (N) * Fs/N in a plot of f (x-axis) vs. dB (y-axis). What do you find? What happens if you subract 10 np. log10 (N) from your dB curve computed using np.fft.fft() ?
Expert Answer:
Answer rating: 100% (QA)
a Heres a Python function that returns an NXN numpy array matrix where the kth column is the basis vector bk written as an Nvector in the original basis python Copy import numpy as np def getinversema... View the full answer
Related Book For
Posted Date:
Students also viewed these programming questions
-
Discuss the Trade-off model and explain its components and the theory behind it. What does that model say to us regarding the optimal capital structure of the firms?
-
Managing Scope Changes Case Study Scope changes on a project can occur regardless of how well the project is planned or executed. Scope changes can be the result of something that was omitted during...
-
Read the case study "Southwest Airlines," found in Part 2 of your textbook. Review the "Guide to Case Analysis" found on pp. CA1 - CA11 of your textbook. (This guide follows the last case in the...
-
Write a short report in which you assess the impact of one piece of health and safety legislation in an organisation of your choice.
-
What are two primary economic arguments that critics use against free trade?
-
In Table 5.2, review the options for avoiding a labor shortage, and discuss how well the options besides new hires could have worked as ways for Reed to reach his goals for growth. As you do so,...
-
Numerous accounting principles require companies to discount future cash flows when estimating amounts that are reported on financial statements. For example, the present value of a \($10,000\)...
-
Morales Company recorded the following selected transactions during November 2013. 1. Open a general ledger having T-accounts for Accounts Receivable, Sales, and Sales Returns and Allowances. Also...
-
4 0.66 Compute the IRR statistic for Project F. The appropriate cost of capital is 11 percent. Note: Do not round Intermedlate calculations and round your final answer to 2 decimal places. Project F...
-
Waylander Coatings Company purchased waterproofing equipment on January 6 for $1,031,600. The equipment was expected to have a useful life of four years, or 10,400 operating hours, and a residual...
-
Haskins Products sells 2 comma 200 kayaks per year at a sales price of $ 450 per unit. Haskins sells in a highly competitive market and uses target pricing. The company has calculated its target full...
-
Which approach to trust repair is an effort to create rules, regulations, and procedures to minimize the likelihood of trust violations in the future
-
a) Organizations are increasingly adopting team approach in management of employees. Outline the benefits of this approach to an organization . b) Explain the factors that influence customer...
-
Write a business simulation game report of 2000 words.
-
RENTAFI has a net income of 142943 euros. It has 100,000 shares outstanding at a unit price of 12 euros. Its Price to Book ratio is 1.5. What is its financial profitability (ROE)?
-
How has global competition affected productivity? Provide specific examples supporting your position. From the Internet, find an example supporting your position.Provide the Web site address of this...
-
Adam Bedwell died in 2012, leaving an estate of $27,000,000. Adam's wife died in 2009. In 2009, Adam gave his son property that resulted in a taxable gift of $6,000,000 and upon which Adam paid...
-
Linda Lopez opened a beauty studio, Lindas Salon, on January 2, 2011. The salon also sells beauty supplies. In January 2012, Lopez realized she had never filed any tax reports for her business and...
-
Use the Table of Integrals on Reference Pages 610 to evaluate the integral. TT cos'0 de
-
Evaluate the limit, if it exists. x + 2 lim x + 8 x-2
-
Find the volume of the solid that lies inside both of the spheres and x? + y? + z? + 4x 2y + 4z + 5 = 0 x + y? + z? = 4 .2 ,2
-
When calculating a firms return on total assets (ROA) ratio, some investment professionals modify the ROA ratio by adding back the interest expense paid by a firm to its creditors, on a net-of-taxes...
-
The Fremont Company has \($465\) million in assets, \($70\) million in current liabilities, \($125\) million in noncurrent liabilities, and \($270\) million in shareholders equity.Of the companys...
-
Presented below are selected financial data (in millions) for Bristol-Myers Squibb, The Coca-Cola Company, and the General Electric Company. Calculate the capital intensity ratio for each of the...
Study smarter with the SolutionInn App