1 Introduction

With the rapid development of worm-like soft robot application in medicine delivery, pipeline cleaning, disaster rescue, military detection, these robots have been attracting more and more attention of many researchers. For the study on these robots, the researchers gain inspiration from the locomotion mechanism of some limbless animals such as earthworm, snail, leech, slug and amoeba, which can effectively move in various environments by regularly changing the shape of their bodies or by periodically changing the position of mass center of their body. Then, it is found that there exist two key factors for the motion, the strategies of shape changes and the interaction force between the worm body and the environment. Based on these two key factors, various conditions for self-propelled system mimicking the motion of worm have been the focus of the attention of many researchers. However, this problem still need to be further considered.

Among the current research on the strategies for shape change driving the motion of worm, many scholars in the past several years paid special attention to the propagation of the extensive and contractive wave. Tanaka et al. [1] studied the locomotion of limbless crawlers driven by elongation–contraction waves propagating along the body axis. The result showed that the locomotion of these crawlers cannot occur when friction coefficient is constant. Then, DeSimone et al. [2,3,4,5] used the extensive or contractive square wave to study a series of problems related to the motility of crawlers based on quasi-static model. It is found that crawlers can move in a constant friction coefficient environment. Apparently, this result is different from the one obtained by Tanaka. For this problem, Bolotnik et al. [6] explained the reason why these two cases can happen. Specifically, two kinds of different friction models were studied, namely, the first one is that the coefficient of friction is constant for a mass element; the other one is given with the coefficient being constant for a length element. And it is found that the locomotion is possible only for the second model.

On the other hand, many researchers considered that the motion of worm-like system interacting with various environments is excited by changing the position of body center of mass. As a result, vibration-driven system based on this locomotion mechanism has been presented. In fact, the condition that the directed motion of this system can be achieved has been widely studied. It is found that the system can be driven forward only when the system or the interaction force possess anisotropic characteristics. In other words, the result whether the motion of this system can occur is different for different drive modes or in various environments. For the single-module vibration-driven locomotion system with one internal mass, Chernousko et al. [7, 8] studied the motion of the system with linear viscous friction was actuated by internal velocity-controlled mode. The result showed that the motion can be achieved only when this friction is anisotropic. If the interaction between the system and environment is dry friction or nonlinear viscous one, the system can move even if this friction is isotropic. While for the case of internal acceleration-controlled mode, the system with asymmetry can move in an isotropic frictional environment. Furthermore, many scholars [9,10,11,12] further considered that the asymmetric single-module system with two or three internal masses can achieve the rectilinear or planar motion of the system in various environments, and analyzed the motion mechanism of this system. Besides, the motion of the multiple-module system connected by spring elements or displacement actuators was further investigated [13,14,15,16]. Zimmermann et al. [14,15,16] considered the condition that two-module system connected by the spring with cubic nonlinearity or displacement actuator can move in various mediums. The results found that the motion of the system can occur only in anisotropic environment if these two modules have the same mass. But if this assumption is not satisfied, the system can move in isotropic environment. The above researches on the vibration-driven system are based on the simplified model describing the motion of worm. While the condition that a continuous worm-like system as mechanical model of worm-like soft robot can move in anisotropic environment by changing the position of mass center of its body, is rarely studied and needs to be further considered.

In this paper, we study that the motion of worm is actuated by changing the position of mass center of its body in anisotropic dry friction environment and assume that the active distortion along worm body is spatially uniform. As a result, the acceleration of time history of active distortion is considered as being piecewise constant. Based on the assumption of a slow actuation history or for a larger friction, the quasi-static equation describing worm-like motion is derived. Then a locomotion gait is constructed to solve this equation on the basis of the continuous distributed tension along the worm body. Therefore, specific expressions of the displacement and the tension are respectively calculated at each stage. After that, the net displacement over one period is further deduced and the length of worm body is attained.

2 Formation of the equation of worm-like motion

The worm-like motion is described as shown in Fig. 1. \(Z_{1} =0\), \(Z_{2} =L\) denote the position of the rear end and the front end of worm body in reference configuration, respectively. The position of worm for \(Z\in [0,L]\) in reference configuration is continuously and reversely mapped to the current configuration for \(x(Z,t)\in [x_{1} (t),x_{2} (t)]\) written by

$$\begin{aligned} \left\{ {{\begin{array}{l} {x_{1} (t)=x(Z_{1} ,t)=Z_{1} +u(Z_{1} ,t)=u_{1} (t)} \\ {x_{2} (t)=x(Z_{2} ,t)=Z_{2} +u(Z_{2} ,t)=L+u_{2} (t)} \\ \end{array} }} \right. \end{aligned}$$
(1)
Fig. 1
figure 1

The motion of one-dimensional worm along the horizontal direction in an anisotropic medium

where u(Zt) represents the displacement at position Z at time t, namely

$$\begin{aligned} u(Z,t)=x(Z,t)-Z. \end{aligned}$$
(2)
Fig. 2
figure 2

Force analysis in the reference configuration

After that, we will deduce the equation of motion. Here, we consider the quasi-static model that the inertia can be ignored. It can be actually observed that the motion of worm such as earthworm, elegans and maggot is very slow and the intervals of acceleration are so short. It means that the rate of change of velocity is enough small. Meantime, because of the small mass of worm (e.g., the mass of earthworm is 1–9 g), it follows that the inertia force does not dominate over other forces such as frictional force, tension or elastic force. On the other hand, it is mainly concerned that the worm moves forward with a nearly constant velocity. As a result, the change of momentum during each periodic motion is very small such that the inertia force is much less than other forces. In addition, the motion of elegans on a solid surface was discussed in [17]. The mass and maximal acceleration of elegans were measured, and the size range of frictional force was estimated. It was found that the order of frictional force is much greater than the one of inertia force. The other authors [1, 18,19,20] also discussed that inertia is negligible. Furthermore, to obtain the equation describing the motion of worm, forces acting on an infinitesimal element of its body during motion in the reference configuration are displayed in Fig. 2, where \(F_\mathrm{e} (Z,t)\), f(Zt), \(F_\mathrm{a} (Z,t)\) denotes the density of elastic force, friction density and the one of actuator force controlling the elastic deformation of its body, respectively. Then, the forces balance of the infinitesimal element are expressed as

$$\begin{aligned} F_\mathrm{e} (Z+\mathrm{d}Z,t)-F_\mathrm{e} (Z,t)+F_\mathrm{a} (Z+\mathrm{d}Z,t)-F_\mathrm{a} (Z,t)+f(Z,t)\mathrm{d}Z=0. \end{aligned}$$
(3)

Then, we divide each side of Eq. (3) by dZ and let dZ tend to zero to obtain the following equation given by

$$\begin{aligned} {F}'_\mathrm{e} (Z,t)+F_\mathrm{a}^{\prime }(Z,t)+f(Z,t)=0, \end{aligned}$$
(4)

where \(F_\mathrm{e} (Z,t)=EA{u}'(Z,t)E\) is Young’s modules; A is the cross-sectional area; the prime stands for differentiating with respect to Z. Here, let \(K=EA\) and \(F_\mathrm{a} (Z,t)=K\varepsilon _{0} (Z,t)\). Then Eq. (4) is simplified as

$$\begin{aligned} {T}'(Z,t)+f(Z,t)=0, \end{aligned}$$
(5)

where \(T(Z,t)=K({u}'(Z,t)-\varepsilon _{0} (Z,t))\) is the internal tension of worm’s body [1, 18]. Here,

It is found in [1, 18] that the term \(\varepsilon _{0} (Z,t)\) is called as spontaneous strain at Z and time t. And it is also regarded as active distortion that identifies the change of rest length of living organism. In fact, it is pretty common for spontaneous strain charactering the phase transition of several smart materials, such as shape memory alloy, liquid crystal elastomer. In this paper, we consider that the actuator force \(F_\mathrm{a} (Z,t)\) is uniformly distributed along the worm body. Namely, it is independent of the position Z and is denoted by \(F_\mathrm{a} (Z,t)=K\varepsilon _{0} (t)\) for \(Z\in [0,L]\).

Then, it is assumed that there are no the tension acting on two ends, and one obtains the following boundary conditions

$$\begin{aligned} \left\{ {{\begin{array}{l} {T(0,t)=K{u}'(0,t)-K\varepsilon _{0} (0,t)=0,} \\ {T(L,t)=K{u}'(L,t)-K\varepsilon _{0} (L,t)=0.} \\ \end{array} }} \right. \end{aligned}$$
(6)

Then, the density of the dry friction between worm body and contact surface is given by

$$\begin{aligned} f(Z,t)=f(\dot{{u}}(Z,t))=\left\{ \begin{array}{ll} \mu _{-} ,&{}\quad \text{ if } \dot{{u}}<0, \\ f_{v} ,&{}\quad \text{ if } \dot{{u}}=0, \\ -\mu _{+} ,&{}\quad \text{ if } \dot{{u}}>0, \\ \end{array} \right. \end{aligned}$$
(7)

where \(f_{v} \in \left[ {-\mu _{-} ,\mu _{+} } \right] \). Here, \(\mu _{-} \) and \(\mu _{+} (\mu _{-}>\mu _{+} >0)\) are threshold forces per unit body length in reference configuration to be overcome for sliding to occur, which implies that it is easy for worm to slide along the positive direction.

Based on the above relations, the solution of equation will be deduced in the next section.

Fig. 3
figure 3

The periodic motion of worm induced by changing the position of mass center in the anisotropic surface

3 The gait construction

In the previous section, we have derived the quasi-static equation controlling worm-like motion. This section will construct a new locomotion gait to solve the problem of the motion induced by the change of the position of mass center of worm body in anisotropic dry friction environment. In fact, the motion of the limbless animals like earthworm, maggot, and sea cucumber belongs to the scope of this motion mechanism. Their motion direction is opposite with the one of the change of mass center of a worm’s body in an anisotropic environment. The motion of vibration-driven system with internal moving mass is in fact based on this mechanism. In addition, Desimene et al. [18] studied the motility of crawlers actuated by breathing deformation modes on the directional substrates and mainly considered the direction of the head and the tail end is opposite each other. The result showed that the crawlers can occur only when spontaneous strain is enough large. For it, the problem that this condition should be weakened needs to be further studied, that is, it is worthwhile to consider further how to construct a new locomotion gait for the directional motion of these worms more efficiency. Therefore, we consider the other situation that the motion with same direction at two ends can be realized by the change of mass center as shown in Fig. 3.

Specifically, this figure reflects the periodic motion of an elastic rod with uniformly distributed actuators, which is regarded as a simplified model of a worm’s body, when the position of mass center travels over one period (i.e., from to the right-hand extreme position and return to the original extreme position again). Here, Fig. 3 firstly shows that the mass center of its body moves forward to the right-hand extreme position, and then it starts to move backward and reaches the left-hand extreme position. After that, it starts to move forward and reaches the right-hand extreme position again, and it is shown that the periodic motion of a worm is completed at this time and the displacement is denoted as \(\Delta u\).

To further describe the locomotion gait of a worm-like system, some equations in Sect. 2 should be firstly transformed.

According to Eqs. (5) and (7), one has

$$\begin{aligned} {T}'(Z,t)=\left\{ \begin{array}{ll} -\mu _{-} ,&{}\quad \text{ if } \dot{{u}}<0, \\ -f_{v} ,&{}\quad \text{ if } \dot{{u}}=0, \\ \mu _{+} ,&{}\quad \text{ if } \dot{{u}}>0, \\ \end{array} \right. \end{aligned}$$
(8)

where \(f_{v} \in \left[ {-\mu _{-} ,\mu _{+} } \right] \) and the tension expression can be written by

$$\begin{aligned} T(Z,t)=K(u'(Z,t)-\varepsilon _{0} (t)). \end{aligned}$$
(9)

Then, the positional relation between any two points \(Z_{1} \) and \(Z_{2} \) on the worm body is derived as

$$\begin{aligned} u(Z_{2} ,t)=u(Z_{1} ,t)+\int _{Z_{1} }^{Z_{2} } {(T(Z,t)/K+\varepsilon _{0} (t))} \mathrm{d}Z. \end{aligned}$$
(10)

If \(\dot{{u}}(Z,t)=0\) for \(\forall Z\in U_{0} (Z_{0} )\), where \(U_{0} (Z_{0} )\) denotes a neighborhood of \(Z_{0} \), then it follows from Eq. (9) that

$$\begin{aligned} \dot{{T}}(Z_{0} ,t)=-K\dot{{\varepsilon }}_{0} (t). \end{aligned}$$
(11)

Meantime, consider that the time history of active distortions is given by the 2p-periodic quadratic parabola graph in Fig. 4, namely the acceleration of its change is piecewise constant. Here, the active distortion in positional interval \([0,L_{0} ]\) is typically given as \(\varepsilon _{0} (t)=\varepsilon _{1} (t)\). The other one \([L_{0} ,L]\) can be denoted as \(\varepsilon _{0} (t)=\varepsilon _{2} (t)\). Then one obtains

$$\begin{aligned} \varepsilon _{1} (t)=\alpha _{1} (t^{2}-2pt),t\in [0,2p], \end{aligned}$$
(12)

and

$$\begin{aligned} \varepsilon _{2} (t)=-\alpha _{2} (t^{2}-2pt),t\in [0,2p]. \end{aligned}$$
(13)

Actually, \(\varepsilon _{0} (t)\) can indicate various active distortions (e.g., sawtooth form [18], sinusoidal form [1]).

To deduce the net displacement of worm motion over one period based on Eqs. (8) and (9), the process from the start to the end of the motion over one period is specifically given as depicted in Fig. 4. Here, the positions of several special points are listed as follows

$$\begin{aligned} X_{L_{1} }= & {} L_{0} +\frac{\mu _{+} }{\mu _{+} +\mu _{-} }(L-L_{0} ), X_{R_{1} } =\frac{\mu _{-} }{\mu _{+} +\mu _{-} }L_{0} ,X_{L_{2} } =\frac{\mu _{+} }{\mu _{+} +\mu _{-} }L_{0} ,X_{R_{2} }\nonumber \\= & {} L_{0} +\frac{\mu _{-} }{\mu _{+} +\mu _{-} }(L\text{- }L_{0} ), \end{aligned}$$
(14)

where

$$\begin{aligned} X_{L_{2} } +X_{R_{1} } =L_{0} ,X_{L_{1} } +X_{R_{2} } =L-L_{0} . \end{aligned}$$
(15)
Fig. 4
figure 4

Time history of active distortions exerted on the worm with 2p-period. a The relation between \(\varepsilon _{1} (t)\) and t in the interval \([0,L_{0} ]\). b The relation between \(\varepsilon _{2} (t)\) and t in the interval \([L_{0} ,L]\)

Fig. 5
figure 5

The moving process of worm at different times of the time interval [0,3p]

In fact, these points can be derived when the tension reaches the maximum value.

Then it is seen from Fig. 5 that the symbol of the velocity \(\dot{{u}}(Z,t)\) can be assigned. Namely, the interval \(\left[ {0,L} \right] \) is partitioned into six disjoint sub-intervals wrote by

$$\begin{aligned} \left[ {0,L} \right] =I_{L_{2} } (t)\cup I_{01} (t)\cup I_{R_{1} } (t)\cup I_{L_{1} } (t)\cup I_{02} (t)\cup I_{R_{2} } (t). \end{aligned}$$
(16)

Here, these sub-intervals are presented according to the following two cases

Case 1 Worm moves forward when the body center of mass moves backward. Then one has

$$\begin{aligned} \left\{ {{\begin{array}{l} {\left. {{\begin{array}{l} \dot{{u}}(Z,t)>0, \quad \text{ for } Z\in I_{L_{2} } (t) \\ \dot{{u}}(Z,t)=0,\quad \text{ for } Z\in I_{01} (t) \\ \dot{{u}}(Z,t)<0,\quad \text{ for } Z\in I_{R_{1} } (t) \\ \end{array} }} \right\} \quad \text{ if } \dot{{\varepsilon }}_{1} (t)<0,} \\ {\left. {{\begin{array}{l} \dot{{u}}(Z,t)<0,\quad \text{ for } Z\in I_{L_{1} } (t) \\ \dot{{u}}(Z,t)=0,\quad \text{ for } Z\in I_{02} (t) \\ {\dot{{u}}(Z,t)>0,\quad \text{ for } Z\in I_{R_{2} } (t)} \\ \end{array} }} \right\} \quad \text{ if } \dot{{\varepsilon }}_{2} (t)>0.} \\ \end{array} }} \right. \end{aligned}$$
(17)

This case is shown Fig. 4 when \(t\in [0,p]\). Specifically, the tension reaches the maximal allowable value when \(t=\tau _{1} \). However, the conditions \(\dot{{\varepsilon }}_{1} (t)<0\) for \(Z\in \left[ {0,L_{0} } \right] \) and \(\dot{{\varepsilon }}_{2} (t)>0\) for \(Z\in \left[ {L_{0} ,L} \right] \) are still satisfied at this time. Hence, this case will continue until \(\dot{{\varepsilon }}_{1} (t)=0\) and \(\dot{{\varepsilon }}_{2} (t)=0\), and then the relation \(t=p\) is derived. In addition, it is observed from Fig. 4 that the other time interval \(t\in [2p,3p]\) is included in this case as well. However, since the tension of the fully relaxed state of a worm is equal to zero when \(t=0\), i.e., \(T(Z,0)=0\), On the other hand, it can be obtained that \(T(Z,2p)=-\mu _{-} Z\) due to the continuity of the change of the tension in motion. It is shown that the initial value of the tension for \(t\in [0,p]\) is apparently different from the one of the tension for \(t\in [2p,3p]\). Therefore, the periodic motion of a worm does not start from the initial instant \(t=0\)

Case 2 Worm moves backward when the mass center moves forward. Namely,

$$\begin{aligned} \left\{ {{\begin{array}{l} {\left. {{\begin{array}{l} {\dot{{u}}(Z,t)<0, \quad \text{ for } Z\in I_{L_{2} } (t)} \\ {\dot{{u}}(Z,t)=0,\quad \text{ for } Z\in I_{01} (t)} \\ {\dot{{u}}(Z,t)>0,\quad \text{ for } Z\in I_{R_{1} } (t)} \\ \end{array} }} \right\} \quad \text{ if } \dot{{\varepsilon }}_{1} (t)>0,} \\ {\left. {{\begin{array}{l} {\dot{{u}}(Z,t)>0,\quad \text{ for } Z\in I_{L_{1} } (t)} \\ {\dot{{u}}(Z,t)=0,\quad \text{ for } Z\in I_{02} (t)} \\ {\dot{{u}}(Z,t)<0,\quad \text{ for } Z\in I_{R_{2} } (t)} \\ \end{array} }} \right\} \quad \text{ if } \dot{{\varepsilon }}_{2} (t)<0.} \\ \end{array} }} \right. \end{aligned}$$
(18)

This case is shown in Figs. 4 and 5 when \(t\in [p,2p]\). The maximum value of the tension is reached at instant time \(t=p+\tau _{2} \), then keeping this value unchanged till \(t=2p\). The conditions \(\dot{{\varepsilon }}_{1} (t)>0\) for \(Z\in \left[ {0,L_{0} } \right] \) and \(\dot{{\varepsilon }}_{2} (t)<0\) for \(Z\in \left[ {L_{0} ,L} \right] \) are still satisfied for \(t\in [p+\tau _{2} ,2p)\) until the relations \(\dot{{\varepsilon }}_{1} (t)=0\dot{{\varepsilon }}_{2} (t)=0\) are derived, i.e., the maximal contraction and extension are achieved at \(t=2p\). Here, the values of the parameters \(\tau _{1} \tau _{2} \) and \(\tau _{3} \) can be derived according the above analysis, and given in next section.

It follows from Eq. (8) and the boundary condition (6). As for the first case \(\dot{{\varepsilon }}_{1} (t)<0,\dot{{\varepsilon }}_{2} (t)>0\), one has

$$\begin{aligned} I_{L_{2} } (t)\subseteq [0,X_{R_{1} } ],I_{R_{1} } (t)\subseteq [X_{R_{1} } ,L_{0} ],I_{L_{1} } (t)\subseteq [L_{0} ,X_{L_{1} } ],I_{R_{2} } (t)\subseteq [X_{L_{1} } ,L]. \end{aligned}$$
(19)

Then, the tension satisfies

$$\begin{aligned} \left\{ {{\begin{array}{ll} T(Z,t)=\mu _{+} Z,&{}\quad \text{ for } Z\in I_{L_{2} } (t), \\ T(Z,t)\le \mu _{+} Z,&{}\quad \text{ for } Z\in I_{01} (t)\cap [0,X_{R_{1} } ],\\ T(Z,t)\le -\mu _{-} (Z-L_{0} ),&{}\quad \text{ for } Z\in I_{01} (t)\cap [X_{R_{1} } ,L_{0} ], \\ T(Z,t)=-\mu _{-} (Z-L_{0} ),&{}\quad \text{ for } Z\in I_{R_{1} } (t)\cup I_{L_{1} } (\tau ), \\ T(Z,t)\ge -\mu _{-} (Z-L_{0} ),&{}\quad \text{ for } Z\in I_{02} (t)\cap [L_{0} ,L_{0} +X_{L_{1} } ], \\ T(Z,t)\ge \mu _{+} (Z-L),&{}\quad \text{ for } Z\in I_{02} (t)\cap [L_{0} +X_{L_{1} } ,L], \\ T(Z,t)=\mu _{+} (Z-L),&{}\quad \text{ for } Z\in I_{R_{2} } (t). \\ \end{array} }} \right. \end{aligned}$$
(20)

Due to the continuous distribution of tension along the worm body, we can obtain that the equality in Eq. (20) holds only at the boundary, namely, \(I_{01} (t)=\{X_{R_{1} } \}\) and \(I_{02} (t)=\{X_{L_{1} } \}\), then tension reaches its extreme admissible value given by

$$\begin{aligned} \left\{ {{\begin{array}{ll} T(Z,t)=\mu _{+} Z,&{}\quad \text{ for } 0\le Z\le X_{R_{1} } , \\ T(Z,t)=-\mu _{-} (Z-L_{0} ),&{}\quad \text{ for } X_{R_{1} } \le Z\le X_{L_{1} } , \\ T(Z,t)=\mu _{+} (Z-L),&{}\quad \text{ for } X_{L_{1} } \le Z\le L. \\ \end{array} }} \right. \end{aligned}$$
(21)

Similarly, for the second case \(\dot{{\varepsilon }}_{1} (t)>0,\dot{{\varepsilon }}_{2} (t)<0\), one has

$$\begin{aligned} I_{L_{2} } (t)\subseteq [0,X_{L_{2} } ],I_{R_{1} } (t)\subseteq [X_{L_{2} } ,L_{0} ],I_{L_{1} } (t)\subseteq [L_{0} ,X_{R_{2} } ],I_{R_{2} } (t)\subseteq [X_{R_{2} } ,L]. \end{aligned}$$
(22)

Then the tension satisfies

$$\begin{aligned} \left\{ {{\begin{array}{ll} T(Z,t)=-\mu _{-} Z,&{}\quad \text{ for } Z\in I_{L_{2} } (t), \\ T(Z,t)\ge -\mu _{-} Z,&{}\quad \text{ for } Z\in I_{01} (t)\cap [0,X_{R_{1} } ], \\ T(Z,t)\ge \mu _{+} (Z-L_{0} ),&{}\quad \text{ for } Z\in I_{01} (t)\cap [X_{R_{1} } ,L_{0} ], \\ T(Z,t)=\mu _{+} (Z-L_{0} ),&{}\quad \text{ for } Z\in I_{R_{1} } (t)\cup I_{L_{1} } (t), \\ T(Z,t)\le \mu _{+} (Z-L_{0} ),&{}\quad \text{ for } Z\in I_{02} (t)\cap [L_{0} ,L_{0} +X_{L_{1} } ], \\ T(Z,t)\le -\mu _{-} (Z-L),&{}\quad \text{ for } Z\in I_{02} (t)\cap [L_{0} +X_{L_{1} } ,L], \\ T(Z,t)=-\mu _{-} (Z-L),&{}\quad \text{ for } Z\in I_{R_{2} } (t). \\ \end{array}}} \right. \end{aligned}$$
(23)

Here, the equality in Eq. (23) only holds at the boundary \(I_{01} (t)=\{X_{L_{2} } \},I_{02} (t)=\{X_{R_{2} } \}\) due to the continuity of the tension, and the corresponding relations can be expressed as

$$\begin{aligned} \left\{ {{\begin{array}{ll} T(Z,t)=-\mu _{-} Z,&{}\quad \text{ for } Z\in [0,X_{L_{2} } ), \\ T(Z,t)=\mu _{+} (Z-L_{0} ),&{}\quad \text{ for } Z\in [X_{L_{2} } ,X_{R_{2} } ], \\ T(Z,t)=-\mu _{-} (Z-L),&{}\quad \text{ for } Z\in [X_{R_{2} } ,L]. \\ \end{array} }} \right. \end{aligned}$$
(24)

This result shows that the worm is moving forward around the stationary points \(X_{L_{2} } \) and \(X_{R_{2} } \) when the position of the mass center of its body moves backward.

Fig. 6
figure 6

The tension T(Zt) along the worm body at different time intervals for the directional distributed friction

4 The solution of motion problem

In Sect. 2, we have constructed the locomotion gait of a worm. This section will analyze and solve the motion problem of the worm-like system at different stages according to the constructed gait.

Next, based on the continuity of the tension T(Zt) in the moving process of worm at different time intervals, the expressions of the tension and the net displacement of the worm at any points can be specifically deduced in each interval.

To simplify the following analysis, three specific time values are first given as

$$\begin{aligned} \begin{array}{l} \tau _{1} =\frac{Kp\alpha _{1} -\sqrt{K\alpha _{1} \left( {Kp^{2}\alpha _{1} -\mu _{+} X_{R_{1} } } \right) } }{K\alpha _{1} },\tau _{2} =\frac{\sqrt{K\alpha _{1} \left( {\mu _{-} +\mu _{+} } \right) X_{L_{2} } } }{K\alpha _{1} }, \\ \tau _{3} =\frac{Kp\alpha _{1} -\sqrt{K\alpha _{1} \left( {Kp^{2}\alpha _{1} -\left( {\mu _{-} +\mu _{+} } \right) X_{L_{2} } } \right) } }{K\alpha _{1} }. \\ \end{array} \end{aligned}$$
(25)

Here, the values of these parameters \(\tau _{1} \tau _{2} \) and \(\tau _{3} \) can be calculated according to the analysis of the tension in the above section. Then, six stages of the motion are discussed as follows.

Stage 1 When \(t\in [0,\tau _{1} ]\). Notice that the initial conditions \(u(Z,0)=0\) and \(T(Z,0)=0\) are satisfied. In addition, it follows from (20) that the worm is stationary at the beginning of this stage, namely, \(I_{01} (0)=[0,L_{0} ],I_{02} (0)=[L_{0} ,L]\). Meantime, it is seen from Eq. (11) that the tension at every point is strictly monotonous until it reaches the extreme values (21) as shown in Fig. 6a. According to the continuity of the tension and the relations (8), (11), (12) and (13), the following expressions can be derived

$$\begin{aligned} T(Z,t)=\left\{ {{\begin{array}{ll} \mu _{+} Z,&{}\text{ for } Z\in [0,C_{11} (t)], \\ K\alpha _{1} (-t^{2}+2pt),&{}\quad \text{ for } Z\in [C_{11} (t),C_{12} (t)], \\ -\mu _{-} (Z-L_{0} ),&{}\quad \text{ for } Z\in [C_{12} (t),C_{13} (t)], \\ -K\alpha _{2} (-t^{2}+2pt),&{}\quad \text{ for } Z\in [C_{13} (t),C_{14} (t)], \\ \mu _{+} (Z-L),&{}\quad \text{ for } Z\in [C_{14} (t),L]. \\ \end{array} }} \right. \end{aligned}$$
(26)

where

$$\begin{aligned} \begin{array}{ll} C_{11} \left( t \right) =\frac{K\left( {2pt-t^{2}} \right) \alpha _{1} }{\mu _{+} },&{}C_{12} \left( t \right) =\frac{L_{0} \mu _{-} -2Kpt\alpha _{1} +Kt^{2}\alpha _{1} }{\mu _{-} }, \\ C_{13} \left( t \right) =\frac{\mu _{-} L_{0} +2Kpt\alpha _{2} -Kt^{2}\alpha _{2} }{\mu _{-} },&{}C_{14} \left( t \right) =\frac{L\mu _{+} -2Kpt\alpha _{2} +Kt^{2}\alpha _{2} }{\mu _{+} }. \\ \end{array} \end{aligned}$$
(27)

At the end of this stage \(t=\tau _{1} \), one obtains

$$\begin{aligned} T(Z,\tau _{1} )=\left\{ {{\begin{array}{ll} T_{\max } (Z),&{}\quad \text{ for } Z\in [0,L_{0} ), \\ T_{\min } (Z),&{}\quad \text{ for } Z\in [L_{0} ,L]. \\ \end{array} }} \right. \end{aligned}$$
(28)

Then, there only exist two points \(X_{R_{1} } \in I_{01} (t)\) and \(X_{L_{1} } \in I_{02} (t)\) in the interval [0, L] such that the worm only at these two points is still stationary, namely,

$$\begin{aligned} u(X_{R_{1} } ,\tau _{1} )=0,u(X_{L_{1} } ,\tau _{1} )=0. \end{aligned}$$
(29)

Hence, using Eq. (10), the displacement of worm at every point Z is attained as follows

$$\begin{aligned} u(Z,t)=\left\{ {{\begin{array}{ll} \frac{\left( {Kt\alpha _{1} \left( {t-2p} \right) +\mu _{+} Z} \right) ^{2}}{2K\mu _{+} },&{}\quad \text{ for } Z\in [0,C_{11} (t)), \\ 0,&{}\quad \text{ for } Z\in [C_{11} (t),C_{12} (t)], \\ -\frac{\left( {\mu _{-} \left( {L_{0} -Z} \right) +K\alpha _{1} t\left( {t-2p} \right) } \right) ^{2}}{2K\mu _{-} },&{}\quad \text{ for } Z\in [C_{12} (t),L_{0} ], \\ -\frac{\left( {\mu _{-} \left( {Z-L_{0} } \right) +K\alpha _{2} t\left( {t-2p} \right) } \right) ^{2}}{2K\mu _{-} },&{}\quad \text{ for } Z\in [L_{0} ,C_{13} (t)], \\ 0,&{}\quad \text{ for } Z\in [L_{0} ,C_{13} (t)], \\ \frac{\left( {\left( {Z-L} \right) \mu _{+} +K\alpha _{2} t\left( {2p-t} \right) } \right) ^{2}}{2K\mu _{+} },&{}\quad \text{ for } Z\in [C_{14} (t),L]. \\ \end{array} }} \right. \end{aligned}$$
(30)

Based on the continuity of the displacement at the position of mass center \(Z=L_{0} \), namely, \(\lim _{Z\rightarrow L_{0}^{+}} u(Z,t)=\lim _{Z\rightarrow L_{0}^{-}} u(Z,t)\). Here, the terms \(Z\rightarrow L_{0}^{+}\) and \(Z\rightarrow L_{0}^{-}\) denote that the position Z tends toward \(Z=L_{0} \) from positive and negative direction, respectively. After calculating this equation, one has

$$\begin{aligned} \alpha _{1} =\alpha _{2} . \end{aligned}$$
(31)

Stage 2 When \(t\in [\tau _{1} ,p]\). At the beginning of this stage for \(t=\tau _{1} \), the tension T(Zt) reaches the extreme value as seen in the relation (21) in terms of Eq. (28). But the equalities \(\dot{{\varepsilon }}_{1} (t)<0\) and \(\dot{{\varepsilon }}_{2} (t)>0\) at this time still hold until the time \(t=p\). Thus, the extreme value of the tension is fixed during this time. Meantime, the worm is still stationary at these two points \(Z=X_{R_{1} } \) and \(Z=X_{L_{1} } \), namely

$$\begin{aligned} u(X_{R_{1} } ,t)=0,u(X_{L_{1} } ,t)=0,t\in [\tau _{1} ,p]. \end{aligned}$$
(32)

According to Eqs. (10) and (32), we can obtain the expression of net displacement at every point Z in the time \(t=\tau _{1} \)

$$\begin{aligned} u(Z,t)=\left\{ {{\begin{array}{ll} \frac{\left( {Z-X_{R_{1} } } \right) \left( {\mu _{+} \left( {Z+X_{R_{1} } } \right) +2Kt\left( {t-2p} \right) \alpha _{1} } \right) }{2K},&{}\quad \text{ for } Z\in [0,X_{R_{1} } ], \\ \frac{\left( {X_{R_{1} } -Z} \right) \left( {\mu _{-} \left( {Z-2L_{0} +X_{R_{1} } } \right) +2Kt\left( {2p-t} \right) \alpha _{1} } \right) }{2K},&{}\quad \text{ for } Z\in [X_{R_{1} } ,L_{0} ], \\ \frac{\left( {X_{L_{1} } -Z} \right) \left( {\mu _{-} \left( {Z-2L_{0} +X_{L_{1} } } \right) +2Kt\left( {t-2p} \right) \alpha _{2} } \right) }{2K},&{}\quad \text{ for } Z\in [L_{0} ,X_{L_{1} } ], \\ \frac{\left( {Z-X_{L_{1} } } \right) \left( {\mu _{+} \left( {Z+X_{L_{1} } -2L} \right) +2Kt\left( {2p-t} \right) \alpha _{2} } \right) }{2K},&{}\quad \text{ for } Z\in [X_{L_{1} } ,L]. \\ \end{array} }} \right. \end{aligned}$$
(33)

It follows from that the relation (31) and the continuity of displacement around the position \(Z=L_{0} \), namely, \(\lim _{Z\rightarrow L_{0}^{+}} u(Z,t)=\lim _{Z\rightarrow L_{0}^{-}} u(Z,t)\), then one has

$$\begin{aligned} L=2L_{0} . \end{aligned}$$
(34)

Stage 3 When \(t\in [p,p+\tau _{2} ]\). During this time interval, the position of mass center of the worm body starts to move forward, the one around two ends will slightly slid backward. Namely, the equalities \(\dot{{\varepsilon }}_{1} (t)>0\) and \(\dot{{\varepsilon }}_{2} (t)<0\) are still satisfied at this time. In addition, the worm is stationary at the beginning of this time interval. Then, it follows from Eq. (11) that the values of the tension at the positional intervals \([0,L_{0} ]\) and \([L_{0} ,L]\) gradually decrease and increase, until they reach the maximum and minimum admissible values, respectively. Specifically, these relations are listed as

$$\begin{aligned} T({Z,t})=\left\{ \begin{array}{ll} -\mu _{-}Z, &{}\quad \hbox {for } Z\in [0,C_{31}(t)],\\ -K\alpha _1(t-p)^2+\mu _+Z,&{}\quad \hbox {for }Z\in [C_{31}(t),X_{R_1}],\\ -K\alpha _1(t-p)^2+\mu _{-}(Z-L_0)&{}\quad \hbox {for }Z\in [X_{R_1},C_{32}(t)],\\ \mu _+(Z-L_0),&{}\quad \hbox {for }Z\in [C_{32}(t),C_{33}(t)],\\ K\alpha _2(t-p)^2-\mu _{-}(Z-L_0),&{}\quad \hbox {for }Z\in [C_{33}(t),L_0+X_{L_1}],\\ K\alpha _2(t-p)^2-\mu _{+}(Z-L),&{}\quad \hbox {for }Z\in [L_0+X_{L_1},C_{34}(t)],\\ -\mu (Z-L),&{}\quad \hbox {for }Z\in [C_{34}(t),L], \end{array} \right. \end{aligned}$$
(35)

where

$$\begin{aligned} \begin{array}{ll} C_{31} \left( t \right) =\frac{K\left( {p-t} \right) ^{2}\alpha _{1} }{\mu _{-} +\mu _{+} },&{}C_{32} \left( t \right) =L_{0} -\frac{K\left( {p-t} \right) ^{2}\alpha _{1} }{\mu _{-} +\mu _{+} }, \\ C_{33} \left( t \right) =L_{0} +\frac{K\left( {p-t} \right) ^{2}\alpha _{2} }{\mu _{-} +\mu _{+} },&{}C_{34} \left( t \right) =L-\frac{K\left( {p-t} \right) ^{2}\alpha _{2} }{\mu _{-} +\mu _{+} }. \\ \end{array} \end{aligned}$$
(36)

At the time \(t=p+\tau _{2} \), the tension reaches the corresponding extreme value, that is

$$\begin{aligned} T(Z,p+\tau _{2} )=\left\{ {{\begin{array}{ll} T_{\min } (Z),&{}\quad \text{ for } Z\in [0,L_{0} ], \\ T_{\max } (Z),&{}\quad \text{ for } Z\in \text{[ }L_{0} ,L\text{] }. \\ \end{array} }} \right. \end{aligned}$$
(37)

Meantime, the following equations can be obtained

$$\begin{aligned} \begin{array}{l} u(X_{L_{2} } ,P+\tau _{2} )=u(X_{L_{2} } ,P),u(X_{R_{1} } ,P+\tau _{2} )=u(X_{R_{1} } ,P), \\ u(X_{L_{1} } ,P+\tau _{2} )=,u(X_{L_{1} } ,P),u(X_{R_{2} } ,P+\tau _{2} )=u(X_{R_{2} } ,P). \\ \end{array} \end{aligned}$$
(38)

By employing Eqs. (10) and (38), the displacement at this time interval can be calculated as

$$\begin{aligned} u(Z,t) = \left\{ {\begin{array}{ll} \left( {t\left( {t - 2p} \right) Z + p^{2} X_{{R_{1} }} } \right) \alpha _{1} - \frac{{Z^{2} \mu _{ - } + \mu _{ + } X_{{R_{1} }}^{2} }}{{2K}} - \frac{{K\left( {p - t} \right) ^{4} \alpha _{1}^{2} }}{{2\left( {\mu _{ - } + \mu _{ + } } \right) }}, &{}\quad {\text {for }} Z \in [0,C_{{31}} \left( t \right) ] \\ u(Z,p), &{}\quad {\text {for }} Z \in [C_{{31}} \left( t \right) ,C_{{32}} (t) ] \\ \frac{1}{2}(2\left( {t\left( { - 2p + t} \right) Z - \left( {p - t} \right) ^{2} L_{0} + p^{2} X_{{R_{1} }} } \right) \alpha _{1} + \\ \frac{{\mu _{ + } \left( {Z - L_{0} } \right) ^{2} }}{K} + \frac{{\mu _{ - } \left( {L_{0} - X_{{R_{1} }} } \right) ^{2} }}{K} + \frac{{K\left( {p - t} \right) ^{4} \alpha _{1}^{2} }}{{\mu _{ - } + \mu _{ + } }}), &{}\quad {\text {for }} Z \in [C_{{32}} (t),L_{0} ], \\ \frac{1}{2}\left( {\frac{{\mu _{ + } \left( {Z - L_{0} } \right) ^{2} }}{K} + \frac{{\mu _{ - } \left( {L_{0} - X_{{L_{1} }} } \right) ^{2} }}{K} + \frac{{K\left( {p - t} \right) ^{4} \alpha _{2}^{2} }}{{\mu _{ - } + \mu _{ + } }}} \right) + \\ \left( {\left( {2p - t} \right) tZ + \left( {p - t} \right) ^{2} L_{0} - p^{2} X_{{L_{1} }} } \right) \alpha _{2} , &{}\quad {\text {for }} Z \in [L_{0} ,C_{{33}} (t)],\\ u(Z,p), &{}\quad {\text {for }} Z \in [C_{{33}} (t),C_{{34}} (t)], \\ \frac{{\alpha _{2} \left( {2t\left( { - 2p + t} \right) \left( {L - Z} \right) \left( {\mu _{ - } + \mu _{ + } } \right) - K\left( {p - t} \right) ^{4} \alpha _{2} } \right) }}{{2(\mu _{ - } + \mu _{ + } )}} + \\ + \frac{{\left( {L - X_{{L1}} } \right) \left( {\mu _{ + } \left( { - L + X_{{L_{1} }} } \right) + 2kp^{2} \alpha _{2} } \right) - \left( {L - Z} \right) ^{2} \mu _{ - } }}{K}, &{}\quad {\text {for }} Z \in [C_{{34}} (t),L]. \\ \end{array} } \right. \end{aligned}$$
(39)

Stage 4 When \(t\in [p+\tau _{2} ,2p]\). According to the results in stage 3, it is clearly seen that the tension distributed along the worm body reaches the corresponding extreme value (21) at \(t=p+\tau _{2} \) , and keeps this value unchanged till \(t=2p\). During this time interval, the position of worm around two ends moves backward when the mass center of the body travels forward, i.e., \(\dot{{\varepsilon }}_{1} (t)>0\) and \(\dot{{\varepsilon }}_{2} (t)<0\). In addition, based on the above analysis, it is found that the points \(Z=X_{L_{2} } \) and \(Z=X_{R_{2} } \) stand still as shown in Fig. 6. Then one has

$$\begin{aligned} u(X_{L_{2} } ,t)=u(X_{L_{2} } ,p+\tau _{2} ),u(X_{R_{2} } ,t)=u(X_{R_{2} } ,p+\tau _{2} ),t\in [p+\tau _{2} ,2p]. \end{aligned}$$
(40)

Using Eqs. (10) and (40), the expressions of the displacement at every point are obtained as

$$\begin{aligned} u(Z,t)=\left\{ {{\begin{array}{ll} \frac{\mu _{-} \left( {X_{L_{2} }^{2} -Z^{2}} \right) +\mu _{+} \left( {X_{L_{2} }^{2} -X_{R_{1} }^{2} } \right) }{2K} \\ +\left( {t\left( {t-2p} \right) Z-\left( {p-t} \right) ^{2}X_{L_{2} } +p^{2}X_{R_{1} } } \right) \alpha _{1} ,&{}\quad \text{ for } Z\in [0,X_{L_{2} } ], \\ \frac{\mu _{+} \left( {Z^{2}-2ZL_{0} +2L_{0} X_{L_{2} } -X_{R_{1} }^{2} } \right) }{2K} \\ +\left( {t\left( {t-2p} \right) Z-\left( {p-t} \right) ^{2}X_{L_{2} } +p^{2}X_{R_{1} } } \right) \alpha _{1} ,&{}\quad \text{ for } Z\in [X_{L_{2} } ,L_{0} ], \\ \frac{\mu _{+} \left( {Z\left( {Z-2L_{0} } \right) +2LX_{L_{1} } -X_{L_{1} }^{2} +2\left( {L_{0} -L} \right) X_{R_{2} } } \right) }{2K} \\ +\left( {\left( {2p-t} \right) tZ-p^{2}X_{L_{1} } +\left( {p-t} \right) ^{2}X_{R_{2} } } \right) \alpha _{2} ,&{}\quad \text{ for } Z\in [L_{0} ,X_{R_{2} } ], \\ \frac{\mu _{-} \left( {2L-Z-X_{R_{2} } } \right) \left( {Z-X_{R_{2} } } \right) +\mu _{+} \left( {2L-X_{L_{1} } -X_{R_{2} } } \right) \left( {X_{L_{1} } -X_{R_{2} } } \right) }{2K} \\ +\left( {\left( {2p-t} \right) tZ-p^{2}X_{L_{1} } +\left( {p-t} \right) ^{2}X_{R_{2} } } \right) \alpha _{2} ,&{}\quad \text{ for } Z\in [X_{R_{2} } ,L]. \\ \end{array} }} \right. \end{aligned}$$
(41)

Stage 5 When \(t\in [2p,2p+\tau _{3} ]\). During this time, the worm starts to be driven forward as the position of mass center gradually moves backward, i.e., \(\dot{{\varepsilon }}_{1} (t)<0\) and \(\dot{{\varepsilon }}_{2} (t)>0\). Then it follows from Eq. (11) that the tension at the positional intervals \([0,L_{0} ]\) and \([L_{0} ,L]\) gradually increase and decrease, respectively, until they reach the corresponding maximum and minimum value as seen in Fig. 6e. Specifically, one has

$$\begin{aligned} T(Z,t)=\left\{ {{\begin{array}{ll} \mu _{+} Z,&{}\quad \text{ for } Z\in [0,C_{51} (t)], \\ K\alpha _{1} (-(t-2p)^{2}+2p(t-2p))-\mu _{-} Z,&{}\quad \text{ for } Z\in [C_{51} (t),X_{L_{2} } ], \\ K\alpha _{1} (-(t-2p)^{2}+2p(t-2p))+\mu _{+} (Z-L_{0} ),&{}\quad \text{ for } Z\in [X_{L_{2} } ,C_{52} (t)], \\ -\mu _{-} (Z-L_{0} ),&{}\quad \text{ for } Z\in [C_{52} (t),C_{53} (\tau )], \\ -K\alpha _{2} (-(t-2p)^{2}+2p(t-2p))+\mu _{+} (Z-L_{0} ),&{}\quad \text{ for } Z\in [C_{53} (t),L_{0} +X_{R_{2} } ], \\ -K\alpha _{2} (-(t-2p)^{2}+2p(t-2p))-\mu _{-} (Z-L),&{}\quad \text{ for } Z\in [L_{0} +X_{R_{2} } ,C_{54} (t)], \\ \mu _{+} (Z-L),&{}\quad \text{ for } Z\in [C_{54} (t),L], \\ \end{array} }} \right. \end{aligned}$$
(42)

where

$$\begin{aligned} \begin{array}{ll} C_{51} \left( t \right) =-\frac{K\left( {8p^{2}-6pt+t^{2}} \right) \alpha _{1} }{\mu _{-} +\mu _{+} },&{}C_{52} \left( t \right) =L_{0} +\frac{K\left( {8p^{2}-6pt+t^{2}} \right) \alpha _{1} }{\mu _{-} +\mu _{+} }, \\ C_{53} \left( t \right) =L_{0} -\frac{K\left( {8p^{2}-6pt+t^{2}} \right) \alpha _{2} }{\mu _{-} +\mu _{+} },&{}C_{54} \left( t \right) =L+\frac{K\left( {8p^{2}-6pt+t^{2}} \right) \alpha _{2} }{\mu _{-} +\mu _{+} }. \\ \end{array} \end{aligned}$$
(43)

When \(t=2p+\tau _{3} \), the tension along the worm body reaches the corresponding extreme value given by

$$\begin{aligned} T(Z,2p+\tau _{3} )=\left\{ {{\begin{array}{l} {T_{\max } (Z),0\le Z\le L_{0} ,} \\ {T_{\min } (Z),L_{0} \le Z\le L.} \\ \end{array} }} \right. \end{aligned}$$
(44)

Moreover, it can be obtained that the following equations hold during this time in Fig. 6e

$$\begin{aligned} \begin{array}{l} u(X_{L_{2} } ,2P+\tau _{3} )=u(X_{L_{2} } ,2P),u(X_{R_{1} } ,2P+\tau _{3} )=u(X_{R_{1} } ,2P), \\ u(X_{L_{1} } ,2P+\tau _{3} )=,u(X_{L_{1} } ,2P),u(X_{R_{2} } ,2P+\tau _{3} )=u(X_{R_{2} } ,2P). \\ \end{array} \end{aligned}$$
(45)

Then, the expressions of displacement of worm along its body can be obtained by using Eq. (10), namely

$$\begin{aligned} u(Z,t) = \left\{ {\begin{array}{ll} \frac{1}{2}\left( {\frac{{K\left( {8p^{2} - 6pt + t^{2} } \right) ^{2} \alpha _{1}^{2} }}{{\mu _{ - } + \mu _{ + } }} + \frac{{\mu _{ - } X_{{L_{2} }}^{2} + \mu _{ + } \left( {Z^{2} + X_{{L_{2} }}^{2} - X_{{R_{1} }}^{2} } \right) }}{K}} \right) \\ + \left( {\left( {8p^{2} - 6pt + t^{2} } \right) Z + p^{2} \left( {X_{{R_{1} }} - X_{{L_{2} }} } \right) } \right) \alpha _{1}, &{}{\text {for }} Z \in [0,C_{{51}} \left( t \right) ], \\ u(Z,2p), &{}{\text {for }} Z \in [C_{{51}} \left( t \right) ,C_{{52}} (t)] \\ \left( {8p^{2} - 6pt + t^{2} } \right) \alpha _{1} \left( {Z - L_{0} - \frac{{K\left( {8p^{2} - 6pt + t^{2} } \right) \alpha _{1} }}{{2(\mu _{ - } + \mu _{ + } )}}} \right) - \\ \frac{{\mu _{ - } \left( {Z - L_{0} } \right) ^{2} + \mu _{ + } \left( {L_{0}^{2} - 2L_{0} X_{{L_{2} }} + X_{{R_{1} }}^{2} } \right) + 2Kp^{2} \left( {X_{{L_{2} }} - X_{{R_{1} }} } \right) \alpha _{1} }}{K}, &{}{\text {for }} Z \in [C_{{52}} (t),L_{0} ], \\ \left( {8p^{2} - 6pt + t^{2} } \right) \left( {L_{0} - Z} \right) \alpha _{2} - p^{2} \left( {X_{{L_{1} }} - X_{{R_{2} }} } \right) \alpha _{2} - \frac{{K\left( {8p^{2} - 6pt + t^{2} } \right) ^{2} \alpha _{2}^{2} }}{{2\left( {\mu _{ - } + \mu _{ + } } \right) }} \\ {{ - }}\frac{{\left( {\mu _{ - } \left( {Z - L_{0} } \right) ^{2} + \mu _{ + } \left( {L_{0}^{2} - 2LX_{{L_{1} }} + X_{{L_{1} }}^{2} + 2\left( {L - L_{0} } \right) X_{{R_{2} }} } \right) } \right) }}{{2K}}, &{}{\text {for }} Z \in [ L_{0} ,C_{{53}} (t)], \\ u(Z,2p), &{}{\text {for }} Z \in [ C_{{53}} (t),C_{{54}} (t)], \\ \frac{{\mu _{ - } \left( {L - X_{{R_{2} }} } \right) ^{2} + \mu _{ + } \left( {\left( {L - Z} \right) ^{2} + 2LX_{{L_{1} }} - X_{{L_{1} }}^{2} - 2LX_{{R_{2} }} + X_{{R_{2} }}^{2} } \right) }}{{2K}}{\text { + }}\alpha _{2} p^{2} \\ \left( {X_{{R_{2} }} - X_{{L_{1} }} } \right) {\text { + }}\alpha _{2} \left( {8p^{2} - 6pt + t^{2} } \right) \left( {\left( {L - Z} \right) + \frac{{K\left( {8p^{2} - 6pt + t^{2} } \right) \alpha _{2} }}{{2(\mu _{ - } + \mu _{ + } )}}} \right) ,&{}{\text {for }} Z \in [ C_{{54}} (t)L]. \\ \end{array} } \right. \end{aligned}$$
(46)

Stage 6 When \(t\in [2p+\tau _{3} ,3p]\) Similarly, it is seen from Fig. 6f that the tension reaches the corresponding extreme value again during this time. As can be seen from Fig 5, the relations \(\dot{{\varepsilon }}_{1} (t)<0\) and \(\dot{{\varepsilon }}_{2} (t)>0\) are still satisfied at this time. In addition, the worm still stands at the points \(Z=X_{R_{1} } \) and \(Z=X_{L_{1} } \) namely,

$$\begin{aligned} u(X_{R_{1} } ,t)=u(X_{R_{1} } ,2P),u(X_{L_{1} } ,t)=u(X_{L_{1} } ,2P),t\in [2p+\tau _{3} ,3p]. \end{aligned}$$
(47)

Then it follows from (10) and (47) that the displacement of worm can be easily calculated as

Fig. 7
figure 7

Time history of the displacements of the worm extremities \(u_{1} (t)\) (red solid curve), \(u_{2} (t)\) (black solid curve) and the mass center of its body \(u_{0} (t)\) (blue solid curve) in the time interval [0, 3p] computed for the maximum distortion \(\varepsilon _{0}^\mathrm{max}=1\), a ratio of \(\mu _{+} /\mu _{-} =5/9\) and \(\mu _{+} L/k=1/2\). The body length l(t) is shown from the vertical distance between the black line and the red line. (Color figure online)

$$\begin{aligned} u(Z,t)=\left\{ {{\begin{array}{ll} \left( {Z\left( {8p^{2}-6pt+t^{2}} \right) -p^{2}X_{L_{2} } -\left( {7p^{2}-6pt+t^{2}} \right) X_{R_{1} } } \right) \alpha _{1} \\ +\frac{\mu _{+} \left( {Z^{2}+2L_{0} \left( {X_{L_{2} } -X_{R_{1} } } \right) -X_{R_{1} }^{2} } \right) }{2K},&{}\text{ for } Z\in [0,X_{R_{1} } ], \\ \left( {\left( {8p^{2}-6pt+t^{2}} \right) Z-p^{2}X_{L_{2} } -\left( {7p^{2}-6pt+t^{2}} \right) X_{R_{1} } } \right) \alpha _{1} \\ -\frac{\mu _{-} \left( {Z-X_{R_{1} } } \right) \left( {Z-2L_{0} +X_{R_{1} }} \right) +2\mu _{+} L_{0} \left( {X_{R_{1} } -X_{L_{2} } } \right) }{2K},&{}\text{ for } Z\in [X_{R_{1} } ,L_{0} ], \\ \left( {-Z\left( {8p^{2}-6pt+t^{2}} \right) +\left( {7p^{2}-6pt+t^{2}} \right) X_{L_{1} } +p^{2}X_{R_{2} } } \right) \alpha _{2} \\ -\frac{\mu _{-} \left( {Z-X_{L_{1} } } \right) \left( {Z-2L_{0} +X_{L_{1} } } \right) -2\mu _{+} \left( {L-L_{0} } \right) \left( {X_{L_{1} } -X_{R_{2} } } \right) }{2K},&{}\text{ for } Z\in [L_{0} ,X_{L_{1} } ], \\ \left( {\left( {7p^{2}-6pt+t^{2}} \right) X_{L_{1} } +p^{2}X_{R_{2} } -\left( {8p^{2}-6pt+t^{2}} \right) Z} \right) \alpha _{2} + \\ \frac{\mu _{+} \left( {Z\left( {-2L+Z} \right) +\left( {4L-2L_{0} -X_{L_{1} } } \right) X_{L_{1} } +2\left( {-L+L_{0} } \right) X_{R_{2} } } \right) }{2K},&{}\text{ for } Z\in [X_{L_{1} } ,L]. \\ \end{array} }} \right. \end{aligned}$$
(48)

So far, it is seen from the obtained results above that the expressions for the displacement of worm everywhere have been deduced during the whole time interval. According to these expressions, the time histories at two ends and the position of mass center are depicted as in Fig. 7. Meanwhile, it is found from this figure that the state of the worm at \(t=3p\) is the same as the one at \(t=p\), namely, the worm in the time interval [p, 3p] will move forward with 2p-period. After that, according to (33) and (48), the net displacement over one period can be expressed by using Eqs. (31) and (34), namely, for \(\forall Z\in [0,L]\), one has

$$\begin{aligned} \Delta u=u(Z,3p)-u(Z,p)=\left( \varepsilon _{0}^\mathrm{max}-\frac{\mu _{+} L}{2K}\right) \frac{\mu _{-} -\mu _{+} }{2(\mu _{-} +\mu _{+} )}L, \end{aligned}$$
(49)

where \(\varepsilon _{0}^\mathrm{max}=\max \nolimits _{t\in [0,3p]} \{\varepsilon _{0} (t)\}=\alpha _{1} p^{2}\). Moreover, according to the relations (33) and (48), the body length of worm can be easily derived as

$$\begin{aligned} l(t)=u(L,t)-u(0,t)=L\text{ for } t\in [0,3p] \end{aligned}$$
(50)

Therefore, it is found from (49) that the worm can achieve the forward motion only if the condition \(\varepsilon _{0}^\mathrm{max}>\frac{\mu _{+} L}{2K}\) is satisfied. This condition has advantage over the previous one obtained by Desimone et al. [18]. In addition, the worm can achieve the fixed motion by changing the position of mass center of its body on the basis of the relation (50).

5 Conclusions

In this paper, the motion actuated by traveling the position of mass center of worm body is studied by constructing a new locomotion gait in the directional substrate. According to the continuity of the tension distributed along worm body, the expressions of the tension along worm body are also deduced. Meantime, the displacements everywhere at each time point are derived by utilizing the method of piecewise analysis. Furthermore, the net displacement over one period is calculated. As a result, the condition that worm can move forward is further presented. In addition, the body length of worm is also derived. This result shows that its body length is constant in the moving process, implying that worm-like system can achieve the motion of the fixed length by using the prescribed locomotion gait. The results above enrich the moving mode of worm-like bionic system and provide a useful theoretical framework to understand the locomotion mechanism of some limbless animals and help to the design of worm-like soft robots.