@@ -145,8 +145,8 @@ set_onsite_coupling!(sys, S -> -D*S[3]^2, 1)
145145# This model has been fitted so that energy minimization yields the physically
146146# correct ground state. Knowing this, we could manually set the magnetic
147147# configuration by calling [`set_dipole!`](@ref) on each site in the system.
148- # Instead, for pedagogy, we will search for the ground state using repeated
149- # energy minimization.
148+ # Instead, for pedagogy, we will search for the ground state using energy
149+ # minimization.
150150#
151151# To reduce bias in the search, use [`resize_supercell`](@ref) to create a
152152# relatively large system of 4×4×4 chemical cells. Call
@@ -162,20 +162,6 @@ minimize_energy!(sys)
162162
163163plot_spins (sys; color= [S[3 ] for S in sys. dipoles])
164164
165- # To search for the true ground state, a simple strategy is to repeatedly
166- # randomize spins and then minimize their energy. The lowest-found energy
167- # configuration is stored in `sys`.
168-
169- sys_min = clone_system (sys)
170- for i in 1 : 100
171- randomize_spins! (sys)
172- minimize_energy! (sys)
173- if energy (sys) < energy (sys_min)
174- copy_spins! (sys_min, sys)
175- end
176- end
177- copy_spins! (sys, sys_min)
178-
179165# Use [`print_wrapped_intensities`](@ref) to get a quick summary of the static
180166# structure factor. For simplicity, this function reports the sum of structure
181167# factors ``\mathcal{S}^{αα}(𝐪)`` calculated for each sublattice ``α``
@@ -184,26 +170,24 @@ copy_spins!(sys, sys_min)
184170
185171print_wrapped_intensities (sys)
186172
187- # This is the correct ground state for FeI₂: a generalized spiral with
188- # propagation wavevector ``𝐤 = ± [0, -1/4, 1/4]`` (equivalently ``±[1/4, 0,
189- # 1/4]`` or ``±[-1/4, 1/4, 1/4]`` under 120° rotations). Subsequent calculations
190- # can be made more efficient by working with a minimized magnetic cell. Find one
191- # with [`suggest_magnetic_supercell`](@ref).
173+ # The correct ground state for FeI₂ is a generalized spiral with one of three
174+ # propagation wavevectors: ``𝐤 = ± [0, -1/4, 1/4]``, ``[1/4, 0, 1/4]``, or
175+ # ``[-1/4, 1/4, 1/4]``. These are related by 120° rotations. The result of
176+ # `print_wrapped_intensities` hints at this spiral phase.
177+ #
178+ # Let's break the 3-fold symmetry by hand. The function
179+ # [`suggest_magnetic_supercell`](@ref) takes any number of propagation
180+ # wavevectors and suggests a magnetic cell that is commensurate with them.
192181
193182suggest_magnetic_supercell ([[0 , - 1 / 4 , 1 / 4 ]])
194183
195- # Create a minimized system with [`reshape_supercell`](@ref). Here, the ground
196- # state is found rapidly. A good consistency check is that the
197- # [`energy_per_site`](@ref) is unchanged by the reshaping .
184+ # After calling [`reshape_supercell`](@ref), it becomes easy to find the ground
185+ # state. Plot the system again, now including "ghost" spins out to 12Å. The
186+ # correct two-up, two-down magnetic order is visually apparent .
198187
199188sys_min = reshape_supercell (sys, [1 0 0 ; 0 1 - 2 ; 0 1 2 ])
200189randomize_spins! (sys_min)
201190minimize_energy! (sys_min)
202- @assert energy_per_site (sys_min) ≈ energy_per_site (sys)
203-
204- # Plot the system again, now including "ghost" spins out to 12Å. The correct
205- # two-up, two-down magnetic order is visually apparent.
206-
207191plot_spins (sys_min; color= [S[3 ] for S in sys_min. dipoles], ghost_radius= 12 )
208192
209193# ### Spin wave theory
0 commit comments