Synthesis and assembly of magnetic nanoparticles for information and energy storage applications