Solved Exercises on Matrix-Vector Products as Transformations

Master matrix-vector products as transformations: linear transformations, geometric interpretations, and transformation properties through these 5 detailed exercises.

Solution: Exercises 1 to 3
1 Scaling Transformation
Exercise 1
Find the result of the scaling transformation represented by matrix A = \(\begin{bmatrix} 2 & 0 \\ 0 & 3 \end{bmatrix}\) applied to vector v = \(\begin{bmatrix} 1 \\ 2 \end{bmatrix}\)
Definition:

Scaling transformation: A diagonal matrix with positive entries scales coordinates independently

Method:
  1. Perform matrix-vector multiplication: Av
  2. Apply the formula: (Av)_i = Σ A_{ij}v_j
  3. Interpret the geometric transformation
Input vector
v = \(\begin{bmatrix} 1 \\ 2 \end{bmatrix}\)
Result
Av = \(\begin{bmatrix} 2 \\ 6 \end{bmatrix}\)
Step 1: Set up the multiplication

Av = \(\begin{bmatrix} 2 & 0 \\ 0 & 3 \end{bmatrix} \begin{bmatrix} 1 \\ 2 \end{bmatrix}\)

Step 2: Calculate first component

(Av)_1 = (2×1) + (0×2) = 2 + 0 = 2

Step 3: Calculate second component

(Av)_2 = (0×1) + (3×2) = 0 + 6 = 6

Step 4: Interpret geometrically

The transformation scales the x-coordinate by factor 2 and y-coordinate by factor 3

Point (1, 2) becomes (2, 6)

Av = \(\begin{bmatrix} 2 \\ 6 \end{bmatrix}\)
Final answer:

The scaling transformation maps (1, 2) to (2, 6)

Applied rules:

• Matrix-vector multiplication: (Av)_i = Σ A_{ij}v_j

• Scaling: Diagonal entries represent scale factors

• Geometric interpretation: Visualize the transformation effect

2 Rotation Transformation
Exercise 2
Apply the 90° counterclockwise rotation matrix R = \(\begin{bmatrix} 0 & -1 \\ 1 & 0 \end{bmatrix}\) to vector v = \(\begin{bmatrix} 3 \\ 1 \end{bmatrix}\)
Definition:

Rotation matrix: R(θ) = \(\begin{bmatrix} \cos θ & -\sin θ \\ \sin θ & \cos θ \end{bmatrix}\) rotates vectors by angle θ

Original
v = \(\begin{bmatrix} 3 \\ 1 \end{bmatrix}\)
Rotated
Rv = \(\begin{bmatrix} -1 \\ 3 \end{bmatrix}\)
Step 1: Set up the multiplication

Rv = \(\begin{bmatrix} 0 & -1 \\ 1 & 0 \end{bmatrix} \begin{bmatrix} 3 \\ 1 \end{bmatrix}\)

Step 2: Calculate first component

(Rv)_1 = (0×3) + (-1×1) = 0 - 1 = -1

Step 3: Calculate second component

(Rv)_2 = (1×3) + (0×1) = 3 + 0 = 3

Step 4: Verify rotation

Original vector (3, 1) rotated 90° counterclockwise gives (-1, 3)

Length preserved: ||v|| = √(9+1) = √10, ||Rv|| = √(1+9) = √10

Step 5: Geometric interpretation

Rotation preserves length and angles, moving the vector counterclockwise by 90°

Rv = \(\begin{bmatrix} -1 \\ 3 \end{bmatrix}\)
Final answer:

The rotation transforms (3, 1) to (-1, 3)

Applied rules:

• Rotation matrix: Specific form for angle θ

• Length preservation: Rotations are isometries

• Angle preservation: Inner products preserved

3 Reflection Transformation
Exercise 3
Apply the reflection across x-axis matrix M = \(\begin{bmatrix} 1 & 0 \\ 0 & -1 \end{bmatrix}\) to vector w = \(\begin{bmatrix} 4 \\ -2 \end{bmatrix}\)
Definition:

Reflection matrix: Changes sign of coordinate perpendicular to the axis of reflection

Original
w = \(\begin{bmatrix} 4 \\ -2 \end{bmatrix}\)
Reflected
Mw = \(\begin{bmatrix} 4 \\ 2 \end{bmatrix}\)
Step 1: Set up the multiplication

Mw = \(\begin{bmatrix} 1 & 0 \\ 0 & -1 \end{bmatrix} \begin{bmatrix} 4 \\ -2 \end{bmatrix}\)

Step 2: Calculate first component

(Mw)_1 = (1×4) + (0×(-2)) = 4 + 0 = 4

Step 3: Calculate second component

(Mw)_2 = (0×4) + ((-1)×(-2)) = 0 + 2 = 2

Step 4: Analyze the reflection

The x-coordinate remains unchanged (4→4)

The y-coordinate changes sign (-2→2)

This reflects across the x-axis

Step 5: Verify properties

Distance to x-axis preserved: |-2| = |2| = 2

Reflection is its own inverse: M² = I

Mw = \(\begin{bmatrix} 4 \\ 2 \end{bmatrix}\)
Final answer:

The reflection transforms (4, -2) to (4, 2)

Applied rules:

• Reflection: Changes sign of perpendicular coordinate

• Involution: M² = I for reflection matrices

• Distance preservation: Distance to axis preserved

Matrix-Vector Transformations: Key Concepts
T(v) = Av
Linear Transformation
Transformation Type
Scaling
Diagonal matrix with scale factors
Transformation Type
Rotation
Orthogonal matrix preserving lengths
Transformation Type
Reflection
Matrix with determinant -1
Linearity: T(cv + dw) = cT(v) + dT(w) for scalars c, d
Standard basis: Columns of A are images of standard basis vectors
Geometric interpretation: Every matrix represents a geometric transformation
Solution: Exercises 4 to 5
4 Shear Transformation
Exercise 4
Apply the horizontal shear matrix S = \(\begin{bmatrix} 1 & 2 \\ 0 & 1 \end{bmatrix}\) to vector u = \(\begin{bmatrix} 3 \\ 4 \end{bmatrix}\)
Definition:

Shear transformation: Shifts one coordinate proportionally to another coordinate

Input vector
u = \(\begin{bmatrix} 3 \\ 4 \end{bmatrix}\)
Result
Su = \(\begin{bmatrix} 11 \\ 4 \end{bmatrix}\)
Step 1: Set up the multiplication

Su = \(\begin{bmatrix} 1 & 2 \\ 0 & 1 \end{bmatrix} \begin{bmatrix} 3 \\ 4 \end{bmatrix}\)

Step 2: Calculate first component

(Su)_1 = (1×3) + (2×4) = 3 + 8 = 11

Step 3: Calculate second component

(Su)_2 = (0×3) + (1×4) = 0 + 4 = 4

Step 4: Analyze the shear

The x-coordinate is increased by 2 times the y-coordinate

Point (3, 4) becomes (3 + 2×4, 4) = (11, 4)

This is a horizontal shear with factor 2

Step 5: Verify area preservation

det(S) = (1×1) - (2×0) = 1, so area is preserved

Su = \(\begin{bmatrix} 11 \\ 4 \end{bmatrix}\)
Final answer:

The shear transformation maps (3, 4) to (11, 4)

Applied rules:

• Shear transformation: One coordinate shifted by multiple of another

• Area preservation: Determinant equals 1

• Parallel lines: Remain parallel after transformation

5 Composite Transformation
Exercise 5
Apply the composite transformation RS to vector v = \(\begin{bmatrix} 1 \\ 1 \end{bmatrix}\), where R is 90° rotation and S is horizontal shear: R = \(\begin{bmatrix} 0 & -1 \\ 1 & 0 \end{bmatrix}\), S = \(\begin{bmatrix} 1 & 1 \\ 0 & 1 \end{bmatrix}\)
Definition:

Composite transformation: (RS)v = R(Sv) - apply S first, then R

First apply S
Sv = \(\begin{bmatrix} 2 \\ 1 \end{bmatrix}\)
Then apply R
RSv = \(\begin{bmatrix} -1 \\ 2 \end{bmatrix}\)
Step 1: Calculate Sv

Sv = \(\begin{bmatrix} 1 & 1 \\ 0 & 1 \end{bmatrix} \begin{bmatrix} 1 \\ 1 \end{bmatrix}\)

(Sv)_1 = (1×1) + (1×1) = 2

(Sv)_2 = (0×1) + (1×1) = 1

So Sv = \(\begin{bmatrix} 2 \\ 1 \end{bmatrix}\)

Step 2: Calculate R(Sv)

R(Sv) = \(\begin{bmatrix} 0 & -1 \\ 1 & 0 \end{bmatrix} \begin{bmatrix} 2 \\ 1 \end{bmatrix}\)

(RSv)_1 = (0×2) + ((-1)×1) = -1

(RSv)_2 = (1×2) + (0×1) = 2

So RSv = \(\begin{bmatrix} -1 \\ 2 \end{bmatrix}\)

Step 3: Alternative approach

First compute RS = \(\begin{bmatrix} 0 & -1 \\ 1 & 0 \end{bmatrix} \begin{bmatrix} 1 & 1 \\ 0 & 1 \end{bmatrix} = \begin{bmatrix} 0 & -1 \\ 1 & 1 \end{bmatrix}\)

Then (RS)v = \(\begin{bmatrix} 0 & -1 \\ 1 & 1 \end{bmatrix} \begin{bmatrix} 1 \\ 1 \end{bmatrix} = \begin{bmatrix} -1 \\ 2 \end{bmatrix}\)

Step 4: Geometric interpretation

First: shear moves (1,1) to (2,1)

Second: rotate 90° counterclockwise moves (2,1) to (-1,2)

RSv = \(\begin{bmatrix} -1 \\ 2 \end{bmatrix}\)
Final answer:

The composite transformation maps (1, 1) to (-1, 2)

Applied rules:

• Composition: Apply transformations right-to-left

• Matrix multiplication: RS represents combined transformation

• Associativity: (AB)v = A(Bv) for matrices A, B

Matrix-Vector Products: Comprehensive Guide
(Av)_i = Σ_j A_{ij}v_j
Matrix-Vector Product Formula
Key definitions:

Linear transformation: Function T: ℝⁿ → ℝᵐ such that T(cv + dw) = cT(v) + dT(w)

Matrix-vector product: Result of applying transformation matrix A to vector v

Standard matrix: Every linear transformation has a unique matrix representation

Complete methodology:
  1. Identify transformation type: Scaling, rotation, reflection, shear, etc.
  2. Set up matrix-vector multiplication: Ensure dimensions are compatible
  3. Compute each component: Apply the formula (Av)_i = Σ A_{ij}v_j
  4. Interpret geometrically: Understand the transformation effect
Tip 1: The columns of matrix A are the images of standard basis vectors.
Tip 2: Rotation matrices preserve length and orientation.
Tip 3: Reflection matrices have determinant -1 and are their own inverses.
Tip 4: Shear transformations preserve area but change shape.
Common errors: Forgetting to check dimensions, misapplying the multiplication formula, confusing transformation types.
Exam preparation: Practice all transformation types, memorize standard forms, understand geometric interpretations.
Transformation properties to know:

• Linearity: T(cv + dw) = cT(v) + dT(w)

• Scaling: Diagonal matrix A_{ii} scales i-th coordinate

• Rotation: Preserves lengths and angles

• Reflection: Changes orientation, preserves distances

• Shear: Preserves area, changes angles

• Composition: (AB)v = A(Bv) - apply rightmost first

Transformation Visualization
Exercise 6: Transformation Analysis
Visual analysis of different matrix transformations:
• Scaling: stretches/shrinks along axes
• Rotation: turns around origin
• Reflection: flips across axis

Analysis: The visualization shows how different transformation matrices affect unit vectors.

  • Scaling matrices stretch the plane in specific directions
  • Rotation matrices preserve shapes while turning them
  • Reflection matrices flip the orientation

Questions & Answers

Question: How can I determine what kind of transformation a matrix represents just by looking at its entries?

Answer: Great question! Here are the patterns to identify transformation types:

  • Scaling: Diagonal matrix \(\begin{bmatrix} s_x & 0 \\ 0 & s_y \end{bmatrix}\) where diagonal entries are scale factors
  • Rotation: \(\begin{bmatrix} \cos θ & -\sin θ \\ \sin θ & \cos θ \end{bmatrix}\) with det = 1 and orthogonal columns
  • Reflection: Orthogonal matrix with det = -1
  • Shear: \(\begin{bmatrix} 1 & k \\ 0 & 1 \end{bmatrix}\) or \(\begin{bmatrix} 1 & 0 \\ k & 1 \end{bmatrix}\) with one off-diagonal entry

For general 2×2 matrices, analyze the determinant and eigenvalues:

  • det > 0: Orientation-preserving (rotation, scaling, shear)
  • det < 0: Orientation-reversing (reflection, improper rotation)
  • det = 0: Collapses dimension (projection)

Practice recognizing these patterns by working with different matrix forms!

Question: Why is matrix-vector multiplication the way it is? What's the intuition behind the formula?

Answer: The matrix-vector multiplication formula has elegant geometric and algebraic interpretations:

  • Linear combination: Av is a linear combination of the columns of A using components of v as coefficients
  • Dot product: Each component of Av is the dot product of a row of A with vector v
  • Coordinate transformation: It expresses the transformed vector in the new coordinate system defined by A's columns

The formula (Av)_i = Σ A_{ij}v_j captures how each output coordinate is formed by combining all input coordinates with appropriate weights. This ensures that the transformation respects the linear structure of vector spaces.

Think of it as: each output dimension is a weighted average of all input dimensions, where the weights are given by the corresponding row of the matrix.

Question: What are the applications of matrix-vector transformations in real-world contexts?

Answer: Matrix-vector transformations have extensive real-world applications:

  • Computer Graphics: 3D transformations, rotations, scaling for games and animation
  • Machine Learning: Linear models, neural network layers, dimensionality reduction
  • Physics: Coordinate transformations, quantum mechanics operators
  • Engineering: Control systems, signal processing, structural analysis
  • Economics: Input-output models, portfolio optimization

In computer graphics, for example, every 3D object is transformed using matrices to rotate, scale, and translate it in virtual space. The camera view is also represented by transformation matrices.

In machine learning, each layer of a neural network applies a matrix-vector transformation followed by a nonlinear activation function, allowing the network to learn complex patterns.