Create problem2.m and use appropriate MATLAB function (if applicable) to solve:
ID: 2324211 • Letter: C
Question
Create problem2.m and use appropriate MATLAB function (if applicable) to solve: A= [2 0 1 1 -1 2 3 1 1] and B = [2 -1 4 0 -1 3 3 -2 1] Verify that det (AB) = det (A) det(B). Verify that det (A^-1) = 1/det(A). Verify that (AB)^-1 =B^-1 A^-1. Report A(:, 2:3) and C=A(:, 1) Report B(1:2, 2:3) and D=B(:, 3) Report "setdiff (C, D)" explain what this function does. You can use MATLAB help by entering "help setdiff" in the command window. Use the following command: A(2, 1:3)=B(3, 1:3), then report new A matrixExplanation / Answer
A=[2,0,1;1,-1,2;3,1,1];
B=[2,-1,4;0,-1,3;3,-2,1];
test1=det(A*B)-det(A)*det(B);% if test is zero both are equal
test2=det(inv(A))-(1/det(A));% if test is zero both are equal
test3=inv(A*B)-inv(B)*inv(A);% if test is zero both are equal
A(:,2:3);%columns 2 and 3
C=A(:,1);%first column
B(1:2,2:3); % two rows of columns2 and 3
D=B(:,3) %third column
setdiff(C,D) % help setdiff%
A(2,1:3)=B(3,1:3)
Related Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.