another. Two-dimensional, or flat, structuring elements are typically much smaller than the
image being processed. The centre value of the structuring element, called the origin, identifies
the pixel of interest. The pixels in the structuring element containing 1's define the
neighborhood of the structuring element. In our research, we are taking structuring element of 3
x 3 matrix shape. In the operation of image dilation and erosion we are considering structuring
element of different matrices, so that the image obtained is free from small unwanted parts
(distortions). In MATLAB working environment there are two built in functions used for
dilation and erosion.These morphological functions point the origin of structuring element, its
center element over the pixel of interest is in the input image. For pixels at the border of the
image, parts of the neighborhood defined by the structuring element can extend past the border
of the image. To process border pixels, the morphological functions assign a value to these
undefined pixels, as if the functions had padded the image with additional rows and columns.
The value of these padding pixels varies for dilation and erosion operations.