In this paper, the application of Muller-Plathe method and Jund method in reverse nonequilibrium molecular dynamics to the heat conduction of one-dimensional nanotubes are tested and studied. The results show that the Jund method cannot obtain a good linear temperature gradient and its thermal conductivity is also dependent on the choice of heat flux. When the exchange frequency is 50, the thermal conductivity obtained by the Muller-Plathe method converges to a stable value. This method can be well applied to the study of thermal conductivity of nanotubes. The Muller-Plathe method is a good option when the number of atoms exchanged is 1 and the exchange frequency is 100. On this basis, we further investigate the effect of length, diameter and temperature of carbon nanotubes and silicon carbide nanotubes on the thermal conductivity. The thermal conductivity of carbon nanotubes is obviously higher than that of silicon carbide nanotubes, and their effects of length, diameter and temperature on the thermal conductivity are consistent. The thermal conductivity of nanotubes increases with the rise of temperature, but the increase rate decreases and the length dependence also weakens. Therefore, when carbon nanotubes and silicon carbide nanotubes reach certain lengths, their values of thermal conductivity will converge and no longer change with length, which is completely consistent with the results of previous studies. Comparing with carbon nanotubes, the convergence rate of thermal conductivity of SiC nanotubes is significantly lower. When the temperature is low, the diameter has a certain effect on the thermal conductivity; however, with the increase of temperature, the diameter has almost no effect on the thermal conductivity at high temperature. The effect of temperature on the thermal conductivity of nanotubes shows that the thermal conductivity of nanotubes generally decreases with the rise of temperature, but the occurrence of the peak phenomenon is also affected by the length of nanotubes. When the length of carbon nanotubes is 10 nm, the influence of temperature and diameter on the thermal conductivity are irregular. However, when the length of carbon nanotubes is 100 nm, the thermal conductivity of carbon nanotubes decreases continuously with the rise of temperature, and there occurs no peak phenomenon. Besides, when the tube length is 10 nm, the peak of SiC nanotubes appears at about 100 K. However, when the tube length is 100 nm, the thermal conductivity of SiC nanotubes decreases with the rise of temperature, but no peak phenomenon occurs.