a machine works