# Presentation of software for movies of vibrating strings with obstacles

Henri Cabannes

<figure><img src="image_1.png" /></figure>

## To cite this version:

Henri Cabannes. Presentation of software for movies of vibrating strings with obstacles. Applied Mathematics Letters, 1997, 10 (5), pp.79-84. 10.1016/S0893-9659(97)00087-6. hal-01527085

HAL Id: hal-01527085

https://hal.science/hal-01527085

Submitted on 23 May 2017

HAL is a multi-disciplinary open access
archive for the deposit and dissemination of sci-
entific research documents, whether they are pub-
lished or not. The documents may come from
teaching and research institutions in France or
abroad, or from public or private research centers.

L'archive ouverte pluridisciplinaire HAL, est
destinée au dépôt et à la diffusion de documents
scientifiques de niveau recherche, publiés ou non,
émanant des établissements d'enseignement et de
recherche français ou étrangers, des laboratoires
publics ou privés.

<figure><img src="image_2.png" /></figure>

Distributed under a Creative Commons Attribution 4.0 International License
# Presentation of Software for Movies of Vibrating Strings with Obstacles

H. CABANNES

Université Pierre et Marie Curie

Laboratoire de Modélisation en Mécanique, associé au CNRS

4, place Jussieu, 75252 Paris Cedex 05, France

**Abstract**—We present software for computing motions of strings vibrating against fixed obstacles. The motions are two-dimensional; the equations of motions are linear during the free oscillation phases and nonlinear during the contacts. The motions can be observed on Internet in http://www.lmm.jussieu.fr/cabannes.html

**Keywords**—Vibrating strings, Obstacles, Vibration with obstacles, Unilateral constraints.

## 1. INTRODUCTION

We present four software programs, which compute motions of a string vibrating against diverse two-dimensional obstacles. The strings are always initially at rest. We consider, in an orthonormed reference system Oxu, a vibrating string with fixed extremities at points ($x = \pm 1/2$, $u = 0$); the shape of the string at time $t$ is $u(x, t)$ and the programs compute that function starting from a given initial position. For the four different cases considered above, the program draws the line corresponding to the position at time $t$, then erases the line and draws the new line corresponding to the position at time $t + \Delta t$, and continues. When the program is compiled and working on a fast microcomputer (IBM 486, 66 MHz), the results appearing on the screen are movies. I will present the movies.

In each case, we recall the formulas, which determine the motion, and we give references of papers where those formulas are established.

## 2. STRING VIBRATING AGAINST A FIXED POINT-MASS OBSTACLE

The fixed obstacle is located at point $x = 0$, $u = -h$, $0 \le h < 1$. The string is initially at rest in the position $u(x, 0) = u_0(x) \ge -h$. The function $u_0(x)$ is an even function, and $u_0(0) = 1$. One introduces the function $K(y) = \{|y| - [|y| - 1/2]|^2$, and $\Phi(y)$ defined by the relation $u_0(y) = 1 - 2|y + \Phi(y)|$, or for $-(1/2) \le y \le (1/2)$, by the relation $y + \Phi(y) = (1/2)\{1 - u_0(y)\} \operatorname{sgn}(y)$. $|[y]|$ denotes the highest integer smaller than the absolute value of variable $y$; $\operatorname{sgn}(y)$ denotes the sign of variable $y$. The function $\Phi$ is an odd function, periodic with period 1, and possesses a derivative greater or equal to $-1$. Then one introduces the
<figure><img src="image_3.png" /><figcaption>Figure 1. $h = 1/3$.</figcaption></figure>

<figure><img src="image_4.png" /><figcaption>Figure 2. $h = 1/3$.</figcaption></figure>

notations $X(x,t) = x + \{\Phi(x+t) + \Phi(x-t)\}/2$, $T(x,t) = t + \{\Phi(x+t) - \Phi(x-t)\}/2$. Also, the function $u(x,t)$ which represents the motion of the string in the presence of the point-mass obstacle is given [1] by formula (1), where $K_1$ is expressed from functions $u_0$, $K$, $\Phi$, $X$, and $T$.

$$u(x,t) = \frac{1+h}{3-h}\{1-2|X|\} + \frac{3-h}{2}K_1, \qquad (1)$$ $$K_1 = K\left(2\frac{X+T}{3-h}\right) + K\left(2\frac{X-T}{3-h}\right) - K\left\{\frac{2(X+T)+1-\lambda}{3-h}\right\} - K\left\{\frac{2(X-T)+1-\lambda}{3-h}\right\}.$$

The parameter $\lambda$ is equal to $h$ if $0 \le 4x \le 1+h$, and equal to $3$ if $1+h \le 4x \le 2$. The motion is always an almost-periodic function of time, periodic when $h$ is rational.

### 3. STRING VIBRATING AGAINST A STRAIGHT FIXED OBSTACLE

The fixed obstacle is located on the straight line $u = -h$, $0 \le h \le 1$. The string is initially at rest in the position $u(x,0) = u_0(x) \ge -h$. In the interval $-(1/2) \le x \le (1/2)$, the function $u_0(x)$ is “unimodal”, which means that the derivative $(du_0/dx)$ is positive or zero for $-(1/2) \le x \le a < (1/2)$, and negative or zero for $-(1/2) < a \le x \le (1/2)$; one has $u_0(a) = 1$. We introduce functions $K(y)$ and $F(y)$, also defined as $K(y) = \{y-(1/2)\}^2$ for $0 \le y \le 1$ and $K(y+1) = K(y)$, $F(y) = (1/2)\{1-u_0(y)\} \operatorname{sgn}(y-a)$. The function $K(y)$ and the function $K_1$, which appear in formulas (2a) and (2b) are different from functions denoted by same letters in former section.

The function $u(x,t)$ which represents the motion of the string in the presence of the straight line obstacle is given by formula (2a) or formula (2b) [2]. Formula (2a) concerns points of the string
<figure><img src="image_5.png" /><figcaption>Figure 3. $h = 2/5$.</figcaption></figure>

<figure><img src="image_6.png" /><figcaption>Figure 4. $h = 1/3$.</figcaption></figure>

which encounter obstacles, that means points which satisfy the condition $|F(x+t) + F(x-t)| \le 1-h$. Formula (2b) concerns points of the string which do not encounter obstacles, that means which satisfy the condition $1-h \le |F(x+t) + F(x-t)| \le 1$.

$$ 
\begin{aligned}
u(x,t) &= \frac{1-h}{2} \frac{\{F(x+t) + F(x-t)\}^2}{2(1+h)} + (1+h)K_1, \\
K_1 &= K \left\{ \frac{F(x+t)}{1+h} \right\} + K \left\{ \frac{F(x-t)}{1+h} \right\} - 2K \left\{ \frac{F(x+t) - F(x-t)}{2(1+h)} + \frac{1}{2} \right\},
\end{aligned} 
\quad (2a) 
$$
<figure><img src="image_7.png" /><figcaption>Figure 5. Rebound of the string.</figcaption></figure>

$$ 
\begin{aligned}
u(x,t) &= \frac{1-h}{1+h} \{1 - |F(x+t) + F(x-t)|\} + (1+h) K_2, \\
K_2 &= K \left\{ \frac{F(x+t)}{1+h} \right\} + K \left\{ \frac{F(x-t)}{1+h} \right\} - K \left\{ \frac{1-\epsilon F(x+t)}{1+h} \right\} + K \left\{ \frac{1-\epsilon F(x-t)}{1+h} \right\}.
\end{aligned} 
\quad (2b) $$

The motion of the string is still an almost-periodic function of time [3], periodic when $h$ is rational.

## 4. VIBRATING STRING, CURVILINEAR OBSTACLE: REBOUND

In the case of a curvilinear fixed obstacle, one cannot represent the motion of the string by explicit formulas, similar to formulas (1), (2a), or (2b) given in two former sections. We prove nevertheless that on the concave part of obstacles, the string always rebounds, while on the convex part, the string generally rebounds, but can wrap for exceptional initial conditions [4].

When the fixed obstacle $u = \varphi(x)$ is a sine curve $\varphi(x) = \lambda \sin(2\pi nx)$, $n$ being an integer, it is possible in some cases to obtain explicit formulas for the function $u(x,t)$ representing the motion of the string. We have computed [5] detailed results for $n = 1$, the string being initially at rest in the position $u(x,0) = u_0(x) = \cos(\pi x)$. Before the first contact, the motion of the string is the free oscillation $u(x,t) = w(x,t) = \cos(\pi x) \cos(\pi t)$. The time of first contact is $t = \tau(x) = (1/\pi) \operatorname{Arccos}\{2\lambda \cos(\pi x)\}$.

For $|2\lambda| \le 1$, this first contact corresponds to a rebound and, after this first rebound, the motion of the string is defined by function

$$ 
\begin{aligned}
u(x,t) &= w(x,t) - \frac{1-4\lambda^2}{2\lambda} G(x,t), \\
G(x,t) &= \pi x - \operatorname{Arctan} \frac{(1+4\lambda^2) \sin(\pi x) - 4\lambda \cos(\pi t)}{(1-4\lambda^2) \cos(\pi x)}.
\end{aligned} 
\quad (3) $$

For $|2\lambda| \le (1/3)$, the time of second contact is $t = 2 - \tau(x)$; this second contact still corresponds to a rebound and, after that second rebound, the motion of the string is again the free oscillation $u(x,t) = w(x,t) = \cos(\pi x) \cos(\pi t)$, so that the motion is periodic; the period is 2.
<figure><img src="image_8.png" /><figcaption>Figure 6. Wrapping of the string.</figcaption></figure>

# 5. VIBRATING STRING, CURVILINEAR OBSTACLE: WRAPPING

Considering the same obstacle $u = \varphi(x) = \lambda \sin(2\pi x)$ and the string always at rest in the position $u(x, 0) = u_0(x) = \cos(\pi x)$, one obtains for $\lambda = -(1/2)$, the wrapping of the string on the convex part of the obstacle and rebounds on the concave part, then the unwrapping on the convex part; unfortunately, it is not possible, after the end of unwrapping, to obtain explicit formulas for the function $u(x, t)$.

If one keeps the same initial conditions, but considers the new obstacle $u = \varphi(x) = (1/3) \cos(3\pi x)$, the motion of the string is a periodic motion, with period $T = (4/3)$, with successive wrapping and unwrapping of the string on the convex part of the obstacle.

# 6. CONCLUSION

The study of motions of vibrating strings is an old problem. The study of free oscillations is a linear problem, and the formulas corresponding to that problem were written by Fourier in 1807. The case of oscillations in the presence of obstacles was considered for the first time by Amerio in 1975 [6]; one has a nonlinear problem, the nonlinearity of which appears during the contacts of the string with the obstacle. In cases of a string initially at rest, it has been possible to obtain explicit formulas (1), (2a), and (2b), which are generalisation of Fourier's formulas, but are, of course, much more complex. For the cases studied in Sections 1 and 2, the consequence of the presence of obstacles is that the periodicity of motions encountered in the free oscillations disappears; but the corresponding motions are almost-periodic. Furthermore, solutions obtained in those two sections are global solutions in time. The study of cases corresponding to strings which are not initially at rest remains an open problem.

The very fast increase of the speed of the microcomputers allows us now to represent, from the explicit formulas, the motions of vibrating strings in the presence of obstacles like movies.
REFERENCES

1. H. Cabannes, Motion of a string vibrating against a fixed point-mass obstacle, C.R. Acad. Sc. Paris, Série II **298**, 613-616, (1984).

2. H. Cabannes, Motion of a string in the presence of a straight rectilinear obstacle, C.R. Acad. Sc. Paris, Série II **295**, 637-640, (1982).

3. A. Haraux and H. Cabannes, Almost periodic motion of a string vibrating against a straight fixed obstacle, *Nonlinear Analysis, Theory, Methods & Applications* **7**, 129-141, (1983).

4. H. Cabannes, Cordes vibrantes avec obstacles, *Acustica* **55**, 14-20, (1984).

5. H. Cabannes, Motion of a vibrating string in the presence of a convex obstacle: A free boundary problem, C.R. Acad. Sc. Paris, Série II **301**, 125-129, (1985).

6. L. Amerio and G. Prouse, Study of the motion of a string vibrating against an obstacle, *Rendiconti di Matematica, Serie VI* **8**, 563-584, (1975).

7. H. Cabannes, Periodic motions of a string vibrating against a fixed point-mass obstacle, *Mathematical Methods in Applied Sciences* **6**, 55-67, (1984).

8. H. Cabannes and C. Citrini, Editors, Vibrations with unilateral constraints, In *Proceedings of the Euromech Colloquium 209*, Tecnoprint, Via del Legatore 3, Bologna, Italy, (1986).