The effects of time-variance on impedance measurements: examples of a corroding electrode and a battery cell