Dynamic modeling and control of a new automatic corking machine for threaded plastic caps