Terminal iterative learning control with an application to RTPCVD thickness control