Skip to content
ohmplay. Electronics
laboratory

Home / Tools / Planar 2R robotic arm

Experiment 009 / Robotics and control

Planar 2R robotic arm

Explore a two-joint arm’s position and the configurations that reach a target.

Workbench / Explicit model ● In your browser
01 / Adjust the model

Sliders with a wide range use a logarithmic scale. When zero is allowed, it has its own position. Type a number to set an exact value.

Try an example

02 / Position and reachable workspace

In inverse mode, click to choose the target, or enter X and Y using the keyboard. A dashed outline shows the other configuration when it exists.

X position 10 cm
Y position 10 cm
Absolute θ1 0°
Relative θ2 90°
Distance from base 14.142 cm
Geometric state Regular

The second angle is relative to the first link. With θ1 = 0° and θ2 = 90°, the endpoint is at (10, 10) cm.

Use it in your classroom

Share this exercise with its current values. The link contains only numbers and model options; do not add names or email addresses.

The code includes a text link to the full explanation outside the frame. Animation starts paused. Adjust the iframe height if your platform needs it.

A right angle you can move

Two 10 cm links with θ1 = 0° and θ2 = 90° place the endpoint at (10, 10) cm. The first link points right; the second is rotated 90° relative to it and points up.

The same point is also reached with θ1 = 90° and θ2 = −90°. One configuration raises the arm before extending right; the other does the reverse. In inverse mode you can switch between them and see the alternative as a dashed outline.

Relative angles, absolute coordinates

x = L1 cos θ1 + L2 cos(θ1 + θ2)
y = L1 sin θ1 + L2 sin(θ1 + θ2)
c2 = (x² + y² − L1² − L2²)/(2 L1 L2)
θ2 = ± arccos(c2)
θ1 = atan2(y,x) − atan2(L2 sin θ2, L1 + L2 cos θ2)

Calculations use meters and radians internally. Unit selectors preserve physical length or angle. θ1 is measured from positive X and θ2 from the first link, both counterclockwise-positive.

A point is reachable when its distance from the base lies between |L1 − L2| and L1 + L2. Unequal link lengths leave an excluded central region. The circles show those bounds, not obstacles.

Two solutions, one… or infinitely many

Most points strictly inside the workspace have two configurations. At an aligned-arm boundary, both branches coincide: a singularity. If L1 = L2 and the target is the origin, any base orientation with the arm folded reaches it. The tool explains this and shows one representative configuration, without claiming it is unique.

The model excludes joint limits, collisions, link thickness, load, torque and dynamics. A geometrically reachable point may be unsafe or inaccessible to a real arm. The view rescales with link lengths; read the coordinates as well.

Common mistakes

  • Interpreting θ2 as an absolute angle relative to the ground.
  • Confusing degrees with radians when using sine or cosine.
  • Assuming every point inside the outer circle is reachable when L1 and L2 differ.
  • Treating a singularity as a calculator error.

Try it yourself

With L1 = 12 cm and L2 = 8 cm, can the arm reach 2 cm from the base?

No. The minimum radius is |12 − 8| = 4 cm. At 2 cm the target lies inside the excluded region.

With two 10 cm links, θ1 = 90° and θ2 = 0°, where is the endpoint?

At (0, 20) cm. Both links point straight up; this is a singular configuration.

Geometry reference: planar 2R inverse kinematics, Alessandro De Luca, Sapienza. Original examples and visualization.