0% found this document useful (0 votes)
7 views2 pages

Lab3 DS412

This lab focuses on visualizing the composition of linear transformations using MATLAB. Students will apply and plot transformations T6, T7, T8, and T9 on a defined input space, observing the effects of each transformation separately and in composition. Deliverables include MATLAB code and a lab report detailing objectives, setup, results, and inferences.

Uploaded by

b22171
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
7 views2 pages

Lab3 DS412

This lab focuses on visualizing the composition of linear transformations using MATLAB. Students will apply and plot transformations T6, T7, T8, and T9 on a defined input space, observing the effects of each transformation separately and in composition. Deliverables include MATLAB code and a lab report detailing objectives, setup, results, and inferences.

Uploaded by

b22171
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

Lab 3 - Linear Transformations - (II)

Instructor: Dr. Adarsh Patel DS412

Objective: This lab explores compositions of linear transformations with the goal of understanding
their effects visually.

Background
The composition of linear transformations refers to the combination of two or more transformations
applied sequentially. If T1 : Rn → Rm and T2 : Rm → Rp are two linear transformations, their
composition is denoted as:
(T2 ◦ T1 )(x) = T2 (T1 (x)).
This composition results in a new linear transformation, which can also be represented by the product
of the corresponding matrices:
T2 ◦ T1 = M2 M1 .
The order of transformations is important since matrix multiplication is not commutative.

Input Space Plot


Consider the input space R2 , where any vector is represented as [x, y]T . The process to visualize the
input space over the range [−2, 3], with equally spaced grid lines is shown below.
1. Define the limits: Set the x- and y-coordinates from −2 to 3 with unit spacing.
2. Generate the Grid Lines:
(a) Utilize MATLAB’s meshgrid function to construct a 2D grid of coordinate points.
(b) Store the generated grid points in two matrices, representing the X- and Y -coordinates.
Each row (column) of X and Y corresponds to a horizontal (vertical) grid line.
(c) Plot all the grid lines within the same figure, use solid red lines for horizontal grid lines and
dashed blue lines for vertical grid lines. (Useful MATLAB functions: plot(), hold on).

Lab Questions on Composition of Linear Transformations


1. Given the following transformation matrices:
   
1 1 −1 0
T6 = and T7 = .
0 1 0 1

Apply the composition of these transformations (T6 followed by T7 ) to the input space. Plot
the following separate subplots within a single figure:
(a) The input space before any transformation.
(b) The transformed space after applying T6 .
(c) The transformed space after applying T7 .
(d) The composition of both transformations (T6 followed by T7 ).
This will allow you to observe how the transformations evolve separately and together within
the same figure.
2. Given the following transformation matrices:
   
1 1 −1 1 0
T8 = √ and T9 = .
2 1 1 0 −1

Apply the composition of these transformations (T8 followed by T9 ) to the input space. Plot
the following separate subplots within a single figure:

1
(a) The input space before any transformation.
(b) The transformed space after applying T8 .
(c) The transformed space after applying T9 .
(d) The composition of both transformations (T8 followed by T9 ).

Deliverables
1. MATLAB code for implementing and visualizing each transformation.
2. Plots comparing input and output spaces.

Submission Guidelines: Follow these simple steps for lab assignment submission:
1. Submit a lab report (PDF on LMS) and MATLAB code (.m files on MATLAB Grader).

2. The report must include: Objectives, Simulation Setup, Results, and Inferences.
3. Ensure originality in both the report and code. Plagiarism is strictly prohibited and will result
in penalties.

You might also like