How this instrument works
A directed line segment is a segment with an assigned direction — from the first input toward the second, not the other way round — so travelling along it carries more meaning than a bare length. Choosing a ratio m:n and asking where P falls, so the piece from the start to P compares to the piece from P onward as m is to n, only makes sense once that direction is fixed, since the two pieces must be measured consistently, start to end. Strip the direction away and all that remains is a bare pair of lengths, which is what the plain ratio-of-two-numbers idea handles; restore the direction and the same numbers pin down an exact location in the plane.
The formula itself, Pₓ = (m·x₂ + n·x₁)/(m+n), is easiest to see as a lever balanced on a fulcrum. Put a weight of size n at the first coordinate and a weight of size m at the second; the segment balances exactly where this calculator's answer lands. That picture also explains the one detail every student trips over first: x₁ is multiplied by n, and x₂ by m — the weight attached to each end is the OTHER ratio term, not its own. A heavy weight at the second end, meaning a large m, has to be balanced by a fulcrum sitting closer to the first, which is exactly what a large m does to the formula.
Set m equal to n and the weighted balance collapses to a plain average, (x₁+x₂)/2 — the ordinary midpoint, recovered as the one case where neither end outweighs the other. Push m all the way to 0 and P lands exactly on the first coordinate, since a ratio of 0:n means no distance has been covered yet; the formula's other boundary, n = 0, drops P onto the second coordinate for the matching reason. Between those two edges, every value of m and n traces a different location along the same fixed segment.
- Fill in Point 1: x and Point 1: y with the segment's starting coordinates.
- Fill in Point 2: x and Point 2: y with the segment's ending coordinates.
- Set the ratio in Ratio part, m and Ratio part, n — m controls how much of the segment is measured from Point 1's side.
- Read Dividing point: x and Dividing point: y — the coordinates of the location that splits the segment in exactly that ratio.
- Try m and n equal to confirm the result lands on the ordinary midpoint before exploring uneven ratios.
Worked example — the segment (0,0) to (10,10), split 1:4
A cable run stretches from a junction box at (0,0) to a panel at (10,10) — Point 1 at (0, 0), Point 2 at (10, 10) — and a splice needs to sit so the box-side piece compares to the panel-side piece as 1 is to 4, meaning Ratio part, m = 1 and Ratio part, n = 4. The sheet returns Dividing point: x = (1×10 + 4×0)/(1+4) = 10/5 = 2 and Dividing point: y = (1×10 + 4×0)/5 = 2, so the splice belongs at (2, 2).
That answer sits close to the junction box rather than the panel, which is the weighted-balance rule doing its job: n = 4 is the larger term, and n is attached to the near end, so the near end pulls harder and the splice lands only a fifth of the way along the run. Checking against the straight-line distance confirms it — (2,2) is exactly 1/5 of the way from (0,0) to (10,10), matching the 1:4 split, where the first piece is one part out of the five total parts in the ratio.
Questions
What is the section formula for dividing a line segment in a ratio?
P = ((m·x₂ + n·x₁)/(m+n), (m·y₂ + n·y₁)/(m+n)), where P divides the segment from the first coordinate pair to the second so the near piece compares to the far piece as m is to n. Setting m = n reduces it to the ordinary midpoint formula, since the weighted average becomes a plain average.
Why is x₁ multiplied by n and x₂ multiplied by m, not the other way round?
Picture the segment as a lever: a weight of size n sits at the first end and a weight of size m sits at the second, and the balance spot is pulled toward whichever end carries the bigger weight. A large m therefore drags the balance toward the first end, which only happens if m multiplies x₁'s neighbour, x₂ — so each end's coordinate is paired with the other end's ratio term.
Why does the segment need to be "directed" for this formula to work?
A ratio like m:n only pins down one location if everyone agrees which piece of the segment is measured first — from the first coordinate toward the second. Reverse the direction and the same m:n describes a different split. A plain, undirected length has no such starting end, which is why an ordered pair of coordinates, not just two bare distances, is required here.
How does this relate to the midpoint formula?
The midpoint is the single case where m equals n, so the weighted average (m·x₂+n·x₁)/(m+n) collapses to the plain average (x₁+x₂)/2. Every midpoint calculation is a 1:1 split; this calculator handles the general split, where the two ratio parts can differ.
What happens if m or n is set to zero?
Setting m to 0 places the dividing point exactly on Point 1, since a 0:n ratio means none of the segment toward Point 2 has been covered yet. Setting n to 0 places it exactly on Point 2 for the mirror reason. Both are valid boundary cases, not errors — they mark the two ends of the segment the formula can reach.
Can m and n be any positive numbers, or only whole numbers?
Any positive numbers work, whole or not — the formula only cares about the proportion between m and n, so a ratio of 1.5:3 gives the identical point as 1:2 once both are scaled to the same relationship. What matters is m+n never equalling zero, which would leave the division undefined.