Theoretical analyses on a piston-based thermal engine for thermal underwater glider