Lite / Intelligent Robotic Systems / Week 16
Elbow up or elbow down? Choosing between solutions
Two sets of joint angles put the hand on the same bolt. One of them smashes the elbow into a shelf. How does a robot choose?
Why should I care?
Multiple IK solutions are a gift and a trap. The gift: a robot can reach around obstacles. The trap: picking the 'other' solution halfway through a move sends the elbow sweeping across the cell. Real controllers choose deliberately, and stick with their choice.
- Find both elbow-up and elbow-down solutions for a two-link arm target.
- Choose between solutions using obstacles, joint limits and how far the joints must move.
- Explain why switching solutions mid-move is dangerous.
Predict
For a target to the right of the base, how are the elbow-up and elbow-down shoulder angles related?
- They are equal
- Elbow up has the larger θ1
- Elbow down has the larger θ1
- One is always negative
Guess first, then reveal
Elbow up has the larger θ1: the shoulder lifts higher so the elbow can bend back down to the target. In the (6, 2) cm example: 46.1° (up) vs −9.3° (down). The two arms are mirror images across the shoulder–target line.
Discover
In the robot-arm lab, set a target and solve IK in both elbow modes. Record θ1 and θ2 for each. Then imagine a shelf just above the arm: which solution would hit it? Move the target towards the outer edge: what happens to the difference between the two solutions?
What the interactive shows (text version)
The robot-arm lab can solve IK with the elbow up or down. Without it: for L1 = 0.4 m, L2 = 0.25 m and target (−0.03, 0.489) m, elbow down gives θ1 ≈ 63.0°, θ2 = 85°; elbow up gives θ1 ≈ 124.1°, θ2 = −85°. The two arms are mirror images across the line from the shoulder to the target.
Understand
Mirror images
The two solutions share |θ2| and are reflections of each other across the line from shoulder to target. With this course's convention elbow up has θ2 < 0, elbow down θ2 > 0. At the edges of the ring (θ2 = 0 or ±180°) they coincide; in the middle of the ring they differ the most.
How to choose
Common rules: (1) reject any solution outside joint limits or that collides with something; (2) among the rest, pick the one closest to the current joint angles, so the move is short and predictable; (3) keep the same branch throughout a task. Many industrial arms fix the branch in the program ('elbow up' configuration) for exactly this reason.
Don't flip mid-move
If a controller re-solves IK at every step of a straight-line hand move and naively picks 'the first solution', it can jump from one branch to the other. The hand target barely changes, but the elbow swings through a huge arc in one step. That's a sudden, fast, dangerous motion, and a classic bug to test for.
Explain it another way
Intuitive
Reach for a cup on a table: you can lead with your elbow up and out, or tucked low. Both get your hand there. You pick the one that doesn't knock the vase over, and you don't swap halfway.
Technical
The IK solution set for a reachable interior target is {(θ1⁺, θ2⁺), (θ1⁻, θ2⁻)}. Choosing by minimum ‖θ − θ_current‖ gives continuity along smooth paths as long as the path stays away from the workspace boundary, where the branches meet.
Mathematical
L1 = 0.4, L2 = 0.25, target (−0.03, 0.489): |θ2| = 85.0°. Elbow down θ2 = +85°: θ1 = 93.51° − 30.55° = 62.96°. Elbow up θ2 = −85°: θ1 = 93.51° + 30.55° = 124.06°.
Applied
Welding robots in car factories are programmed with a fixed configuration so that the hoses and cables on the elbow always sit on the same side and never wind up as the arm moves.
Worked example 1
The arm is at (θ1, θ2) = (40°, −70°). The two IK solutions for the next target are (45°, −75°) and (−5°, 75°). Which should it use?
The first: it's 5° away on each joint, on the same branch (θ2 negative). The second needs a 45° shoulder move and a 150° elbow swing.
Common mix-ups
Elbow up and elbow down are equally good, so it doesn't matter which you pick.
✓ Obstacles, joint limits and continuity with the current pose usually make one clearly better.Re-solving IK every step is always safe.
✓ Only if you keep the same branch; switching branches mid-move causes sudden large joint motions.
Practice
Practice, not a test. Answers are checked on our server; a wrong answer gets a hint and another try. Nothing is saved.
Apply it
A shelf occupies y > 0.45 m. For an arm with L1 = 0.4 m and L2 = 0.3 m reaching (0.5, 0.2) m, compute both solutions and the elbow position of each (the elbow is at L1(cos θ1, sin θ1)). Which one hits the shelf? Confirm in the lab.
Reflect
Your own arm has a third option your robot doesn't: rotating at the shoulder out of the plane. How does that extra freedom change the 'two solutions' picture?
Write your answer on paper or in your own notes. Lite never stores what you write.
Go further
- Inverse kinematics (Wikipedia)
Analytic and numerical IK, and the issue of multiple solutions.