# Integrating the IoT and Blockchain Technology for the Next Generation of Mining Inspection Systems
## 5 Evaluation
### Inspection Report Footprint  
Mining operations typically occur in remote locations, where network access might be limited and expensive. Therefore, estimating the traffic needed at the edge of the mining application is important. To this end, we evaluated the average data needed to upload an inspection to the cloud platform. The number of measurements and observations collected during an inspection depends on the actual status of the inspected machine and its checkpoints, as shown in Table 1. To preserve the confidentiality of information collected during the pilot, we statistically estimated the size of reports using a Monte Carlo approach. First, we modeled the number of checkpoints per subsystem of each machine type as a random variable with _truncated Gaussian_ distribution by starting from a _Gaussian_ distribution with mean and standard deviation defined in Table 1. Then, we modeled the aging, and, consequently, the lifetime of a generic machine, as an integer number \(N_{age}\) between 1 and 100: 1 means that the machine is new, while 100 means that the machine is at the end of its useful life. Next, we carried out 100 different campaigns of report generation by choosing 100 different random seeds (i.e., seeds computed from timestamp) to not stick to one particular \"lucky\" seed. For each campaign, we generated 250 reports as follows: first, we randomly chose one of the 12 machine types (Table 1), then we sampled from a uniform distribution between 1 and 100 the normalized age \(N_{age}\) of the machine. Following that, we sampled, for each of the subsystems of the target machine, an integer number from the distribution of checkpoints as the number of checkpoints to be inspected. Then, for each checkpoint, we extracted a random integer \(N\) between 1 and 100. Assuming that, for each checkpoint, we can collect only one measurement or one observation, if \(N<N_{age}\), we assumed that we collected an observation associated with the checkpoint; otherwise if \(N>=N_{age}\), we collected a measurement. In this way, it is more likely to have more observations than measurements for an old machine. At this point, we have a population of 25,000 inspections reports and we can statistically characterize the amount of KB required to transmit them to the cloud. Inside the mobile app, the inspection data has the following structure:  
* Each measurement is represented as a _double_ variable (8 bytes) for the actual value and an _integer_ variable (4 bytes) for the ID of the unit of measure. * Each observation is represented as a _string_ with length 255 chars (1 char is equal to 1 byte). * Each checkpoint is represented as a _integer_ variable (4 bytes) that contains the ID. * The report contains also the ID of the inspector (_integer_, 4 bytes), the machine ID (_integer_, 4 bytes), the machine working hours (_integer_, 4 bytes), the inspection timestamp since the Unix Epoch (_integer_, 4 bytes), and the timestamp of the next inspection (_integer_, 4 bytes). Figure 3 shows the box plots of reports size in KB against the normalized age of the target machines. There, for the sake of visualization, we split the sample distribution into four groups, according to the normalized age of the machines. Therefore, normalized ages between 1-25 could represent new machines; fairly new and fairly old machines are represented by normalized ages between 26-50 and 51-75, respectively; normalized ages between 76-100 could represent old machines. Then, for each sample distribution, the upper and lower quartiles are represented with a box, and the whiskers represent the lowest and highest values of the report footprint distribution. From the data, we can highlight that when the machine is getting older, the size of the report increases. This is due to how the information about the machine status is reported. If the machine is \"young\", we collect more numerical readings (i.e., double numbers or integers with 8- or 4-bytes length, respectively) than observations (i.e., text with a prefixed length of 255 bytes).