Update difference calculation