# Decentralized Public Transport Management System Based on Blockchain Technology +
## 3 System Design and Implementation
### Proposed System Description  
The blockchain for the proposed system should have several characteristics. However, it is necessary to consider the specifics of the application in the transport sector when developing it. While both private and consortium blockchains offer advantages for transportation systems, our choice of a private blockchain architecture is justified by several key factors specific to public transportation management, as follows:  
1. Operational Control: Private blockchains allow for complete control over network parameters and transaction validation, which is crucial for maintaining the required transaction processing capacity. 2. Data Privacy: Public transport organizations need to maintain control over sensitive operational data while still ensuring transparency within their organization. 3. System Efficiency: Our implementation requires processing a specific number of vehicle tokens, which is more efficiently managed within a private blockchain structure. 4. Geographical Scope: Since the system is designed to operate within one geographical area, a private blockchain provides sufficient decentralization while maintaining operational efficiency. The main characteristics and justification of these values are presented in Table 5. \begin{table}
\begin{tabular}{c c c} \hline
**Source** & **Data Type** & **Data Transmission Frequency** \\ \hline Engine speed, vehicle speed & Word & One per minute \\ \hline Temperature of engine oil, antifreeze & Integer & One per minute \\ \hline Check engine & Boolean & One per 30 min \\ \hline The mileage of a vehicle & Integer & One per day \\ \hline Wear of brake pads and discs & Byte & One per day \\ \hline Number of stops, passengers, drivers & Word & One per day \\ \hline Engine running time & Datetime & One per day \\ \hline Vehicle location & Geometry & One per minute \\ \hline \end{tabular}
\end{table} 
Table 4: Data types. Figure 2: Average distribution of passengers by time. An Ethereum-based blockchain will be used to implement the described system as a universal solution in the industry. To implement these characteristics effectively, we develop a three-layer blockchain integration architecture that ensures seamless interaction between the token-based monitoring system and the blockchain infrastructure. Table 6 presents the key components and functionality of each architectural layer. This architectural approach enables automated maintenance decisions through smart contracts while maintaining the system's performance requirements. When a vehicle's token value reaches predetermined thresholds, the system leverages this architecture to trigger maintenance scheduling, update the vehicle status, notify stakeholders, and record all events in the blockchain, ensuring data integrity and operational efficiency. In this model, one of the key tasks is to transfer information from the vehicle, namely from the IoT sensors to the cloud server. Placing messages from the sensors in SBD packets with subsequent compression can be accomplished by applying the compression algorithm (operator) to messages placed in the container for the SBD package [46]. **Theorem 2**. : _Let: First, we define the SBD packets as having a size \(V\) and a set of \(n\) messages of sizes \(a_{1}\),... \(a_{n}\). It is necessary to find an integer number of containers B and partition the set {1,...,n} into B subsets \(S_{1}\),... \(S_{B}\) such that we obtain the following:_  
\[\sum\
olimits_{(\forall i\in S_{1})}a_{i}\leq V,\forall k=\{1,\ldots,B\} \tag{2}\]