Synthetic aperture focusing techniques in time and frequency domains for photoacoustic imaging