# An Enhanced Adaptive Block Truncation Coding with Edge Quantization Scheme +
## 3 The Proposed ABTC-EQ
### The Proposed Schemes
In this scheme, four clusters \((c_{0},c_{1},c_{2},c_{3})\) are introduced for edge blocks and the bitmap \((M_{e}^{\prime\prime}=[b_{i}])\) shown in Equation (12) is used. The mean \(\mu_{i}^{\prime\prime}\) of each cluster \(c_{i},0\leq i\leq 3\), is calculated with Equation (13), where \(\mu_{0}^{\prime\prime}\leq\mu_{1}^{\prime\prime}\leq\mu_{2}^{\prime\prime}\leq \mu_{3}^{\prime\prime}\). Moreover, via Observation 2, we use a new quantization levels \((\delta_{0}^{\prime},\delta_{1}^{\prime},\delta_{2}^{\prime},\delta_{3}^{ \prime})\) to represent \((\mu_{0}^{\prime\prime},\mu_{1}^{\prime\prime},\mu_{2}^{\prime\prime},\mu_{3} ^{\prime\prime})\). Here, the quantization range is defined like Equation (14) and the value \(\delta_{i}^{\prime},0\leq i\leq 3\) is then iteratively determined based on radix \(R_{i}\) with the the criteria \(\min\{\mu_{i}^{\prime\prime}-\sum_{j=0}^{i}\delta_{j}^{\prime}\}\). Finally, we use new format \((f=0,\delta_{0}^{\prime},\delta_{1}^{\prime},\delta_{2}^{\prime},\delta_{3}^{ \prime},M_{e}^{\prime\prime})\) for an edge block. Scheme C is a method to improve image quality while maintaining the same level of compression as ABTC-EQ, and here, it is proved that the compression ratios of Scheme C and ABTC-EQ are the same for this case. \[b_{i}= \begin{cases}00,\text{ if }x_{i}\in c_{0},\\ 01,\text{ if }x_{i}\in c_{1},\\ 10,\text{ if }x_{i}\in c_{2},\\ 11,\text{ if }x_{i}\in c_{3}.\end{cases}  \tag{12}\]  
\[\mu_{i}^{\prime\prime}=\left\lfloor\frac{1}{|c_{i}|}\sum_{x_{i}\in c_{i}}x_{i }\right\rfloor,0\leq i\leq 3. \tag{13}\]  
\[(n_{0}=6,n_{1}=6,n_{2}=6,n_{3}=6)\text{ with }\left\{ \begin{aligned} & R_{0}:(r_{6},r_{5},\cdots,r_{1})=(128 64\ 32\ 16\ 8\ 4\ ),\\ & R_{1}:(r_{6},r_{5},\cdots,r_{1})=(64\ 32\ 16\ 8\ 4\ 2),\\ & R_{2}:(r_{6},r_{5},\cdots,r_{1})=(32\ 16\ 8\ 4\ 2\ 1),\\ & R_{3}:(r_{6},r_{5},\cdots,r_{1})=(32\ 16\ 8\ 4\ 2\ 1).\end{aligned} \right. \tag{14}\]  
**Theorem 3**. : _Suppose that the percentages of edge blocks and non-edge blocks in an image be \(p_{e}\) and \(p_{n}\), where \(p_{e}+p_{n}=1\), when dealing with \((k\times k)\)-pixel block in an image. Scheme C has the \(CR_{\text{C}}=\frac{8k^{2}}{(17+k^{2})+(8+k^{2})\times p_{e}}\), where \(CR_{\text{C}}=CR_{\text{MN}}\)._  
Proof. : By the compression data formats of Scheme C \((f=1,\mu_{0},\mu_{1},M_{n})\) and \((f=0,\delta_{0}^{\prime},\delta_{1}^{\prime},\delta_{2}^{\prime},\delta_{3}^{ \prime},M_{e}^{\prime\prime})\), we may easily derive \(\text{CR}_{\text{C}}\) in Equation (15). 36, 11101101111111011110101010010) of 51 bits (\(\cdot\) \(|\delta_{0}|+|\delta_{1}|+|\delta_{2}|=21\) bits). In reconstruction phase, the recovered values of are (60, 89, 125). Thus, the AMSE = 78 is slightly larger than that of Scheme A._  
Consider using the quantization range in Scheme B-II. By the same argument of Scheme B-I, we may derive \((\delta_{0}=60,\delta_{1}=28,\delta_{2}=36)\). The recovered values of \((\mu^{\prime}_{0},\mu^{\prime}_{1},\mu^{\prime}_{2})\) are (60, 88, 124). Thus, Scheme B-II has AMSE=80.19, but further reduces the compressed data to 48 bits. When using quantization ranges of Scheme B-III and Scheme B-IV, we have and \((\delta_{0}=64,\delta_{1}=24,\delta_{2}=36)\) and \((\delta_{0}=64,\delta_{1}=24,\delta_{2}=40)\), respectively. In reconstruction, Scheme B-III and Scheme B-IV can recover \((\mu^{\prime}_{0},\mu^{\prime}_{1},\mu^{\prime}_{2})\) = (64, 88, 124) and \((\mu^{\prime}_{0},\mu^{\prime}_{1},\mu^{\prime}_{2})\) = (64, 88, 128). Finally, Scheme B-III (respectively, Scheme B-IV) has AMSE=81.69 (respectively, 82.19) and stores 45 (respectively, 42) bits for this block. **Example 3**. : _Compress the image block by Scheme C. By k-means clustering algorithm, we subdivide this block into four clusters, and assign (00), (01), (10), and (11) for each cluster to establish bit map \(M^{\prime\prime}_{e}= \begin{bmatrix}10&01&10&00\\ 11&10&10&01\\ 10&11&00&01\\ 10&10&00&01\end{bmatrix} \).