Suppose that D is a scrambled set inside A . Define the set The set ˜ D is uncountable since the same is true for D . Moreover, the intersection of ˜ D and ˜ R is empty since the intersection of D and R is empty. Because each couple of different functions inside D × D is proximal, Lemma 4 . 1 implies the same feature for each couple of different functions inside ˜ D × ˜ D . On the other hand, since each couple of different functions ( x ( t ) , x ( t )) ∈ D × D is frequently ( ϵ$_{0}$, Δ) − separated for some positive numbers ϵ$_{0}$ and Δ , Lemma 4 . 2 implies that each couple of different functions ( y ( t ) , y ( t )) ∈ ˜ D × ˜ D is frequently ( ϵ$_{1}$, Δ) − separated for some positive numbers ϵ$_{1}$ and Δ . Additionally, the frequent separation feature holds also for each pair inside ˜ D × ˜ R . Therefore, the set ˜ D is a scrambled set inside B . Consequently, B is a Li-Yorke chaotic set in accordance with Definition 4.1. □ Using the technique of the proof of Theorem 4.1, one can confirm that if the function G ( t, y ) , which is used in the right hand side of system (1 . 1) , is quasi-periodic (periodic) in t uniformly for y ∈ R $^{n}$, then under the conditions of Theorem 4.1, the set B is chaotic in the sense of Li-Yorke with infinitely many quasi-periodic (periodic) motions provided that the same is true for A . In the following section, the theoretical results of Section 4 will be supported by simulations. We will show how Theorem 4.1 can be utilized to obtain a Li-Yorke chaotic Duffing oscillator with infinitely many almost periodic motions. In order to construct the Li-Yorke chaotic set A , we will take into account the bounded solutions of a Duffing oscillator perturbed with a relay function whose switching moments are changing chaotically. Let us consider the forced Duffing oscillator where ν ( t, θ$_{0}$ ) is the relay function defined as 5 An Example x ′′ + x ′ + 11 2 x + 0 . 0003 x 3 = sin(2 πt ) + ν ( t, θ$_{0}$ ) , (5.8) ν ( t, θ$_{0}$ ) =     3 . 6 , if θ$_{2}$$_{i}$ < t ≤ θ$_{2}$$_{i}$$_{+1}$, 1 . 3 , if θ$_{2}$$_{i}$ − 1 < t ≤ θ$_{2}$$_{i}$. (5.9) 9 ˜ D = { φ$_{x}$$_{(}$$_{t}$$_{)}$ ( t ) | x ( t ) ∈ D } .