Shear Matrix — Definition, Formula & Examples
A shear matrix is a square matrix that, when multiplied by a vector, shifts one component of that vector by an amount proportional to another component. It 'slants' shapes without changing their area.
A shear matrix is an elementary matrix obtained from the identity matrix by adding a nonzero off-diagonal entry in position where . It represents a linear map that fixes all basis vectors except that the image of gains a component . The determinant of every shear matrix equals 1, so the transformation is volume-preserving.
Key Formula
Where:
- = Shear factor — determines how much the x-component is displaced per unit of y
- = The 2D horizontal shear matrix (shears parallel to the x-axis)
How It Works
To build a 2D shear matrix, start with the identity matrix and place the shear factor in the off-diagonal position corresponding to the direction you want to displace. A horizontal shear uses position , shifting the -component based on . A vertical shear uses position , shifting based on . When you multiply the shear matrix by a column vector, the targeted component changes while the other stays fixed. In higher dimensions, the same idea applies: place at row , column to shear the -th coordinate proportionally to the -th.
Worked Example
Problem: Apply a horizontal shear with factor k = 2 to the point (3, 1).
Step 1: Write the shear matrix with k = 2 in position (1,2).
Step 2: Multiply the shear matrix by the column vector.
Answer: The sheared point is (5, 1). The x-component shifted by 2·1 = 2, while the y-component stayed at 1.
Why It Matters
Shear matrices appear in LU decomposition, where Gaussian elimination steps are encoded as shear (elementary) matrices. In computer graphics, shearing is a basic affine operation used to skew images and derive oblique projections. Understanding shear also clarifies why row operations preserve determinant sign and magnitude.
Common Mistakes
Mistake: Placing the shear factor on the diagonal instead of off-diagonal.
Correction: The diagonal entries of a shear matrix are all 1. The shear factor k goes in an off-diagonal position (i, j) with i ≠ j. Changing the diagonal would introduce scaling, not shearing.
