On this page
This sheet covers Chapter 11 of the NCERT Class 12 Mathematics Part II textbook (reprint 2026-27). The CBSE 2026-27 Mathematics syllabus keeps only lines in this chapter, and its Unit IV, Vectors and Three-Dimensional Geometry, carries 14 of the 80 theory marks.
In vector formulas, r, a, b, a₁, a₂, b₁, b₂ are vectors; in Cartesian ones, a, b, c are direction ratios. · is the dot product, × the cross product and |v| a magnitude. For marking advice, see our Three Dimensional Geometry Class 12 board exam guide.
What are direction cosines and direction ratios?
Direction cosines: l = cos α, m = cos β, n = cos γ, where α, β, γ are the angles a directed line makes with the positive axes. Reversing the line flips all three signs.
For every line: l² + m² + n² = 1.
Direction ratios a, b, c: any numbers with a = λl, b = λm, c = λn for some real λ ≠ 0.
From direction ratios to direction cosines: l, m, n = ± a/k, ± b/k, ± c/k, where k = √(a² + b² + c²), one sign for all three, a, b, c not all zero.
Line through P(x₁, y₁, z₁) and Q(x₂, y₂, z₂), with P ≠ Q: direction ratios x₂ − x₁, y₂ − y₁, z₂ − z₁; divide each by PQ for direction cosines.
PQ = √((x₂ − x₁)² + (y₂ − y₁)² + (z₂ − z₁)²), the distance between two points in 3D.
A, B, C are collinear when the direction ratios of AB and BC are proportional.
Worked example: for A(1, −2, 3) and B(3, 4, 6), the direction ratios are 2, 6, 3 and AB = √49 = 7, so the direction cosines are 2/7, 6/7, 3/7.
Watch for: giving 2, 6, 3 as direction cosines; divide by the length first.
Equations of a line in space
Vector form: r = a + λb, where a is a point's position vector, b ≠ 0 is parallel to the line and λ is real. The components of b are direction ratios.
Parametric form, through (x₁, y₁, z₁) with direction ratios a, b, c: x = x₁ + λa, y = y₁ + λb, z = z₁ + λc.
Cartesian form: (x − x₁)/a = (y − y₁)/b = (z − z₁)/c.
With direction cosines: (x − x₁)/l = (y − y₁)/m = (z − z₁)/n.
Through two points (x₁, y₁, z₁) and (x₂, y₂, z₂): (x − x₁)/(x₂ − x₁) = (y − y₁)/(y₂ − y₁) = (z − z₁)/(z₂ − z₁).
A zero denominator, say a = 0, means x = x₁ all along the line.
Worked example: through (1, 3, −2) parallel to 3i − 2j + 6k, r = (i + 3j − 2k) + λ(3i − 2j + 6k), or (x − 1)/3 = (y − 3)/(−2) = (z + 2)/6.
Watch for: lines not in standard form. (2 − x)/5 = (3y − 6)/4 = (z + 1)/2 becomes (x − 2)/(−5) = (y − 2)/(4/3) = (z + 1)/2, so the direction ratios are −5, 4/3, 2 (or −15, 4, 6), not 5, 4, 2.
How do you find the angle between two lines?
Direction ratios a₁, b₁, c₁ and a₂, b₂, c₂, with θ the acute angle: cos θ = |a₁a₂ + b₁b₂ + c₁c₂| / (√(a₁² + b₁² + c₁²) · √(a₂² + b₂² + c₂²)).
Vector form, lines r = a₁ + λb₁ and r = a₂ + μb₂: cos θ = |b₁ · b₂| / (|b₁| |b₂|).
Direction cosines l₁, m₁, n₁ and l₂, m₂, n₂: cos θ = |l₁l₂ + m₁m₂ + n₁n₂|.
Sine form: sin θ = √((a₁b₂ − a₂b₁)² + (b₁c₂ − b₂c₁)² + (c₁a₂ − c₂a₁)²) / (√(a₁² + b₁² + c₁²) · √(a₂² + b₂² + c₂²)).
Perpendicular lines: a₁a₂ + b₁b₂ + c₁c₂ = 0.
Parallel lines: a₁/a₂ = b₁/b₂ = c₁/c₂ (direction ratios proportional).
Worked example: for direction ratios 1, 2, 2 and 2, −1, 2, the dot product is 4 and both lengths are 3, so cos θ = 4/9 and θ ≈ 63.6°.
Watch for: putting the point (x₁, y₁, z₁) into the angle formula. Only direction ratios decide the angle.
How do you find the shortest distance between two lines?
Skew lines are neither parallel nor intersecting, so they do not lie in one plane. The shortest-distance segment is perpendicular to both.
Vector form, with b₁ × b₂ ≠ 0: d = |(b₁ × b₂) · (a₂ − a₁)| / |b₁ × b₂|.
Cartesian form: d = |Δ| / √((b₁c₂ − b₂c₁)² + (c₁a₂ − c₂a₁)² + (a₁b₂ − a₂b₁)²), where Δ is the determinant with rows (x₂ − x₁, y₂ − y₁, z₂ − z₁), (a₁, b₁, c₁), (a₂, b₂, c₂).
If the lines are not parallel and d = 0, they intersect.
Parallel lines r = a₁ + λb and r = a₂ + μb: d = |b × (a₂ − a₁)| / |b|.
Worked example: for l₁: r = (i + 2k) + λ(i + j) and l₂: r = (3j + k) + μ(2i + k), the lines in the diagram, a₂ − a₁ = −i + 3j − k and b₁ × b₂ = i − j − 2k, of length √6. Their dot product is −2, so d = 2/√6 = √6/3 ≈ 0.82.
Watch for: using the skew formula on parallel lines, where b₁ × b₂ = 0 and it divides by zero. Also keep the modulus: −2/√6 is not a distance.
How to revise this formula sheet
Put every line in standard form first and name its point and direction ratios.
Learn the vector forms; the Cartesian determinant Δ is just (b₁ × b₂) · (a₂ − a₁) in components.
Dot every cross product with b₁ and b₂; both must give 0, which catches sign slips.
Work NCERT Exercise 11.2 (questions 8 to 11 for angles, 12 to 15 for distance) with this sheet closed. If you keep picking the wrong method, the Fermi Problem Library has worked problems with a step-by-step solver that explains the reasoning rather than printing an answer.
Revise dot and cross products with our vector algebra Class 12 board exam guide.


