Question
MATlab coding assignment ****** I have the code for part a, well most of it, my real issue is part b, if someone could code
MATlab coding assignment ****** I have the code for part a, well most of it, my real issue is part b, if someone could code both that'd be nice, but here's my code for part A!
a)
% givensrot.m
function Gval =givensrot(n1,i1,j1,theta) % func generate
if(i1=j1 || j1>n1) % condition process
Gval = []; % return matrix
return % display
end % end
Gval = eye(n1); % gkk matrix
Gval(i1,i1) = cos(theta);
Gval(j1,j1) = cos(theta);
Gval(j1,i1) = -sin(theta);
Gval(i1,j1) = sin(theta);
end % End of function
%main.m
Gval =givensrot(4,3,2,pi/2)
Gval =givensrot(5,2,4,pi/4)
Gval =givensrot(3,1,2,pi)
ExercIsE3 (5 points) Theory: The transformation defined by the matrix A- performs a rotation in x1x2-plane through the angle ? radians in the counterclockwise direction for a positive angle 0. The same type of a "plane" rotation in x.x, -plane can be performed in IR" (n2 2, lStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started