Question

Should be an easy one in MATLAB with a simple proof for part (a). Thanks for the help in checking my answers:

(Pencil-and-paper and MATLAB) L A be a non-singular n x n matrix. Then it has an inverse (a) Let the vectors ui, i 1,2,... n, be the columns of of A-1. Show that the wi satisfy the linear systems Au where v is a vector whose sole nonzero entry is 1 in the ith position. (b) se the above equation to compute A-1. Take A to be a 5 x 5 random matrix, which can be constructed by using the MATLAB command A rand (5). You may use the backslash or lu commands of MATLAB to solve the linear systems for the vi. (c) Check that the product A A recovers the identity matrix I Write a MATLAB script that carries out all the tasks listed above, and prints the results in a properly labelled form. The results should display the matrices A and A 1 and their product

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Sample Run:

Raw Paste Code of (b) & (c)

A=rand(5)

%initialize vis
v1=[1; 0; 0; 0; 0];
v2=[0;1; 0; 0; 0];
v3=[0; 0; 1; 0; 0];
v4=[0; 0; 0; 1; 0];
v5=[0; 0; 0; 0; 1];

%use backslash to find ui
u1=A\v1
u2=A\v2
u3=A\v3
u4=A\v4
u5=A\v5

%combine ui to produce A^-1

Ain=[u1 u2 u3 u4 u5]

%to check the value A*Ain=I
I=A*Ain

Add a comment
Know the answer?
Add Answer to:
Should be an easy one in MATLAB with a simple proof for part (a). Thanks for...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • MATLAB MATLAB MATLAB Consider the diagram below V R$ Here, each V represents a change in...

    MATLAB MATLAB MATLAB Consider the diagram below V R$ Here, each V represents a change in voltage (in volts) at a battery, each R represents a resistance in ohms) at a resistor and each I represents a current (in amps) through a wire. These quantities obey two simple laws: 1. Ohm's law: The voltage drop across a resistor is V = IR. 2. Kirchhoff's second law: The sum of all the voltage changes in a closed loop is zero. Using...

  • Need help with this MatLab exercise. Please show all commands in MatLab. Enter the following matrices...

    Need help with this MatLab exercise. Please show all commands in MatLab. Enter the following matrices and vectors in MATLAB [ 2 -6 3 ] [ 5 ] -3 A= 2 -7 -2 , B= 2 -2 -3 , b= -13 , c= 3 -1 4], d= 0 [ 7 -2 7 [1 -8 -1 ] [ 10 (a) Perform the following operations: AB, BA, CA and Bd (use standard linear algebra multiplication). - 3 (b) Construct a 6 x...

  • Linear equation question Use Matlab for b) and c) and show all the work Oct 3,ao16...

    Linear equation question Use Matlab for b) and c) and show all the work Oct 3,ao16 MTH 301: Matrix Theory and Applications Project 1 on Linear System of Equations, and LU factorization This project studies a problem on heat transfer, where a steady-state temperature distribution of a thin plate is sought when the temperature around the boundary is known. Assume the plate shown in the figure represents a cross-section of a metal beam with very negligible heat flow in the...

  • Please answer these Matlab questions when able. Thanks. 4. Laboratory Problem Description In this laboratory you...

    Please answer these Matlab questions when able. Thanks. 4. Laboratory Problem Description In this laboratory you are required to find eigenvalue and eigenvectors for A in the following systems of linear equation Ax-B: 17x1+2x2+3x3+4x44 5x1+6x2+7x3+8x4 3 9x1+10x2+11x3+12x4 2 13x1+14x2+15x3+16x4 1 Apply the following commands: >>A 1 12:211 Verify that the columns of X in the example above indeed are eigenvectors to the matrix A. In other words, multiply (using Matlab) the matrix A to the columns (one at a time)...

  • I need 7.3. This is a matlab question and I don't know what simple number is....

    I need 7.3. This is a matlab question and I don't know what simple number is. 7.3. Examine the eigenvalues of the family of matrices 「-2 1 0 0 1 0 0 一2 1 Dr =-N- 10 where Dv is N x N, for growing values of N, for example, N 32,64,128. The smallest eigenvalues converge to integer multiples of a simple number. 7.4. Verify, for a random 10 x 5 matrix, the identity i=1 where K-minrn, n), {σ1, ....

  • Using MATLAB, develop an M-file to determine LU factorization of a square matrix with partial pivoting....

    Using MATLAB, develop an M-file to determine LU factorization of a square matrix with partial pivoting. That is, develop a function called mylu that is passed the square matrix [A] and returns the triangular matrices [L] and [U] and the permutation P. You are not to use MATLAB built-in function lu in your codes. Test your function by using it to solve a system of equations listed below in part 3. Confirm that your function is working properly by verifying...

  • Can you help me with this question please? For the code, please do it on MATLAB. Thanks

    Can you help me with this question please? For the code, please do it on MATLAB. Thanks 7. Bonus [3+3+4pts] Before answering this question, read the Google page rank article on Pi- azza in the 'General Resources' section. The Google page rank algorithm has a lot to do with the eigenvector corresponding to the largest eigenvalue of a so-called stochastic matrix, which describes the links between websites.2 Stochastic matrices have non-negative entries and each column sums to1, and one can...

  • Do the following using Matlab: Let A be a matrix where each row corresponds to an...

    Do the following using Matlab: Let A be a matrix where each row corresponds to an article, and each column to how often a specific word appears in the article. Patterns among the articles and words can often be identified by analyzing the singular values and vectors of the singular value decomposition of A. (a) Use the Matlab svd function to find the singular values of the following . Note this problem does not ask you to print out the...

  • Please code in MatLab or Octave Output should match Sample Output in the second picture Thank...

    Please code in MatLab or Octave Output should match Sample Output in the second picture Thank You 4. In this problem we will investigate using loops to calculate the product of two matrices. Given an mxn matrix A and an n x p matrix B, the matrix product C = AB is the m xp matrix with Cij = R=1 Qikbky. Write a program which calls a function get matrix.dimensions which should • print a description of the purpose of...

  • In this exercise you will work with LU factorization of an matrix A. Theory: Any matrix A can be ...

    In this exercise you will work with LU factorization of an matrix A. Theory: Any matrix A can be reduced to an echelon form by using only row replacement and row interchanging operations. Row interchanging is almost always necessary for a computer realization because it reduces the round off errors in calculations - this strategy in computer calculation is called partial pivoting, which refers to selecting for a pivot the largest by absolute value entry in a column. The MATLAB...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT