Fresnel and Fraunhofer diffraction can be distinguished mathematically based on the assumptions and conditions under which they are analyzed. Fraunhofer diffraction results from taking the Fourier transform of the wave across the aperture, assuming a planar incident wave, while Fresnel diffraction does not involve this expansion. The key criterion for differentiating the two is the maximum phase error, with Fraunhofer diffraction applicable when the distance R is greater than a²/λ, and Fresnel diffraction when R is less than a²/λ. The critical point of λ/8 maximum phase error serves as a boundary between the two regimes. Understanding these distinctions is essential for analyzing diffraction patterns accurately.