Response of thermal storage units to periodic operating conditions