A wide range of medical applications in clinic and research exploit images acquired by fast magnetic resonance imaging (MRI) sequences such as echo-planar imaging (EPI), e.g. functional MRI (fMRI) and diffusion tensor MRI (DT-MRI). Since the underlying assumption of homogeneous static fields fails to hold in practical applications, images acquired by those sequences suffer from distortions in both geometry and intensity. In the present paper we propose a new variational image registration approach to correct those EPI distortions. To this end we acquire two reference EPI images without diffusion sensitizing and with inverted phase encoding gradients in order to calculate a rectified image. The idea is to apply a specialized registration scheme which compensates for the characteristical direction dependent image distortions. In addition the proposed scheme automatically corrects for intensity distortions. This is done by evoking a problem dependent distance measure incorporated into a variational setting. We adjust not only the image volumes but also the phase encoding direction after correcting for patients head-movements between the acquisitions. Finally, we present first successful results of the new algorithm for the registration of DT-MRI datasets.© (2010) COPYRIGHT SPIE--The International Society for Optical Engineering. Downloading of the abstract is permitted for personal use only.