## 2 Related Works  
### Absolute Moment Block Truncation Coding  
AMBTC (Absolute Moment Block Truncation Coding) [26] is a type of BTC [25] that provides a faster compression processing speed and better image quality. A block consists of two quantization levels and a bitmap, and one block is compressed by preserving the moment. The two quantization values represent a high mean and a low mean for the pixel values of each block. Before the gray image is compressed with AMBTC, the image is first divided into non-overlapping sized blocks. That is, assuming that the variable corresponding to the block size set is \(k\times k\), the block size may be (\(2\times 2\)), (\(4\times 4\)), (\(6\times 6\)), and (\(8\times 8\)). The mean of each block is as follows.  
\[\bar{g}=\frac{1}{k\times k}\sum_{i=1}^{k^{2}}g_{i} \tag{1}\]  
In Equation (1), \(g_{i}\) is the \(i\)-th pixel in the block. Pixels constituting each block are compressed into a bitmap. That is, the pixels in the block are replaced by a '1' if the pixel is greater than the mean value \(\bar{g}\), and a '0' otherwise. Bitmap blocks are divided into the following two groups: '1' and '0'. Bitmap \(b_{i}=\{b_{i1},b_{i2},\ldots,b_{ik\times k}\}\) is generated as a result of Equation (2).  
\[b_{i}=\begin{cases}1,\;\;if\;(g_{i}\geq\bar{g}),\\ 0,\;\;otherwise\end{cases} \tag{2}\]  
In order to recover a bit-plane compressed into a bitmap into a gray image, two quantization levels representing each block are needed. The method of obtaining two quantization levels in each block is provided in Equations (3) and (4), where \(t\) and \(k^{2}-t\) represent the number of '0' and the number of '1', respectively.  
\[Q_{1}=\left\lfloor\frac{1}{t}\sum_{g_{i}<g}^{k^{2}}g_{i}\right\rfloor \tag{3}\]  
\[Q_{2}=\left\lfloor\frac{1}{k^{2}-t}\sum_{g_{i}\geq\bar{g}}^{k^{2}}g_{i}\right\rfloor \tag{4}\]  
Here, \(Q_{1}\) and \(Q_{2}\) may be used for decoding AMBTC. An image block can be compressed into two quantization levels \(Q_{1}\), \(Q_{2}\) and a bitmap \(M\) and cab be expressed as a _trio_ (\(Q_{1}\),\(Q_{2}\), \(b\)). According to the value of the bitmap, \(Q_{1}\) and \(Q_{2}\) values are decoded by applying Equation (5). Finally, the compressed image can be decoded into a gray image.  
\[g_{i}=\begin{cases}Q_{1},\;\;\text{if}\;(b_{i}=0),\\ Q_{2},\;\;\text{otherwise}\end{cases} \tag{5}\]The size of the block is inversely proportional to the image quality and compression ratio. If the block size increases, the compression rate increases but the image quality deteriorates. If the block size decreases, the compression rate decreases, and the image quality improves. We used a block size of \(4\times 4\) in this study. The reason is that it is considered as a size that complies with the appropriate level of compression ratio and PSNR. If the block size is increased to \((8\times 8)\), the PSNR will decrease. If we reduce the block size to \((2\times 2)\), PSNR will increase, but the number of pixels required to apply our proposed RDH will be insufficient.  
**Example 1**.: _As shown in Figure 1a is a block of the original image and the process is explained using this. If a block of gray images \(g=\{176,\,171,\,188,\,169,\,179,\,157,\,167,\,187,\,189,\,179,\,197,\,184,\,182, \,172,\,159,\,159\}\), the mean of this block is 106. Applying Equations (1)-(4), the trio of this block becomes \(\text{trio}(Q_{1},Q_{2},M)=(165,\,185,\,101010011111000)\). Here, the mean (\(g\)) is 106, the low mean (\(Q_{1}\)) is 165, and the high mean (\(Q_{2}\)) is 185. A bitmap (\(b\)) is constructed by assigning '1' to those values that are greater than the average and '0' to those that are not. Decoding using Equation (5) results in \(g^{\prime}=\{185,165,185,165,185,165,185,185,185,185,185,185,165,165\}\). (\(c\)) is generated by the decoding process._