# Hide45: A Method for Optimal Payload Data Hiding in Base45 Encoded Strings
## 6 Empirical Analysis  
The set of experiments we set up was aimed at verifying the improvement over the one-bit per (most frequent) symbol encoding presented in [23]: thus we considered the same file formats and incidentally used the same files, but other files of the same format should present the same results due to the large number of files we employed. The files and formats we used were:  
* JPEG: 500 images \(768\times 576\) pixels 24 bpp, quality 80, 2 \(\times\) 2 subsampling;
* TIFF: 500 images \(768\times 576\) pixels 24 bpp, uncompressed;
* PNG: 500 images \(768\times 576\) pixels 24 bpp, compressed;
* ZIP: 7000 files of 500,000 octets;
* BZ2: 1100 files of 100,000 octets; \begin{table}
\begin{tabular}{c c c c c} \hline \hline
**Entry** & **Symbol** & **Sequence** & **Payload** & **Sequences for** \\
**Type** & \(\in\mathcal{B}\) & \(\in\mathcal{S}\) & **Bits** & **Embedding** \\ \hline Type 1 & B & \(\mathsf{S}\in\mathcal{W}-\mathcal{E}\) & 0 & \(\varnothing\) \\ \hline Type 2 & B & \(\mathsf{S}_{0}\in\mathcal{E}\) & \(k\) & \(\begin{bmatrix}\mathsf{S}_{0},\mathsf{S}_{1},\mathsf{S}_{2},\ldots,\mathsf{S}_{2^{k}-1 }\end{bmatrix}\), \\  & & & \(\mathsf{S}_{1},\mathsf{S}_{2},\ldots,\mathsf{S}_{2^{k}-1}\in\mathcal{D}\) \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Type of records of table \(EncDec\) for storing the functions \(\mu\), \(\eta\) and their inverses \(\mu^{-1}\) and \(\eta^{-1}\). GZ: 7000 files of 500,000 octets;
* PDF: 2000 files of 500,000 octets;
* MP3: 3000 audio files having size 500,000 octets. For every file format we performed a 5-fold cross validation with a proportion of 4:1 using the first set to compute the statistic distribution of the \(2^{16}=65\),536 symbols and the second set to test the payload capability of the optimized bit assignment. Experiments were run on laptop with CPU Intel\({}^{\text{\tiny{TM}}}\) Core\({}^{\text{\tiny{TM}}}\) i7-1165G7 2.80 GHz with 16 GB RAM. Comparisons between the method [23] and the improvement described in this paper are reported in Table 2. The first column of these tables reports the file format, and the second and the third report the average payloads (and standard deviation) for the 5-fold cross validation obtained by method developed in [23] and by the proposed Hide45 algorithm, respectively. The payload is expressed in bit per output symbol (bps), that is average number of bits carried by a Base45 character of the embedded output file. The \"Th. Gain\" (theoretical gain) column refers to the expected payload gain computed by the optimization function (6). The \"Emp. Gain\" (empirical gain) column reports the percentage advantage of the proposed method over the one-bit baseline payload, that is used in [23]. To account for the different improvements in payload gain depending on the file format we analyzed, for each format, the relative frequency distributions of the symbols sorting them in decreasing order. The plots are reported in Figures 3 and 4: the first one shows the cumulative distribution of the relative frequencies for all the 65,536 symbols while the second magnifies on the first 128 most frequent symbols of each file format (note that the symbols are not the same being the use of the various symbols a peculiarity of each format). From these figures it may be observed that for the distributions having a steepest start (for example, the MP3 file type distribution) there is a bigger gain in assigning a variable number of bits to every symbol: this is due to the fact that when there are symbols more frequent than others then allocating more bits to them increases the average payload (2). We remark that the execution times for the encoding/embedding procedures do not depend upon the given map, therefore there is no difference between [23] and the proposed method Hide45 with regard to the required time. As already stated in Section 5.1, the optimization procedure that gives the best possible assignment table given the configuration frequencies is computed only once for every file type.