Although only a few trains have power for every seat, most train carriages have at least one power outlet for cleaners to plug in cleaning equipment. (Yes - even the slow trains). The socket typically at one end of the carriage. These power outlets are not provided for passenger use, but they seem to have regular two-pin formats, so it's possible to insert a Japanese, domestic plug.
I think Mrs. Jib once read somewhere that there is a rule that prohibits passengers from using these sockets, but I've never seen an electricity thief (denki dorobo) reprimanded for taking a bit of electricity in this way. (You probably would be stopped if you tried hooking up a trailing extension to a seat on the other side of the carriage, though).