Predicting the bladder urinary volume with a reabsorbed primitive urine model

With the rapid aging of the population, urination management is one of the challenges experienced in nursing homes. Although constrained devices, such as ultrasonic sensors, have been used for urination management, and they can sequentially measure urinary volume in the bladder, unconstrained methods to obtain urinary volume are needed. To accomplish such goals, a mathematical model is required that considers the nature of the bladder, especially reabsorption of the primitive urine. In this paper, we propose a model based on the primary delay system with five parameters, which are determined based on the absorption spectrum of urine that is obtained immediately after urination, through regression analysis. In the regression analysis, the values of the five parameters and the absorption spectrum of urine are objective and explanatory variables, respectively, and the partial regression coefficients are determined through a genetic algorithm. When the values of the five parameters are estimated using the absorption spectrum of urine immediately after urination, we can predict the next time series of the urinary volume in the bladder based on the model. Finally, the predicted urinary volume is corrected using a multitask Gaussian process and the final predicted urinary volume is obtained. We performed a series of experiments to evaluate the proposed method and calculated the error rate between the actual urinary volume and the urinary volume predicted using the proposed method at the time of urination. The mean error rate of the proposed method is 13.32%.


Introduction
With the rapid aging of the population, urination management is becoming a serious problem in nursing homes. Most caregivers help residents urinate by using a diaper or a catheter. Residents do not need help from caregivers before urinating while wearing a diaper. However, the caregivers need to change the diaper after a resident experiences urinary incontinence (UI); the residents remain insanitary until they are changed. In terms of using a catheter, germs may be generated from the tube, which is placed in the drain tube. As a result, both devices are at risk of a urinary tract infection (UTI) due to poor hygiene. UTIs are a common type of bacterial infection, and catheter-associated UTIs account for more than 1 million cases in hospitals and nursing homes [1][2][3]. Studies have estimated the occurrence of 150 million UTIs yearly on a global scale; these result in more than 6 billion dollars in direct care expenditures [4]. In particular, the treatment of such infections requires several doctor visits and is a significant financial burden [5]. Therefore, several smart diaper systems that can detect the diaper's moisture and raise an alarm to alert the caregiver(s) to change the diaper have been developed [6][7][8]. These smart diaper systems can help caregivers change the soiled diaper quickly, and improve the residents' mental health by preventing UI. The use of diapers and catheters requires time and labour of the caregivers, and thus the shortage of caregivers is a serious problem in developed countries, as the caregivers have low wages and poor working environments in clinical situations [9][10][11]. Hence, a system for predicting the next urination time is needed to help the caregivers bring the residents to the toilet before they experience UI. To predict the appropriate time when the residents need to go to the toilet, the volume of the urine in the bladder must be monitored. Various methods have been proposed for the bladder transition measurement based on the use of a pressure sensor [12][13][14][15][16][17][18][19], near-infrared spectroscopy (NIRS) [20], and ultrasonic sensors [21][22][23][24][25]. Although ultrasonic sensors enable caregivers to take residents to the toilet at appropriate times, they are not useful for creating care plans at nursing homes because they cannot inform the caregivers when the next urination will occur. To create care plans in advance, caregivers must know the time of urination of a resident. Furthermore, the daily continuous measurement of the urinary volume in the bladder stresses the residents and restricts their activities.
To facilitate the prevention of UTI and lighten the burden on the caregivers, this study proposes a method for predicting the urinary volume in the bladder without attaching a sensor to the body. The proposed method uses a model that has been employed in our previous study [26]; the model demonstrates how urine accumulates in the bladder. The model comprises three parameters: the time (T r ) when urine starts to accumulate after urination, the amount of urine (K) that can accumulate in the bladder, and the time constant (τ ) of the urinary accumulation. If the values of the three parameters can be determined immediately after urination, the urinary volume accumulated in the bladder can be predicted. In our previous study, to determine the values of the three parameters, we used the absorption spectrum of the urine obtained immediately after urination as inputs for the trained model to estimate the values of the three parameters. The true values of the three parameters can be calculated using an interior point method for the output signals of the ultrasonic sensor. Therefore, by learning a dataset of the absorption spectrum of the urine using a neural network, we obtained the trained model. When the absorption spectrum of the urine is input into the trained model, we can obtain the values of the three parameters and predict the urinary volume. Finally, we corrected the predicted urinary volume by using a multitask Gaussian process (MGP).
In this study, we expanded the previously proposed model to design a new model that considers the reabsorption of primitive urine. The prediction phase was divided into two steps to predict the urinary volume in the bladder more accurately. First, we predicted the urinary volume in the bladder based on the absorption spectrum of the urine obtained immediately after urination by using the new model. In the second step, we corrected the predicted urinary volume by using the MGP. The proposed method does not require the attachment of sensors to the skin.

Reabsorbed primitive urine model
During the reabsorption, some primitive urine is reabsorbed and the rest flows into the bladder. However, the previous model ignored the effect of urine entering the bladder during the process of reabsorption of the primitive urine. In this study, we propose a mathematical model to describe the transition of urine accumulation in the bladder during and after reabsorption. The new model with five parameters was used to predict the accumulated urinary volume in the bladder.
where T r is the time until the urine begins to accumulate in the bladder; τ 1 and τ 2 are the time constants, K 1 is the upper limit of the amount of urine that can be accumulated before the reabsorption, and K 2 is the amount of urine that can be stored in the bladder. Therefore, the amount of urine in the bladder can be predicted by determining the values of the parameters in Equation (1): T r , τ 1 , τ 2 , K 1 , and K 2 . Moreover, this model further generalizes our previous model, and functions the same as our previous model, especially when K 1 = 0.

Signal-processing flow chart for predicting the urinary volume in the bladder
By determining the values of parameters T r , τ 1 , τ 2 , K 1 , and K 2 immediately after urination, the amount of urine that accumulates in the bladder at a given time can be predicted using Equation (1). By using the proposed method, we can determine the appropriate values of these parameters by using the absorption spectrum of the urine that is obtained immediately after urination. Figure 1 shows the overall flow of the proposed method, which consists of two phases: the training and prediction phases.

Training phase
In this phase, the regression equations are derived to determine the values of the five aforementioned parameters: T r , τ 1 , τ 2 , K 1 , and K 2 . We used the absorption spectrum of urine that was obtained immediately after urination as inputs for the regression equations to obtain the values of the five parameters as the outputs. The signal-processing flow chart for the training phase consists of three stages, namely absorption spectrometry, derivation of regression equations, and the building of an observation matrix, as shown in Figure 1, in which the discrete time is denoted by k.

Absorption spectrometry stage.
In this stage, the urine sampled during the urination and pure water were analysed to consider the difference in the degree of the light absorption; hence, their absorption spectra were determined. The determined absorption spectra of the urine and water are expressed as S u (λ) and S w (λ), respectively, where λ denotes the wavelength of light. As the absorption spectrum of urine is affected by the light conditions of the measurement environment, we normalized urine spectrum S u (λ) with respect to that of water, S w (λ), and we obtained the normalized spectrum, S(λ), as follows: Spectrum S(λ) is used as an input to train the model, that is, it is an explanatory variable, whereas the true values of parameters T r , τ 1 , τ 2 , K 1 , and K 2 are used as the objective variables. Therefore, by learning a dataset of spectrum S(λ), we obtained the regression equations to estimate the values of parameters T r , τ 1 , τ 2 , K 1 , and K 2 in the building regression equations stage.

Building regression equations stage.
After building the regression equations, we used genetic algorithms (GAs) to determine the partial regression coefficients β ij . In addition, we used RMSE to evaluate how well the urinary volume, x u (k), measured using the ultrasonic sensor, and predicted urinary volume, x(k), fit (the goodness-of-fit) in the GA.
where T u is the time elapsed since the last urination and is the urination interval, which is computed based on the output of the ultrasonic sensor. As a result, we do not need to compute the true values of parameters T r , τ 1 , τ 2 , K 1 , and K 2 because the partial regression coefficients, β ij , are determined by minimizing the RMSE as much as possible. Figure 2 shows the signal-processing flow chart for determining the solution in the GA. By determining the partial regression coefficients, β ij , through the GA, we can obtain the regression equation of each parameter for the building regression equation stage.

Building an observation matrix.
In this study, to update the predicted urinary volume, x(k), we applied an MGP that uses a self-measuring similarity [27]. In this stage, we developed an observation matrix for the MGP beforehand. The matrix was constructed using the time series data, x u (k), for the urinary volume measured using the ultrasonic sensor. By assuming that we obtained n data of the urinary volume through the ultrasonic sensor, we created the observation matrix from the first to n-th row based on n data. Here, the number of rows represents the time series data for the urinary volume and the columns represent the urination interval. As the urination interval depends on the time series data, we adjusted the number of columns. To ensure the same length as the time series data with the longest urination interval, i.e. the highest number of columns, maxT, we assumed that the last value of each row is the value when the urination continues to reach maxT. With this procedure, observation matrix Z is created.

Prediction phase
The signal-processing flow chart for the prediction phase consists of four stages, as shown in Figure 1: the absorption spectrometry, estimation parameters, prediction, and correction. Spectrum S(λ) in the absorption spectrometry stage is obtained in the same manner as in the training phase. During the parameter estimation stage, by inputting a different spectrum S(λ) into the regression equations, the values of the parameters T r , τ 1 , τ 2 , K 1 , and K 2 can be estimated. The estimated values of the parameters are expressed asT r ,τ 1 ,τ 2 ,K 1 , andK 2 , respectively. By substitutingT r ,τ 1 ,τ 2 ,K 1 , and K 2 in Equation (1), we can predict the urinary volume x(k) in the prediction stage.
Finally, to accurately predict the urinary volume in the bladder, we corrected the predicted urinary volume, x(k), for the MGP and obtained the final predicted urinary volume,x(k), in the correction stage. The predicted urinary volume, x(k), was corrected using the mean of the Bayesian predictive distribution proposed in [27], which is based on self-measuring similarity. Therefore, we calculated the self-measuring similarity between the predicted urinary volume, x(k), and observation matrix Z built in the training phase using the positive definite kernel. This is how we could obtain the final predicted urinary volume,x(k).

Outline of the experiments
We performed a series of experiments to evaluate the validity of the proposed method and calculated the error rate between the actual urinary volume and the urinary volume that was predicted by the proposed model at the time of urination. Here, the actual volume of urine was measured using a measuring cup.

Experiment setting
In our experiment, we used an ultrasonic sensor (Lilium Otsuka Co., Ltd.: Lilium α-200) to obtain the discrete time series data for the urinary volume in the bladder. This sensor is often used in Japanese nursing homes and hospitals, and it can measure the urinary volume after correctly positioning the probe. The sampling interval was 60 s and the measurement accuracy was ±15%. To obtain the absorption spectra of urine, S u (λ), and water S w (λ), we used a hyperspectral camera (Resonon Inc.: PikaXC2). This camera can capture images for wavelengths that range between 398.67 and 1016.78 nm for every 1.34 nm wavelength. The measurement with the hyperspectral camera was performed in a closed space to prevent external light from entering. Figure 3 shows the schematic of the experimental system, and Figure 4 illustrates the actual experimental system. A halogen light (Caster: CHP-500-0.3), which has a wide wavelength and does not affect the absorption spectrum, was used to illuminate the sampled urine and water in the closed space. As the object can be captured more accurately when it has a plane surface, the collected urine sample and water were injected into transparent cells (BRAND GMBH + CO KG: disposable cuvettes 7590 05) with a volume of 2.5 mL, which were placed next to each other at a distance of 0.21 m from the camera. The absorption spectrum could not be correctly measured for urine because the light was too intense when using the halogen light. Therefore, a piece of frosted glass was placed between the cells and halogen light to disperse the light. The  distance between the cell and frosted glass, and the distance between the frosted glass and halogen light were 0.07 and 0.04 m, respectively. Under these conditions, we could capture the urine samples and water images in the closed space while preventing external light as much as possible. In the images, every pixel in the captured image area has a spectral for each wavelength. Therefore, in this experiment, the spectral data for each wavelength of urine (S u (λ)) and water (S w (λ)) were calculated as the averages of the spectra of each image area for each wavelength. Figure 5 shows the experimental procedures used to obtain the data. By attaching the probe of the ultrasonic sensor to the skin above the bladder, the urinary volume of the participants can be measured. During the measurement, the participants maintained a resting state to prevent the probe from shifting. The participants were free to go to the toilet at any time. When urinating, a sample of urine was obtained and the corresponding time was recorded. Absorption spectrum S(λ) was calculated using the absorption analysis of the sampled urination. In addition, the urinary volume, which is expressed as X true , was measured using a measuring cup, and it was considered to be the actual urinary volume. After returning from the toilet, the participants were required to drink 300 mL of water and rest again. These steps were repeated for an arbitrary number of times. Here, the dataset consisted of urination interval T u , spectrum S(λ), the values of T r , τ 1 , τ 2 , Figure 5. Experimental procedure to obtain the data. K 1 , and K 2 , actual urinary volume X true , and the urinary volume that was measured using the ultrasonic sensor x u (k).

Experimental procedure to obtain data
In this experiment, we obtained 50 datasets from 3 males in their 20s. All experiments were performed with the approval of the Life Science Committee of Aoyama Gakuin University (permission no. M15-17). Consent was obtained from each participant.

Setting of the GA
In this study, we used the GA to determine the partial regression coefficients β ij when we built the regression equations to estimate the values of the parameters T r , τ 1 , τ 2 , K 1 , and K 2 . Firstly, we selected the nine wavelengths by using an auto-encoder for the acquired spectrum. Therefore, to build the regression equations for the parameters T r , τ 1 , τ 2 , K 1 , and K 2 , we determined 10 of these partial regression coefficients, which included an intercept for each. In other words, we had to compute a total of (50 = 10 × 5) partial regression coefficients for β ij . The solution in the GA consists of 50 partial regression coefficients for β ij . There are 150 generations and 10 individuals in the GA. Then, we used the RMSE calculated by Equation (3) as the goodness-of-fit in the GA. Elitism selection was also used as the selection. The genes for the lowest rated individuals were replaced by the most highly rated genes through elitism selection. A single-point crossover was used as the crossover. By using the single-point crossover, 5 pairs of individuals were created from 10 individuals, and the genes of the parents that were crossed at a single cleavage site were randomly selected. In the mutation, we picked an individual at random and mutated a random gene to a random value.

Evaluation method
In this experiment, we used 40 of the 50 datasets to create the regression equations, and a hold-out validation was performed. The remaining datasets were used to predict the urinary volume,x(k). We calculated error rate E forx(k) by using the actual volume of the urine, .., and predicted value x(T u ) for urination time T u .
In addition, we calculated error rate E u of the ultrasonic sensor that corresponds to each E to compare the accuracies of the proposed method and ultrasonic sensor. Figure 6 shows five measured datasets and the results of the predictions that are based on the proposed method. The solid lines represent urinary volumex(k) for the proposed method. The dotted lines represent urinary volume x u (k) that is measured using the ultrasonic sensor. In addition, the asterisk marks show the actual urinary volume, X true . Here, the horizontal and vertical axes show the urination interval, T u , and the urinary volume in the bladder, respectively. The actual urinary volume, X true , does not overlap the value of x u (k) obtained through the ultrasonic sensor because the sensor has a measurement error. As demonstrated in Figure 6(a), error rate E for the proposed method was 16.88%. Although the result is certainly not good, it is better than those obtained using the other two methods. Furthermore, the curve of the urinary volume graph obtained using the proposed method,x(k), is slightly different from the output signal of the ultrasonic sensor, x u (k). Error rate E in Figure 6(b) shows the second best result, which is 3.12% of the other error rate. The predicted urinary volume,x(T u ), at the urination interval, T u = 55 min, was 339.07 mL. As the actual urinary volume, X true , was 350 mL, the difference was only about 11 mL. However, the curve for the proposed method,x(k), is also different from that of the ultrasonic sensor, x u (k). In addition,x(k) shows a relatively gradual rise. Urination interval T u in Figure 6(c) is the shortest of the five intervals at 36 min, and has an error rate of with an average value of E = 32.42%, which is the worst result among the three methods. Moreover, the curve for the proposed method,x(k), is completely different from that of the ultrasonic sensor, x u (k). The urine in the proposed method accumulated in the bladder relatively slowly, as demonstrated in Figure 6(d).

Examples of the time series data for the urinary volume in the bladder
In addition, the urine measured using the ultrasonic sensor accumulated at a similar speed. As shown in Figure 6(e), the error rate was the smallest (2.14%) in this experiment. The curve for the proposed method, x(k), appears to have a linear slope. Although each curve of the two methods shows different waveforms, as demonstrated in Figure 6(e), the error rates for the two methods did not differ significantly.

Summary of the results for each method
By performing a series of experiments, mean error rate E for the proposed method was determined as 13.32%. In contrast, error rate E u obtained using the ultrasonic sensor was 24.14%, which is summarized in Table 1. Therefore, the error rate for the proposed method was the smaller than error rate E u , showing a significant difference of 5%.

Discussion and conclusions
In this study, we predicted the urinary volume by using a model that considers the reabsorption of primitive urine by improving the previously proposed model. As the proposed model was considered during and after the reabsorption, we can predict the urinary volume in the bladder more accurately. The predicted urinary volume in the bladder,x(T u ), was measured at urination interval T u . The actual urinary volume, X true , was measured using a measuring cup. The mean error rate between the predicted and actual urinary volume was 13.32%. This implies that the proposed method can help us predict the urinary volume without constraints and is better than the ultrasonic sensor when measuring the volume using physical constraints. However, the proposed method must be applied to a system that considers the eating and drinking habits of the residents so that it can be used in nursing homes. As the current method can predict the urinary volume according to the absorption spectrum only at times that the urine is sampled, in the future, we will try to build a system that considers the urinary volume accumulation in the bladder that changes when eating meals and intaking water. Therefore, to predict the updated urinary volumes, we would need to determine additional water content of the body, which includes the water content in the mouth, sweat on the hands and/or feet, and blood viscosity. Furthermore, several effective wavelength bands should be selected by analysing the absorption spectrum. In this study, although we used wavelengths that were selected using the auto-encoder for the acquired spectrum, these bands will be able to estimate the accuracy of the parameter values for T r , τ 1 , τ 2 , K 1 , and K 2 . For this purpose, the components that affect the process of urine accumulation must be determined.
In conclusion, by obtaining the time series data of the urinary volume and the absorption spectrum of the urine obtained immediately after urination, we were able to predict the urinary volume in the bladder more accurately by using a new model with five parameters. Therefore, the proposed method can help caregivers create care plans at nursing homes and prevent UTIs by predicting the urinary volume in the bladder without attaching a sensor to the body.

Disclosure statement
No potential conflict of interest was reported by the author(s).

Notes on contributors
Taku Hirota He received the B.E. degree from Aoyama Gakuin University, Japan, in 2020, where he is currently pursuing the degree with the Graduate School. His research interests include system engineering, machine learning, and biosignal measurement.