Energy use and CO 2 emissions of the Moroccan transport sector

ABSTRACT


INTRODUCTION
Like many developed countries, Morocco consumes a lot of energy in the various national sectors despite its positive efforts.Around 91.3% of total consumption is based on fossil fuels including coal, oil, and natural gas in 2020, according to the International Energy Agency (IEA) [1].The transport sector in Morocco is the first energy consumer.The shares of the total energy consumption by sector are shown in Figures 1(a) and 1(b) both in the years 1990 and 2019 respectively.This sector depends almost exclusively on petroleum products, which are imported and weigh heavily on our trade balance.Based on the World Energy Balances report released by the IEA in 2021 [1], the sectors with the highest energy demand shares in 2019 were transport (37%) followed by residential (25%) and industry (19%) [2].In the other hand, the total final consumption increased 3 times between 1990 and 2019 to reach a value of 702000 TJ in 2019.Moreover, the transport sector accounts for 29% of total carbon dioxide (CO2) emissions in 2019 [1].In fact, Morocco has seen a rapid increase in the number of cars on the road over the past 20 years due to the country's growing population and standard of life and it is expected that the rising trend will persist in the future.The increase in the car fleet and fuel consumption has also resulted the increase in demand of energy and CO2 emissions.Accordingly, transport sector plays a very important role in the national effort against climate change.As the transport sector has a continuous growth, several objectives have been set by our kingdom to achieve sustainable transport, in order to respect environmental standards.Indeed, Morocco is committed through different strategies for several years to reduce its greenhouse gas emissions (GHG) and environmental impact in all sectors in general and the transport sector in particular.Since 2009, Morocco has adopted the National Energy Strategy [3] which had as a short-term goal to ensure 42% of electricity production in 2020 from renewable sources and as a long-term goal to reduce energy consumption by 15% by 2030; however, the first objective was not achieved.Morocco's sustainable development strategy aims for a green economy.It has ratified the Paris Agreement, committing to a 40% reduction in GHG emissions by 2030.These efforts are crucial to prevent climate disruption.Accurate knowledge, evaluation, and forecasting of future trends are essential for the government to manage the transport energy consumption (TEC) and CO2 emissions effectively.
There is a large body of research on modeling energy consumption and CO2 emissions in various nations related to road transportation.These researches was carried out with different methodologies, including multivariate, univariate, panel ordinary least squares regression (OLS) models [4], and machine learning ML applications such as artificial neural network (ANN) [5].For example, Zhang et al. [6] created a partial least squares regression model with the urbanization rate, gross domestic product (GDP), freight transportation volume, and passenger transportation amount.They forecasted TEC for 2010, 2015 and 2020.
Rivera-González et al. [7] used leap model application to estimate TEC in Ecuador under four scenarios.According to the estimated findings, diesel and gasoline will most likely remain the primary energy sources for the transport sector.Similarly, Beyca et al. [8] employed two machine learning tools to forecast natural gas consumption for Istanbul.These tools include support vector regression and ANN method.The findings show that the support vector regression (SVR) technique outperforms the ANN technique significantly, providing more accurate and dependable predictions in terms of error rates.Chai et al. [9] forecasted China's road transportation energy consumption using several regression models.They demonstrated that the results of the ANN model are more accurate than those of multiple linear regression (MLR) in predicting TEC.Also, Murat and Ceylan [10] noted that the ANN model performs better in predicting Turkey's central European time (CET).
On the other hand, several methods have also been applied to predict transport emissions gas.For instance, Hosseini et al. [11] used MLR and multiple polynomial regression analysis to estimate GHG emissions in Iran based on the assumptions of two different scenarios, namely business as usual (BAU) and the sixth development plan by 2030.They found that they will only meet Iran's commitment to the Paris agreement under the second scenario.Similarly, Javanmard and Ghaderi [12] conducted a study on GHG using energy market data and a hybrid model that incorporates machine learning algorithms.In China, Yang et al. [13] proposed transport CO2 emission models under several scenarios.The results show that low carbon transportation infrastructure and energy efficiency technologies should receive additional funding.Niu et al. [14] provided a case study aimed at determining effective carbon emission reduction policies in China using machine learning algorithms.Arora et al. [15] projected the number of highway cars, energy demand, and CO2 emissions in India using a variety of economic functions.
In light of the above reasons mentioned and with the goal of contributing to the existing literature, this study is conducted to forecast energy demand and CO2 emission in the Moroccan transport sector by 2030.To achieve this goal, we used two machine learning (ML) methods and four mathematical models that integrate past trends of various self-reliant parameters including GDP, population (POP), urbanization (URB), evolution of the number of vehicles (EVOL) and introduction of electric vehicles (EV).Moreover, a dummy variable was introduced in both ML models to reflect the introduction of electric vehicles in 2016.All models are trained  ISSN: 2088-8708 Int J Elec & Comp Eng, Vol.14, No. 1, February 2024: 86-98 88 using the 1990-2017 dataset and was tested using the years (2018-2020).The performance of the algorithms is then compared using four important statistical metrics (R 2 , root mean square error (RMSE), mean absolute percentage error (MAPE), and Theil's U).Finally, forecasts of the TEC and CO2 emissions by 2030 are made based on six scenarios for the evolution of the input parameters.
To our knowledge, this article is one of the first TEC and CO2 emission prediction studies carried out in Morocco.The major contribution of this study is then to provide an overview of transport energy requirements in Morocco specifically and in emerging nations without oil resources generally, by 2030.Moreover, this research will help government, researchers and decision-makers in the energy sector to comprehend the degree of energy dependence of the transport sector, namely by providing answers to the following two key questions: Will Morocco be able to achieve the objectives outlined in its national energy strategy, especially the one that asks for a 15% decrease in TEC by 2030?What role will electric cars play in Morocco's efforts to cut CO2 emissions?
In the rest of this paper, we will explore the following topics: section 2 defines data sources and provides descriptions of ML algorithms, mathematical models and statistical benchmarks.Results and discussions are presented in section 3. Finally, the main conclusions are outlined in section 4.

DATA AND METHOD
This section provides thorough explanations of data sources employed, the mathematical models, and machine learning techniques.In section 2.1 and 2.2, the collected data is detailed and described.In section 2.3, the algorithms and optimum machine learning parameters are displayed.Finally, further details on mathematical models are provided in section 2.4.

Data collection
The present paper covers the annual sample period from 1990 to 2020.Data on POP, URB, GDP were provided by the World-Bank [2].Data on the evolution of the number of vehicles in circulation by type and category (EVOL) and the introduction of electric vehicles (EV) was taken from the Haut Commissariat au Plan (HCP) [16].Other data on TEC and CO2 emissions from transport sector are provided by the International Energy Agency [1].Table 1 presents descriptive statistics of the dataset used in this study.Due to varying magnitude scales of each parameter, displaying the data as a graph is not feasible.Instead, each parameter was converted to a normalized form ranging from 0 to 1.This is also helps to reduce the noise during the data collection process.Formula (1) illustrates the transformation process from actual data to normalized data.
where  1 represents the actual data, the minimum and maximum values are  1  and  1  in the data respectively.As a result,  1  displays the normalized value of  1 and ranges from 0 to 1. Figure 2 displays the normalized form of input and output parameters.It indicates a general increasing trend for each parameter over the years, although occasional fluctuations have occurred in the past.Indeed, to explain the link between energy and emissions, numerous models have been utilized in previous studies [17].Table 2 illustrates the correlation between input and output parameters.The values range from 0.972 to 0.998, indicating a strong relationship.The coefficients associated with the EV parameter range from 0.330 to 0.362.Overall, this suggests that transitioning to (EVs) for passenger transportation aligns with the goal of reducing GHG emissions in Morocco, presenting a promising approach.Indeed, the electrification of transportation is growing increasingly widespread, and current projections indicate that the number of electric vehicles on the road will increase quickly in the future [18], hence the need to keep parameter EV in the models in order to show the impact of the transition in Morocco.The machine learning algorithms are trained using these inputs to forecast TEC and transport CO2 emissions.

Description of collection data
Figure 3 shows the changes in Moroccan TEC and transport CO2 emissions between 1990 and 2020.Both variables have shown a virtually linear growing tendency over time, as can be seen from the Figure 3. Therefore, there is a very significant correlation between TEC and transport CO2 emissions.In 1990, Morocco's transport CO2 emissions and TEC were equal to 4 Mt of CO2 and 2.27 Mtoe respectively, while they reached 19 Mt of CO2 and 10.88 Mtoe respectively in 2019 [1].This evolution is due to the rapid growth of the country's population, socio-economic progress and improved quality of life.Moreover, Morocco is a developing country with more than 37 million inhabitants in 2021 [16], so an increase in the number of registered vehicles in the country is quite normal.Indeed the registered vehicle number was equal to 47494 in the year 1990, and it increased to 432336 in the year 2020, according to data obtained from HCP [16].Undoubtedly, the country's energy needs in the transport sector will rise as the number of vehicles increases.Considering the data in 1990 as the starting point, the cumulative growth rate in the evolution of Moroccan vehicle numbers increased by 368% in 2020.As a result, it seems that the vehicle number in the country will probably increase annually.Undoubtedly, the country's energy needs in the transport sector will rise as the number of vehicles increases.Not only does this case impede the nation's economic development, but it also brings environmental problems into focus.These data demonstrate that policymakers and decision-makers should take the TEC and its effects on the economy and environment seriously when considering future investments and taking proactive measures in the short, medium, and long terms.The evolution of vehicles number in our country is given in Figure 4 over the years.

Machine learning algorithms
Machine learning is a form of artificial intelligence that enables machines to learn from mathematical and statistical concepts.ML algorithms collect data to create accurate models for production, research, or decision-making [19].In this paper, two ML algorithms-ANN and support vector machine (SVM) are applied in order to forecast TEC and transport CO2 emissions in Morocco.In fact, the choice of ANN and SVR is based on their proven effectiveness in energy-related forecasting tasks.As reported by Biswas et al. [20], several researchers have supported that ANNs are more effective than linear regression methods for modeling energy consumption; nevertheless, regression models remain simpler and more understandable [21].Furthermore, ANNs have been found to be more accurate than linear regression, SVR [22], k-nearest neighborhood (KNN) and multivariate adaptive regression splines (MARS) methodologies [23] for modeling nonlinear fluctuating phenomena.ANNs can model energy consumption based on hourly intervals [24] or even sub-hourly intervals (e.g., 15 minutes) [25].On the other hand, we have also chosen ANN and SVR as they are compatible with the specific characteristics of our dataset (size, dimensions, and data type).

Artificial neural network models
ANNs are developed on the human cognitive system and stimulated by the neurological characteristics of the human brain.Generally, they are used to model nonlinear, multidimensional, and complex datasets.ANN contain a large number of neurons interacting through weighted connections [8].This tool has become widely used in research studies, it can provide successful results for classification, prediction and impact assessment in various fields like energy studies; applied physics; application engineering [26].ANNs are categorized into different versions like feed-forward and feedback recall architectures, supervised and unsupervised learning techniques [2].
Although there are several types of ANN, we have chosen to use the multilayer perceptronbackpropagation, in the present study, since it offers several advantages, namely: It is a compact network with fast computational speed, enabling the training of large input datasets [27]; It provides automatic knowledge generalization, enabling the recognition of data patterns [28]; It exhibits robustness against data obscured by noise; and finally, it minimizes the mean squared error across all training datasets [29].The formulas (2) and (3) represent the general output and MLP's functions of error [30].
where   and   present the input data, and a value of weight, respectively.Additionally, () refers to the activation function, and   and   are the net output, and the value of estimated output, respectively.Typically, a backpropagation algorithm includes three layers: input, hidden, and output, and testing and training are its two phases.The structure of the model in this study is obtained when the input, output and hidden layers are 5-8-1 and 5-10-1 for TEC and CO2 forecast.Other important parameters such as training, test and validation performance are obtained to be "0.997904961","0.995633011", "0.999955615" respectively for TEC and "0.997185", "0.999816", "0.998852" for CO2.

Support vector machine algorithm
Support vector machine was developed as a reliable and precise data mining method for pattern recognition, classification, and regression issues, and it was first introduced by Boser et al. [31].When the error is decreased, the risk of over-fitting is also decreased while the flatness of the function is increased.A succession of high-dimensional functions is used to build the regression model.From a mathematical standpoint, the formulas between (4) and ( 13) describe SVR methodology: where a and b are parameters and () stands for the function of kernel transformation for the inputs.The regularized risk function is presented below, and the coefficients are determined through minimization of this function: where the tolerance value is the parameter ɛ, (, ()) is referred to ɛ insensitive loss function in (6).If the estimated value is contained within the tube, the loss is equal to zero.Similar to the soft margin hyperplane, one must include two slack variables, ɛ  and ɛ  * which stand for positive and negative deviations out of the zone, respectively.In the ensuing constraint form, equation ( 7) is rewritten as: subject to: Subject to: In the feature space () and (), the result of the kernel function K(  ,  ) is the inner product of the two vectors   and   .The sigmoidal kernel, linear kernel, polynomial kernel, and radial basis kernel are the most widely used kernel functions.The polynomial kernels used in this study demonstrate successful performance because the dimension of the feature space is determined by their degree, and the simplicity of computation.Polynomial kernels have also been widely used in a variety of applications [33].Thereafter, equation ( 13) expresses the polynomial kernel with an order of d and a constant of  1 and  2 .A proper configuration of the hyperparameters (C) and kernel parameters is crucial for the SVR's performance (d) [34].It is essential to choose the kernel function, C, and parameters carefully since their combined effect on the SVM algorithm's ability is very important to achieve high accuracy and high performance.In this paper, the best results are noticed for TEC forecast when kernel function type was sigmoid, capacity=1.000,epsilon=0.500,while kernel function type was sigmoid, capacity=7.000,epsilon=0.100for CO2 forecast.

Mathematical models
Many researchers have chosen to forecast energy use and CO2 emissions based on the change of the year across the literature [19].In keeping with these researchers, we decided to forecast Morocco's CO2 emissions from transportation and TEC using only year variable.Then, the provided forecasts will be compared with those generated by the ML algorithms.For this aim, four mathematical models-linear, exponential, logarithmic and polynomial regression are developed to express future Morocco's TEC and CO2 emissions as a function of year.The data between 1990 and 2017 was used to generate the mathematical models.Therefore, the mathematical formulas are expressed as ( 14)-( 21): 2  = 1 − 41 0.0528 (15) 4  = 89.307 2 − 350984 + 3 + 08 1  = 0.503 − 997.64 4  = 0.0061 2 − 24.044 + 23592 (21) where Y is the year.Model 1, model 2, model 3 and model 4 give the linear, exponential, logarithmic and polynomial regression equations, respectively for TEC and transport CO2 emissions.

Statistical benchmarks
This paper discusses the performance of ML algorithms and mathematical models for forecasting using four widely-used statistical metrics commonly employed in numerous studies [35].The four metrics are R 2 , RMSE, MAPE, and U-Theil statistics, which stand for determination coefficient (R 2 ), RMSE, and MAPE, respectively.These considered performance measures are given by the mathematical formulas.
where   and   are predicted and measured data, and n is the total number of observations.

RESULTS AND DISCUSSION
The results and discussion part will be presented in four subsections.Section 3.1 presents a projection of the study's input parameters through the year 2030.Sections 3.

93
CO2 emissions using the two ML algorithms and the four mathematical models, respectively.Finally, section 3.4 presents the overall discussion of study findings.

Forecast of the parameters until 2030
To forecast TEC and CO2 emissions, future trends in URB, POP, GDP, EVOL, and EV must be anticipated.According to recent reports [26], the population is projected to reach 39.3 million by 2030, with urbanization increasing from 55.1% in 2004 to 67.8% in 2030 [26].For EVOL's forecast, an exponential equation is fitted to the EVOL growth curve as shown in Figure 5.The high R2 value of 99.37% indicates the accuracy of the fitted curve.For GDP, the World Bank has made projections and identified 3 scenarios for Morocco's economic growth by 2030: Probable, trend and desirable, with a growth rate of 3%, 4% and 5% respectively [2].Finally, the future values of the EV parameter are taken from the energy federation in Morocco and are classified according to 2 scenarios (pessimistic and optimistic scenario) [36].Table 3 summarizes the forecast of all the parameters used in this study until 2030.

Forecasting of transport CO2 emission and TEC using ML algorithms
Two ML techniques are used to forecast transport CO2 emissions and TEC in Morocco until 2030.Figure 6 shows the predicted and actual values of CO2 emissions in Figure 6(a) and TECs in Figure 6(b) over time.The forecasted and actual values are typically fairly similar to one another.Table 4 presents the statistical metrics for a more effective comparison of the algorithms.Indeed, it can be seen that R 2 value ranges from 0.998 to 1 for all ML models, which is a good sign.Another important metric used to compare the results is MAPE.The earlier researches suggested evaluating the MAPE metric's performance by classifying it in four different ways [19]: i) MAPE≤10%, so the outcomes of the forecast can be categorized as having "excellent forecast accuracy," ii) 10%<MAPE≤20%, so the outcomes of the forecast can be classified as having "Good forecast accuracy," iii) 20%<MAPE≤50%, so the outcomes of the forecast can be categorized as having "Reasonable forecast accuracy," and iv) If MAPE>50%, then the outcome of the forecast might be classified as "Inaccurate forecast accuracy".The MAPE results for each algorithm indicate "high forecast accuracy" as they are all below 10%.Specifically, the ANN model outperforms the other algorithms in terms of  2 , RMSE, MAPE, and U-Theil errors for transport CO2 emissions.However, for TEC, the ANN algorithm performs better only in terms of  2 and MAPE.Therefore, both ML algorithms are necessary for accurate forecasting.Table 5 presents projections for TEC and transport CO2 emissions across the 6 scenarios, combining different GDP evolution and electric vehicle introduction rates.Note that the 6 scenarios were generated by combining the three GDP evolution scenarios (3%, 4%, and 5%) with those of the rate of introduction of electric vehicles (pessimistic and optimistic).The 6 scenarios are named as follows: (pessimistic, 3%), (optimistic, 3%), (pessimistic, 4%), (optimistic, 4%), (pessimistic, 5%), (optimistic, 5%). Figure 7 explains the structured framework for creating scenarios in the forecasting process.

Forecasting of transport CO2 emissions and TEC with mathematical models
Knowing a country's projected energy needs is a crucial tool for achieving equilibrium between supply and demand.In this section, the goal is then to forecast Moroccan transport CO2 emissions and TEC consumption using only year variables.Accordingly, four mathematical models are developed in this study based on the years as expressed in ( 14)-( 21) presented in section 4.2.
The equations are generated and models are fitted using the TEC and transport CO2 emissions data from 1990 to 2017.The models are then evaluated using the four statistical metrics (R 2 , RMSE, MAPE, and Theil's U) and data spanning the years 2017 and 2020, as shown in Table 6.The test phase showed that while the linear function (as expressed in (15)) better reflects the TEC, the ln function (as expressed in ( 20)) better expresses transportation-related CO2 emissions.Therefore, in (15) and ( 21) will be used to forecast TEC and CO2 emissions respectively, in 2030.The outcomes of the forecasts are shown in

Discussion
Through the evaluation of the calculated statistical metrics as shown in Table 4 and comparative analysis of the performance of ANN, SVM, and mathematical models (Linear function for TEC and logarithmic function for CO2) using the four metrics (MAPE, RMSE, R 2 , and U-Theil), the robustness of the analysis was assessed, yielding consistent and logical results.All calculated error rates did not exceed 10%.It can be therefore deduced that both methods consistently produce accurate results across various data samples.Furthermore, the utilization of cross-validation techniques to assess the stability and generalizability of both methods enhances the robustness in our study.
As result, in 2030, the ANN model revealed that the TEC will range between 133286.2 and 143614.4TJ, according to the six scenarios.It is in the (pessimistic, 3%) scenario that consumption will reach 133286 TJ, indicating a 15% drop from 2020 levels.This means that Morocco is already on track to meet its national energy strategy goals [3].Additionally, the optimistic scenario shows higher consumption, aligned with the hypothesis that increased electric car usage leads to higher power demand.In contrast to the ANN model, the SVM model forecasts stable consumption in 2030, with TEC ranging from 220,390.4 TJ to 245,658.8TJ.
The ANN model forecasts a decrease in CO2 emissions by 2030, ranging from 4 MT to 10.58 MT across the six scenarios.Increasing the number of EVs shows then a positive environmental impact.In fact, if Morocco succeeds in achieving its objective of powering its fleet with 425.704 electric vehicles by 2030 (optimistic scenario), it could achieve an average emissions reduction of 75%.In other words, adding 1% of electric vehicles to the fleet results in a reduction of approximately 0.40% of emissions.However, in the case of 11.391 vehicles (pessimistic scenario), the emissions reduction would be 49% on average.Unlike the ANN model, the SVM model predicts emissions to remain virtually unchanged until 2030, even with different scenarios.Note that the outputs of SVR and ANN models can differ for several reasons.Firstly, the structural dissimilarities, with SVR using a kernel-based approach and ANN having interconnected nodes and hidden layers, affect how they capture data patterns.Secondly, their distinct capabilities in handling data representation, with SVR excelling in non-linear relationships and ANN in complex, non-linear patterns, lead to varied performance based on data characteristics.Thirdly, differences in hyperparameter settings, such as kernel functions or hidden layers in ANN, impact model performance and contribute to differing results.Lastly, SVR and ANN respond differently to data fluctuations, making them more or less sensitive to specific variations, which further accentuates the discrepancies in their predictions Another important result from Table 5 is that TEC and CO2 emissions experience a slight elevation in response to GDP growth.This result indicates that economic growth has an increasing effect on the amount of energy used and CO2 emitted by the transportation sector.More precisely, by maintaining a low rate of electric vehicle adoption (pessimistic scenario), when the GDP increases by 1%, the TEC and CO2 emissions increase by an average of 0.52% and 1.8%, respectively.However, with a high rate of electric vehicle adoption (optimistic scenario), the increase in GDP will result in a rise of TEC and emissions by only 0.19% and 0.15% on average, respectively.
On the other hand, mathematical models have indicated that the transport energy consumption would keep rising in the coming years as shown in Table 7.The TEC will increase from 227260 TJ in 2020 to 321822 TJ in 2030, representing an increase of approximately 42%.Similarly, CO2 emissions from the transport sector are projected to increase by around 37.47% in 2030.Therefore, if TEC and CO2 emissions follow the same trend and no policies are adopted, the transport sector will remain to be a burden on the country's economy as well as a source of future environmental issues.Given Morocco's heavy reliance on foreign energy sources, it

CONCLUSION AND POLICY IMPLICATIONS
In this paper, we forecast the TEC and transport CO2 emissions in Morocco in 2030 using two ML tools (including ANN and SVM) and four mathematical models.For this purpose, various macro-economic variables and technological factors are initially used including GDP, population, urbanization rate, evolution of the vehicles number and the introduction of electric vehicles.The performance of twenty models (10 models for TEC and 10 models for CO2 emissions) was evaluated by using different statistical metrics (R 2 , RMSE, MAPE, and Theil's U).The last criteria revealed that the proposed models generally performed well.The forecasts were made according to 9 development scenarios of the input variables.The study's findings can be summarized as follows: i) Model outputs showed that a decrease in TEC and CO2 emissions is expected until 2030, this result is in line with Morocco's green growth policy, which aims to reduce TEC as by 15% in 2030.Therefore, Morocco must keep working to reduce transport CO2 emissions and follow the path of other countries that have introduced new regulations on fuel economy and motor vehicle emissions.Due to this, these countries have experienced varying levels of success in reducing overall emissions and increasing gasoline fuel efficiency; ii) Our results showed that the lowest values of CO2 were obtained in the optimistic scenario with the high electric vehicles number.Therefore, it can be inferred that electric vehicles will be essential component in future transport systems, enabling substantial reductions in overall CO2 emissions; and iii) The findings revealed also that TEC and transport CO2 emissions are positively impacted by economic growth in Morocco.
The findings have significant policy implications, particularly for the Moroccan government and national stakeholders, in guiding their sustainable transport strategies.Several measures can be implemented, among others: i) The implementation of new measures to encourage the purchase of clean vehicles, for example, free credit and exemption from the vignette and all taxes; ii) The development of infrastructure for charging stations to develop electric mobility in Morocco, therefore encouraging clean vehicles; iii) The promotion and development of public transport to limit the mobility of private transport; iv) The use of the eco-driving principle in professional driving training programs to improve logical, safe, and inexpensive driving; and v) The implementation of a national logistics competitiveness development strategy targeted at creating logistics platforms that will optimize the flow of goods and reduce the need for petroleum-based products.
Forecasting transport energy in Morocco faces unique limitations due to the country's strong energy transition and ongoing economic development in all sectors.As Morocco shifts towards renewable energy sources and implements policies to become more competitive globally, the dynamics of energy demand and usage are rapidly changing.This evolution makes historical data less indicative of the future trajectory, posing challenges for accurate predictions.The dynamic nature of the transportation sector with ongoing innovations also hinders precise forecasting.Therefore, researchers and policy makers should approach the predictions of this study cautiously and perform continuous reassessment to enhance accuracy.

Figure 2 .
Figure 2. Normalized input and output variables

Figure 3 .Figure 4 .
Figure 3. Variation of TEC and transport CO2 emissions between 1990 and 2020 in Morocco (The graph produced using data from the IEA [1]) Int J Elec & Comp Eng ISSN: 2088-8708  Energy use and CO2 emissions of the Moroccan transport sector (Hasnaa Oubnaki) 91 2 and 3.3 address the forecasting of TEC and Int J Elec & Comp Eng ISSN: 2088-8708  Energy use and CO2 emissions of the Moroccan transport sector (Hasnaa Oubnaki)

Figure 5 .
Figure 5. Forecasting of EVOL using an exponential algorithm

Figure 6 .
Figure 6.Forecasting of transport (a) CO2 emissions and (b) TEC using the different ML algorithms

Figure 7 .
Figure 7. Scenarios for the TEC and CO2 forecasting process up to 2030


ISSN: 2088-8708 Int J Elec & Comp Eng, Vol.14, No. 1, February 2024: 86-98 96 is obvious that the demand of energy should be reduced and more effective resource usage should be significantly required.

Table 3 .
Forecast of the parameters (GDP, UR, POP, EVOL, and EV)

Table 4 .
Results of statistical metric for TEC and CO2 emissions forecasting according to ML algorithms

Table . 5
Moroccan transport CO2 emissions and TEC projections by 2030