Nanostructured magnets for improved energy efficiency