Reflect any vector across a chosen boundary fast. Supports 2D lines and 3D planes accurately. Download tables, PDFs, and CSV for your records securely.
| Case | Dimension | Method | v | Normal/Direction | Reflected r |
|---|---|---|---|---|---|
| 1 | 3D | Across normal | (3, −2, 1) | n = (0, 1, 0) | (3, 2, 1) |
| 2 | 2D | Across direction | (2, 1) | d = (1, 0) | (2, −1) |
| 3 | 2D | Across normal | (1, 4) | n = (1, 1) | (4, 1) |
Vector reflection flips a vector across a boundary while preserving its distance from the origin. For a line in 2D or a plane in 3D that passes through the origin, reflection is a rigid transform: lengths are preserved and angles to the boundary are mirrored. In practice, the calculator will often show ‖r‖ = ‖v‖ within the chosen rounding precision.
The primary method uses r = v − 2(v·n̂)n̂, where n̂ is the unit normal to the boundary. The dot product v·n̂ is the signed normal component. Decomposing v into v = v⊥ + v∥ with v⊥ = (v·n̂)n̂ and v∥ tangent to the boundary, reflection keeps v∥ unchanged and replaces v⊥ with −v⊥. This means r·n̂ = −(v·n̂) and r − v is always parallel to n̂.
When a 2D line through the origin is given by unit direction u, the tool applies r = 2(v·u)u − v. Here v·u is the scalar projection onto the line, and 2(v·u)u is twice the parallel component. Subtracting v swaps the perpendicular component’s sign. For example, reflecting (2, 1) across the x-axis direction u = (1, 0) yields (2, −1).
Correct reflection requires unit vectors. With auto-normalize enabled, n̂ = n/‖n‖ or u = d/‖d‖ is computed first, preventing scale distortions. If you supply a non-unit normal without normalization, the reflected vector would be incorrect unless you used the scaled form r = v − 2(v·n)/(n·n)n. Precision from 0–12 decimals controls presentation and helps compare near-parallel cases where v·n̂ is small.
Use the result table to validate behavior: the magnitude should stay consistent, and the dot value should reverse sign for normal reflection. These checks are common in physics (bounce directions), robotics (mirror trajectories), and graphics (symmetry operations). Exporting CSV and PDF supports lab notes, classroom worksheets, and reproducible calculations for reviews. If the result seems unexpected, verify the boundary vector is not zero and that the chosen method matches your interpretation of the mirror. Switching from normal to direction in 2D can change the reference boundary substantially in real applications.
It reflects across a line (2D) or a plane (3D) that passes through the origin. You define the boundary using a normal vector for line/plane reflection, or a direction vector for a 2D axis reflection.
No. If auto-normalize is enabled, the calculator converts your normal or direction into a unit vector before computing reflection. Disable it only when you are sure your boundary vector already has length one.
Not directly. For an offset boundary, translate your vector by subtracting a point on the line or plane, perform the reflection, then translate back by adding the same point.
A single direction uniquely defines a mirror axis in 2D. In 3D, a direction alone does not define a unique mirror plane; you would also need additional constraints, so the tool uses the normal-based method instead.
The dot value is the signed component of v along the unit normal or unit direction. For normal reflection, the sign should flip because r·n̂ equals −(v·n̂), while the tangential component stays the same.
Reflection preserves length mathematically, but displayed rounding can introduce small differences. Length can also appear inconsistent if the boundary vector is zero, not normalized when required, or if inputs contain extremely large or tiny magnitudes.
Important Note: All the Calculators listed in this site are for educational purpose only and we do not guarentee the accuracy of results. Please do consult with other sources as well.