## 2 Materials and Methods
### Synthesized Training and Testing Datasets  
The synthesized data are partitioned into training and testing datasets. Using Equations (6)-(12): (1) random noise corresponding to meter class is added to the sum and consumer current, voltage and active power readings of training and testing datasets before and after the consumer power event (Figure 3), (2) systematic gain error is injected into the testing set of only consumer meter readings in the (6)-(12), (3) finally, the resolution is restricted in all datasets by applying (17). The notations of the synthesized data with the injected random and systematic gain errors is denoted in Figure 3. The index 1 denotes average (from \(K\) samples) power, current \begin{table}
\begin{tabular}{p{28.5 pt} p{28.5 pt} p{28.5 pt} p{28.5 pt} p{28.5 pt} p{28.5 pt} p{28.5 pt}} \hline \hline \multirow{2}{*}{**Case**} & \multirow{2}{*}{\begin{tabular}{c} **Sum Meter** \\ **Class** \\ \end{tabular} } & \multicolumn{1}{p{28.5 pt}}{\begin{tabular}{c} **Sum Meter,** \\ **Random Power** \\ **Error (\(r_{P}\)), \%** \\ \end{tabular} } & \multicolumn{1}{p{28.5 pt}}{\begin{tabular}{c} **Consumer Meter,** \\ **Rate, Class** \\ \end{tabular} } & \multicolumn{1}{p{28.5 pt}}{\begin{tabular}{c} **Consumer Meter,** \\ **Random Power** \\ **Error (\(r_{P}\)), \%** \\ \end{tabular} } & \multicolumn{1}{p{28.5 pt}}{\
\begin{tabular}{c} **Sum Meter Voltage,** \\ **Current and Power** \\ **Readings Resolution** \\ \end{tabular} } & \multicolumn{1}{p{28.5 pt}}{
\begin{tabular}{c} **Consumer Meter** \\ **Voltage, Current** \\ **and Power** \\ **Readings Resolution** \\ \end{tabular} } \\ \hline M1 & 0 & 0 & 0 & 0 & 0.1 V, 0.05 A, 1 W & 0.1 V, 0.05 A, 1 W & 0.1 V, 0.05 A, 1 W \\ M2 & 0.5 & 0.5 & 0.5 & 0.1 V, 0.05 A, 1 W & 0.1 V, 0.05 A, 1 W & 0.1 V, 0.05 A, 1 W \\ M3 & 0.5 & 0.5 & 1 & 1 & 0.1 V, 0.05 A, 1 W & 0.1 V, 0.05 A, 1 W \\ \hline \hline \end{tabular}
\end{table} 
Table 4: Meter class and random error (\(r_{P}\)) of active power measurement. Figure 3: Power, current, and voltage readings of sum meter and consumer MUT before and after power event. and voltage before the power event, and index 2 denotes average (from \(K\) samples) power, current and voltage after the power event. In Table 5, cases of training and testing datasets are assigned distinctive titles (T1, T2, T3) for the faster reference in the following text. Odd samples from the complete synthesized dataset (Figure 2) of power, current and voltage are always used to build data-driven models (training phase), which will be used to predict PCC and estimate gain error of consumer MUT. The test data set was composed from even samples of the full dataset or by selecting other samples according to the rule listed in Table 5.  
To summarize, the dataset was generated:  
1. [label=(0)]
2. Setting power consumption such that to cover ranges of typical loads used at households of residential consumers
3. Modeling equivalent network to obtain voltage and current corresponding to the power consumption before the power step and after power step at the consumer site which is metered by consumer MUT. Different distribution branch resistances were used to generate data sets representing distribution networks with different wiring resistances (losses)
4. Injecting random and systematic errors into simulated I/V/P according to (6), (7) and (10)
5. Limiting resolution of V/I/P readings to represent limited resolutions of readings available from smart meters over communication interfaces. Despite the wiring resistances and power consumptions might be slightly different depending on countries, historical period of electrical network construction, contracts between consumers and utilities in different countries, but absolute values are not particularly critical for the verification of the performance of a suggested method for PCC in the branch and meter gain error detection.