Computer Simulation of Skyrmions on a Square Lattice Aleksander Perzhua,b, Egor Vasilieva,b , Dmitrii Kapitana,b , Alexey Rybina,b , Alena Korola,b, Konstantin Nefedev a,b and Vitalii Kapitana,b a Department of Computer Systems, School of Natural Sciences, Far Eastern Federal University, Vladivostok, 690950, 8 Sukhanova St., Russian Federation b Institute of Applied Mathematics, Far Eastern Branch, Russian Academy of Science, Vladivostok, 690041, 7 Radio St., Russian Federation Abstract We studied a square lattice of spins in frame of Heisenberg model with direct exchange and Dzyaloshinskii-Moriya interaction. For the analysis of data obtained during the Monte Carlo simulation, a convolutional neural network was used for the recognition of different phases of the spin system, which was dependent on simulation parameters such as DMI and external magnetic field (Hz). Based on these data, the phase diagram (Hz,D) was plotted. The various states of the systems under observation were visualized, and the boundaries between the different phases were defined as spirals, skyrmions and others. We proposed the controlling method for movement of skyrmions using by Monte Carlo simulation. Keywords 1 Monte Carlo method, convolutional neural network, magnetic skyrmion, Heisenberg model, Dzyaloshinskii-Moriya interaction 1. Introduction Spintronics or magnetic electronics is continually evolving, and new promising materials for new storage and processing data devices are emerging. Skyrmions are attractive candidates for information carriers in a new type of non-mechanical magnetic medium - a racetrack memory - because they are only a few nanometers in size, very stable, and can be driven by pulses of spin-polarized currents. At a fundamental level, skyrmions are model systems for topologically protected spin structures and can be regarded as an analogue of topologically protected states, emphasizing the role of topology in the formation of complex states of condensed matter [1]. The creation, detection and control of individual skyrmions have become especially relevant topics in connection with the possible implementation of physical devices based on skyrmions in spintronics. For the development of control methods for magnetic skyrmions in a magnetic nanostrip, it is necessary to conduct a detailed analysis of the simulation parameters and the correlations between them in order to select the optimal parameters for further studies of magnetic skyrmions. In our paper, the conditions for the nucleation and stable existence of magnetic skyrmions in two- dimensional magnetic films were considered in the frame of the classical Heisenberg model. For computer simulation, we used the Metropolis algorithm. For the analysis of the data obtained during the Monte Carlo simulation, a convolutional neural network (CNN) was used for the recognition of different phases of the spin system, depending on simulation parameters such as Dzyaloshinskii- Moriya interaction and the external magnetic field (Hz). Based on these data, the phase diagram (Hz,D) was plotted. Also, we proposed the controlling method for the movement of skyrmions. VI International Conference Information Technologies and High-Performance Computing (ITHPC-2021), September 14–16, 2021, Khabarovsk, Russia EMAIL: perzhu_av@dvfu.ru (A. 1); kapitan.vyu@dvfu.ru (A. 7); ORCID: 0000-0002-5068-8910 (A. 7) ©️ 2020 Copyright for this paper by its authors. Use permitted under Creative Commons License Attribution 4.0 International (CC BY 4.0). CEUR Workshop Proceedings (CEUR-WS.org) 206 2. Model and algorithms 2.1. Mathematical model In 1960 Dzyaloshinskii presented a model to describe weak ferromagnetism [2]. Based on symmetries he introduced an asymmetrical term which later on was clarified by Moriya [3]. The Dzyaloshinskii-Moriya (DMI) interaction is a microscopic characteristic of interacting spins that occurs in a system that lacks inversion symmetry and has a strong spin-orbit coupling. The Heisenberg model is one of the models used in statistical physics to model ferromagnetism. It is used in the study of critical points and phase transitions of different magnetic systems. We used the lattice Hamiltonian, consisting of Heisenberg exchange (HJ) and DMI interaction (HD) terms for the microscopic description of a chiral helimagnet [4-6], see formulas (1-3). 𝐻 = (𝐻𝐽 + 𝐻𝑧 + 𝐻𝐴 ) + 𝐻𝐷 , (1) 𝐻𝐽 = βˆ’π½ βˆ‘π‘Ÿ π‘†βƒ—π‘Ÿ β‹… (π‘†βƒ—π‘Ÿ+π‘₯Μ‚ + π‘†βƒ—π‘Ÿ+𝑦̂ ) βˆ’ 𝐻𝑧 βˆ‘π‘Ÿ π‘†βƒ—π‘Ÿ βˆ’ 𝐻𝐴 βˆ‘π‘Ÿ βƒ—βƒ—βƒ—βƒ— |π‘†π‘Ÿ |2 , (2) 𝐻𝐷 = βˆ’π· βˆ‘π‘Ÿ π‘†βƒ—π‘Ÿ Γ— π‘†βƒ—π‘Ÿ+π‘₯Μ‚ β‹… π‘₯Μ‚ + π‘†βƒ—π‘Ÿ Γ— π‘†βƒ—π‘Ÿ+𝑦̂ β‹… 𝑦̂, (3) where π‘†βƒ—π‘Ÿ is the atomic spin, 𝐽 is the value of ferromagnetic short-range exchange interaction, 𝐷 is the value of DMI, Hz – an external magnetic field and a magnetic anisotropy coefficient is HA. 2.2. Metropolis algorithm The Metropolis algorithm is used to determine the global minimum. The main idea is to uniformly sample the state space with a given distribution probability. At each iteration of the sample, the configuration of the system changes due to a change in the orientation of a randomly selected spin. The configuration is accepted and becomes the initial one for the next step if the new energy value is greater than the previous one (𝐸1 > 𝐸2 ); otherwise, it is accepted with the probability: 𝑃(𝐸 ) 𝑃(𝐸𝑖 β†’ 𝐸𝑗 ) = π‘šπ‘–π‘› (𝑃(𝐸 𝑖 ) , 1) (4) 𝑗 Due to this, the algorithm avoids getting stuck in local minima. Convergence is achieved after passing a given number of Monte Carlo steps until the moment when the standard deviation reaches a specified minimum, depending on the problem being solved [7-10]. C++ and Rust programming languages were used for software development, providing possibilities for the independent calculation of the properties of the spin systems. We used dimensionless quantities in J units for the simulation. The software has been verified for the Heisenberg model [11,12]. 2.3. Convolutional neural network for states classification We used configurations of spin systems obtained at different simulation parameters for the training and subsequent classification of them in a neural network. To date, the most accurate analysis results are demonstrated by neural networks based on convolutional architecture. We used the TensorFlow library to create a convolutional neural network [13] and to classify our spin systems to different phases [14]. In our research, we have reduced the problem of determining the phases of spin systems to the problem of image classification - in fact, to the main problem area in which neural networks are used. For recognising images, CNN accepts them in the RGB format as a three-dimensional matrix. In our case, the convolutional neural network received as input a three-dimensional array representing the components of a three-dimensional spin in the frame of the Heisenberg model. 207 Following this, the convolutional neural network learned, using the training dataset, to highlight the features inherent in one or another spin configuration. Our CNN consists of next layers (main ones), see Figure 1: 1. Input layer Input data (configurations of spins), each of the neurons (spins) of which is assigned an initial random weight. The components of a three-dimensional vector were fed to the network input (i.e., the components of Heisenberg spin). The dataset was prepared using Monte Carlo simulation data for training the neural network in state recognition. Figure 1: The architecture of the convolutional neural network 2. Convolutional layer with 3Γ—3 filter When neurons are connected to only a few neurons in the next layer, the layer is said to be convolutional. The convolutional layer acts as a filter that discards the least informative parts of the input data. Each layer has filters (i.e., matrices with weight values). When the filter moves along the matrix of the previous layer, each filter element is multiplied by the value of the neuron, and the values are summed up and written to the feature map. 3. Pooling layer for reducing the dimensions of the data 4. Fully connected layer Fully connected layers are used for classification. All layers before the fully connected layer are used to highlight various features that are fed to the input of the classifier. This layer can also be used as the final (output) CNN layer, the result of which is the probability of the input configuration of spins belonging to a certain class. 3. Results and discussions We studied different phases that appeared depending on the magnitude of the Dzyaloshinskii- Moriya interaction D and the external magnetic field Hz at fixed temperature T, see Figure 2. The convolutional neural network was used to analyze the data obtained from the Monte Carlo simulations for the recognition of the different phases of the spin system, dependent on the simulation parameters. In a magnetic film, with an increase of the magnetic field strength and DMI, various phases were observed for the flat Heisenberg spin systems: Spiral (Sp), Spiral-skyrmion (SpSk) Skyrmion (Sk), Skyrmion-ferromagnetic (SkF) and Ferromagnetic (FM) phases, see Figure 3. In Skyrmion phase, due to the alignment of the stripes against the magnetic field, stable skyrmions are formed in the system. 208 In these skyrmions, the spins of the nucleus are directed against the magnetic field. In this study, skyrmions of the Bloch type were formed. Figure 2: (𝐻𝑧 , 𝐷) phase diagram for the square lattice. Figure 3: a) Stripe configuration, b) Mixed state, c) Skyrmion’s lattice. 209 We could also β€œpush” the skyrmion from one side of the sample to another using the increasing of a magnetic anisotropy. This is a rather precise method, see Figure 4. In frame of this numerical experiment, we have an anisotropy gradient from 0.9 on the left side of the sample to 0.1 on the other side. We have an incline plane of anisotropy gradient. And we increase the value of anisotropy step by step for pushing the skyrmion. In the physical experiment, it is possible to control the anisotropy applying the voltage to the sample. Figure 4: Movement of the skyrmion. 4. Conclusion In the frame of the classical two-dimensional Heisenberg model, a spin system with direct short- range exchange was modelled, and a study of its competition with the Dzyaloshinskii-Moriya interaction was carried out. Due to the direct exchange interaction, the neighboring spins of the system are collinearly aligned and, in turn, the Dzyaloshinskii-Moriya interaction contributes to the deviation of the spins from parallel orientation. As a result, competition results between collinear and noncollinear alignments of spins, which leads to the transition of the system of spins from a ferromagnetic to a spiral ground state. In the presence of an external magnetic field, stable topological structures - magnetic skyrmions - are generated in such systems. In this paper, we proposed a method for manipulation of the position of a skyrmion using by a control of anisotropy gradient. We performed MC simulation and the convolutional neural network was used for the recognition of the different phases of the spin systems, depending on the simulation parameters. For the visualisation and analysis of research data, the phase diagram (Hz,D) was plotted. The data obtained in the numerical experiments will be used in our further studies to determine the model parameters of the system for the formation of a stable skyrmion state, both in the form of individual skyrmions and skyrmion lattices and for the development of methods for controlling skyrmions in magnetic stripes. 5. Acknowledgements This work was supported in frame of joint program "Mikhail Lomonosov" of the Ministry of Science and Higher Education of Russia and German Academic Exchange Service (DAAD) (#2298- 21). The studies were carried out using the resources of the Center for Shared Use of Scientific 210 Equipment "Center for Processing and Storage of Scientific Data of the Far Eastern Branch of the Russian Academy of Sciences" [15], funded by the Russian Federation represented by the Ministry of Science and Higher Education of the Russian Federation under project No. 075-15-2021-663. Additional computing resources were provided by the FEFU supercomputer cluster (cluster.dvfu.ru). 6. References [1] N. Nagaosa and Y. Tokura, Topological properties and dynamics of magnetic skyrmions, Nature nanotechnology 8 (2013) 899–911. doi: 10.1038/nnano.2013.243 [2] I. Dzyaloshinsky, A thermodynamic theory of β€œweak” ferromagnetism of antiferromagnetics, J. of Physics and Chemistry of Solids 4 (1958) 241–255. [3] T. Moriya, Anisotropic superexchange interaction and weak ferromagnetism, Physical Review 120, 91 (1960). [4] A. Belemuk, S. Stishov, Phase transitions in chiral magnets from Monte Carlo simulations, Physical Review B 95 (22) (2017) 224433. [5] V. Kapitan, et al., Numerical simulation of magnetic skyrmions on flat lattices, AIP Advances 11(1) (2021) 015041. doi:10.1063/9.0000082. [6] E. Vasil'ev, et al. Numerical simulation of two-dimensional magnetic skyrmion structures, Computer Research and Modeling, 12(5) (2020) 1051-1061. doi:10.20537/2076-7633-2020-12- 5-1051-1061. [7] K. Nefedev and V. Kapitan, Concentration phase transition and hysteresis phenomena in co- nanofilms. computer data processing and simulation, in Advanced Materials Research, 718–720 (2013) 69–73. [8] V. Kapitan and K. Nefedev, Labyrinth domain structure in the models with long-range interaction, J. Nano- Electron. Phys. 6, (2014) 03005. [9] K. S. Soldatov, K. V. Nefedev, V. Y. Kapitan, and P. D. Andriushchenko, Approaches to numerical solution of 2d ising model, J. of Physics: Conference Series, 741 (1) (2016) 012199. doi:10.1088/1742-6596/741/1/012199. [10] A. G. Makarov, K. V. Makarova, Y. A. Shevchenko, P. D. Andriushchenko, et al., On the numerical calculation of frustrations in the Ising model, JETP Letters 110 (2019) 702–706. doi: 10.1134/S0021364019220090. [11] V. Y. Kapitan, Y. A. Shevchenko, A. V. Perzhu, and E. V. Vasiliev, Thermodynamic properties of Heisenberg spin systems, in Key Engineering Materials, 806 (2019) 142–154. doi: 10.4028/www.scientific.net/KEM.806.142 [12] V. Kapitan, E. Vasil’ev, Y. Shevchenko, et al., Thermodynamic properties of heisenberg spin systems on a square lattice with the Dzyaloshinskii–Moriya interaction, Dal’nevostochnyi Matematicheskii Zhurnal [Far Eastern Mathematical Journal] 20 (2020) 63–73. [13] M. Abadi, P. Barham, J. Chen, Z. Chen, A. Davis, J. Dean, M. Devin, S. Ghemawat, G. Irving, M. Isard, et al., Tensorflow: A system for large scale machine learning, in 12th fUSENIXg symposium on operating systems design and implementation (fOSDIg 16) (2016) 265–283. [14] J. Carrasquilla and R. G. Melko, Machine learning phases of matter, Nature Physics 13 (2017) 431–434. doi: 10.1038/nphys4035. [15] A.A. Sorokin, S.V. Makogonov, S.P. Korolev, The Information Infrastructure for Collective Scientific Work in the Far East of Russia // Scientific and Technical Information Processing. 44 (4) (2017) 302-304. doi:10.3103/S0147688217040153. 211