Bug fix from Alec in EMFields3D.h + Python scripts

Bug fix from Alec in EMFields3D.h