Answered step by step
Verified Expert Solution
Question
1 Approved Answer
***Answering this question requires MATLAB for parts 3 and 4. If this is unavailable to you, please complete parts 1 and 2 only and I'll
***Answering this question requires MATLAB for parts 3 and 4. If this is unavailable to you, please complete parts 1 and 2 only and I'll still give thumbs up! Thanks ***
Problem 2: Shapeshifting in MATLAB Consider the initial polygon described by the points xo = (0,0), x = (0, 3), as well as the final polygon described by the points X" X" = (6, 1), and X" = (6,2). Assume that X" is the transformation of xn for n = 0, 1, 2, 3. For your written answers below, give numerical results (i.e., numbers rather than variables). (3,0), x2 = (3, 3), and (0, 2), X" = (0, -1), -: 1. For a uniform transformation (all points transformed the same way), the method used in Problem 1 is not the most efficient. Using homogenous coordinates, rewrite x and X' as ma- trices in order to optimize the procedure. How many elements are there in the transformation matrix T? 2. Write down exactly three separate transformation matrices (one scaling, one rotation, and one translation) that, when combined, transform x to X". Use the transformations in any order you like as long as the result is correct. 3. In MATLAB, plot each step in the same order on a separate subplot (four subplots total, including initial). Plot points in blue and sides in black. Label the points in each figure using the 'text' function. Use the correct number of "prime marks" to denote the transformation number (e.g., for the first point: xo, X6, X", and so on). Use a 4x1 subplot structure and set the following options for each subplot: 'hold on', 'grid on', 'axis(|-8 8 -8 8])', and 'daspect([1 1 1])'. Add a title to each subplot indicating the operation performed at that step (e.g., "initial", "scaling", and so on). 4. Just in case the indecisive graphic artist finds your code, add a section at the end that displays the single matrix that will undo the combined transformation. Problem 2: Shapeshifting in MATLAB Consider the initial polygon described by the points xo = (0,0), x = (0, 3), as well as the final polygon described by the points X" X" = (6, 1), and X" = (6,2). Assume that X" is the transformation of xn for n = 0, 1, 2, 3. For your written answers below, give numerical results (i.e., numbers rather than variables). (3,0), x2 = (3, 3), and (0, 2), X" = (0, -1), -: 1. For a uniform transformation (all points transformed the same way), the method used in Problem 1 is not the most efficient. Using homogenous coordinates, rewrite x and X' as ma- trices in order to optimize the procedure. How many elements are there in the transformation matrix T? 2. Write down exactly three separate transformation matrices (one scaling, one rotation, and one translation) that, when combined, transform x to X". Use the transformations in any order you like as long as the result is correct. 3. In MATLAB, plot each step in the same order on a separate subplot (four subplots total, including initial). Plot points in blue and sides in black. Label the points in each figure using the 'text' function. Use the correct number of "prime marks" to denote the transformation number (e.g., for the first point: xo, X6, X", and so on). Use a 4x1 subplot structure and set the following options for each subplot: 'hold on', 'grid on', 'axis(|-8 8 -8 8])', and 'daspect([1 1 1])'. Add a title to each subplot indicating the operation performed at that step (e.g., "initial", "scaling", and so on). 4. Just in case the indecisive graphic artist finds your code, add a section at the end that displays the single matrix that will undo the combined transformationStep 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