Assignment title: Information
AUTO 504 Name (Print):
Spring 2017
HW2
Announced on 03/25/17
Due on 03/04/17 Student ID Number
This exam contains 3 pages (including this cover page) and 5 problems. Check to see if any pages
are missing. Enter all requested information on the top of this page, and put your initials on the
top of every page, in case the pages become separated.
You may not use your books, notes on this midterm.
You are required to show your work on each problem on this midterm. The following rules apply:
• Organize your work, in a reasonably neat and
coherent way, in the space provided. Work scattered all over the page without a clear ordering
will receive very little credit.
• Mysterious or unsupported answers will not
receive full credit. A correct answer, unsupported by calculations, explanation, or algebraic
work will receive no credit; an incorrect answer
supported by substantially correct calculations and
explanations might still receive partial credit.
• If you need more space, use the back of the pages;
clearly indicate when you have done this.
Do not write in the table to the right.
Problem Points Score
1 5
2 10
3 10
4 5
5 5
Total: 35AUTO 504 HW2 - Page 2 of 3 03/25/17
VR
VL
X
Y
x
y
L
2R
θ
V
(a) A differential robot.
X
Y
Start
(Initial Point)
Finish
(Final Point)
7H
4H
4H
Intermediate
Point 1
Intermediate
Point 2
(0; 0)
(0; 7H) (4H; 7H)
(4H; 3H)
(b) The desired path.
Figure 1: The illustration of a differential robot and the desired path.
A sketch of a differential robot is given in Figure 1a. It is a quite popular system for applications.
The equations of motion are given by
x _(t) =r (VR(t) + VL(t)) cos(θ(t)); (1)
y _(t) =r (VR(t) + VL(t)) sin(θ(t)); (2)
θ_(t) = r
L
(VR(t) − VL(t)) ; (3)
where r; L are the radius of the wheel and the width of the vehicle, respectively. The control inputs
are the speed of the right and left wheels, VR(t); VL(t).
The system parameters are given by r = 0:1m; L = 0:5m. Take H = 5m;
Trajectory Generation
In the firs part, a reference trajectory is generated for the desired path given in Figure 1b. The
dashed line shows the desired path of the mass centre of the robot. In order to generate a successful
path, consider a 5th order minimum jerk trajectory,
pref(t) = c5t5 + c4t4 + c3t3 + c2t2 + c1t + c0: (4)
The coefficients, ci’s are calculated according to the boundary conditions. For instance, the boundaries for the trajectory from the start point to the intermediate point 1 are given as followsAUTO 504 HW2 - Page 3 of 3 03/25/17
Position (y) Velocity Acceleration
t=0 0 0 0
t=T 7H 0 0
These conditions provide 6 equations for 6 unknowns. We want the robot to move as follows; (Step
1) Start from the initial point with θ = π=2 and arrive the intermediate point 1 in 20sec; (Step
2)Turn −π=2 and make θ = 0 in 3sec; (Step 3) Start moving from the intermediate point 1 and
arrive the intermediate point 2 in 10sec; (Step 4) Turn −π=2 and make θ = −π=2 in 3sec; (Step 5)
Start moving from the intermediate point 2 and arrive the final point in 10sec.
1. (5 points) Decide for the all boundary conditions for the given steps.
2. (10 points) Calculate the coefficients for all trajectories. Plot the desired trajectories for
xref(t); yref(t); θref(t) as follows. Figure 1 time vs. xref(t), Figure 2 time vs. _ xref(t), Figure 3 time vs. ¨ xref(t), Figure 4 time vs. yref(t), Figure 5 time vs. _ yref(t), Figure 6 time vs.
y ¨ref(t), Figure 7 time vs. θref(t), Figure 8 time vs. θ_ref(t), Figure 9 time vs. θ ¨ref(t). Please
place them on one single page and one under the other.
Control Design and Simulation
3. (10 points) Since the system has two inputs, only two states of the system can be controlled
simultaneously. Design feedback and feedforward controllers for each step that achieves perfect
reference tracking.
4. (5 points) Apply the designed controllers by using Matlab. Plot your results as follows; Figure
1 time vs. x(t); xref(t), Figure 2 time vs. y(t); yref(t), Figure 3 time vs. θ(t); θref(t).
5. (5 points) Assume that you have changed the wheels with a larger one. The radius of the
new wheels are now 5 times larger than the previous (i.e., r = 0:5m). However, you have not
changed your control design. Run the simulation and plot your results as follows; Figure 1
time vs. x(t); xref(t), Figure 2 time vs. y(t); yref(t), Figure 3 time vs. θ(t); θref(t). Does your
controller still do its job? Why, Why not?
.