TOOLS / ROOT LOCUS

Root locus calculator

See where the closed-loop poles go as the gain K rises from 0, where they cross into the right half-plane, and which range of K keeps the loop stable.

System / G(s) = N(s) / D(s)

Coefficients in descending powers (1 3 2) or an expression such as s(s+1)(s+2).

L(s) = K·G(s); the closed loop is K·G/(1 + K·G) with unity negative feedback.

G(s) =4s² + 2s + 4
Poles of G(s)
−1 ± 1.732j
Zeros of G(s)
none
DC gain G(0)
1
Closed-loop poles at this K (1)
−1 ± 2.646j
Stability
Closed loop stable: every pole is in the left half-plane.
Stable range of K
K > 0
Imaginary-axis crossings
none
Breakaway / break-in points
none
Asymptotes
centroid −1, angles 90°, 270°

Closed-loop poles at K = 1: −1 ± 2.646j

K is swept from 0 to 6.25. × Open-loop poles, ○ Open-loop zeros.

Same result in code

MATLAB
% G(s) = (4) / (s^2 + 2s + 4)
G = tf([4], [1 2 4]);
K = 1;
rlocus(G)   % closed-loop poles of 1 + K*G(s) = 0 for K >= 0
p = pole(feedback(K*G, 1))
Python (python-control)
import control as ct

G = ct.tf([4], [1, 2, 4])
K = 1
ct.root_locus_plot(G)  # older versions: ct.root_locus(G)
print(ct.poles(ct.feedback(K*G, 1)))

MATLAB uses the Control System Toolbox; Python uses python-control 0.10 or later (pip install control).

WHAT IT COMPUTES

What this calculator computes

The roots of 1 + K·G(s) = 0, that is D(s) + K·N(s) = 0, for K ≥ 0, drawn as continuous branches that start at the open-loop poles (×) and end at the open-loop zeros (○) or along asymptotes.

For K/(s(s+1)(s+2)) the branches leave the real axis at the breakaway point s = −0.423 (K = 0.385), cross the imaginary axis at ω = √2 rad/s when K = 6, and follow asymptotes at ±60° and 180° from the centroid −1. The loop is stable for 0 < K < 6.

READ THE RESULT

How to read the result

  • The filled markers are the closed-loop poles at the current K; drag the gain slider to move them along the branches.
  • Imaginary-axis crossings list the gain and frequency at which a pole pair reaches the axis: that gain is the edge of the stable range, and the frequency is the oscillation you would see there.
  • The stable range of K is computed from those crossings and checked at a gain inside each interval, so it also covers loops that are stable only between two gains.
METHOD

Method and conventions

  • Each gain step solves the characteristic polynomial from scratch, then matches the new roots to the previous ones with a minimum-total-distance assignment. The gain step is halved wherever a pole would jump, so branches stay continuous through breakaway points.
  • Crossings solve Im[D(jω)·N(−jω)] = 0 for ω; breakaway points solve N·dD/ds − D·dN/ds = 0 and keep the solutions with real, positive K.
LIMITS

Only K ≥ 0 and negative feedback are drawn (no complementary locus). The plot view is chosen automatically; zoom with the mouse wheel or a pinch.