Measurements of the tilt angle of potential fields can be a useful aid to their interpretation. There are several varieties of the methods in use, such as tilt angle, and the derivative of tilt angle. Tilt angle filters are used for exact edge detection of the rectangular bodies artificially by writing a MATLAB code. The gravity effects of these models are computed by standard algorithms. The edges of these complex rectangular bodies are determined appropriately by tilt angle. It is also applied on real gravity data. The residual gravity anomalies are used as the real data. Tilt angles are used to determine the edges of these residual anomalies. The results are compared with the results from the analytic signal method which is a classical edge detection method. This shows the better performance of the tilt angle filter method.