FFT-Based Visualization and Animation of Magnetization Dynamics in Micromagnetic OVF Data
收藏资源简介:
This Python code is designed for the analysis and visualization of magnetization dynamics obtained from micromagnetic simulations stored in OVF (OOMMF Vector Field) format. The script processes time-dependent magnetization data generated by MuMax3 simulations and produces animated visualizations of spin-wave and skyrmion dynamic modes at a selected excitation frequency. The program loads a series of cropped OVF files corresponding to a chosen magnetization component (mxm_xmx, mym_ymy, or mzm_zmz) and verifies mesh consistency across all simulation frames. Using the discretisedfield library, the script reconstructs the spatial coordinates of the magnetic system and extracts the temporal evolution of the magnetization. A Fourier transform (FFT) is then applied along the time axis to identify the complex dynamical mode corresponding to a specified microwave excitation frequency. The code calculates both the amplitude and phase distributions of the selected mode and reconstructs its harmonic time evolution. The resulting dynamical mode is visualized as a two-dimensional animated scatter plot, where the color scale represents the oscillating magnetization amplitude. The animation illustrates the GHz-frequency dynamics of skyrmions, vortices, or spin-wave excitations in multilayer magnetic nanostructures. The script supports manual or automatic amplitude scaling and exports the animation as an MP4 video using FFmpeg. The code is intended for the investigation of dipolarly stabilized magnetic textures, including skyrmions and vortices in DMI-free multilayer systems, and can be applied to studies of magnonics, spin-wave propagation, and magnetization dynamics in nanoscale magnetic devices.
本Python代码用于分析与可视化以OVF(OOMMF Vector Field)格式存储的微磁仿真磁化动力学数据。本脚本可处理由MuMax3仿真生成的时变磁化数据,并可针对选定的激发频率,生成自旋波与斯格明子动态模式的动画可视化结果。 该程序会加载一系列经裁剪的OVF文件,这些文件对应选定的磁化分量(mxm_xmx、mym_ymy或mzm_zmz),并校验所有仿真帧的网格一致性。借助discretisedfield库,脚本可重构磁系统的空间坐标,并提取磁化强度的时间演化过程。 随后沿时间轴执行傅里叶变换(FFT),以识别与指定微波激发频率对应的复动态模式。该代码会计算选定模式的振幅与相位分布,并重构其谐频时间演化特性。 最终得到的动态模式会被可视化为二维动画散点图,色阶用于表征磁化强度的振荡振幅。该动画可展示多层磁纳米结构中,斯格明子、磁涡旋或自旋波激发的吉赫级动态行为。本脚本支持手动或自动的振幅缩放,并可借助FFmpeg将动画导出为MP4视频文件。 本代码旨在研究偶极稳定的磁织构,包括无DMI多层系统中的斯格明子与磁涡旋,可应用于磁子学、自旋波传播以及纳米级磁器件中的磁化动力学相关研究。



