I observed that in a significant number of cases the noise added to either the steering angle or the distance will produce either a steering angle larger than the max_steering_angle or either a negative distance. Anybody else observe this behavior? Normal? Abnormal? Should I remove checking?
Traceback (most recent call last):
Edit: I would like to upload an histogram of the distance distribution, however it seems I haven't the rights to. To summarize, it is almost certain I will get negative distance values in a run with test case 2.
EDIT2: Clarification required. Are the steering_noise, distance_noise and bearing_noise variances or standard deviations?
EDIT3: Clarification here: http://www.udacity-forums.com/cs373/questions/16527/variance-vs-standard-deviation-ambiguity-in-hw-3-6
Summary: steering_noise, distance_noise and bearing_noise are STANDARD DEVIATIONS not variances.
A negative distance should be very unlikely, with a distance noise of 5.0, and a [planned] forward motion of 20.0. If you are seeing negative values regularly, I think you need to check the calculation where the noise is used.
answered 09 Mar '12, 01:21
But the world isn't cyclic...according to the comments at the start of the code
answered 09 Mar '12, 02:59
David L Sprague
You are right but it doesn't matter and here is the proof :
First for the oreintation:
we all know that -pi/2 is equavielent to 3pi/2 and -pi/4 is equavelent to 7pi/4 so generaly -theta is equavielent to 2pi - theta
and what % (num1%num2) operator do is it asks it self what number should i subtract from num1 to be devisable by num2
2nd for position
here we apply the same analysis sence the world is cyclic so for world with size 100x100 we have the following x = -12 is equavellent to x = 88 , y = -1 is equavelent to 99 and so on