## 3 System Description
### Compression Algorithm  
This study developed a compression algorithm for the lossless real-time transmission of the EMG signals of mothers. The mainstream algorithm model of our prior research regarding ECG [8] was used, but its core dictionary code word was modified for the application to EMG signals. The algorithm was designed to be spread throughout the proposed system architecture, contributing to a seamless and lossless transmission network environment. The emphasis on the lossless nature of the system is an important feature, since the network environment proposed in this system handles potentially critical medical information. Any loss in signal may lead to clinical misjudgment or diagnostic errors. A flow chart of the EMG transmission solution is shown in Figure 4.  
The EMG data are first obtained and converted to integers. Channels are then separated according to each EMG lead. Then, delta computation of the samples in each lead is implemented.  
Variable bits are dynamically and appropriately allocated for each sample, according to the code word size. Note that the EMG samples originally have 32 bits (EMG machines collect samples in  
Figure 4: Functional diagram of the proposed system.  
4 bytes by default). An example histogram regarding the distribution curve of dynamic EMG records after delta computation is shown in Figure 5. An example record was randomly selected from those used in this study.  
In Table 3, bit allocation is calculated from the selected example distributions shown in Figure 5. 8 bits (1 byte) were allocated to sample integers from \(-128\) to \(127\), which were originally 32 bits, and 16 bits (2 bytes) were allocated to sample integers from \(-32\),768 to \(-129\) or from 128 to 32,767, which were also originally 32 bits.  
EUMTS is then applied as the final process of the compression algorithm, creating the final compressed EMG data. Bit allocation and code word modification are the core processes of the EUMTS, and the main difference compared to our prior research [8]. As mentioned in Section 2.3, EMG data have a low redundancy (Table 4). Of the total of 2000 samples, 638 (31.4%) were redundant. Thus, the sample diversity was 1372 (based on Figure 5 and Table 3); therefore, a different code length compared to in cases of high redundancy was needed, not to mention a different dictionary. The proposed algorithm was modified accordingly, and was optimized for the characteristics of EMG signals.  
Efficiently compressed data by EUMTS (lossless) is then transferred by real-time wireless transmission. At the receiver site, the decoding process is the opposite. EUMTS decodes the compressed signal based on a uterine EMG optimized code word/dictionary, delta computed values are recovered,  
\begin{table}
\begin{tabular}{c c c} \hline \hline
**Classification** & **Frequency** & **Percentage** \\ \hline Redundant samples & 628 & 31.4 \\ Sample diversity & 1372 & 68.6 \\ Total & 2000 & 100 \\ \hline \hline \end{tabular}
\end{table}
Table 4: Low Redundancy in EMG Signals.  
Figure 5: Distribution curve of example records after delta computation.  
\begin{table}
\begin{tabular}{c c c} \hline \hline
**Size** & **Frequency** & **Percentage** \\ \hline
1 byte & 1904 & 95.2 \\
2 bytes & 96 & 4.8 \\ \hline \hline \end{tabular}
\end{table}
Table 3: Frequency of Samples Allocated to 1 and 2 Bytes.  
and channels are integrated. Finally, integers are acknowledged and the receiver end users (usually clinicians) check the EMG signal in user interface form.