A Kirchhoff-like theory for hard magnetic rods under geometrically nonlinear deformation in three dimensions. (March 2022)