Ted invents a new kind of steam engine