Application and evaluation of reinforcement learning for two-dimensional trajectory tracking in snake-like robots
Abstract
Context—Snake-like robots are biomimetic systems that can move effectively in narrow, complex, and restricted environments thanks to their modular and flexible body structures composed of numerous serially connected joints. These characteristics offer significant advantages, particularly in areas such as pipeline inspection, search and rescue operations, industrial maintenance applications, and exploration missions. The multiple degrees of freedom distributed along the body enable the robot to achieve high maneuverability but also make the control problem quite complex. Due to the dynamic interactions between segments, friction-based motion characteristics, and nonlinear system behavior, achieving reliable and accurate trajectory tracking emerges as a significant engineering problem.
Objective—In this study, a reinforcement learning (RL) based control method has been developed to solve the trajectory tracking problem for snake-like robots in a two-dimensional plane.
Method—In the proposed approach, the robot’s dynamic model was created in the Webots simulation environment, an open-source simulation program, and all training and testing processes were carried out in this environment. During the learning process, policy- based RL algorithms from the Stable-Baselines library were used. In this context, Proximal Policy Optimization (PPO) and three different RL algorithms were used during the training process. To enable the robot to adapt to different orientation scenarios, seven different angles defined in the range of +45 to −45 and trajectories of varying lengths were used. Thus, the goal was for the agent to learn a generalizable control policy not only for a specific trajectory type but also for tracks with different slopes and orientations.
Results—The results obtained show that the PPO algorithm produced a higher average reward compared to other methods and exhibited a more stable learning process. After training was completed, the developed method was tested both on trajectories used during the training phase and on previously unseen trajectories. For the 0 trajectory, maximum errors were recorded as 0.093 m and 0.040 m for the x and y axes, respectively. Furthermore, the system exhibited robust generalization capabilities on a +22.5 trajectory, not encountered during the training phase, yielding maximum errors of 0.099 m and 0.052 m.
Conclusion—These findings demonstrate that the proposed RL-based control approach can effectively solve the two-dimensional trajectory tracking problem in snake robots. In future studies, the proposed method can be extended to the three-dimensional trajectory tracking problem, or it can be evaluated under more complex conditions, such as scenarios involving obstacles.
Keywords
References
- T. Takemori, M. Tanaka, F. Matsuno, “Adaptive helical rolling of a snake robot to a straight pipe with irregular cross-sectional shape”, IEEE Transactions on Robotics, 39(1), 437–451, 2023. https://doi.org/10.1109/TRO.2022.3189224.
- G. Çetin, E. Aksakal, S. Taskın, “Göçük altında kalanların tespiti için biyonik yılan robot tasarımı”, Journal of Materials and Mechatronics: A, 3(1), 63–78, 2022. https://doi.org/10.55546/jmm.1079962.
- X. Hou, Y. Shi, L. Li, Y. Tian, Y. Su, T. Ding, Z. Deng, “Revealing the mechanical characteristics via kinematic wave model for snake-like robot executing exploration of lunar craters”, IEEE Access, 8, 38368–38379, 2020. https://doi.org/10.1109/ACCESS.2020.2971221.
- X. Liu, C. D. Onal, J. Fu, “Reinforcement learning of cpg-regulated locomotion controller for a soft snake robot”, IEEE Transactions on Robotics, 39(5), 3382–3401, 2023. https://doi.org/10.1109/TRO.2023.3286046.
- F. Sheng, F. Wan, C. Tang, X. Guo, “A maneuverable winding gait for snake robots based on a delay-aware swing and grasp framework combining rules and learning methods”, IEEE Robotics and Automation Letters, 10(1), 311–318, 2025. https://doi.org/10.1109/LRA.2024.3506274.
- Y. Li, C. Wei, Q. Wu, P. Chen, Y. Jiang, Y. Li, “Study of 3 dimension trajectory tracking of underactuated autonomous underwater vehicle”, Ocean Engineering, 105, 270–274, 2015. https://doi.org/10.1016/j.oceaneng.2015.06.034.
- H. Shi, Y. Meng, W. Cui, M. Rao, S. Wang, Y. Xie, “Biomimetic underwater soft snake robot: Self-motion sensing and online gait control”, IEEE Transactions on Robotics, 41, 1193–1210, 2025. https://doi.org/10.1109/TRO.2025.3530349.
- Y. Cai, H. Xu, Y. Wang, D. Chen, W. Matusik, W. Shou, Y. Chen, “Modular self-reconfigurable continuum robot for general purpose loco-manipulation”, IEEE Robotics and Automation Letters, 10(2), 1976–1983, 2025. https://doi.org/10.1109/LRA.2025.3526560.
Details
Primary Language
English
Subjects
Control Theoryand Applications
Journal Section
Research Article
Early Pub Date
August 19, 2026
Publication Date
-
Submission Date
April 2, 2026
Acceptance Date
August 5, 2026
Published in Issue
Year 2026 Number: Advanced Online Publication