Commit JT 021318
This commit is contained in:
@ -16,13 +16,12 @@ ID, group-ID are documented in "fix"_fix.html command :ulb,l
|
|||||||
langevin/spin = style name of this fix command :l
|
langevin/spin = style name of this fix command :l
|
||||||
T = desired temperature of the bath (temperature units, K in metal units) :l
|
T = desired temperature of the bath (temperature units, K in metal units) :l
|
||||||
Tdamp = transverse magnetic damping parameter (adim) :l
|
Tdamp = transverse magnetic damping parameter (adim) :l
|
||||||
Ldamp = longitudinal magnetic damping parameter (adim) :l
|
|
||||||
seed = random number seed to use for white noise (positive integer) :l
|
seed = random number seed to use for white noise (positive integer) :l
|
||||||
:ule
|
:ule
|
||||||
|
|
||||||
[Examples:]
|
[Examples:]
|
||||||
|
|
||||||
fix 2 all langevin/spin 300.0 0.01 0.0 21 :pre
|
fix 2 all langevin/spin 300.0 0.01 21 :pre
|
||||||
|
|
||||||
[Description:]
|
[Description:]
|
||||||
|
|
||||||
@ -36,6 +35,8 @@ the following stochastic differential equation:
|
|||||||
:c,image(Eqs/fix_langevin_spin_sLLG.jpg)
|
:c,image(Eqs/fix_langevin_spin_sLLG.jpg)
|
||||||
|
|
||||||
with lambda the transverse damping, and eta a random verctor.
|
with lambda the transverse damping, and eta a random verctor.
|
||||||
|
This equation is referred to as the stochastic Landau-Lifshitz-Gilbert (sLLG)
|
||||||
|
equation.
|
||||||
|
|
||||||
The components of eta are drawn from a Gaussian probability law. Their amplitude
|
The components of eta are drawn from a Gaussian probability law. Their amplitude
|
||||||
is defined as a proportion of the temperature of the external thermostat T (in K
|
is defined as a proportion of the temperature of the external thermostat T (in K
|
||||||
@ -43,6 +44,16 @@ in metal units).
|
|||||||
|
|
||||||
More details about this implementation are reported in "(Tranchida)"_#Tranchida1.
|
More details about this implementation are reported in "(Tranchida)"_#Tranchida1.
|
||||||
|
|
||||||
|
Note: due to the form of the sLLG equation, this fix has to be the last defined
|
||||||
|
magnetic fix before the integration/spin fix. As an example:
|
||||||
|
|
||||||
|
fix 1 all force/spin zeeman 0.01 0.0 0.0 1.0
|
||||||
|
fix 2 all langevin/spin 300.0 0.01 21
|
||||||
|
fix 3 all integration/spin lattice yes :pre
|
||||||
|
|
||||||
|
is correct, but defining a force/spin command after the langevin/spin command
|
||||||
|
would send an error message.
|
||||||
|
|
||||||
Note: The random # {seed} must be a positive integer. A Marsaglia random
|
Note: The random # {seed} must be a positive integer. A Marsaglia random
|
||||||
number generator is used. Each processor uses the input seed to
|
number generator is used. Each processor uses the input seed to
|
||||||
generate its own unique seed and its own stream of random numbers.
|
generate its own unique seed and its own stream of random numbers.
|
||||||
@ -71,6 +82,9 @@ See the "Making LAMMPS"_Section_start.html#start_3 section for more info.
|
|||||||
The numerical integration has to be performed with {fix/integration/spin}
|
The numerical integration has to be performed with {fix/integration/spin}
|
||||||
when {langevin/spin} is enabled.
|
when {langevin/spin} is enabled.
|
||||||
|
|
||||||
|
This fix has to be the last defined magnetic fix before the integration fix
|
||||||
|
("fix integration spin"_fix_integration_spin.html).
|
||||||
|
|
||||||
[Related commands:]
|
[Related commands:]
|
||||||
|
|
||||||
"fix integration spin"_fix_integration_spin.html,
|
"fix integration spin"_fix_integration_spin.html,
|
||||||
|
|||||||
@ -1,55 +1,55 @@
|
|||||||
# sc iron atoms in bismuth oxide
|
# layer sc iron atoms (in the [001] plane) in bismuth oxide
|
||||||
|
|
||||||
clear
|
clear
|
||||||
units metal
|
units metal
|
||||||
atom_style spin
|
atom_style spin
|
||||||
|
|
||||||
dimension 3
|
dimension 3
|
||||||
boundary p p p
|
boundary p p f
|
||||||
|
|
||||||
# check why?
|
# check why?
|
||||||
atom_modify map array
|
atom_modify map array
|
||||||
|
|
||||||
lattice sc 3.96
|
lattice sc 3.96
|
||||||
region box block 0.0 34.0 0.0 34.0 0.0 5.0
|
region box block 0.0 34.0 0.0 34.0 0.0 5.0
|
||||||
create_box 1 box
|
create_box 1 box
|
||||||
create_atoms 1 box
|
create_atoms 1 box
|
||||||
|
|
||||||
# setting mass, mag. moments, and interactions for bfo
|
# setting mass, mag. moments, and interactions for bfo
|
||||||
|
|
||||||
mass 1 1.0
|
mass 1 1.0
|
||||||
|
|
||||||
set group all spin/random 11 2.50
|
set group all spin/random 11 2.50
|
||||||
|
|
||||||
pair_style hybrid/overlay pair/spin/exchange 6.0 pair/spin/me 4.5
|
pair_style hybrid/overlay pair/spin/exchange 6.0 pair/spin/me 4.5
|
||||||
pair_coeff * * pair/spin/exchange exchange 6.0 -0.01575 0.0 1.965
|
pair_coeff * * pair/spin/exchange exchange 6.0 -0.01575 0.0 1.965
|
||||||
pair_coeff * * pair/spin/me me 4.5 0.000109 1.0 1.0 1.0
|
#pair_coeff * * pair/spin/me me 4.5 0.000109 1.0 1.0 1.0
|
||||||
|
pair_coeff * * pair/spin/me me 4.5 0.00109 1.0 1.0 1.0
|
||||||
|
|
||||||
neighbor 0.1 bin
|
neighbor 0.1 bin
|
||||||
neigh_modify every 10 check yes delay 20
|
neigh_modify every 10 check yes delay 20
|
||||||
|
|
||||||
fix 1 all force/spin anisotropy 0.0000035 0.0 0.0 1.0
|
fix 1 all force/spin anisotropy 0.0000033 0.0 0.0 1.0
|
||||||
fix 2 all langevin/spin 0.0 0.1 0.0 21
|
fix 2 all langevin/spin 0.0 0.1 21
|
||||||
|
fix 3 all integration/spin lattice no
|
||||||
|
|
||||||
fix 3 all integration/spin lattice no
|
timestep 0.0002
|
||||||
|
|
||||||
timestep 0.0001
|
compute out_mag all compute/spin
|
||||||
|
compute out_pe all pe
|
||||||
|
compute out_ke all ke
|
||||||
|
compute out_temp all temp
|
||||||
|
|
||||||
compute out_mag all compute/spin
|
variable magz equal c_out_mag[4]
|
||||||
compute out_pe all pe
|
variable magnorm equal c_out_mag[5]
|
||||||
compute out_ke all ke
|
variable emag equal c_out_mag[6]
|
||||||
compute out_temp all temp
|
variable tmag equal c_out_mag[7]
|
||||||
|
variable mag_force equal f_1
|
||||||
variable magz equal c_out_mag[4]
|
|
||||||
variable magnorm equal c_out_mag[5]
|
|
||||||
variable emag equal c_out_mag[6]
|
|
||||||
variable tmag equal c_out_mag[7]
|
|
||||||
variable mag_force equal f_1
|
|
||||||
|
|
||||||
thermo_style custom step time v_magnorm v_emag temp etotal
|
thermo_style custom step time v_magnorm v_emag temp etotal
|
||||||
thermo 10
|
thermo 50
|
||||||
|
|
||||||
#dump 1 all custom 100 dump_spin_BFO.lammpstrj type x y z spx spy spz
|
dump 1 all custom 100 dump_spin_BFO.lammpstrj type x y z spx spy spz
|
||||||
|
|
||||||
run 10000
|
run 20000
|
||||||
|
|
||||||
|
|||||||
@ -31,8 +31,8 @@ pair_coeff * * pair/spin/exchange exchange 4.0 0.0446928 0.003496 1.4885
|
|||||||
neighbor 0.1 bin
|
neighbor 0.1 bin
|
||||||
neigh_modify every 10 check yes delay 20
|
neigh_modify every 10 check yes delay 20
|
||||||
|
|
||||||
fix 1 all force/spin zeeman 0.1 0.0 0.0 1.0
|
fix 1 all force/spin zeeman 0.01 0.0 0.0 1.0
|
||||||
fix 2 all langevin/spin 0.0 0.1 0.0 21
|
fix 2 all langevin/spin 0.0 0.0 21
|
||||||
|
|
||||||
fix 3 all integration/spin lattice yes
|
fix 3 all integration/spin lattice yes
|
||||||
|
|
||||||
|
|||||||
@ -32,7 +32,7 @@ neighbor 0.1 bin
|
|||||||
neigh_modify every 10 check yes delay 20
|
neigh_modify every 10 check yes delay 20
|
||||||
|
|
||||||
fix 1 all force/spin zeeman 0.1 0.0 0.0 1.0
|
fix 1 all force/spin zeeman 0.1 0.0 0.0 1.0
|
||||||
fix 2 all langevin/spin 0.0 0.1 0.0 21
|
fix 2 all langevin/spin 0.0 0.1 21
|
||||||
|
|
||||||
fix 3 all integration/spin lattice yes
|
fix 3 all integration/spin lattice yes
|
||||||
|
|
||||||
|
|||||||
@ -48,10 +48,10 @@ velocity all create 200 4928459 rot yes dist gaussian
|
|||||||
#Magneto-mechanic interactions for bulk fcc Cobalt
|
#Magneto-mechanic interactions for bulk fcc Cobalt
|
||||||
#pair_style pair/spin/exchange 4.0
|
#pair_style pair/spin/exchange 4.0
|
||||||
#pair_style eam/alloy
|
#pair_style eam/alloy
|
||||||
#pair_style hybrid/overlay eam/alloy pair/spin/exchange 4.0 pair/spin/soc/neel 4.0
|
pair_style hybrid/overlay eam/alloy pair/spin/exchange 4.0 pair/spin/soc/neel 4.0
|
||||||
pair_style hybrid/overlay eam/alloy pair/spin/exchange 4.0
|
#pair_style hybrid/overlay eam/alloy pair/spin/exchange 4.0
|
||||||
|
|
||||||
pair_coeff * * eam/alloy ../examples/SPIN/Co_PurjaPun_2012.eam.alloy Co
|
pair_coeff * * eam/alloy ../examples/SPIN/dev/Co_PurjaPun_2012.eam.alloy Co
|
||||||
#pair_coeff * * ../Co_PurjaPun_2012.eam.alloy Co
|
#pair_coeff * * ../Co_PurjaPun_2012.eam.alloy Co
|
||||||
|
|
||||||
#pair_style pair/spin/exchange 4.0
|
#pair_style pair/spin/exchange 4.0
|
||||||
@ -67,7 +67,7 @@ pair_coeff * * pair/spin/exchange exchange 4.0 0.0446928 0.003496 1.4885
|
|||||||
#pair_coeff * * me 2.6 0.01 1.0 1.0 1.0
|
#pair_coeff * * me 2.6 0.01 1.0 1.0 1.0
|
||||||
|
|
||||||
#type i and j | interaction type | cutoff | K1 (eV) | K2 (adim) | K3 (Ang) (for SOC)
|
#type i and j | interaction type | cutoff | K1 (eV) | K2 (adim) | K3 (Ang) (for SOC)
|
||||||
#pair_coeff * * pair/spin/soc/neel neel 4.0 0.003330282 0.864159 2.13731
|
pair_coeff * * pair/spin/soc/neel neel 4.0 0.003330282 0.864159 2.13731
|
||||||
#pair_coeff * * pair/spin/soc/neel neel 4.0 0.0 0.864159 2.13731
|
#pair_coeff * * pair/spin/soc/neel neel 4.0 0.0 0.864159 2.13731
|
||||||
|
|
||||||
#Define a skin distance, update neigh list every
|
#Define a skin distance, update neigh list every
|
||||||
@ -78,13 +78,13 @@ neigh_modify every 10 check yes delay 20
|
|||||||
|
|
||||||
#Magnetic field fix
|
#Magnetic field fix
|
||||||
#Type | Intensity (T or eV) | Direction
|
#Type | Intensity (T or eV) | Direction
|
||||||
#fix 1 all force/spin zeeman 0.0 0.0 0.0 1.0
|
fix 1 all force/spin zeeman 0.0 0.0 0.0 1.0
|
||||||
#fix 1 all force/spin anisotropy 0.01 0.0 0.0 1.0
|
#fix 1 all force/spin anisotropy 0.01 0.0 0.0 1.0
|
||||||
|
|
||||||
#Fix Langevin spins (merging damping and temperature)
|
#Fix Langevin spins (merging damping and temperature)
|
||||||
#Temp | Alpha_trans | Alpha_long | Seed
|
#Temp | Alpha_trans | Alpha_long | Seed
|
||||||
#fix 2 all langevin/spin 0.0 0.1 0.0 21
|
#fix 2 all langevin/spin 0.0 0.1 0.0 21
|
||||||
#fix 2 all langevin/spin 0.0 0.0 0.0 21
|
fix 2 all langevin/spin 0.0 0.0 21
|
||||||
|
|
||||||
#Magnetic integration fix
|
#Magnetic integration fix
|
||||||
fix 3 all integration/spin lattice yes
|
fix 3 all integration/spin lattice yes
|
||||||
@ -112,14 +112,15 @@ variable tmag equal c_out_mag[7]
|
|||||||
variable mag_force equal f_1
|
variable mag_force equal f_1
|
||||||
#variable test equal etotal-0.5*c_out_mag[6]
|
#variable test equal etotal-0.5*c_out_mag[6]
|
||||||
|
|
||||||
thermo 10
|
thermo 50
|
||||||
thermo_style custom step time v_magnorm v_emag temp etotal
|
#thermo_style custom step time v_magnorm v_tmag temp etotal
|
||||||
|
thermo_style custom step time pe ke v_emag etotal
|
||||||
thermo_modify format float %20.15g
|
thermo_modify format float %20.15g
|
||||||
|
|
||||||
#Dump the positions and spin directions of magnetic particles (vmd format)
|
#Dump the positions and spin directions of magnetic particles (vmd format)
|
||||||
dump 1 all custom 50 dump_cobalt.lammpstrj type x y z spx spy spz
|
#dump 1 all custom 50 dump_cobalt.lammpstrj type x y z spx spy spz
|
||||||
|
|
||||||
#Running the simulations for N timesteps
|
#Running the simulations for N timesteps
|
||||||
run 10
|
#run 10
|
||||||
#run 1000
|
run 200000
|
||||||
|
|
||||||
|
|||||||
15009
examples/SPIN/iron/Fe_Mishin2006.eam.alloy
Normal file
15009
examples/SPIN/iron/Fe_Mishin2006.eam.alloy
Normal file
File diff suppressed because it is too large
Load Diff
19
examples/SPIN/iron/fe_dd.dat
Normal file
19
examples/SPIN/iron/fe_dd.dat
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
6 8
|
||||||
|
Optimal parameter set
|
||||||
|
1 4.100199340884814 F
|
||||||
|
2 1.565647547483517 F
|
||||||
|
1 0.9332056681088162 T 3.000000000000000
|
||||||
|
2 -1.162558782567700 T 2.866666666666670
|
||||||
|
3 -0.3502026949249225 T 2.733333333333330
|
||||||
|
4 0.4287820835430028 T 2.600000000000000
|
||||||
|
5 4.907925057809273 T 2.400000000000000
|
||||||
|
6 -5.307049068415304 T 2.300000000000000
|
||||||
|
1 -0.1960674387419232 F 4.100000000000000
|
||||||
|
2 0.3687525935422963 F 3.800000000000000
|
||||||
|
3 -1.505333614924853 F 3.500000000000000
|
||||||
|
4 4.948907078156191 T 3.200000000000000
|
||||||
|
5 -4.894613262753399 T 2.900000000000000
|
||||||
|
6 3.468897724782442 T 2.600000000000000
|
||||||
|
7 -1.792218099820337 T 2.400000000000000
|
||||||
|
8 80.22069592246987 T 2.300000000000000
|
||||||
|
|
||||||
59
examples/SPIN/iron/in.spin.iron
Normal file
59
examples/SPIN/iron/in.spin.iron
Normal file
@ -0,0 +1,59 @@
|
|||||||
|
# bcc iron in a 3d periodic box
|
||||||
|
|
||||||
|
clear
|
||||||
|
units metal
|
||||||
|
atom_style spin
|
||||||
|
|
||||||
|
dimension 3
|
||||||
|
boundary p p p
|
||||||
|
|
||||||
|
# check why?
|
||||||
|
atom_modify map array
|
||||||
|
|
||||||
|
lattice bcc 2.8665
|
||||||
|
region box block 0.0 5.0 0.0 5.0 0.0 5.0
|
||||||
|
create_box 1 box
|
||||||
|
create_atoms 1 box
|
||||||
|
|
||||||
|
# setting mass, mag. moments, and interactions for bcc iron
|
||||||
|
|
||||||
|
mass 1 55.845
|
||||||
|
|
||||||
|
set group all spin/random 31 2.2
|
||||||
|
velocity all create 100 4928459 rot yes dist gaussian
|
||||||
|
|
||||||
|
#pair_style hybrid/overlay eam/alloy pair/spin/exchange 4.0 pair/spin/soc/neel 4.0
|
||||||
|
pair_style hybrid/overlay eam/alloy pair/spin/exchange 3.5
|
||||||
|
pair_coeff * * eam/alloy ../examples/SPIN/iron/Fe_Mishin2006.eam.alloy Fe
|
||||||
|
pair_coeff * * pair/spin/exchange exchange 4.0 0.025498 0.281 1.999
|
||||||
|
#pair_coeff * * pair/spin/soc/neel neel 4.0 0.003330282 0.864159 2.13731
|
||||||
|
|
||||||
|
neighbor 0.1 bin
|
||||||
|
neigh_modify every 10 check yes delay 20
|
||||||
|
|
||||||
|
fix 1 all force/spin zeeman 0.1 0.0 0.0 1.0
|
||||||
|
fix 2 all langevin/spin 0.0 0.0 21
|
||||||
|
|
||||||
|
fix 3 all integration/spin lattice yes
|
||||||
|
|
||||||
|
timestep 0.0001
|
||||||
|
|
||||||
|
|
||||||
|
compute out_mag all compute/spin
|
||||||
|
compute out_pe all pe
|
||||||
|
compute out_ke all ke
|
||||||
|
compute out_temp all temp
|
||||||
|
|
||||||
|
variable magz equal c_out_mag[4]
|
||||||
|
variable magnorm equal c_out_mag[5]
|
||||||
|
variable emag equal c_out_mag[6]
|
||||||
|
variable tmag equal c_out_mag[7]
|
||||||
|
variable mag_force equal f_1
|
||||||
|
|
||||||
|
thermo_style custom step time v_magnorm v_emag temp etotal
|
||||||
|
thermo 50
|
||||||
|
|
||||||
|
dump 1 all custom 50 dump_iron.lammpstrj type x y z spx spy spz
|
||||||
|
|
||||||
|
run 10000
|
||||||
|
|
||||||
30006
examples/SPIN/nickel/Ni99.eam.alloy
Normal file
30006
examples/SPIN/nickel/Ni99.eam.alloy
Normal file
File diff suppressed because it is too large
Load Diff
59
examples/SPIN/nickel/in.spin.nickel
Normal file
59
examples/SPIN/nickel/in.spin.nickel
Normal file
@ -0,0 +1,59 @@
|
|||||||
|
# fcc cobalt in a 3d periodic box
|
||||||
|
|
||||||
|
clear
|
||||||
|
units metal
|
||||||
|
atom_style spin
|
||||||
|
|
||||||
|
dimension 3
|
||||||
|
boundary p p p
|
||||||
|
|
||||||
|
# check why?
|
||||||
|
atom_modify map array
|
||||||
|
|
||||||
|
lattice fcc 3.54
|
||||||
|
region box block 0.0 5.0 0.0 5.0 0.0 5.0
|
||||||
|
create_box 1 box
|
||||||
|
create_atoms 1 box
|
||||||
|
|
||||||
|
# setting mass, mag. moments, and interactions for cobalt
|
||||||
|
|
||||||
|
mass 1 58.93
|
||||||
|
|
||||||
|
set group all spin/random 31 1.72
|
||||||
|
velocity all create 100 4928459 rot yes dist gaussian
|
||||||
|
|
||||||
|
#pair_style hybrid/overlay eam/alloy pair/spin/exchange 4.0 pair/spin/soc/neel 4.0
|
||||||
|
pair_style hybrid/overlay eam/alloy pair/spin/exchange 4.0
|
||||||
|
pair_coeff * * eam/alloy ../examples/SPIN/cobalt/Co_PurjaPun_2012.eam.alloy Co
|
||||||
|
pair_coeff * * pair/spin/exchange exchange 4.0 0.0446928 0.003496 1.4885
|
||||||
|
#pair_coeff * * pair/spin/soc/neel neel 4.0 0.003330282 0.864159 2.13731
|
||||||
|
|
||||||
|
neighbor 0.1 bin
|
||||||
|
neigh_modify every 10 check yes delay 20
|
||||||
|
|
||||||
|
fix 1 all force/spin zeeman 0.1 0.0 0.0 1.0
|
||||||
|
fix 2 all langevin/spin 0.0 0.1 21
|
||||||
|
|
||||||
|
fix 3 all integration/spin lattice yes
|
||||||
|
|
||||||
|
timestep 0.0001
|
||||||
|
|
||||||
|
|
||||||
|
compute out_mag all compute/spin
|
||||||
|
compute out_pe all pe
|
||||||
|
compute out_ke all ke
|
||||||
|
compute out_temp all temp
|
||||||
|
|
||||||
|
variable magz equal c_out_mag[4]
|
||||||
|
variable magnorm equal c_out_mag[5]
|
||||||
|
variable emag equal c_out_mag[6]
|
||||||
|
variable tmag equal c_out_mag[7]
|
||||||
|
variable mag_force equal f_1
|
||||||
|
|
||||||
|
thermo_style custom step time v_magnorm v_emag temp etotal
|
||||||
|
thermo 10
|
||||||
|
|
||||||
|
#dump 1 all custom 50 dump_cobalt.lammpstrj type x y z spx spy spz
|
||||||
|
|
||||||
|
run 1000
|
||||||
|
|
||||||
@ -52,7 +52,7 @@ fix 1 all force/spin zeeman 0.0 0.0 0.0 1.0
|
|||||||
|
|
||||||
#Fix Langevin spins (merging damping and temperature)
|
#Fix Langevin spins (merging damping and temperature)
|
||||||
#Temp | Alpha_trans | Alpha_long | Seed
|
#Temp | Alpha_trans | Alpha_long | Seed
|
||||||
fix 2 all langevin/spin 0.0 0.0 0.0 21
|
fix 2 all langevin/spin 0.0 0.0 21
|
||||||
|
|
||||||
#Magnetic integration fix
|
#Magnetic integration fix
|
||||||
fix 3 all integration/spin serial
|
fix 3 all integration/spin serial
|
||||||
|
|||||||
@ -1,55 +1,81 @@
|
|||||||
# fcc cobalt in a 3d box
|
# initial variables
|
||||||
|
|
||||||
clear
|
# dimensions of the box and of each layer
|
||||||
units metal
|
variable box_size equal 50.0
|
||||||
atom_style spin
|
variable ir_thick equal 4.0
|
||||||
|
variable fe_thick equal 0.5
|
||||||
|
variable pd_thick equal 0.5
|
||||||
|
|
||||||
dimension 3
|
variable fe_hi equal ${ir_thick}+${fe_thick}
|
||||||
boundary p p f
|
variable pd_hi equal ${ir_thick}+${fe_thick}+${pd_thick}
|
||||||
|
|
||||||
|
|
||||||
|
units metal
|
||||||
|
atom_style spin
|
||||||
|
|
||||||
|
dimension 3
|
||||||
|
boundary p p f
|
||||||
|
|
||||||
# check why?
|
# check why?
|
||||||
atom_modify map array
|
atom_modify map array
|
||||||
|
|
||||||
lattice fcc 3.54
|
lattice fcc 3.839 orient x 1 -1 0 orient y 1 1 -2 orient z 1 1 1
|
||||||
region box block 0.0 50.0 0.0 50.0 0.0 4.0
|
region box block 0.0 ${box_size} 0.0 ${box_size} 0.0 ${pd_hi}
|
||||||
create_box 1 box
|
region box_ir block 0.0 ${box_size} 0.0 ${box_size} 0.0 ${ir_thick}
|
||||||
create_atoms 1 box
|
region box_fe block 0.0 ${box_size} 0.0 ${box_size} ${ir_thick} ${fe_hi}
|
||||||
|
region box_pd block 0.0 ${box_size} 0.0 ${box_size} ${fe_hi} ${pd_hi}
|
||||||
|
|
||||||
|
create_box 3 box
|
||||||
|
|
||||||
|
create_atoms 1 region box_ir
|
||||||
|
create_atoms 2 region box_fe
|
||||||
|
create_atoms 3 region box_pd
|
||||||
|
|
||||||
|
group ir_atoms region box_ir
|
||||||
|
group fe_atoms region box_fe
|
||||||
|
group pd_atoms region box_pd
|
||||||
|
|
||||||
# setting mass, mag. moments, and interactions for cobalt
|
# setting mass, mag. moments, and interactions for cobalt
|
||||||
|
|
||||||
mass 1 58.93
|
mass 1 192.217 # mass of Ir atoms
|
||||||
|
mass 2 55.845 # mass of Fe atoms
|
||||||
|
mass 3 106.42 # mass of Pd atoms
|
||||||
|
|
||||||
set group all spin/random 31 1.72
|
set group ir_atoms spin/random 31 0.01 # has to set a length for LAMMPS to be happy
|
||||||
|
set group fe_atoms spin/random 89 2.7
|
||||||
|
set group pd_atoms spin/random 55 0.3
|
||||||
|
|
||||||
#pair_style hybrid/overlay eam/alloy pair/spin/exchange 4.0 pair/spin/soc/neel 4.0
|
#pair_style hybrid/overlay eam/alloy pair/spin/exchange 4.0 pair/spin/soc/neel 4.0
|
||||||
pair_style hybrid/overlay pair/spin/exchange 4.0 pair/spin/soc/dmi 2.6
|
pair_style hybrid/overlay pair/spin/exchange 4.0
|
||||||
pair_coeff * * pair/spin/exchange exchange 4.0 0.0446928 0.003496 1.4885
|
#pair_style hybrid/overlay pair/spin/exchange 4.0 pair/spin/soc/dmi 2.6
|
||||||
pair_coeff * * pair/spin/soc/dmi dmi 2.6 0.01 0.0 0.0 1.0
|
pair_coeff * * pair/spin/exchange exchange 4.0 0.0 0.003496 1.4885
|
||||||
#pair_coeff * * pair/spin/soc/neel neel 4.0 0.003330282 0.864159 2.13731
|
pair_coeff 2 2 pair/spin/exchange exchange 4.0 0.0446928 0.003496 1.4885
|
||||||
|
#pair_coeff * * pair/spin/soc/dmi dmi 2.6 0.01 0.0 0.0 1.0
|
||||||
|
#pair_coeff * * pair/spin/soc/neel neel 4.0 0.003330282 0.864159 2.13731
|
||||||
|
|
||||||
neighbor 0.1 bin
|
neighbor 0.1 bin
|
||||||
neigh_modify every 10 check yes delay 20
|
neigh_modify every 10 check yes delay 20
|
||||||
|
|
||||||
fix 1 all force/spin anisotropy 0.0001 0.0 0.0 1.0
|
fix 1 fe_atoms force/spin anisotropy 0.0001 0.0 0.0 1.0
|
||||||
fix 2 all langevin/spin 0.0 0.1 0.0 21
|
fix 2 all force/spin zeeman 0.1 0.0 0.0 1.0
|
||||||
|
fix 3 all langevin/spin 0.0 0.1 21
|
||||||
fix 3 all integration/spin lattice no
|
fix 4 all integration/spin lattice no
|
||||||
|
|
||||||
timestep 0.0002
|
timestep 0.0002
|
||||||
|
|
||||||
# define output and run
|
# define output and run
|
||||||
|
|
||||||
compute out_mag all compute/spin
|
compute out_mag all compute/spin
|
||||||
variable magz equal c_out_mag[4]
|
variable magz equal c_out_mag[4]
|
||||||
variable magnorm equal c_out_mag[5]
|
variable magnorm equal c_out_mag[5]
|
||||||
variable emag equal c_out_mag[6]
|
variable emag equal c_out_mag[6]
|
||||||
variable tmag equal c_out_mag[7]
|
variable tmag equal c_out_mag[7]
|
||||||
variable mag_force equal f_1
|
variable mag_force equal f_1
|
||||||
|
|
||||||
thermo_style custom step time v_magnorm v_emag etotal
|
thermo_style custom step time v_magnorm v_emag etotal
|
||||||
thermo 50
|
thermo 10
|
||||||
|
|
||||||
dump 1 all custom 50 dump_skyrmion.lammpstrj type x y z spx spy spz
|
dump 1 all custom 50 dump_skyrmion.lammpstrj type x y z spx spy spz
|
||||||
|
|
||||||
run 10000
|
run 1000
|
||||||
|
|
||||||
|
|||||||
@ -51,7 +51,7 @@ using namespace MathConst;
|
|||||||
FixLangevinSpin::FixLangevinSpin(LAMMPS *lmp, int narg, char **arg) :
|
FixLangevinSpin::FixLangevinSpin(LAMMPS *lmp, int narg, char **arg) :
|
||||||
Fix(lmp, narg, arg), id_temp(NULL), random(NULL)
|
Fix(lmp, narg, arg), id_temp(NULL), random(NULL)
|
||||||
{
|
{
|
||||||
if (narg != 7) error->all(FLERR,"Illegal langevin/spin command");
|
if (narg != 6) error->all(FLERR,"Illegal langevin/spin command");
|
||||||
|
|
||||||
dynamic_group_allow = 1;
|
dynamic_group_allow = 1;
|
||||||
scalar_flag = 1;
|
scalar_flag = 1;
|
||||||
@ -61,8 +61,7 @@ FixLangevinSpin::FixLangevinSpin(LAMMPS *lmp, int narg, char **arg) :
|
|||||||
|
|
||||||
temp = force->numeric(FLERR,arg[3]);
|
temp = force->numeric(FLERR,arg[3]);
|
||||||
alpha_t = force->numeric(FLERR,arg[4]);
|
alpha_t = force->numeric(FLERR,arg[4]);
|
||||||
alpha_l = force->numeric(FLERR,arg[5]);
|
seed = force->inumeric(FLERR,arg[5]);
|
||||||
seed = force->inumeric(FLERR,arg[6]);
|
|
||||||
|
|
||||||
if (alpha_t < 0.0) {
|
if (alpha_t < 0.0) {
|
||||||
error->all(FLERR,"Illegal langevin/spin command");
|
error->all(FLERR,"Illegal langevin/spin command");
|
||||||
@ -72,14 +71,6 @@ FixLangevinSpin::FixLangevinSpin(LAMMPS *lmp, int narg, char **arg) :
|
|||||||
tdamp_flag = 1;
|
tdamp_flag = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (alpha_l < 0.0) {
|
|
||||||
error->all(FLERR,"Illegal langevin/spin command");
|
|
||||||
} else if (alpha_l == 0.0) {
|
|
||||||
ldamp_flag = 0;
|
|
||||||
} else {
|
|
||||||
ldamp_flag = 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (temp < 0.0) {
|
if (temp < 0.0) {
|
||||||
error->all(FLERR,"Illegal langevin/spin command");
|
error->all(FLERR,"Illegal langevin/spin command");
|
||||||
} else if (temp == 0.0) {
|
} else if (temp == 0.0) {
|
||||||
@ -119,7 +110,8 @@ int FixLangevinSpin::setmask()
|
|||||||
|
|
||||||
void FixLangevinSpin::init()
|
void FixLangevinSpin::init()
|
||||||
{
|
{
|
||||||
// warn if any fix comes after this one
|
// fix_langevin_spin has to be the last defined fix
|
||||||
|
|
||||||
int after = 0;
|
int after = 0;
|
||||||
int flag_force = 0;
|
int flag_force = 0;
|
||||||
int flag_lang = 0;
|
int flag_lang = 0;
|
||||||
|
|||||||
@ -39,7 +39,7 @@ class FixLangevinSpin : public Fix {
|
|||||||
|
|
||||||
protected:
|
protected:
|
||||||
double *spi, *fmi;
|
double *spi, *fmi;
|
||||||
double alpha_t, alpha_l; // transverse and longitudunal damping coeff.
|
double alpha_t; // transverse mag. damping
|
||||||
double dts; // magnetic timestep
|
double dts; // magnetic timestep
|
||||||
double temp; // spin bath temperature
|
double temp; // spin bath temperature
|
||||||
double D,sigma; // bath intensity var.
|
double D,sigma; // bath intensity var.
|
||||||
|
|||||||
Reference in New Issue
Block a user