#---------------------------------------------------------------- # Au+ Ar #----------------------------------------------------------------------------------------------------------------------- #-----------------------------------------------------Variable definition---------------------------------------------- variable latparamAu equal 4.08 #[A] variable Y_d equal 3.0*${latparamAu} variable ydim equal 32 #[A] variable Au_T_ymin equal ${ydim}-${Y_d}-11 variable Au_B_max equal 10+${Y_d} variable KJtoKmol equal 0.239 # Convert [KJ/mol] to [Kcal/mol] variable kB equal 1.3806504e-23 # [J/K] Boltzmann variable eps_Ar_Ar equal 0.0104 #[eV] variable sigma_Ar_Ar equal 3.4 #[A] #------------------------------------------------------------------------------------- ####variable eps_Au_Ar equal 0.6580*${KJtoKmol} variable eps_Au_Ar equal 11.36e-3 #[eV] variable sigma_Au_Ar equal 3.82 #[A] #----------------------------------------------------------------------------------- variable rc equal 12 #--------------------------------------------------------------------------------------------------- ############-----------------------Couette flow ##########------------------------- variable m_Ar equal 6.63e-26 variable S_w equal 0.1 variable T_bottom_wall equal 300 variable T_top_wall equal 400 variable T_couette equal (${T_bottom_wall}+${T_top_wall})/2 variable C_m equal sqrt(2*${kB}*${T_bottom_wall}/${m_Ar}) variable v_wall_SI equal ${S_w}*${C_m} #[m/s] variable vel_conv_metal equal 1.0e-2 #convert [m/s] to [An/ps] variable v_wall_metal equal ${v_wall_SI}*${vel_conv_metal} #[An/ps] variable v_wall_metal_top equal 1*${v_wall_metal} #-------------------------------------------------------------------------------------------------------- # ----------------------------------------------------------------------------- INITIALIZATION ---------------------- units metal dimension 3 boundary p p p atom_style atomic lattice fcc ${latparamAu} processors 4 1 4 region whole block 0 100 0 155 0 100 units box create_box 2 whole region Au_B block INF INF 10 19 INF INF units box #Bottom Wall region Au_T block INF INF 135 145 INF INF units box #Top wall mass 1 196.97 mass 2 39.95 create_atoms 1 region Au_B create_atoms 1 region Au_T group AuB region Au_B group AuT region Au_T group whole region whole region Au_B_fix block INF INF 10 11 INF INF units box region Au_T_fix block INF INF 144 145 INF INF units box group AuBfix region Au_B_fix group AuTfix region Au_T_fix group AuB_thermo subtract AuB AuBfix group AuT_thermo subtract AuT AuTfix region Au_B_first block INF INF 18 19 INF INF units box region Au_T_first block INF INF 135 137 INF INF units box group AuBfirst region Au_B_first group AuTfirst region Au_T_first timestep 0.001 #----------------------------------------------FORCE FIELD-------------------------------------------------------------- pair_style hybrid eam lj/cut ${rc} pair_coeff 1 1 eam Au_u3.eam pair_coeff 1 2 lj/cut ${eps_Au_Ar} ${sigma_Au_Ar} pair_coeff 2 2 lj/cut ${eps_Ar_Ar} ${sigma_Ar_Ar} neighbor 2 bin #-------------------------------------------------------Adding Ar atoms #---------------------------------------------------------------------------- region Ar block 0 100 40 110 0 100 units box group Ar type 2 fix Dipos Ar deposit 800 2 5 12345 region Ar near 5 units box variable Count equal count(Ar) thermo_style custom step atoms temp epair etotal press v_Count thermo 100 run 4000 unfix Dipos #----------------------------------------------------------------------------------------------------------- #####-----------------------------------------------------------Energy minimization min_style cg minimize 1e-16 1e-16 100000 100000 #write_data data.Au_Ar_Eq reset_timestep 0 timestep 0.001 variable dt equal "timestep" ##########################################################---------temperature computes compute TBtot AuB temp compute TBCOM AuB temp/com compute TBthermo AuB_thermo temp compute TBthermoCOM AuB_thermo temp/com compute TBX AuB temp/partial 1 0 0 compute TBY AuB temp/partial 0 1 0 compute TBZ AuB temp/partial 0 0 1 compute TBYZ AuB temp/partial 0 1 1 #-------------------------------------------------------------------------- compute TTtot AuT temp compute TTCOM AuT temp/com compute TTthermo AuT_thermo temp compute TTthermoCOM AuT_thermo temp/com compute TTX AuT temp/partial 1 0 0 compute TTY AuT temp/partial 0 1 0 compute TTZ AuT temp/partial 0 0 1 compute TTYZ AuT temp/partial 0 1 1 #------------------------------------------------------------------------- compute TAr Ar temp compute TArCOM Ar temp/com ############################################################ velocity Ar create 300.0 9999999 rot yes dist gaussian fix NVE all nve fix 6 AuB temp/berendsen ${T_bottom_wall} ${T_bottom_wall} 10.0 fix_modify 6 temp TBYZ fix 8 AuT temp/berendsen ${T_top_wall} ${T_top_wall} 10.0 fix_modify 8 temp TTYZ fix 10 AuBfix spring/self 10 y fix 11 AuTfix spring/self 10 y ##fix 12 AuB setforce 0 NULL NULL ##fix 13 AuT setforce 0 NULL NULL compute CC AuBfix com compute BB AuTfix com thermo 1000 thermo_style custom step c_TBCOM c_TBX c_TBY c_TBZ c_TBYZ c_TTCOM c_TTX c_TTY c_TTZ c_TTYZ c_CC[2] c_BB[2] thermo_modify lost warn run 1000000 write_restart restart.Eq_after_thermos ################################################################################################################# ##fix NVE all nve dump 1 all custom 10000 dumpsystem.lammpstrj id type x y z #velocity AuB set -${v_wall_metal} 0 0 units box velocity AuT set ${v_wall_metal_top} 0 0 units box #fix 12 AuB setforce 0 NULL NULL fix 13 AuT setforce 0 NULL NULL thermo 1000 thermo_style custom step c_TBCOM c_TBX c_TBY c_TBZ c_TBYZ c_TTCOM c_TTX c_TTY c_TTZ c_TTYZ c_CC[2] c_BB[2] thermo_modify lost warn run 2000000 #################################################################################################################### #velocity AuB set -${v_wall_metal} 0 0 units box velocity AuT set ${v_wall_metal_top} 0 0 units box ############################################################################################################ #---------------------------------------Temperature profile ################################################################################################# variable Bin_Length equal 1/20 variable LY equal "ly" variable Bin_Length2 equal ${LY}/20 compute layers1 Ar chunk/atom bin/1d y lower ${Bin_Length2} units box #fix aveTPA2 Ar ave/chunk 100000 1 100000 layers1 temp file temp_no_average.txt fix aveTPA3 Ar ave/chunk 100 1000 100000 layers1 temp file temp.txt fix aveVelocityX Ar ave/chunk 100 1000 100000 layers1 vx file velocity_x.txt #fix aveVelocityX2 Ar ave/chunk 100000 1 100000 layers1 vx file velocity_x_no_average.txt compute cc1 Ar temp/chunk layers1 temp com yes #fix T_com Ar ave/time 100 1000 100000 c_cc1[1] file temp_com.txt mode vector #fix 100 Ar ave/time 100000 1 100000 c_cc1[1] file temp_com_no_average.txt mode vector #------------------------------------------------------------------------------------------------ #compute layers20 Ar chunk/atom bin/1d y lower 5.80 bound y 19 135 units box #20 bins #fix aveTPA20 Ar ave/chunk 100 1000 100000 layers20 temp file temp_20_b.txt #fix aveVelocityX20 Ar ave/chunk 100 1000 100000 layers20 vx file velocity_x_20_b.txt #compute cc12 Ar temp/chunk layers20 temp com yes #fix 1000 Ar ave/time 100 1000 100000 c_cc12[1] file temp_com_20_b.txt mode vector #------------------------------------------------------------------------------------------------------------ #compute layers10 Ar chunk/atom bin/1d y lower 11.60 bound y 19 135 units box #10 bins #fix aveTPA10 Ar ave/chunk 100 1000 100000 layers10 temp file temp_10_b.txt #fix aveVelocityX10 Ar ave/chunk 100 1000 100000 layers10 vx file velocity_x_10_b.txt #compute cc111 Ar temp/chunk layers10 temp com yes #fix 10000 Ar ave/time 100 1000 100000 c_cc111[1] file temp_com_10_b.txt mode vector compute myTemp Ar temp/profile 1 1 1 y 20 out bin fix TTprof Ar ave/time 100 1000 100000 c_myTemp[*] file temp_prof.txt mode vector #fix TTprof11 Ar ave/time 100000 1 100000 c_myTemp[*] file temp_prof_no_average.txt mode vector #--------------------------------------------------------------------------------------------------------- ############################################################################################################################# #----------------------------------------------------Computing ACs--------------------------------------------------- ############################################################################################################################# compute kea1 Ar ke/atom dump 3 Ar custom 500 AC500_T300.txt id y vx vy vz c_kea1 dump_modify 3 sort id #dump 4 AuBfirst custom 100000 y_coor_BW.txt id y #dump_modify 4 sort id #dump 5 AuTfirst custom 100000 y_coor_TW.txt id y #dump_modify 5 sort id run 25000000