# Fractal Dimension-Based Methodology for Discriminating Original Paintings from Replicas
## 3 Material and Methods
### The DBC-RGB Algorithm
Moreover, a patch size of 512 \(\times\) 512 pixels ensures sufficient scale for the linear regression required in

Figure 4: The sliding window methodology for processing a pair of paintings: (**1**) selection of values for the following parameters: window size (512 \(\times\) 512) and window overlap (25%); (**2**) sliding window computation; (**3**) example of the FD computation for a window using the DBC-RGB algorithm; and (**4**) statistical analysis of the distributions of FD values for all windows to identify significant differences between paintings. *****: \(p\)-value < 0.0001.

the DBC-RGB algorithm's FD computation. An average correlation coefficient of 0.9997 was obtained for the linear regression calculation performed during FD computation for all 512 \(\times\) 512-pixel patches across all paintings in the Princeton dataset. For the paintings in the Cleveland dataset, we used a window size of 256 \(\times\) 256 pixels. This size, corresponding to a painting patch of approximately 1 \(\times\) 1 cm\({}^{2}\), was selected based on the recommendations in [2], where the authors found that the optimal size for analyzing that dataset ranged between 100 \(\times\) 100 pixels and 300 \(\times\) 300 pixels. Since the DBC-RGB algorithm requires patch sizes with dimensions that are powers of two, we considered two possible patch sizes in that range: 128 \(\times\) 128 and 256 \(\times\) 256 pixels. Finally, we selected a patch size of 256 \(\times\) 256 pixels to ensure a wider range of scales for the linear regression calculation in the FD computation, similar to the case with the Princeton dataset. This selection allowed us to obtain an average correlation coefficient of 0.9992 in the linear regression performed during the FD computation for all 256 \(\times\) 256-pixel patches across all paintings in the Cleveland dataset. As shown, patch size selection is highly dependent on the characteristics of the painting images being analyzed. General recommendations for selecting the patch size include the following trade-offs: (1) Small patches enable a detailed analysis of the painting but require longer computation times, may overlook key characteristics like brushstroke size, and might not provide a sufficient range of scales for the linear regression calculation in FD computation. (2) Large patches speed up calculations, but they may result in too few FD values for statistical comparisons, as they could be analyzed overly large portions of the painting, thus introducing excessive heterogeneity in terms of painting techniques and brush combinations. In our experiments, we tested five different window overlap percentages: 0%, 25%, 50%, 75%, and 90%. Rather than seeking optimal values for each dataset, this incremental selection of window overlaps aimed to observe the relationship between this parameter and the emergence of significant differences in painting comparisons. This approach also allows us to identify which painting comparisons might benefit from further analysis with a higher window overlap percentage. Table 2 shows the number of patches generated for paintings in both datasets using each sliding window configuration. It is not currently possible to automatically determine the optimal window overlap parameter for comparing pairs of paintings in a specific dataset. As we will show in the Section 4, increasing the window overlap percentage leads to identifying more significant differences between paintings within the two datasets, albeit with increased computation times. Therefore, some empirical experimentation is required when analyzing a new dataset, starting with a low value (fastest processing) and then increasing it when no significant differences are found.