Electron diffraction and complex atomic factors