The method used to detect the tank will be described using an image on the Duncan carpet. The original image is
shown below.
We start by getting the coordinates for the edge pixels from edge detection. From this matrix, we create a vector with the indices for columns which have edges but without repeating columns which have multiple edges. For each column, we calculate the minimum and maximum distances from the current edge to the next. We then find which pairs are in range and create a matrix with these coordinates. We then use these coordinates to create a matrix with these indices set high.
Then we do the same thing for the rows. We OR these two resulting matrices.
Unfortunately, the results from this stage were not as good as we had hoped. We could have added more steps to this method, but decided that we would instead pursue our other method.