# Finding changes in environment using 2d laser

I have known map of the environment (2d occupancy grid map). I am trying to find if anything changed in environment using 2d laser while navigating by using maximum likelihood of laser with known map.

My question is how to know which measurements are corresponding to changes. My environment is not static and has some changes which is differs from known map. Now i am trying to find which objects newly came into the environment or moved out of the environment using laser.

• Does your laser scan a range (horizontal and/or vertical) or just a point? Maybe you're better off with an ultrasonic? Commented Feb 8, 2015 at 18:06

Let's asume that our 2D occupancy grid map is called G.
Programmatically, G is a 2D array of float numbers between -1 and 1 called evidences.

Now, to update the map, we need to :

1. read the new laser mesurements
2. calculate the distances of obstacles from the robot
3. re-calculate the evidence values of G, and then
4. replace the old values by the new evidence values.

If we want to find the changes in the environment, we can simply store the old values of G in a temporary array before re-calculating the new evidence values (step 3).

Therefore, the changes can be found by substracting the two arrays : C = G - old_G.
In this case: C is a 2D array representing the differences between the two grid maps, so 0 values of C represent no changes in the environement, while other values represent either new or moved objects.

• thanks for answer, but robot position from is not certain, i.e with some variance. Commented Sep 10, 2014 at 14:49
• In this case, you need first to localize your robot. You can use particles filter for this, it's quite simple to implement. Commented Sep 10, 2014 at 16:18
• Yes i am doing locazisation and using initial map and moving the robot in modified environment. But the localisation will have some variance. Commented Sep 10, 2014 at 20:00
• Yes, I've meet the same problem once, the reason is that the motion model can't be so precise to handle a 0% error. But there's another localization algorithms known to have a good precision, like SLAM methods per example, which use a Kalman Filter to predict and correct the localization errors. Commented Sep 10, 2014 at 21:02