Based on the classical molecular dynamics method by using TLHT potential, the dynamical process of rare-gas atoms injected into single-walled carbon nanotube (SWCNT) is discussed. Firstly, the minimal diameters of SWCNT absorbing rare-gas atoms He, Ne, Ar, Kr, Xe are obtained as 6.3 ?,7.0 ?, 8.6 ?,8.6 ? and 8.6 ?, respectively. Then, the threshold energies to encapsulate the rare-gas atoms in SWCNT of different diameters are calculated. The interesting result is that the encapsulated rare-gas atoms are constantly oscillating in SWCNT, and the oscillation period bears no relation to the injection energy, while the amplitude depends on the injection energy, that is, the amplitude increases with increasing injection energy. The investigation indicates that for a suitable SWCNT, rare-gas atoms with a relative small kinetic energy will oscillate steadily in SWCNT, and the oscillation frequency can reach GHz order.