This paper discusses the problem of the fastest motion of an object in a curved earth tunnel. By establishing a mathematical model and applying the Python visualization toolkit, the analytical expression of steepest descent line is derived, and the physical meaning of the integral constant C is analyzed . The study found that under certain conditions, a curved tunnel can provide a shorter travel time than a straight tunnel, which challenges intuitive cognition . At the same time, this research method that combines mathematical software and physical models can help students better expand their thinking about physical models, making complex expanded physical models easy to understand and master.