Localisation · University · about 30 min
The motion update: every particle drives, and every particle's own error goes with it.
[1 mark]A motion update moves every particle by the measured motion with no random term. What goes wrong?
[1 mark]The noise added per step is much smaller than the robot's real motion error. What is the likely result?
[1 mark]Each particle gets independent noise with standard deviation 0.35 cm per step. After 40 steps, what spread (standard deviation) should the cloud have, in cm to two decimal places?
[1 mark]You double the per-step noise standard deviation. What happens to the spread of the cloud after 5 seconds?
[1 mark]A Kalman filter for the same robot would use a process noise Q of 0.16 cm squared per step. What standard deviation, in cm, is a reasonable starting point for the per-particle motion noise?
[1 mark]Which of these belong in the motion update of a particle filter?
Tick every answer that is true.
Start every particle at zero, move them with the flow sensor plus their own noise as the robot drives at least 40 cm, plot mean y and spread y, and print both at the end.
from bugbot import * import random connect() DT, N = 0.1, 300 ys = [0.0] * N
The hint students can ask for: Start every particle at zero. Each tick, move every one of them by the measured flow, plus a small random amount of its own. The cloud tracks the robot and slowly spreads, which is dead reckoning uncertainty made visible.
from bugbot import *
import random
connect()
DT = 0.1
N = 300
ys = [0.0] * N
forward(70)
for i in range(60):
v = flow()[1]
ys = [y + v * DT + random.gauss(0, 0.35) for y in ys]
mean = sum(ys) / N
spread = (sum((y - mean) ** 2 for y in ys) / N) ** 0.5
plot("mean y", mean)
plot("spread y", spread)
wait(DT)
stop()
mean = sum(ys) / N
spread = (sum((y - mean) ** 2 for y in ys) / N) ** 0.5
print("mean y:", round(mean, 1))
print("spread y:", round(spread, 2))
Any program that meets the task's checks is marked correct in the simulator; this is one way, not the only way.