Simple Degree-of-Freedom Modeling of the Random Fluctuation Arising in Human–Bicycle Balance

: In this study, we propose a new simple degree-of-freedom ﬂuctuation model that accurately reproduces the probability density functions (PDFs) of human–bicycle balance motions as simply as possible. First, we measure the time series of the roll angular displacement and velocity of human–bicycle balance motions and construct their PDFs. Next, using these PDFs as training data, we identify the model parameters by means of particle swarm optimization; in particular, we minimize the Kolmogorov–Smirnov distance between the human PDFs from the participants and the PDFs simulated by our model. The resulting PDF ﬁtnesses were over 98.7% for all participants, indicating that our simulated PDFs were in close agreement with human PDFs. Furthermore, the Kolmogorov–Smirnov statistical hypothesis testing was applied to the resulting human–bicycle ﬂuctuation model, showing that the measured time responses were much better supported by our model than the Gaussian distribution.


Introduction
Bicycles provide a useful means of short-distance transportation, and their utilization is expected to contribute to building a healthy and environmentally friendly society [1]. However, at least on Japanese roads, bicycle transportation is not always necessarily safe due to collisions with automobiles. The Japan National Police Agency reported that over 83% of bicycle accidents in Japan in the last ten years have involved automobiles [2]. To avoid such accidents, autonomous vehicle technology will play an important role; if it can predict bicycle motions, the resulting self-driving cars may reduce such accidents. For this purpose, accurate simulation models of bicycle motions are required, and they should be provided as simply as possible for the potential use of electronic control units in self-driving cars.
Bicycle motions with human riders in traffic seem to be broadly classified into two types: voluntary and involuntary. The former comprises purposeful motions such as right and left turning at a street intersection. Google [3] reported that their sensors can detect a cyclists' hand signals as an indication of an intention to make a turn or shift over. The latter comprises unconscious motions such as human fluctuated balance motions, which have already been found universally in human quiet standing [4][5][6], human stick balancing [7,8], human visuomotor tracking [9][10][11], and so on.
In this study, we propose a simple stochastic model that allows us to simulate the latter type of bicycle motion, i.e., involuntary fluctuated human-bicycle balance motions. To this end, we have conducted an experiment in which each human participant rides a bicycle on bicycle-trainer rollers, allowing it to move without rolling or yawing constraints. During this experiment, we measured the bicycle's rolling motion using a three-dimensional motion sensor attached to it. The measured time-series of the rolling motion are characterized by their probability density functions (PDFs). Next, we designed our proposed human-bicycle model as a simple pendulum mechanism controlled by our human controller model, which was successfully used in our previous study [11] to simulate random human fluctuations during a visuomotor tracking task. We then identified the model parameters based on the measured PDFs as training data, using particle swarm optimization (PSO) to minimize the Kolmogorov-Smirnov (KS) distance between the measured PDFs and those simulated by our proposed human-bicycle model. The results show that our proposed model successfully reproduces the measured PDFs with fitnesses of over 98.7%. Furthermore, we conducted a statistical hypothesis test called the KS test [12,13] on our results to check their stochastic reliability, showing that the measured time series were much better supported by our model than the Gaussian distribution.
Our stochastic human-modeling approach sharply contrasts with other studies in the fields of autonomous or unmanned bicycle-control systems [14][15][16][17][18][19][20][21][22] because their models have been deterministic and not designed to have randomly fluctuating terms. Our approach also differs from Google's study on voluntary bicycle motions, as mentioned above [3]. Although there has been another study on the stochastic modeling of bicycle fluctuated motion [23], it addressed large-scale bicycle running paths, unlike our study, which deal with small fluctuations.
The rest of the paper is structured as follows: Section 2 describes the experimental test of human-bicycle balance motions. In Section 3, our proposed stochastic model of these motions is presented. In Sections 4 and 5, we describe the method of parameter identification and the identification results are presented with the KS testing results. Section 6 concludes our study.  The experimental participants were eight healthy males in their early twenties. They were first instructed on the operation of the experimental device, the number of trials, and the duration of each trial. The experiment was performed according to the principles of the Declaration of Helsinki, and informed consent was obtained.

Experimental Setup and Procedure
In each trial, the participant rode a bicycle on trainer rollers for significantly more than 180 s at a speed of about 15 km/h. Several practice trials were performed prior to measurement. The air pressure of the tires was set to 300 kPa.
Note that, in our setup, the bicycle is constrained on the stationary trainer. This may cause our measured motion to differ from free motions on the road. Such potential discrepancy, however, did permit a three-minute safety trial without external disturbances and was minimized by using a roller-type trainer known to have fewer constraints than other types of trainers.

Experimental Data
During each trial, the time series of the measurement vector, (hereafter, (·) T denotes a transpose), was obtained by the motion sensor. Here, θ [rad] is the roll angle from the vertical line to the bicycle's vertical axis, andθ := dθ/dt [rad/s] is the corresponding angular velocity. Figure 2 schematically shows the definition of the roll angle in the front view of the bicycle. The bicycle's vertical axis was nominally determined based on the direction of the bicycle frame. The motion sensor was initially calibrated to output θ = 0 when the bicycle's vertical axis was parallel to the vertical line. Therefore, θ = 0 does not indicate the upright equilibrium of the unmanned bicycle. Nevertheless, since the resulting calibration setting was commonly maintained for all participants and trials, the obtained datasets can be compared with each other. Throughout the experiment, x(t) were stored in the computer in the following form: hum (t I−1 )}, i = 0, · · · , I − 1, s = 1, · · · , S, n = 1, · · · , N, (2) where t i := i∆t [s] is a discrete time with a sampling period of ∆t [s], I is the length of the time series, s and S are an index and the number of participants, respectively, and n and N are an index and the number of trials, respectively. For this study, we chose ∆t = 10 −2 s and I = 18,001 to obtain the physical data length (I − 1)∆t = 180 s. The number of participants was S = 8, and the number of trials undertaken by each participant was N = 5. Figure 3 shows the measured time series for (s, n) = (1, 1), i.e., for the first participant's first trial. The result clearly exhibits fluctuations specific to human balancing motions in which large-amplitude spikes intermittently arise among the moderate-amplitude fluctuation process, which has already been recognized as temporal intermittency in the field of nonlinear physics [6][7][8]. Thus, we obtained the time series for all s = 1, · · · , S and n = 1, · · · , N. As shown in the upper graph of Figure 3, the vibrational center of θ(t) is shifted from the origin, θ = 0. This is mainly because the calibrated θ = 0 does not indicate the vertical equilibrium of the bicycle, as mentioned above. We statistically evaluate these shifts by identifying them as the mean roll angles given by which is the temporal average of the sth participant's θ(t), further averaged over all of his trials.
The resulting values are listed in Table 1 with standard deviations given by Viewing the average over all participants' values, E (s) [θ] takes about 1.75 × 10 −2 , indicating that the actual equilibrium angle of the bicycle was approximately at θ ≈ 1.75 × 10 −2 rad (or 1.01 • ) in our setup. In addition, each E (s) [θ] value is slightly different due to the respective riding forms of the participants.

Construction of Measured PDFs
First, we obtain P (s,n) hum (x 1 , x 2 ), the joint PDF with respect to the components of the time series in (2) for the sth participant's nth trial, by normalizing the two-dimensional histogram of {x (s,n) (t i )} I−1 i=0 with bin width (x k − x k )/N bin (k = 1, 2). Here, N bin is the number of histogram bins and x k and x k are the upper and lower limits of x k , respectively.

Fluctuation Model of the Human-Bicycle Balance
In this section, we propose a new fluctuation model that allows us to reproduce the measured PDFs obtained above as simply as possible.

A Human-Bicycle Fluctuation Model
In view of our setup in Figure 2, we model the human-bicycle mechanics by a simple inverted pendulum about the contact point of the bicycle wheel. Based on the time series statistics in Table 1, we also assume that the roll angle θ about the equilibrium is sufficiently small; the maximal three standard deviation indicates 3 × max s SD (s) [θ] ≈ 4.88 × 10 −2 rad (or 2.80 • deg). Therefore, we model the bicycle's rolling motion by a linearized inverted pendulum of the form: where m [kg] and r [m] are the mass and length of the pendulum, respectively, g := 9.81 m/s 2 is the gravitational acceleration, T [Nm] is a torque input, andθ [rad] is the equilibrium angle. The equation of motion (6) is nondimensionalized and represented in the following state-space form: where x = (x 1 , x 2 ) T := (θ,θ) T , k := g/r, and u := T/mr 2 . Next, we specify u to simulate the human fluctuation during human-bicycle motion. As successfully demonstrated in our previous study [11], some human fluctuations can be accurately simulated by the following state-feedback mechanism: where ξ 1 (t) and ξ 2 (t) are independent white Gaussian noises with zero mean and unit variance. The first coefficient F 1 {1 + σ 1 ξ 1 (t)} represents a random proportional gain with mean F 1 and variance (F 1 σ 1 ) 2 . The second coefficient F 2 is a deterministic derivative gain. The third term σ 2 ξ 2 (t) represents an additive random perturbation.
Finally, we substitute (8) into (7), rewrite it to reduce the dependency between parameters, and propose a human-bicycle fluctuation model of the forṁ with the generalized parameter vector p = (p 1 , p 2 , p 3 , p 4 ) := (g/r + F 1 , which parameterizes the equivalent properties of human-bicycle motion. Here, p 1 and p 2 are a mean and a standard deviation of the randomly fluctuating stiffness of the human-bicycle motion, respectively, p 3 is a deterministic viscous damping, and p 4 is an additive random fluctuation strength.

Calculation of Simulated PDFs
Using givenθ and p, we obtain N samples of the stationary numerical solution of (9) as {x (n ) by means of a fourth-order Runge-Kutta-Gill method with time step ∆t = 10 −2 s, the same as the experimental sampling period. To generate these samples, N different sequences of normal pseudo-random numbers [24], {ν are used to simulate the independent white Gaussian noises ξ 1 (t) and ξ 2 (t) by where (∆t) −1/2 is the numerical factor required for integrating stochastic differential equations [25].
From the simulated time series in (11), we construct the n th sample's joint PDF P (n ) sim (x 1 , x 2 ;θ, p) using the same procedure and conditions as applied for deriving the measured PDF in Section 2.3.
We also take the average P (n ) sim (x 1 , x 2 ;θ, p) over all samples by We call (14) the simulated PDFs forθ and p, which are to be compared with the measured P (s) hum (x 1 , x 2 ).

Method of Parameter Identification
In this section, we formulate the identification problem of an unknown parameter vector p that allows the simulated P sim (x 1 , x 2 ;θ, p) to reproduce the measured P (s) hum (x 1 , x 2 ).

Parameter Identification Problem
We solve the optimization problem with the cost function Equation (16) is known as a two-dimensional Kolmogorov-Smirnov (KS) distance [12] and is used for two-dimensional goodness-of-fit testing between the empirical distribution of data and a hypothetical density law or between two distributions of separate data [12,13]. Here, F i sim (x 1 , x 2 ) and F i(s) hum (x 1 , x 2 ) (i = 1, · · · , 4) are the cumulative distribution functions (CDFs) with respect to the four quadrants about (x 1 , x 2 ) on the (x 1 , x 2 )-plane, i.e., hum (x 1 , x 2 )dx 1 dx 2 , (17) with their domains R 1 : x 2 ], respectively. The cost function (16) evaluates the CDFs' reproduction error and satisfies E(p) = 0 if P sim (x 1 , x 2 ;θ, p) = P (s) hum (x 1 , x 2 ). Hence, it also indicates the PDFs' reproduction error.

Particle Swarm Optimization (PSO)
We employ PSO [26] to solve (15). Consider a swarm of M candidate solutions, which are called particles. Each component of p i is recursively updated by where p i j (k) denotes the jth component of p i at iteration k; v i j (k) is the corresponding velocity; ω, c 1 and c 2 are system parameters of PSO; η i 1j (k) and η i 2j (k) are random numbers independently generated by [24] for each i, j, and k with a uniform distribution in [0, 1]; and pb i j (k) and gb j (k) are the jth components of the vectors pb i (k) and gb(k) ∈ R 4 , respectively. pb i (k) is the position of the particle taking the lowest cost among those at p i (0), · · · , p i (k); this is called the personal best. gb(k) is the position of the particle with the lowest cost among all particles for all iterations up to k; this is called the global best. For sufficiently large K, gb(K) is expected to be close to the optimal solution p * .

Identification Condition
In our PSO application, the number of particles was set to M = 32, and the initial particles p i (0), i = 1, · · · , M were given by random points uniformly distributed within the four-dimensional hyperrectangle The number of iterations is K = 500. We set the number of the simulated samples in (14) to N = 5, the same as the number of experimental trials par participant.
We hereafter denote by p (s) the optimized solution gb(K) obtained from the sth participant's data: . We also use the notation P (s) sim (x 1 , x 2 ) := P sim (x 1 , x 2 ;θ (s) , p (s) ) for the simulated PDFs derived from the sth participant's data. Table 2 lists the identified vector components of p (s) by PSO for all participants s = 1, · · · , 8 and the corresponding KS cost value E(p (s) ). The seventh column indicates the cost value as a PDF fitness value of the form Fitness :

Identification Results
which indicates the accuracy of our human-bicycle fluctuation model (9) in terms of the reproducibility of PDFs. The best and worst results are indicated by " ** " and " * ", respectively. The second-last and the last columns show the cost value and the corresponding fitness value, respectively, between the measured P (s) hum (x 1 , x 2 ) and the mathematical two-dimensional Gaussian PDF P (s) Gauss (x 1 , x 2 ) with the same mean vector and covariance matrix as those of the measured P (s) hum (x 1 , x 2 ). Table 2. Identified p (s) = (p 1 , p 2 , p 3 , p 4 ) and its cost value for the sth participant. " ** " denotes the best result and " * ", the worst. The last two columns show the corresponding Gaussian results.

Our Proposed Fitting
Gaussian Fitting The results clearly show that our proposed model (9) successfully achieved over 98.7% PDF fitness, even in the worst case (s = 5). This implies that it provides much better fitness than conventional Gaussian models.
Next, the left column of Figure 5 shows the difference of our simulated P (s) sim (x 1 , x 2 ) from the measured P (s) hum (x 1 , x 2 ), and the right column shows that for the Gaussian PDF P  Table 2, our simulated PDFs agree well with the measured PDFs, compared to the Gaussian PDFs. As the shapes of Gaussian PDFs are symmetric by definition, the right column's results imply that our measured PDFs have asymmetric shapes, as indicated by the deep-colored peaks and troughs.

As already indicated by the fitness values in
Therefore, our proposed model properly reproduced such asymmetric shapes, which were barely reproduced by the Gaussian distribution.

KS Test
Up to this point, we have found that our simple model (9) provides high reproducibility of the PDF shapes of the human-bicycle fluctuation. However, this does not directly support the stochastic reliability of our model. Therefore, in this section, we conduct a statistical-hypothesis test called the KS test [12,13] on our results to check their stochastic reliability.
As described in [12], the statistic of the one-sample KS test is provided by where E is the KS distance already given in (16), and n is the number of samples. On the other hand, the two-sample KS test employs the following statistic: Z(n 1 , n 2 , E) = n 1 n 2 n 1 + n 2 where n 1 and n 2 are the numbers of two independent samples. Under the null hypothesis (the sample follows a given distribution or the two samples follow the same distribution) and for large n (or n 1 and n 2 ), the random variable Z follows the following CDF [12,13]: where the lowercase z denotes a value of Z. The value of F(z) is called the p-value of the observed z. If this p-value is smaller than a pre-defined α called a significance level, the null hypothesis is rejected.
In Figure 6, the solid curve shows F(z). The small circles plot the p-values between P (s) hum and P (s) sim at z = Z(n 1 , n 2 , E) using E = E(p (s) ) listed in Table 2, the measured data length n 1 = I × N = 18,001 × 5, and the simulated n 2 = I × N = n 1 . Under the significance level α = 0.01, the null hypothesis is rejected for s = 1, 5, and 8; that is to say that three of the eight measurements cannot be said to follow our simulated distributions. On the other hand, the cross marks show the results between P  Table 2 and n = n 1 . In this Gaussian case, the null hypothesis is rejected for all s; i.e., no measurements can be said to follow these Gaussian distributions.
Given the above, we conclude in terms of statistical hypothesis testing that our simple model (9) can simulate the time series of human-bicycle fluctuations much better than the Gaussian distribution. Note that our proposed model can separately fit the measurements of individual participants; it does not provide a general description of human-bicycle fluctuation. Conversely, it provides a means of mechanical parameterization of individual difference. The obtained parameter vector p is useful for comparing individuals and seeing how they differ, in a mechanical manner.

Conclusions
In this study, we have constructed a simple degree-of-freedom human-bicycle fluctuation model that accurately reproduces the PDFs of experimentally measured human-bicycle balance motions.
First, we measured the time series of the roll angular displacement and the velocity of the human-bicycle balance motions and constructed their PDFs. Using these PDFs as the training data, we identified the model parameters by PSO, minimizing the KS distance between the measured PDF from the participant and the simulated PDF from our model. The resulting PDF fitnesses were over 98.7%, indicating that the simulated PDFs were in close agreement with the measured ones.
Next, we applied the KS statistical hypothesis test to our results, showing that our model simulated the time series of human-bicycle fluctuation much better than the Gaussian distribution.
The above result leads to the conclusion that our proposed model can provide an accurate single-degree-of-freedom model of human-bicycle fluctuations.
In future work, using our model parameters, we plan to compare various cyclists of different ages and genders who ride different types of bicycles in different environments. We also plan to develop a multi-degree-of-freedom fluctuation model of human-bicycle balance motions, making it possible to simulate fluctuating bicycle running paths based on physically identified human-bicycle parameters.
Funding: This work was funded by JSPS KAKENHI Grant Numbers JP18H01391 and JP17H06552.