About fix nvt

The model consists of the SiC particle and Cu matrix. Fix npt is used to relax the model at first.
Just like this:

velocity                    all create ${T} 8819988 mom yes rot yes dist gaussian
fix                             relax all npt temp ${T} ${T} 0.1 iso 0.0 0.0 1.0 (T=1000K, units:metal, boundary: PPP)

The temperature of the Cu matrix and the SiC particle is computed.
compute cutemp cu temp
compute sictemp sic temp
question: the temperature of the SiC particle is higher than 1000K. while the temperature of the Cu matrix is lower than 1000K. But the temperature of the model is 1000K.

The same thing happened when fix nvt is used to relax all(group).

When fix nvt is used to the SiC group and Al group, temperature of them is 1000K and that of all group is 1000K. Is it right?

fix                               relax_cu cu nvt temp ${T} ${T} 0.1 
fix_modify                  relax_cu temp cutemp

fix                               relax_sic sic nvt temp ${T} ${T} 0.1 
fix_modify                  relax_sic temp sictemp

Yes and no. Due to choosing two independent thermostat you have enforced equipartitioning between the two groups. But if you want to understand whether your system is properly equilibrated and whether there are intrinsic issues with your setup that will cause one group to accumulate kinetic energy versus the other, then not.

For starters, you should not look at individual temperature values (e.g. at the end of a run) but the trends and especially from the very beginning. Are the values converging toward the desired equipartitioning or not, perhaps only slowly. Also, you may want to use a dissipative thermostat instead of fix nvt (e.g. fix nve + fix langevin) at the beginning of the equilibration to speed up the equipartitioning process.

#***************1initialization***************
units                      metal
dimension                  3
boundary                   p p p
atom_style                 atomic
timestep                   0.001   
neighbor                   2.0 bin		
neigh_modify               every 1 delay 10 check yes


#***************parameters***************
variable                   prerelax_step equal 100000
#***************modelling and setting***************
variable                   latconst_a equal 4.150  #1000K lattice constant 
variable                   latconst_s equal 4.389  #1000K lattice constant

variable                   Al_x    equal    27  
variable                   Al_y    equal 	54   
variable                   Al_z    equal 	27 

variable                   sic_y   equal    ${Al_y}*${latconst_a}/2/${latconst_s}  
 
##nano SiC 半径,直径12variable                   SiC_r   equal    12  #12*4.389=52.668  

#create cu
lattice                    fcc ${latconst_a} origin 0.25 0.25 0.25 

region                     aluminum block -${Al_x} ${Al_x} 0 ${Al_y} -${Al_z} ${Al_z}  

create_box                 3 aluminum

create_atoms               3    region    aluminum   

#sic
lattice                    custom ${latconst_s} a1 1.0 0.0 0.0 a2 0.0 1.0 0.0 a3 0.0 0.0 1.0 &
basis 0.0  0.0  0.0  &
basis 0.5  0.5  0.0  &
basis 0.0  0.5  0.5  &
basis 0.5  0.0  0.5  &
basis 0.25 0.25 0.25 &
basis 0.25 0.75 0.75 &
basis 0.75 0.25 0.75 &
basis 0.75 0.75 0.25

region                     sic_del   sphere 0 ${sic_y} 0 ${SiC_r}   
delete_atoms               region    sic_del

create_atoms               2 region sic_del &     
basis 1 1 &
basis 2 1 &
basis 3 1 &
basis 4 1 &
basis 5 2 &
basis 6 2 &
basis 7 2 &
basis 8 2

mass                       1 28.085  #Si
mass                       2 12.011  #C
mass                       3 26.982  #Al

write_data                 model.data

#**************************group sic al
group                      sic region    sic_del              
group                      al  subtract  all sic                 

info                       group

#***************************************************interatomic potential********
pair_style hybrid  eam/fs   tersoff   morse 10 morse 10 
pair_coeff * *     eam/fs   Al_mm.eam.fs       NULL NULL   Al  
pair_coeff * *     tersoff  SiC_1989.tersoff   Si   C      NULL 
pair_coeff 1 3     morse    1  0.4824 1.322 2.920     #Al-Si
pair_coeff 2 3     morse    2  0.4691 1.738 2.246     #Al-C

#***************************************************minimize******** 

min_style                   cg        
minimize                    1e-18 1e-18 10000 10000

#**************************************************variable**************************
variable                    T           equal  1000 
shell                       mkdir     t_${T} ./t_${T}/relax_${T} 

variable                    path_relax      string  ./t_${T}/relax_${T}/


#***************equilibration***********************relax_{T}*********
reset_timestep              0
timestep                    0.001

compute                     altemp  al   temp
compute                     sictemp sic  temp

thermo                      100
thermo_style                custom step temp c_altemp c_sictemp pe pxx pyy pzz  ke
dump                        relax  all custom 10000 ${path_relax}relax_nanoSiCAl${T}.equil.*.lammpstrj id type x y z 

velocity                    all create ${T} 8819988 mom yes rot yes dist gaussian 
#fix                         relax all npt temp ${T} ${T} 0.1 iso 0.0 0.0 1.0
fix                         relax_al al nvt temp ${T} ${T} 0.1 
fix_modify                  relax_al temp altemp


fix                         relax_sic sic nvt temp ${T} ${T} 0.1 
fix_modify                  relax_sic temp sictemp
#fix_modify                 relax temp altemp
run                         ${prerelax_step}

undump                      relax
unfix                       relax_al
unfix                       relax_sic
units           metal

atom_style      atomic
atom_modify     map array
boundary        p p p
atom_modify     sort 0 0.0

# temperature

variable t equal 1800.0

# cubic diamond unit cell

variable a equal 5.431
lattice         custom $a               &
                a1 1.0 0.0 0.0          &
                a2 0.0 1.0 0.0          &
                a3 0.0 0.0 1.0          &
                basis 0.0 0.0 0.0       &
                basis 0.0 0.5 0.5       &
                basis 0.5 0.0 0.5       &
                basis 0.5 0.5 0.0       &
                basis 0.25 0.25 0.25    &
                basis 0.25 0.75 0.75    &
                basis 0.75 0.25 0.75    &
                basis 0.75 0.75 0.25

region          myreg block     0 4 &
                                0 4 &
                                0 4

create_box      8 myreg
create_atoms    1 region myreg &
                basis 1 1  &
                basis 2 2  &
                basis 3 3  &
                basis 4 4  &
                basis 5 5  &
                basis 6 6  &
                basis 7 7  &
                basis 8 8

mass            *       28.06

velocity        all create $t 5287287 loop geom

# Equilibrate using Stillinger-Weber model for silicon

pair_style      sw
pair_coeff      * * Si.sw Si Si Si Si Si Si Si Si

thermo_style    custom step temp epair etotal econserve press
thermo          10
fix             1 all nvt temp $t $t 0.1
timestep        1.0e-3
neighbor        1.0 bin
neigh_modify    every 1 delay 10 check yes
run             100

write_restart   restart.equil

clear
read_restart    restart.equil

pair_style      sw threebody on
pair_coeff      * * mWxL.sw mW mW mW mW xL xL xL xL

thermo_style    custom step temp epair etotal econserve press
thermo          10
fix             1 all nvt temp $t $t 0.1
timestep        1.0e-3
neighbor        1.0 bin
neigh_modify    every 1 delay 10 check yes
run             100

clear
read_restart    restart.equil

pair_style      hybrid sw threebody on sw threebody off
pair_coeff      * *   sw 1 mWxL.sw mW mW mW mW NULL NULL NULL NULL
pair_coeff      * 5*8 sw 2 mWxL.sw mW mW mW mW xL xL xL xL
info coeffs


thermo_style    custom step temp epair etotal econserve press
thermo          10
fix             1 all nvt temp $t $t 0.1
timestep        1.0e-3
neighbor        1.0 bin
neigh_modify    every 1 delay 10 check yes
run             100