gradation value of the image data while any numerical value including negative numbers and decimals is permitted for the element value of the array data in the present specification u201c array u201d when simply referred to means a data structure of the array data and a two dimensional array is generally used however an optimum data structure may be employed in accordance with a programming language or a computer system for performing calculation such as a two dimensional array or a one dimensional array in a bit plane form first as shown in fig1 an inspection image and design data are read into a computer b 2 b 12 next an roi corresponding to a pattern to be evaluated in the inspection image is designated to detect an edge es 2 on the whole periphery of the pattern to be evaluated a threshold method a linear approximation method or any other methods may be used to detect the edge es 2 fig2 edge points also need to be detected with a sub pixel resolution and if an image size in fig2 is 100 u25a1 100 pixels edge data detected with a sampling resolution of 1 10 pixels is stored in.