Visual Tools
Calculators
Tables
Mathematical Keyboard
Converters
Other Tools

How to Check If a Transformation Is Linear

A map TT is linear when it respects addition and scaling: T(cu+v)=cT(u)+T(v)T(c\mathbf{u} + \mathbf{v}) = cT(\mathbf{u}) + T(\mathbf{v}) for all vectors and scalars. To prove it, check that identity with general vectors; to disprove it, one numerical counterexample is enough.

Recognize the task

A formula for TT and the question "is TT linear?": T(x,y)=(2x−y, 3y)T(x, y) = (2x - y, \ 3y), T(x,y)=(x+1, y)T(x, y) = (x + 1, \ y), T(x,y)=(xy, x)T(x, y) = (xy, \ x), T(A)=ATT(A) = A^T on matrices, T(p)=p′T(p) = p' on polynomials. Quick test on Rn\mathbb{R}^n: each output coordinate of a linear map is a sum of constants times input coordinates, with no added constant, no products or powers of inputs, and no functions such as sin⁡\sin or ∣⋅∣|\cdot|.
Linearity is defined in What a Linear Transformation Is; the combined test is The One-Step Test.

Ways to do it

One-step testproof
T(cu+v)=cT(u)+T(v)T(c\mathbf{u} + \mathbf{v}) = cT(\mathbf{u}) + T(\mathbf{v})
Checks both conditions of the definition in one computation.
Two conditions separatelyproof
T(u+v)=T(u)+T(v),T(cu)=cT(u)T(\mathbf{u} + \mathbf{v}) = T(\mathbf{u}) + T(\mathbf{v}), \quad T(c\mathbf{u}) = cT(\mathbf{u})
Additivity and homogeneity, checked one at a time; both must hold.
Counterexampledisproof
T(0)≠0  or  T(2u)≠2T(u)T(\mathbf{0}) \ne \mathbf{0} \ \text{ or } \ T(2\mathbf{u}) \ne 2T(\mathbf{u})
A linear map sends the zero vector to zero; if that holds, try doubling or negating a vector.

Steps

StepOn T(x,y)=(2x−y, 3y)T(x, y) = (2x - y, \ 3y)
1Check T(0)=0T(\mathbf{0}) = \mathbf{0}. If it fails, TT is not linear: stop. If it holds, nothing is proved yet.T(0,0)=(0,0)T(0, 0) = (0, 0): continue
2Take general vectors and a scalar. Write u=(x1,y1)\mathbf{u} = (x_1, y_1), v=(x2,y2)\mathbf{v} = (x_2, y_2) and any scalar cc. Specific numbers can disprove linearity but never prove it.cu+v=(cx1+x2, cy1+y2)c\mathbf{u} + \mathbf{v} = (cx_1 + x_2, \ cy_1 + y_2)
3Apply TT and expand. Substitute into the formula and group the terms by cc.T(cu+v)=(2cx1−cy1+2x2−y2, 3cy1+3y2)T(c\mathbf{u} + \mathbf{v}) = (2cx_1 - cy_1 + 2x_2 - y_2, \ 3cy_1 + 3y_2)
4Compare with cT(u)+T(v)cT(\mathbf{u}) + T(\mathbf{v}). Equal for all inputs: linear, and the coefficients give its matrix. Not equal: plug numbers into the mismatch to get a counterexample.c(2x1−y1,3y1)+(2x2−y2,3y2)c(2x_1 - y_1, 3y_1) + (2x_2 - y_2, 3y_2) is the same ✓: linear, with matrix (2−103)\begin{pmatrix} 2 & -1 \\ 0 & 3 \end{pmatrix}

Worked examples

Example 1 · a shift

zero test
T(x,y)=(x+1, y)T(x, y) = (x + 1, \ y)
T(0,0)=(1,0)≠(0,0)T(0, 0) = (1, 0) \ne (0, 0): not linear
translations are not linear

Example 2 · a product of inputs

counterexample
T(x,y)=(xy, x)T(x, y) = (xy, \ x): T(0,0)=(0,0)T(0, 0) = (0, 0)
zero test passes, proves nothing
T(2⋅(1,1))=T(2,2)=(4,2)T(2 \cdot (1, 1)) = T(2, 2) = (4, 2)
2T(1,1)=(2,2)≠(4,2)2T(1, 1) = (2, 2) \ne (4, 2): not linear
scaling fails

Example 3 · matrices as inputs

abstract space
T(A)=ATT(A) = A^T on 2×22 \times 2 matrices
T(cA+B)=(cA+B)T=cAT+BTT(cA + B) = (cA + B)^T = cA^T + B^T
transpose rules
=cT(A)+T(B)= cT(A) + T(B): linear
holds for all AA, BB, cc

See it happen

A linear map keeps the origin fixed and keeps grid lines straight, parallel and evenly spaced. A shift moves the origin, so it fails at once; (xy,x)(xy, x) bends straight lines into curves, so doubling an input does not double the output. Every matrix in the linear transformation 2D visualizer shows the linear picture: the grid stays a grid.

Common mistakes

Taking the zero test as proof

✗ T(0,0)=(0,0)T(0, 0) = (0, 0), so T(x,y)=(xy,x)T(x, y) = (xy, x) is linear
✓ T(0)=0T(\mathbf{0}) = \mathbf{0} is necessary, not sufficient; here T(2,2)≠2T(1,1)T(2, 2) \ne 2T(1, 1)

Proving with numbers

✗ T(1,2)+T(3,4)=T(4,6)T(1, 2) + T(3, 4) = T(4, 6), so TT is linear
✓ a numerical check can only disprove; a proof uses general u\mathbf{u}, v\mathbf{v} and cc

Forgetting negative scalars

✗ T(x)=∣x∣T(x) = |x| satisfies T(2x)=2T(x)T(2x) = 2T(x), so it is linear
✓ T(−1⋅1)=1T(-1 \cdot 1) = 1 but −1⋅T(1)=−1-1 \cdot T(1) = -1: not linear

Calling a line through any point linear

✗ T(x)=3x+2T(x) = 3x + 2 is linear because its graph is a line
✓ it is affine; T(0)=2≠0T(0) = 2 \ne 0, so it is not a linear transformation