## 2 Material and Method
### Wavelet Haar
Figure 3 shows the Haar wavelet approximation histogram is a visual representation of the energy distribution of an image or data after the Haar wavelet transformation process. Haar wavelet is a type of wavelet transform used in image analysis and image processing. The researchers can read the Haar wavelet approximation histogram through the following steps:  
1. Wavelet Haar involves the decomposition of the original image into basic parts called approximation (coarse features) and detail (fine features). 2. The original image is divided into two equal parts, after which the difference between the two parts is calculated to obtain the detail, while the average of the two parts results in an approximation. 3. A histogram is a visual representation of the distribution of values in the data. The approximation histogram of Haar wavelets shows the frequency of appearance of approximation values after the Haar wavelet transform. \begin{table}
\begin{tabular}{l l} \hline
1. & Input: take a grayscale image from the input image. \\
2. & Read: divide the image into 2 \(\times\) 2 sub-blocks for each sub-block. \\
3. & Read: calculate the average of pixels in sub-blocks (approximation components), and calculate horizontal, \\
3. & vertical, and diagonal details. \\
4. & Original Detail Horizontal = top-left pixels—average \\
5. & Original Detail Vertical = top-right pixel—average \\
6. & Original Detail Diagonal = bottom-left pixels—average \\
7. & Combine all the average values to create an approximation coefficient (cA) component. \\
8. & Combine all the horizontal detail values to create a detail horizontal coefficient (cH) component. \\
9. & Combine all the vertical detail values to create a vertical detail coefficient (cV) component. \\
10. & Combine all the detail diagonal values to create a detail diagonal coefficient (cD) component. \\
11. & Return cA, cH, cV, and cD as the result of the Haar wavelet transform \\ \hline \end{tabular}
\end{table} 
Table 1: Pseudocode approximation (cA) and detail coefficients (cH, cV, and cD) are calculated in the Haar wavelet transform. 4. Peaks in a histogram appear due to a distinctive structure or pattern in the data. In the context of Haar wavelets, these peaks may appear due to sudden changes in approximation values, which may be indicative of significant changes in the original image. 5. The peaks in a Haar wavelet approximation histogram can provide information about important features in the data, such as sudden changes, the presence or absence of certain patterns, and the level of roughness or smoothness in the image. Why do many peaks appear? Some causal factors include the following:  
1. If the original image has many sudden changes or small details, there will be many peaks in the approximation histogram of the Haar wavelet. 2. The resolution of the Haar wavelet transform also influences the number of peaks. The greater the resolution, the finer the details that can be detected, resulting in fewer peaks in the histogram. 3. Using different scales in the Haar wavelet transform can also affect the number of peaks in the histogram. The more varied the scales used, the more details are captured, resulting in more peaks. By understanding the Haar wavelet approximation histogram and analyzing its peaks, researchers can gain valuable insights into the structure and characteristics of the image or data they are reviewing.