fixed but in core.z.Z when computing res_phase if freq is None