The control of quality in automatic production