Fantastic! Thermodynamics is one of my favorite topics! (Along with mass balance equations.) Thanks for the post.
Karl's estimate on EV efficiency is quite accurate - and if the rare earth metal production costs are included, the efficiency gets considerably worse.
Also on a vaguely related matter: I work extensively with hydrogen gas. It is one of the most difficult to control, it leaks easily, and collects in unexpected places (like under the tops of cabinets). I seriously can't envision widespread use of H2 without frequent mini-Hindenburg events...