A submarine battery exploded in an Iranian military shipyward on Saturday, killing three workers, state broadcaster IRIB said.