Components of ElegansBot.

(A) Chain model for C. elegans body. (B) Rods in chain model. (C) i-actuator, which is a damped torsional spring. (D) Frictional force (black arrow) due to the translation motion of a rod. (E) Frictional force (black arrow) due to the rotational motion of a rod. (F) Joint force (black arrows) acting on i-rod and (i+1)-rod.

Simulated locomotion from a sine kymogram.

(A) Crawling kymogram. Kymogram indicates the angle of i-joint which is located between i-rod and (i+1)-rod. Red and blue color mean i-joint bend in the dorsal and ventral directions, respectively. (B) Crawling trajectory. The yellow circle indicates the position of the worm’s head. The Orange and sky-blue lines show the worm’s head and tail trajectories, respectively. (C) Swimming kymogram. (D) Swimming trajectory

Simulated locomotion from a kymogram of a real worm locomotion video.

The length and direction of a black arrow indicate the magnitude and direction of the frictional force that the corresponding body part, which is the starting point of the arrow, exerts on the surface. (A) escaping behavior kymogram. Triangles over the heatmap indicate the corresponding time of snapshots shown in Figure (C). (B) Delta-turn kymogram. Triangles over the heatmap indicate the corresponding time of snapshots shown in Figure (D). (C) Escaping behavior trajectory. (D) Delta-turn trajectory. The arrow length scale is different from Figure (C) to clearly show the arrows’ directions and head and tail tracks. (Those videos are in Supplementary Information)

Frictional force on each rod (A) Escaping behavior. The top panel represents the frictional force experienced by i-rod. As indicated on the color wheel to the right, the hue of this heatmap represents the direction of the force, and the saturation represents the magnitude of the force. The second panel from the top shows the magnitude of the frictional force . The third panel from the top represents the average (black solid line) of each column in the middle panel and the power (red dotted line), which is the amount of energy the worm consumes per unit time. The bottom panel represents the classification of the worm’s behavior (blue: forward locomotion, red: backward locomotion, green: turn) (The definitions of behavioral categories are in Methods). The triangles over each panel indicate the corresponding time of the snapshots depicted in Fig. 3C. (B) Delta-turn. The triangles over each panel indicate the corresponding time of the snapshots depicted in Fig. 3D.

Body shape transition from the shape in water to the shape in agar.

Average velocity of the worm as a function of wavenumber (v) and period (T) for a given friction coefficient. The star symbol indicates the pair of (v, T) that maximizes the worm’s average velocity. (B) For each environmental index σ, the pair of (v, T) that maximizes the worm’s average velocity. The worm figures inside the small rectangles pointed to by the arrows represent the body shape corresponding to the respective (v, T) pair.