Re-implemented cycle on distance calc. The cycle on the photometric band is inside and not the main one. Files are open 4 time less.