分子动力学实验1. 空位形成能2. 表面、界面能3. 层错能4. 晶格常数与体弹模量5. 熔化SJTU.CMS.April 2012You and Your Computer你手机的计算能力,已经超越了NASA 1969 年拥有的计算能力的总和。
NASA 用那些计算能力发射人上了月球,而你用更强的计算能力发射愤怒的小鸟去砸猪。
Linux分子动力学五要素1. 粒子间相互作用势2. 初始条件3. 边界条件4. 求解牛顿运动方程5. 粒子运动轨迹LAMMPS Molecular Dynamics SimulatorAtomEye: atomistic configuration viewerBasic Linux CommandsNAME SYNOPSIS DESCRIPTIONpwd pwd print name of working directory mkdir mkdir□haha make directorycd cd□haha change directorycd□..upper directorycd back homegedit gedit□a edit a filecat cat□a concatenate filesls ls listcp cp□a□b copy file a to file b cp□–r□A□B copy a file folderrm rm□b remove[Tab]*1. 空位形成能Point Defects: VacancyModel system: Cu, fcc, a0= 3.61 ÅTasks:1. generate a point defect within anequilibrium lattice2. calculate the formation energyModel system CuInitial conditions fcc latticedefect-free state, vacancySupercell N, PBCs Interatomic potentials EAM (Cu) Ensembles Minimize(1) Copy the file folder to home and then get into it. $cp□-r□share/md□.$cd□md$cd□1_vacancy$ls(2) What is the setup in input file$gedit□in.vacancy(3) Run LAMMPS$lmp□-in□in.vacancy(4) After running, view the configuration$ A.i686□a0.cfg(5) View the result data$cat□dataAtomeye命令Tab 键切换视角k, Alt + H, Alt + +/-改变颜色Delete / Insert下一帧/上一帧PgUp/ PgDn原子变大/变小滚轮放大/缩小↑↓ ← → 方向键旋转q关闭units metal boundary p p p atom_style atomiclattice fcc 3.61region box block 0 6 0 6 0 6create_box 1 box create_atoms 1 box pair_style eam/alloy pair_coeff * * jin_copper_lammps.setfl Cu timestep 0.005variable E equal pe variable N equal atoms compute pe all pe/atomdump 1 all cfg 1 a*.cfg id type xs ys zs c_pe run 0fix extra all print 1 "pefect lattice, 0K: atoms = $N, energy = $E“region centerpoint block 3 3.05 3 3.05 1 1.05delete_atoms region centerpointrun 0fix extra all print 1 "^ an atom deleted, 0K: atoms = $N, energy = $E"周期边界条件指定fcc 晶体box 大小Cu 的EAM 势删除一个原子Vacancy formation energy:1 pefect lattice, 0K: atoms = 864, energy = -3015.3715122 an atom deleted, 0K: atoms = 863, energy = -3010.5854693 after minimization: atoms = 863, energy = -3010.6240332. 表面、界面能Planar Defects: Surface and Grain BoundaryModel system: Cu, fcc, a0= 3.610 ÅTasks:1.Surface energies of (111) and (100);2.Grain boundary energiesModel system CuInitial conditions T, P…Supercell N, PBCs …Interatomic potentials EAM (Cu) Ensembles MinimizeSurface energy: Methodperfect regionvacuum2 surfacesN 0atoms, E 0N atoms, E γS = (E –E 0*N/N 0) / (2*A )h 1h 3h 2(111) Surface:h 1= a 0/2[11-2]*L 1; h 2= a 0/2[-110]*L 2; h 3= a 0[111]*L 3(100) Surface:h 1= a 0[100]*L 1; h 2= a 0[010]*L 2; h 3= a 0[001]*L 3Surface energy: Calculationsperfect: N0= 123772,E0= –431965.9291 eV(111): N S1= 124722,E S1= –434642.1217 eV,A S1= 39.792*104.659 Å2(100): N S2= 123772,E S2= –431275.1878 eV,A S2= 39.71*104.69 Å2γS1= (E S1–E0*N S1/N0)*16020 / (2*A S1) = 1230 mJ/m2γS2= (E S2–E0*N S2/N0)*16020 / (2*A S2) = 1331 mJ/m2Grain boundary energyh2h1 region1S1:(111)GBregion2vacuumS2:(100)h3γGB = (E – E0*N/N0) / A – γS1 – γS2GB+S1+S2: N = 248494, E = –866449.3465 eV, A = 39.755*104.677 Å2 γGB = (E – E0*N/N0)*16020 / A – γS1 – γS2 = 512 mJ/m2region 1:a1 = a0/2[11-2];a3a2 = a0/2[-110];a3 = a0[111]a2a3region 2:a1 = a0[100];a2 = a0[010];a3 = a0[001]a2a1a1(1) Change into the 2nd directory$ cd□../2_surface_boundary $ ls(2) What is the commands in bash file$ cat□run.sh(3) Run bash file$ ./run.sh(4) After running, view the configuration$ A.i686□a0.cfgrun.sh#!/bin/bashlmp < in.100 ‐log log.100 lmp < in.111 ‐log log.111 lmp < in.GB ‐log log.GBecho "%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%" echo " "echo "‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐ (100) ‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐" grep ^^ log.100 echo " "echo "‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐ (111) ‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐" grep ^^ log.111echo " " echo "‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐ GB ‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐" grep ^^ log.GBecho " " echo "%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%"Surface energy: γS = (E – E0*N/N0) / (2*A)%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐ (100) ‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐^‐‐‐ Number of Particles = 11520, Energy = ‐40204.95349^‐‐‐ Number of Particles = 8640, Energy = ‐30075.76547^‐‐‐ Size of (100):A = 469.1556‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐ (111) ‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐^‐‐‐ Number of Particles = 46080, Energy = ‐160819.814^‐‐‐ Number of Particles = 34560, Energy = ‐120448.5379^‐‐‐ Size of (111):A = 1083.468448‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐ GB ‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐ ^‐‐‐ Number of Particles = 248494, Energy = ‐866449.3465 ^‐‐‐ Size of GB x*y: A = 4161.446533%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%(111) surface (100) surfaceAtomeye 命令Tab 键 k, Alt + H, Alt + +/Delete / Insert PgUp / PgDn 滚轮 ↑↓ ← → 方向键 q切换视角 改变颜色 下一帧/上一帧 原子变大/变小 放大/缩小旋转 关闭4 Grain boundary 4.1 Modelbox 150 unitsh2region 1S1h1region 2 GBvacuum S2h356 unitsregion 1:56 unitsUnit cell aa1 = a0/2[11-2]; a2 = a0/2[-110]; a3 = a0[111] h1 = 9*a1; h2 = 41*a2; h3 = 56*a32a1a3region 2:a1 = a0[100]; a2 = a0[010]; a3 = a0[001] h1 = 11*a1; h2 = 29*a2; h3 = 97*a3Grain boundary3. 层错能2High Tensile Strength and Ductility of Cu with Nano ‐Sized TwinsLu et al., Science 287(2000) 1463; 304(2004) 422.dislocationfluxtwin in experimentstwin boundary89 ×118 ×77 Å56,400 atomstwin in CuTwin faultsintrinsic stacking fault Extrinsic stacking fault ISF ESF TSFplanar fault in FCCExtrinsic stacking fault (ESF)ESFfree surfacePlanar Defects: Stacking Fault EnergyModel system: Cu, Al, fccTasks:(1) clarify three types of planar faults in fcc metals(2) calculate stacking fault energies(3) compare: Al and CuModel system Cu, Al Initial conditions T, P…Supercell N, PBCs …Interatomic potentials EAM Ensembles Minimizeinput file: in.isfCuunits metalboundary p p patom_style atomicread_data isf-Cu# 读取其他文件中的构型pair_style eam/alloypair_coeff* * jin_copper_lammps.setfl Cutimestep0.005minimize 1.0e-8 1.0e-81000 1000compute pe all pe/atomdump 1 all cfg 1 a.isf.*.cfg id type xs ys zs c_pedump_modify 1 element Curun0variable E equal pevariable N equal atomsprint"-------isf in Cu, E = $E -------"run.sh#!/bin/bashlmp< in.isfCulmp< in.esfCulmp< in.twinCulmp< in.refCulmp< in.isfAllmp< in.esfAllmp< in.twinAllmp< in.refAl(1) Change into the 3rd directory$cd□../3_stacking_fault $ls(2) What is the commands in bash file $gedit□run.sh(3) Run bash file$./run.sh(4) After running, view the configuration $cd□cfg$ls$ A.i686□esf-Cu.a4.cfg (5) View the result data$cat□dataAtomeye命令Tab 键切换视角k, Alt + H, Alt + +/-改变颜色Delete / Insert下一帧/上一帧PgUp/ PgDn原子变大/变小滚轮放大/缩小↑↓ ← → 方向键旋转q关闭------isf in Cu, E = -40119.62288 ------------esf in Cu, E = -40119.56232 ------------Twin in Cu, E = -40120.10708 ------------ref of Cu, E = -40120.50995 ------------------------isf in Al, E = -38615.90978------------esf in Al, E = -38615.22202 ------------Twin in Al, E = -38618.18627 ------------ref of Al, E = -38621.04416 ------orthogonal box = (0 0 0) to (15.3371 35.4196 269.239)orthogonal box = (0 0 0) to (17.1827 39.6817 301.637)……………………for Cu: area (A) = 15.3371 ×35.4196for Al: area (A) = 17.1827 ×39.6817Stacking fault energy:resultsγusfγisfγ1utf γ2utf γ3utf Displacement (b p )01234γ(m J m -2)4.晶格常数与体弹模量Model system Cu, Al, Si Initial conditions perfect lattice Supercell N, PBCsInteratomic potentials EAM (Cu, Al), Stilling-Weber (Si)Ensembles None(we calculate ground state properties, 0 K)(1) Copy the file folder to home and then get into it. $cp□-r□share/md2□.$cd□md2$cd□4_lattice(2) What is the setup in input file$gedit□in.diamond(3) Run LAMMPS$lmp□-i□in.diamond(4) Plot$gnuplot>p‘data.d’ u 1:2 w lp输入文件in.Silicon# bulk Silicon lattice# 注释行,随便给units metal# 单位,指定为lammps里的金属类的单位,长度为Å,能量为eV。