Previous Article in Journal
Fairness in Predictive Marketing: Auditing and Mitigating Demographic Bias in Machine Learning for Customer Targeting
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Multiplicative Decomposition Model to Predict UK’s Long-Term Electricity Demand with Monthly and Hourly Resolution

by
Marie Baillon
1,*,
María Carmen Romano
1,2 and
Ekkehard Ullner
1
1
Physics Department, School of Natural and Computing Sciences, University of Aberdeen, Aberdeen AB24 3FX, UK
2
Institute of Medical Sciences, Foresterhill, University of Aberdeen, Aberdeen AB25 2ZD, UK
*
Author to whom correspondence should be addressed.
Analytics 2025, 4(4), 27; https://doi.org/10.3390/analytics4040027
Submission received: 27 July 2025 / Revised: 27 August 2025 / Accepted: 12 September 2025 / Published: 6 October 2025

Abstract

The UK electricity market is changing to adapt to Net Zero targets and respond to disruptions like the Russia–Ukraine war. This requires strategic planning to decide on the construction of new electricity generation plants for a resilient UK electricity grid. Such planning is based on forecasting the UK electricity demand long-term (from 1 year and beyond). In this paper, we propose a long-term predictive model by identifying the main components of the UK electricity demand, modelling each of these components, and combining them in a multiplicative manner to deliver a single long-term prediction. To the best of our knowledge, this study is the first to apply a multiplicative decomposition model for long-term predictions at both monthly and hourly resolutions, combining neural networks with Fourier analysis. This approach is extremely flexible and accurate, with a mean absolute percentage error of 4.16% and 8.62% in predicting the monthly and hourly electricity demand, respectively, from 2019 to 2021.

Graphical Abstract

1. Introduction

1.1. The Pressure to Get It Right

The stability of the UK energy market is subject to external pressures from long-term factors, such as the Net Zero target from the Paris Agreement, which sets out policies for decarbonising all sectors of the UK economy by 2050 [1], and geopolitical events like the Russia–Ukraine war.
The electricity supply sector was the biggest contributor to UK greenhouse gas emissions until 2014 [2]. With a steady increase in renewable energy since 2010 (Figure 1), the electricity supply sector dropped to fourth position in 2022 for UK greenhouse gas emissions, behind the domestic transport, buildings and product uses, and industry sectors.
The UK could potentially meet its electricity needs through wind and solar sources alone [3]. However, due to the intermittent nature of these sources, this approach would require investment in large-scale energy storage facilities [4]. National Grid published a pragmatic analysis of Future Energy Scenarios [5] with a focus on reducing the overall electricity demand and transitioning to low-carbon energy generation sources. A less carbon-intensive and more resilient grid is a credible option and would allow the UK to meet its 2050 Net Zero target.
Accurately forecasting electricity demand is key to building the future electricity grid, as the UK needs to be more resilient to these external pressures.
The forecast can be carried out on different timescales. In this study, we focus on long-term predictions (from 1 year and beyond), which are critical for strategic planning, such as deciding on the construction of new electricity generation plants or large-scale grid improvements.

1.2. Initial Observations

The time series data of UK electricity demand is provided by the National Grid ESO (Electricity System Operator) [6] with a resolution of one data point per 30 min (called a settlement period) from 2009 onwards. Figure 2a shows the raw data between 2009 and 2024, featuring both a long-term downward trend and cyclical variations on different timescales. Figure 2b shows the data averaged over 1 year (with a stride of 1 year), making the long-term downward trend clearly visible. Figure 2c displays the data averaged over 1 month (with a stride of 1 month), showing a clear seasonal pattern with a maximum of demand in winter and a minimum of demand in summer. Figure 2d shows the data averaged over 1 week (with a stride of 1 week), emphasising the weekly pattern, with weekdays having higher demand than weekends. Finally, Figure 2e shows the average of the data over 24 h (with a stride of 24 h), highlighting two clear peaks around 12 pm and 6 pm for both weekdays and weekends.

1.3. Literature Review

Several different approaches have been applied to forecast electricity demand in the literature. Given the pronounced cyclical patterns in the demand time series, approaches using Fourier analysis have been widely used.
A study of the monthly electricity demand in Spain [7] isolated the long-term trend in the data from the cyclic components. The trend was modelled using a simple neural network, with historical data from the previous 12 months. Cyclic components were modelled by fitting linear coefficients to six sinusoidal functions, whose frequencies were identified via the Discrete Fourier Transform (DFT) analysis of the time series. The overall predictions of electricity demand were obtained by summing the predictions from both models.
A similar approach was applied to forecasting demand in a fashion company [8]. The main difference from [7] was that the model for the cyclic components was based on the inverse Fourier transform using the amplitude, frequency, and phase of the DFT components of the time series. The model optimisation consisted of minimising mean absolute percentage error (MAPE) (Appendix A.4) by changing the number of Fourier components included in the inverse Fourier transform sum.
Besides long-term trend and cyclic components, Li et al. [9] also considered the short-term fluctuations from the time series. An Adaptive Fourier Decomposition (AFD) method was used to break down the time series into its unique features, and the authors showed that modelling irregularities as a distinct component of the signal decomposition adds value to the overall analysis.
A study of the hourly electricity demand in Turkey [10] proposed a descriptive model, where the trend and cyclic components were combined in a multiplicative manner. This model also included weekly variations within a year and hourly variations within a week. A second-order polynomial fit was used to model the long-term trend, and the model did not include a component for short-term fluctuations. The results provide medium- and long-term simulations of electricity demand with an hourly resolution. Hourly resolution is typically used for short-term predictions (1 h–1 week) to support the daily operation of electricity generation and distribution systems, but a long-term hourly prediction can provide greater accuracy in strategic planning. The model was, however, not tested on unseen data and therefore, prediction accuracy could not be confirmed.
For the UK specifically, an early study proposed by Hunt et al. [11] presented an additive model of the trend, cyclic, and irregular components to forecast energy demand by sector for residential, manufacturing, and transportation between 1971 and 1997. Independent variables like energy price, income, and temperature were included in an Autoregressive Distributed Lag model to study their direct influence on energy demand. Their analysis emphasised the stochastic nature of the trend, with its pace and even direction altering over time, showing that approximation by a linear time trend is not appropriate.
Additionally, Bowerman et al. [12] analysed the applicability of the additive versus multiplicative models, concluding that if seasonal variations in the time series are not constant, then a multiplicative decomposition is preferred to the additive decomposition.
Furthermore, Iftikar et al. [13] proposed a day-ahead electricity demand forecasting model based on Nord Pool power market data that decomposes the time series into long-term, seasonal and stochastic components using autoregressive models. A similar model was proposed in [14] for the monthly forecast of electricity consumption in Pakistan. A different approach, solely based on a feed-forward neural network and transfer learning, was proposed in [15] to provide a short-term load forecasting of day-ahead electricity demand for 27 European countries.
Finally, Fields et al. [16] provided a long-term forecast of electricity demand in Sierra Leone for capacity-building purposes using a model proposed by the International Atomic Energy Agency that integrates energy intensities from different sub-sectors by energy and fuel type, together with key drivers, such as GDP growth, population trends, and efficiency improvements.

1.4. Our Proposed Approach

In this study, we propose a multiplicative decomposition model for UK electricity demand that accounts for the following components:
  • Long-term downward trend, as shown in Figure 2b.
  • Cyclic components: Seasonal, weekly, and daily trends, as shown in Figure 2c–e.
  • Short-term fluctuations that are not taken into account in any of the components above.
We apply the proposed model to both the monthly and hourly electricity demand data. The cyclic components of the monthly data are modelled using the approach presented by Fumi et al. [8]. The non-cyclic components are modelled using a neural network that includes independent variables to improve prediction accuracy. The individual components are then multiplied to obtain an overall forecast for electricity demand. This approach is explainable and flexible, with separate models adapted to each component of the signal. This combined approach generates a long-term prediction of the electricity demand with hourly resolution, achieving an MAPE of 8.62% for the testing period 2019–2021. To the best of our knowledge, this is the first attempt to combine prediction methods in a multiplicative model to achieve genuine long-term forecasting at an hourly resolution, and it has not previously been applied to the UK electricity demand. Table 1 summarises methodologies from the key papers that informed this study and contrasts them with our proposed approach.
In addition, we compare our results with a traditional stochastic time series model, namely a SARIMA model. We show in Appendix C that even though a SARIMA approach offers an equally comprehensive modelling of trend, cycle, and random components, our approach is superior in terms of the achieved accuracy, in particular when predicting electricity demand with hourly resolution.
As shown in Figure 3, we implemented a structured computational pipeline to ensure a systemic progression from raw data acquisition to validated results.
This paper is organised as follows: in Section 2, we describe the electricity demand data and other datasets used as input to the model, such as the average temperature in the UK and housing energy efficiency. In Section 3, we present a detailed description of the main model proposed in this study, and in Section 4, we show the main results. In Section 5, we discuss the results and main conclusions of this study. Comparison of our model predictions with the ones obtained with a SARIMA model has been detailed in Appendix C.

2. Selection of Variables and Data Description

2.1. Dependent Variable: Electricity Demand

2.1.1. Data Selection

We accessed the time series data of UK electricity demand from the National Grid ESO (Electricity System Operator) [6], which is provided with a resolution of one data point per 30 min (called a settlement period) from 2009 onwards.
The dataset contains several measures of electricity demand [6], including the following:
  • The National Demand, defined as the sum of electricity generation monitored by the National Grid on the transmission network via metering.
  • The Transmission System Demand (TSD), which is the National Demand plus the additional generation required to meet station load (the power required by the generators themselves to generate electricity), storage pumping (to operate pumps at hydropower plants), and interconnector exports (power exported out from the UK).
  • Embedded Generation Demand: Most of the solar and wind generation is embedded into the distribution network and not metered by National Grid, and therefore, the embedded generation demand must be estimated. The National Grid maintains calibrated models to estimate solar and wind electricity generation using weather data and data collected from selected sites.
Embedded generation effectively lowers the demand required from the transmission network. The steady increase in renewable energy, as shown in Figure 1, results in an increasing gap between the curves TSD only and TSD + embedded generation in Figure 4. An accurate measure of the UK electricity demand should include both Transmission System Demand and embedded generation. Therefore, we considered the sum of Transmission System Demand plus embedded generation Demand as our dependent variable. Figure 4 shows the time series for National Demand, Transmission System Demand (TSD) and TSD plus embedded generation.

2.1.2. Data Pre-Processing

Dealing with Zero-Demand Periods
The Transmission System Demand dataset contains settlement periods of zero demand. Since the demand for electricity is strictly positive, it seems to be due to errors in the data capture process, as it affects 48 consecutive settlement periods at different points in time (see Table 2) with a major anomaly in 2012, having a span of 290 consecutive periods of zero demand.
We selected the average as the interpolation method for those settlement periods of zero demand. We observed in Figure 2e that the electricity demand on weekdays significantly differs from that on weekends. Therefore, we chose to interpolate missing weekday values from the nearest available weekday values before and after, and following the same procedure for weekend values. Notice that only 0.18% of the total number of data points had zero demand. Hence, the specific choice of interpolation method does not affect the main results of this study.
For days with zero demand for either 46 or 48 settlement periods, we replaced the whole day demand with an average of the first matching working day/non-working day with non-zero demand right before and right after. For example, 11 June 2012 is a working day that has a total of 46 missing settlement periods. These missing values are interpolated by calculating the average of the settlement periods from 8 June 2012, since it is the prior working day, and the settlement periods from 12 June 2012, which is the next working day.
For days with zero demand for only one or two settlement periods, we replaced the demand for these periods with an average of the first period with non-zero demand right before and right after.
Dealing with Summer/Winter Time Change
The summer/winter time change artificially creates days with 46 periods at the end of March each year and 50 periods at the end of October.
To ensure that the time series is regularly sampled with all days having 48 settlement periods, we imputed periods 47 and 48 by the average of period 46 and period 1 of the next day. For the days with 50 settlement periods, we replaced the value for period 48 with an average of periods 48, 49 and 50.
Descriptive Statistics of Half-Hourly Electricity Demand Data
Following the treatment of missing values, the dataset of UK electricity demand contains 262,944 data points at 30 min intervals from 1 January 2009 to 31 December 2023. The electricity demand is reported in MW per half hour.
Although statistical analyses identified several data points as outliers (outliers represent 0.08% of the total number of data points using the Interquartile Range method), inspection of the data indicated that these values were consistent with the expected range of natural variation and were therefore retained in subsequent analyses. The statistical characteristics of the UK electricity demand data are summarised in Table 3.

2.2. Independent Variables

We considered a set of independent variables to model the downward trend shown in Figure 2b and short-term fluctuations. Many factors could influence the electricity demand, such as temperature, economic factors, adoption of energy-efficient technologies, and population growth. But identifying all the relevant explanatory variables is challenging because some of these factors may not be directly measurable, and also because the data sources for some other variables do not share the same sampling granularity or time span as the electricity demand dataset.
Table 4 lists a set of variables that could potentially be used to model the downward trend. Table 4 also explains why each variable has been considered, and it summarises the data resolution and source(s) of each dataset.

2.3. Selection of Independent Variables: Correlation Analysis

In order to select the independent variables to be used to predict the downward trend in electricity demand, we studied the correlation between those variables and electricity demand. The results obtained with Spearman’s correlation coefficient [32] are shown in Table 5.
All independent variables, excluding gas demand, are significantly correlated with the downward trend in the electricity demand. Percentage renewables, population growth, number of new builds and electricity CPI are highly correlated with a correlation coefficient greater than 0.9 in absolute numbers.
To understand how the independent variables considered are correlated to each other, we calculated Spearman’s correlation coefficient between all pairs of independent variables (Table A1 in Appendix A.1). To visualise those correlations, we built a network diagram using the obtained values, in such a way that two variables are shown to be connected if their Spearman’s correlation coefficient is significant and larger than 0.7 in absolute value (see Figure 5). It provides a visualisation of groups of variables sharing many connections and variables sharing only a few connections.
Accordingly, we extracted the following groups of variables:
  • Real GDP, average temperature, percentage renewables, and electricity CPI.
  • Housing efficiency and number of new builds.
  • Bid price.
  • Population growth.
  • Gas demand.
We considered those groupings of variables as input to the combined long-term and short-term variability components of the model of electricity demand (see Section 3.1.5) instead of variables considered one by one, so as to avoid the effect of confounding variables. The sensitivity study protocol is detailed in Appendix B.1 with the groups of variables listed in Table A3.

3. Multiplicative Decomposition Model

3.1. Prediction of Monthly Electricity Demand

Here we propose a multiplicative decomposition model to describe monthly electricity demand. The raw UK electricity demand data from National Grid ESO is provided with a time resolution of 30 min, as mentioned in Section 2.1, i.e., the time interval between two consecutive data points is equal to
t r = 30   m i n
(one settlement period). We denote the corresponding time series as Y i r , where i = 1 ,   ,   N r , and N r is the total number of data points considered. From this time series, we construct the monthly electricity demand time series Y i m by adding all the values Y i r corresponding to a given month, i.e.,
Y i m = j = 1 N s ( i ) Y j r
where N s ( i ) is the total number of settlement periods in the ith calendar month, i = 1 ,   ,   N m , and with N m denoting the total number of months considered. The time interval between two consecutive data points Y i m and Y i + 1 m is
Δ t m = 1   m o n t h .
Figure 6 presents the standard deviation of the monthly electricity demand time series across multiple years, revealing non-stationary behaviour. In such cases, a multiplicative decomposition model is more appropriate than an additive one, as it better captures the changing variability relative to the level of the series [12].
Therefore, we propose the following model to describe the monthly electricity demand:
Y i m = T i m j = 1 P m C j , i m   I i m         i = 1 ,   ,   N m
Here, we assume that the monthly electricity demand signal can be factorised into a long-term trend component T i m , a number P m of cyclic components C j , i m , and a short-term variability component I i m .
To implement the monthly multiplicative decomposition model, we use the workflow detailed in following section with illustrations of the key steps. This is followed by detailed explanations of each step.

3.1.1. Workflow to Implement the Monthly Multiplicative Decomposition Model

  • Calculate the trend by smoothing the signal with a Gaussian low-pass filter with a kernel of radius equal to 12 months, Figure 7. Divide the signal by its long-term trend to obtain the cyclical components (detrended signal). Divide the detrended signal by its average to obtain a scaled detrended signal with cycles centred around 1.
2.
Fit an inverse Fourier transform model to the scaled detrended signal by finding the number of Fourier components that minimises the error between the modelled and actual detrended signal. The result is the predicted cyclical component, Figure 8. Divide the signal by the predicted cyclical component to obtain the combined long-term trend and short-term variability component.
3.
Plot the Auto-Correlation Function (ACF), Figure 9, for the combined long-term and short-term variability component obtained in step 2 to check for visible patterns. If there are still cyclical components present, repeat steps 1 and 2 on the signal obtained in step 2; otherwise, proceed to step 4.
4.
Model the combined long-trend and short-term variability component with a neural network, Figure 10.
5.
Assemble the overall prediction, Figure 11, by multiplying the predicted cyclical components in step 2 with the predicted long-term trend and short-term variability components in step 4.

3.1.2. Detrending the Signal—Step 1 in Section 3.1.1

We applied a Gaussian low-pass filter, with a kernel of radius equal to 12 months, to Y i m to obtain an estimate T ~ i m of the long-term trend of the signal. Several other methods to identify the long-term trend were tested and compared in Appendix A.2, including different values of the kernel radius for the Gaussian filter. The Gaussian low-pass filter with radius 12 achieved the best goodness of fit (see the results in Appendix A.2).
Once the long-term trend T ~ i m was estimated, we divided the signal Y i m by it to obtain a detrended signal that allows for estimating the cyclical components in the next step.

3.1.3. Fourier Model of Cyclical Components—Step 2 in Section 3.1.1

We modelled the periodic patterns present in the detrended signal Y i m / T ~ i m by means of its Fourier analysis ([33], pp. 203–229).
The detrended signal Y i m / T ~ i m was first scaled by its average so that the cycles were centred around 1 and could be subsequently incorporated into the multiplicative decomposition model.
Secondly, the Discrete Fourier Transform (DFT) of the signal was calculated (see Appendix A.3), and then the Fourier components were sorted by decreasing order of amplitude, with the zero frequency kept at the first position. After that, a partial reconstruction of the signal using the inverse DFT was obtained by using only a subset of the Fourier components: the sorted Fourier components were incorporated one by one, and every time, the error between the actual detrended signal Y i m / T ~ i m and the partially reconstructed one was calculated using the mean absolute percentage error (MAPE) and the mean absolute scaled error (MASE) (defined in Appendix A.4). By plotting the MAPE against the number of Fourier components (see Section 4.1.2 for detailed results), we could visually identify a minimum, suggesting an optimised model. We made sure that at least two Fourier components were included in the reconstruction: the zero and the first non-zero frequency components. This procedure led to the first cyclic component of the model as follows:
C ~ 1 , i m = A 1,1 m + k = 2 n 1 m A 1 , k m c o s ( 2 π ν 1 , k m Δ t m i + ϕ 1 , k m )
where A 1,1 m is the amplitude for the zero frequency component; A 1 , k m , ν 1 , k m , and ϕ 1 , k m are the amplitude, frequency, and phase of the k-th component, respectively; and n 1 m indicates the number of Fourier components for the first cyclic component of the model.
We observed that the modelled cyclical component may present a time shift compared to the signal (see Section 4.1.2 for detailed results). In order to correct the time shift, we set the number of Fourier components arbitrarily to 5 or 6, and we calculated the MAPE for each value of the time shift. We then selected the time lag that corresponded to the minimum MAPE and applied that time lag to the obtained cyclical component.
After that, we divided the original signal Y i m by the estimated first cyclical component C ~ 1 , i m to obtain the combined long-term trend and short-term variability component.

3.1.4. Review Remaining Periodicities—Step 3 in Section 3.1.1

Before proceeding to the next step, we checked whether there were still any prominent cycles present. This is because it is possible that not all cyclical components are removed by the previous step due to the usage of a limited number of Fourier frequencies and the main frequencies masking smaller ones.
In order to do this, we took the signal divided by the estimated first cyclic component Y i m / C ~ 1 , i m from step 2 and divided it by its long-term trend T ~ i m , once again estimated by a Gaussian low-pass filter. We then plotted the Auto-Correlation Function (ACF) of Y i m / C ~ 1 , i m   T ~ i m and visually identified any periodicities. The major frequencies could then be identified using the Fourier spectrum. When periodic patterns were still visible in the ACF plot, we applied the same steps 1 and 2 detailed in this section to the signal Y i m / C ~ 1 , i m to obtain the second cyclic component as follows:
C ~ 2 , i m = A 2,1 m + k = 2 n 2 m A 2 , k m c o s ( 2 π ν 2 , k m Δ t m i + ϕ 2 , k m )
This process was repeated until no pattern was visible on the ACF plot for the detrended signal divided by all cyclic components Y i m / T ~ i m j = 1 P m C j , i m , where P m denotes the total number of cyclic components used.

3.1.5. Modelling the Combined Long-Term Trend and Short-Term Variability Component—Step 4 in Section 3.1.1

Once all cyclical components were estimated, we divided the original signal Y i m by j = 1 P m C ~ j , i m to obtain the combined long-term trend T i m and short-term I i m variability component, or equivalently, the monthly electricity demand time series detrended from cyclical patterns,
M i m = Y i m / j = 1 P m C ~ j , i m
This signal may be influenced by external factors, including fluctuations in seasonality and the economy. To predict the time evolution of M i m , we proposed a neural network model, which includes independent variables, such as average temperature over the UK, housing energy efficiency, and percentage of renewables used in the energy generation, see Table 4.
We gathered the value of l independent variables V i m , 1 , V i m , 2 , …, V i m , l at timepoint i and the values of long-term trend and short-term variability component between timepoints i 1 and i w , for w timesteps in the past, creating a sparse array of size ( l + 1 )   × ( w + 1 ) organised as shown in the following matrix.
V i m , 1 0 0 V i m , 2 0 0 V i m , l 0 0 0 M i 1 m M i w m
Note that all independent variables are resampled monthly to align with the sampling of the signal.
This array is then input into a neural network, which predicts the value M i m of the combined long-term trend and short-term variability component at timepoint i . The underlying assumption is that by knowing the conditions at timepoint i of the independent variables and the behaviour of the electricity demand over the previous w months, we can predict the electricity demand at timepoint i . We first used actual data for the independent variables to build a descriptive model of electricity demand data (Section 4.1), and then discuss a modification of the model that only uses past electricity demand data to provide a predictive model of electricity demand (Section 4.2).
The selected neural network is a multi-layer perceptron (MLP) consisting of two hidden layers with 18 and 40 neurons each, including a normalisation layer and a dropout layer; see Figure 12. We settled for this network structure following a sensitivity study testing different network architectures (the results are detailed in Appendix B.2). The output of the MLP gives the estimate for M i m , denoted as M ~ i m .
A sensitivity study was conducted on the inputs to determine the combination of independent variables and the window length for historical data that yields the best predictions (the results are detailed in Appendix B.1).
The optimised input includes a 13-month window for historical data and the following seven independent variables:
  • Real GDP.
  • Average temperature.
  • Percentage renewables.
  • Electricity CPI.
  • Housing efficiency.
  • Number of new builds.
  • Population growth.
This leads to the 8 × 14 input matrix shown in Figure 12.
The sensitivity study showed that normalising both the independent variables and the long-term trend and short-term variability components of the signal improved prediction quality compared to other pre-processing techniques. This leads to defining two important constants: the mean and standard deviation for the combined long-term trend and short-term variability component over the training and validation period (defined in the following paragraph). The output from the neural network was then multiplied by the standard deviation, and the mean was added to obtain a prediction of the combined long-term trend and short-term variability component.
The data was divided into training, validation, and test sets, comprising approximately 62%, 15%, and 23% of the data, as follows:
  • 2009–2016: Training.
  • 2017–2018: Validation.
  • 2019–2021: Testing.
To avoid extrapolation, the model excluded the years 2022–2023 because some independent variables were only available until December 2021 at the time of our studies.
The validation dataset was used to validate the neural network model of the combined long-term trend and short-term variability component. Such data is not required to validate the model for the cyclic components. Hence, the whole period covering training and validation was used to optimise the estimation of the cyclic components of the signal.

3.1.6. Overall Prediction of Electricity Demand—Step 5 in Section 3.1.1

Finally, we computed the overall prediction of monthly electricity demand by multiplying the modelled cyclical components with the combined predicted long-term trend and short-term variability component, i.e.,
Y ~ i m = j = 1 P m C ~ j , i m M ~ i m

3.2. Prediction of Hourly Electricity Demand

The hourly electricity demand prediction model is a refinement of the previously introduced decomposition model (Section 3.1), scaled up to weekly resolution and multiplied by the typical weekly pattern at hourly resolution. This requires the decomposition model to predict the average hourly demand for the predicted week, which, when multiplied by the typical weekly pattern at hourly resolution, results in predicted hourly demand.
We use the notation Y ¯ w to represent the average hourly demand over one week. The typical weekly pattern is an additional cyclic component that enters the overall model as another factor. However, the estimation of the typical weekly pattern is based on averaging rather than Fourier analysis, unlike the other cyclic component introduced in steps 2–3 in Section 3.1.1. In this section, we introduced the modifications to the basic approach (Section 3.1) and the addition of the weekly pattern.
We first construct the total hourly electricity demand time series
Y i h = Y 2 i 1 r + Y 2 i r
where i = 1 ,   ,   N h , and N h = N r / 2 denotes the total number of hours considered. We constructed the time series for the average hourly demand for the week j (or weekly electricity demand, for short) Y ¯ j w as follows:
Y ¯ 1 w = 1 168 i = 1 168 Y i h Y ¯ 2 w = 1 168 i = 169 337 Y i h
etc. (notice that one week has 168 h), and j = 1 ,   ,   N w , where N w = N h / 168 is the total number of weeks included in our time series of electricity demand. Then, we modelled the weekly electricity demand as follows:
Y ¯ j w = T j w k = 1 P w C k , j w I j w
with j = 1 ,   ,   N w . Here, analogously to Section 3.1, we assumed that the weekly electricity demand signal can be factorised into a long-term trend component T j w , a number P w of cyclic components C k , j w , and a short-term variability component I j w .
As before, the long-term trend T j w and short-term variability I j w components are combined as M i w and modelled using the neural network architecture described in Figure 12. For simplicity and to avoid extended run time for the neural network predictions, we resampled the signal M i w monthly to obtain M i m and re-use the neural network exactly as set up in Section 3.1. The long-term trend of our weekly electricity demand is adequately captured by this approach, and we observed that the short-term variabilities are smoothed a little but not significantly.
After we obtained a prediction for the weekly electricity demand Y ¯ j w , we could predict the hourly electricity demand by multiplying Y ¯ j w for each specific week j with the scaled (mean value of 1) hourly electricity demand over one week.
To obtain the scaled hourly electricity demand over a week, we chose the year 2013, as it was a typical year in terms of electricity demand (see discussion in Section 4.3). For this calculation and the decomposition model later, it is convenient to structure the hourly electricity demand Y i h into a matrix with elements Y i , j h where i indicates the hour of the week, with i = 1 ,   ,   168 , and j indicates the week of the year, with j = 1 ,   ,   52 . We then divided Y i , j h by the corresponding average weekly electricity demand value Y ¯ j w , thereby obtaining a rescaled time series of electricity demand with hourly resolution for 2013 with an average equal to 1, i.e.,
Z i , j h = Y i , j h / Y ¯ j w
where i = 1 , , 168 and j = 1 , , 52 .
Finally, we averaged Z i , j h over all weeks in 2013, i.e.,
Z ¯ i h = 1 52 j = 1 52 Z i , j h
with i = 1 , , 168 .
Hence, Z ¯ i h represents the scaled hourly electricity demand over one week for a typical year, which we called the weekly pattern. Lastly, we predicted the electricity demand with hourly resolution Y ~ i , j h as follows:
Y ~ i , j h = Z ¯ i h Y ¯ ~ j w
where Y ¯ ~ j w is the multiplicative decomposition model estimate of the weekly electricity demand with j = 1 , ,   N w , where N w indicates the total number of weeks in the time series, and index i = 1 , ,   168 is the index for the 168 h within week j . Since both Z ¯ i h and Y ¯ ~ j w time series need to have the same hourly resolution for the multiplication to work; we resampled the time series where required.

4. Results from the Multiplicative Decomposition Method

We first present the results obtained for the monthly electricity demand model (Section 4.1 and Section 4.2), and then we show the results for the hourly electricity demand model (Section 4.3 and Section 4.4). In Section 4.1 and Section 4.3, we present descriptive models for monthly and hourly electricity demand, respectively, that use independent variables as input to the long-trend and short-term variability components of the model. In Section 4.2 and Section 4.4, we present long-term predictive models that only use past electricity demand data as input by using a modified neural network that uses recursive inputs.

4.1. Descriptive Model with Independent Variables for Monthly Data

4.1.1. Detrending the Monthly Electricity Demand Data—Step 1 in Section 3.1.1

We divided the signal Y i m by the estimated trend T ~ i m obtained with a Gaussian low-pass filter with kernel of size 12, and rescaled each year by its average. Figure 13 shows the scaled detrended signal.

4.1.2. Estimating the Cyclic Components—Steps 2–3 in Section 3.1.1

First Cyclic Component
We computed the Fourier spectrum (Figure 14) of the signal shown in Figure 13. The Fourier spectrum shows a fundamental frequency at 3.17 × 10 8 Hz, which corresponds to a period of 12 months, and higher frequency harmonics at periods of 6, 4, 3, and 2.4 months. These observations are consistent with the peak frequencies identified in the monthly electricity demand for Spain [7].
Table 6 shows the first 10 peak frequencies sorted by amplitude, which are incorporated one by one into the cyclic model until the MAPE reaches a minimum.
When evaluating the cyclic model over the training and validation period, it shows a shift compared to the detrended, scaled signal (Figure 15).
To correct the shift, we calculated the MAPE between the modelled and the actual detrended and rescaled signal for different time lags, initially setting the number of Fourier components to five arbitrarily. The MAPE reached a minimum at a lag of 1 month, with the minima repeating periodically after 12 months, as shown in Figure 16. For simplicity, we chose the time lag as 1 month.
We could now optimise the model by setting the time lag to 1 month between the predictions and the signal and changing the number of Fourier components. Figure 17 shows that the error reaches a minimum when the model contains the six largest Fourier components from Table 6.
The first cyclic model (lag of 1 month and six Fourier components) produces an MAPE of 0.15% and MASE of 0.46% over the test period 2019–2021 (Figure 8).
Second Cyclic Component
The next step is to remove the first cyclic component from the signal, detrend the resulting signal, and check whether there are any prominent periodic patterns still present; see Figure 9. Hence, we repeated all the steps above to identify any residual cycles.
The peak frequencies detected by the second Fourier analysis are detailed in Table 7, showing a cycle with a period of 13.3 months and shorter seasonal components. The top frequency here has an amplitude one order of magnitude lower than the top frequency detected in the first cyclic analysis.
When evaluating the second cyclic model over the training period, we found a shift of 13 months (Figure 18) compared to the detrended, scaled signal.
With a time lag of 13 months between the input signal and the target predictions, we optimised the model by varying the number of Fourier components. As shown in Figure 19, the prediction error reaches a local minimum when the model includes the first 5, 9, and 14 Fourier components listed in Table 7. A model with five components underfits the signal, while a better MAPE is obtained with nine components. Selecting 14 components overfits the signal, since it produces better results for the training period but worse for the testing period. Hence, we selected nine components for the second cyclic model.
The second cyclic model produces an MAPE of 0.096% and an MASE of 1.32% over the test period 2019–2021. Figure 20 shows that most of the cyclic behaviour in the original signal Y i m has been captured by the first cyclic model. The second cyclic model only brings a marginal improvement.

4.1.3. Estimating the Combined Long-Term Trend and Short-Term Variability Component—Step 4 in Section 3.1.1

With both cyclical components removed from the signal, we then had the long-term trend and short-term variability components left, which we modelled using the neural network, as detailed in Section 3.1.5.
The neural network predicts the combined long-term trend and short-term variability component for the timepoint i , using as input the independent variable values at the same timepoint i and historical data for electricity demand between i 1 and i w . Note that our aim here is to build the model that best describes the electricity demand by using actual data of the independent variables to predict electricity demand one month ahead.
Figure 10 shows the fit of the neural network model to the scaled signal detrended from cyclical components over the training and validation periods, 2009–2018. The training parameters are summarised in Table A7 in Appendix B.3. Due to the nature of the MAPE calculation, with the error between the predicted and actual values divided by the actual value, it shows large errors when the values are close to zero. Here the MAPE is 210.87% for the neural network predictions over the test period 2019–2021. The MASE of 0.83% is, however, more indicative of the goodness of fit. We included the convergence curve of the loss function obtained for both the training and the validation sets in Figure A7 in Appendix B.3.

4.1.4. Overall Model—Step 5 in Section 3.1.1

Figure 21 shows the MAPE values for the final predictions of the multiplicative decomposition model over the training (2008–2016), validation (2017–2018), and testing period (2019–2021). An MAPE of 5.29% for 2020 is an excellent result given the anomaly introduced in the electricity demand by the COVID-19 pandemic.
Note that the MAPE of each component of the overall model, as seen in Section 4.1.2 and Section 4.1.3, do not translate to the MAPE for the overall model. The bulk of the overall prediction is carried by the first cyclic component and the model for the long-term trend and short-term variability components. The second cyclic component improved marginally the overall predictions.
The model tends to overpredict the signal, as shown by the scatter plot in Figure 22. This would result in oversizing the electricity network, which is a desired outcome: a deficit of electricity results in blackouts, while a surplus of electricity could be stored or exported.
The residuals are considered random (auto-correlation test = 0.75 > 0.05, the null hypothesis that the data are uncorrelated is not rejected at the 5 percent level based on the Ljung–Box test), confirming that the model captures all the key features of the signal.

4.2. Long-Term Predictive Model Without Independent Variables for Monthly Data

The model for the combined long-term trend and short-term variability component in Section 4.1 is limited to one-month-ahead prediction. However, it is well optimised, achieving an MAPE of 4.37% over the testing period 2019–2021. In this section, we leverage the optimised one-month-ahead prediction model by applying a recursive approach to generate long-term forecasts. In this scenario, the independent variables would require their own long-term predictive models, rather than relying on the actual observed data used in Section 4.1. While developing such models is beyond the scope of this study, we highlight the potential benefits of this approach and discuss it further in Section 5.

4.2.1. Short-Term Predictive Model, Monthly Resolution

Without the independent variables, the input to the neural network becomes a one-dimensional array
( M i 1 m M i w m )
The architecture of the neural network remains identical to Figure 12, with the difference that now the input is an array of size {11}, as is the normalisation layer. As shown in the sensitivity study (see Appendix B.1), the optimal window size w for historical data, when no independent variables are included, is 11 months.

4.2.2. Long-Term Predictive Model 1, Monthly Resolution

We introduced a recursive function, illustrated in Figure 23, that appends the output from the neural network to its input, creating an array of size 12. Then, the function drops the first element of the array to maintain an array size of 11, which is input into the neural network to predict the next step. Over the long term, the input to predict the long-term trend and short-term variability components at time step i includes only the outputs from previous time steps between i 1 and i w .
The training parameters for this long-term predictive model 1 are summarised in Table A7 in Appendix B.3. We included the convergence curve of the loss function obtained for both the training and the validation sets in Figure A8 in Appendix B.3.

4.2.3. Long-Term Predictive Model 2, Monthly Resolution

We tested a modified neural network (Figure 24), which includes an additional normalisation layer and a scaling layer before the output layer. Figure 25 shows the recursive predictions using the previous neural network (Figure 12) with an input array size of 11 and the modified neural network (Figure 24).
To assess the difference between the different neural network models, we needed to consider the overall model. Table 8 shows that using the long-term predictive model 2, described in Figure 24, improves the long-term electricity demand predictions compared to the long-term predictive model 1, described in Figure 12. The results with the short-term predictive model, i.e., no recursion, are also shown for reference.

4.3. Descriptive Model with Independent Variables for Hourly Data

In this section, we applied the same process as in Section 4.1 to hourly data, i.e., including actual independent variables without recursion.
The weekly time series Y ¯ j w with j = 1 , ,   N w was processed through the method described in Section 3.2. The trend was extracted via the Gaussian low-pass filter with a kernel of radius 52 (weeks).
Table 9 summarises the characteristics of the first and second cyclic component models.
As mentioned in Section 3.2, we chose 2013 as a typical year to obtain the scaled hourly electricity demand over a week. Figure 26 shows that the hourly pattern of electricity over a week, scaled to be centred around 1, is stable between the years 2009 and 2023. All years are within ±5% of the pattern for 2013.
The third cyclic component model is simply the weekly pattern for 2013 repeated over, as shown in Figure 27.
The predictions for the first two cyclic components have a weekly resolution, the weekly pattern has a resolution of hours, and finally, the predictions for the combined long-term trend and short-term variability component have a monthly resolution. All time series were resampled hourly to be able to perform the multiplication at each timepoint.
Figure 28 shows the predictions from the proposed model compared to the hourly total of the UK electricity demand data, with Figure 29 showing a zoom on one week, Monday to Sunday, in August 2019. The MAPE value for the overall model was 7.5% for the testing period 2009–2021.
The scatter plot (see Figure 30) of predictions versus actual values shows a slight tendency of the model to overpredict the electricity demand.

4.4. Long-Term Predictive Model Without Independent Variables for Hourly Data

In order to derive true long-term predictions for the hourly electricity demand, we remove the independent variables from the input to the neural network and apply the recursive function, as described in Figure 23.
As shown in Table 10, the original neural network, described in Figure 12, gives marginally better predictions than the modified neural network, Figure 24, introduced for the monthly electricity demand long-term predictions. The training parameters for this long-term predictive model are summarised in Table A7 in Appendix B.3. We included the convergence curve of the loss function obtained for both the training and the validation sets in Figure A10 in Appendix B.3.

5. Discussion

In this paper, we have proposed a novel multiplicative decomposition model to predict the long-term UK electricity demand at both monthly and hourly resolution. The model assumes that electricity demand can be described as the product of cyclic components, including yearly, weekly, and daily cycles, and a long-term trend and short-term variability component. We model the cyclic components based on the Fourier analysis of the detrended signal, and we apply a neural network model to describe the combined long-term trend and short-term variability component.
We have successfully implemented an approach similar to the model of cyclic components in fashion demand [8]. We have also efficiently applied a neural network-based prediction for the combined long-term trend and short-term variability components, a notably simpler approach to the implementation of the Autoregressive Distributed Lag model used by Hunt et al. [11].
Our model achieves highly accurate results for long-term predictions with an MAPE of 4.16% for the period 2019–2021 with a monthly resolution, and an MAPE of 8.62% for the same period with an hourly resolution. Moreover, our model is highly flexible and accurate: when increasing the forecasting period from monthly to hourly, the model’s resolution increases by approximately 730× while the model error only increases by 2.1×.
Based on our review, other papers focus on descriptive modelling rather than long-term prediction. As such, our comparison is restricted to the descriptive component of our approach (Section 4.1), which yielded an MAPE of 3.47% over a 3-year horizon. This may be compared with the Spanish electricity demand model [7], which reported an MAPE of 1.74% over 5-year predictions.
We compared our proposed model with a traditional SARIMA model, which performs worse, achieving long-term predictions on monthly data with an MAPE of 7.11% for the period 2019–2021 (Figure A13 in Appendix C.2). The results from the SARIMA model predictions for hourly data are substantially poorer, obtaining an MAPE of 42.57% for the same period. Figure A15 in Appendix C.3 shows the SARIMA model predictions for hourly data, which are unable to capture the dynamics of hourly electricity demand.
The novelty of our model lies in the provision of a long-term prediction of electricity demand at hourly resolution, achieving highly accurate results. However, our model also presents some limitations. It is noteworthy that the long-term predictions did not include any exogenous variables. Modelled data for those exogenous variables could be included to improve the model’s performance, as we showed that including those in the descriptive model leads to a 1.4% improvement in MAPE for the monthly data.
Models for the exogenous variables could also consider different scenarios to study the impact of different factors on electricity demand, such as an increase in housing energy efficiency following a government policy, different renewable energy penetration rates, or edge-case scenarios in UK temperatures due to climate change.
Our proposed model could be further improved by specifically modelling the disruption in electricity demand caused by external major events, such as the COVID-19 pandemic. An intervention model with a pulse function or step function that estimates the impact of lockdowns on the electricity demand could be integrated as input to the neural network. In fact, observation of hourly demand data during the Christmas holidays allowed us to estimate a drop of 18% in electricity demand due to business closures, as detailed in Appendix D.
Finally, applying the model to different segments of electricity demand, such as by region or by industry, or to adjacent domains such as natural gas demand forecasting, could provide further insights into its adaptability and broader applicability.
Overall, this paper offers a promising approach to improving National Grid’s ability to predict UK electricity demand with greater resolution than previously achieved. The model could contribute to ongoing efforts to plan and shape the future electricity grid, particularly in supporting decisions around future electricity generation capacity.

Author Contributions

Conceptualisation, M.B.; data curation, M.B.; formal analysis, M.B.; methodology, M.B.; supervision, M.C.R. and E.U.; writing—original draft, M.B.; writing—review and editing, M.C.R. and E.U. All authors have read and agreed to the published version of the manuscript.

Funding

This research received no external funding.

Data Availability Statement

The data presented in this study are openly available in GitHub at https://github.com/mariebaillon/UK_electricity_demand.

Acknowledgments

The work was carried out as part of a Master of Science qualification at the University of Aberdeen. I am forever grateful to Derek Dalton and Alejandro Jeketo for their thorough proofreading and their encouragement. The authors would like to thank Reviewer 2 of the manuscript, who provided insightful comments and suggestions for how the model could be further enhanced in the future.

Conflicts of Interest

The authors declare no conflicts of interest.

Appendix A. Supporting Information

Appendix A.1. Spearman’s Correlation Coefficient Between Independent Variables

Table A1 shows the results of the Spearman’s correlation between the independent variables defined in Table 4.
Table A1. Values of Spearman’s correlation coefficient between independent variables. The underlined numbers indicate statistically significant results with a significance level of 5%.
Table A1. Values of Spearman’s correlation coefficient between independent variables. The underlined numbers indicate statistically significant results with a significance level of 5%.
A—Bid price1--------
B—Electricity CPI−0.5551-------
C—Percentage Renewables−0.4820.9451------
D—Average temperature−0.5270.8090.8451-----
E—Real GDP−0.5720.8270.8910.6821----
F—Population growth0.555−0.891−0.891−0.745−0.7451---
G—Gas demand0.5450.6−0.464−0.655−0.4270.5181--
H—Number of new builds−0.60.9550.9550.8090.809−0.936−0.5641-
I—Housing efficiency0.2520.6400.6500.3880.491−0.827−0.1590.7151
ABCDEFGHI

Appendix A.2. Selection of a Smoothing Model

To extract the long-term trend from the signal, we tested different smoothing models:
  • Arithmetic mean function with 12-month average.
  • Arithmetic mean function with 24-month average.
  • Low-pass Gaussian filter with a kernel of size 12.
  • Low-pass Gaussian filter with a kernel of size 24.
  • Linearly decreasing weighted average function.
To select the best smoothing model, we followed the method developed in [7], which consists of comparing the goodness of fit ( R 2 ) and a smoothness factor ( S ) for each method.
R 2 varies between 0 and 1, with a value of 1 corresponding to a perfect fit.
The smaller the smoothness factor, the better, with a zero value for the linear function.
The R 2 coefficient is defined as follows:
R 2 = 1 i = 1 N ( S i T R i ) 2 i = 1 N ( S i S ^ ) 2
with
  • i : Time step variable.
  • S i : Signal value.
  • T R i : Smoothed value.
  • S ^ : Mean of the signal per 12-month period.
  • N : Number of data points.
The smoothness factor S is defined as follows:
S = 1 N i = 1 N ( Δ 2 T R i ) 2
with
  • Δ 2 T R i : Discrete second derivative of the smoothed signal at i
  • We followed the definition of the discrete second derivative in ([33], p. 177).
Table A2 shows the values of the goodness of fit and the smoothness factor for each model. We select the Gaussian low-pass filter as it has the highest R 2 value and a good smoothness factor.
Table A2. Evaluation of different smoothing models.
Table A2. Evaluation of different smoothing models.
MethodR SquaredSmoothness Factor
Arithmetic mean 120.6040.0035
Arithmetic mean 240.5940.00155
Gaussian Low-Pass filter with kernel of size 120.6130.00079
Gaussian Low-Pass filter with kernel of size 240.6070.0004
Linearly decreasing weights0.5840.00052

Appendix A.3. Discrete Fourier Transform

The cyclic components are a function of time. The Discrete Fourier Transform for one variable is used to represent the detrended signal in the frequency domain:
F u = t = 0 N 1 f t e j 2 π u t / N u = 0 , 1 , 2 , , N 1
where
  • t : Time variable.
  • u : Frequency variable.
  • f t : Value of detrended signal at t .
  • F u : Fourier component at u .

Appendix A.4. Measure of Forecast Accuracy

In this study, we propose three measures of accuracy: the mean absolute percentage error ( M A P E ), the Symmetric Mean Absolute Percentage Error ( s M A P E ) and the mean absolute scaled error ( M A S E ), with equations detailed below.
e t = A c t u a l t P r e d i c t e d t p t = 100 e t A c t u a l t M A P E = m e a n ( p t )
s M A P E = m e a n ( 2 100 e t A c t u a l t + P r e d i c t e d t )
q t = n 1 e t k = 2 n | A c t u a l k A c t u a l k 1 | M A S E = m e a n ( q t )
M A P E is widely used to compare model accuracy and has been used in most of the papers referenced in this study. However, M A P E puts a heavier penalty on overprediction errors than on underprediction errors, which the s M A P E tries to correct. Both the M A P E and s M A P E measures also involve division by a number close to zero when the observed values are small, which we encountered when assessing sub-models in this study.
This leads to the use of M A S E , which scales the mean absolute error of the model with the mean absolute error of a naive model (i.e., one-step-ahead forecast using the previous value). An M A S E value less than 1 indicates better performance than the naive model, while a value greater than 1 indicates worse performance.

Appendix B. Neural Network

The neural network model predicts the long-term trend and short-term variability components after all the cyclical components have been removed from the signal.

Appendix B.1. Sensitivity Study on Inputs

As described in [7], a simple network such as a multi-layer perceptron (MLP) can be used to model the long-term trend of the signal.
An MLP is a feedforward network with one or several hidden layers, where each neuron performs a weighted sum of its inputs, which is then processed through an activation function. Here we chose the logistic sigmoid function as the activation function. The neural network learns to fit the signal by adjusting the weights in the network. Mathematica uses the backpropagation algorithm and chooses the best gradient-based optimisation strategies to minimise the error between the actual and desired response at any training step.
In this study, we used a neural network to model both the long-term trend and the short-term variability components of the signal.
Before optimising the network with respect to different layer architectures and different numbers of neurons per layer, we had to decide on the number of independent variables to consider, on the window length for historical data, i.e., the number of months of previous electricity demand data, and on the pre-processing method of these inputs.
The purpose of this section is to answer these questions through a sensitivity study.
Using an MLP with two hidden layers and one output layer (see Figure A1) and a max number of training rounds set to 1000, we obtained a prediction for the test data. We then measured the MAPE and MASE between the prediction and the signal.
Figure A1. Neural network used for the sensitivity study, shown with an input of size {8,14}. The input size varies through the sensitivity study as we tested different groups of variables and different window lengths for the historical data.
Figure A1. Neural network used for the sensitivity study, shown with an input of size {8,14}. The input size varies through the sensitivity study as we tested different groups of variables and different window lengths for the historical data.
Analytics 04 00027 g0a1
Table A3 details the groups of independent variables tested. The grouping is based on the correlation coefficient of each variable with the electricity demand data and also considers the connectivity between the variables, as detailed in Section 2.3. The independent variables are grouped so as to avoid the effect of confounding variables when considered one by one.
We also tested with no independent variable.
Table A3. Groups of variables selected for sensitivity study.
Table A3. Groups of variables selected for sensitivity study.
Group Name
Variables 1Variables 2Variables 3Variables 4No Var
Percentage renewables
Population growth
Real GDP
Number of new builds
Electricity consumer price index
Average temperature
Dwelling efficiency
Bid price
Gas demand
For the historical demand data, the parameter is the number of previous months considered. We tested a 2-, 3-, 4-, 6-, 11-, 12-, 13-, and 14-month window.
Both the independent variables and the historical demand data have been normalised prior to inputting the data into the network. With the group “Variables 3”, we then reran the predictions having differenced and then normalised all the inputs, and separately we also reran the predictions having shuffled the order of the variables within the group.
For each group of variables, we identified the window length that gives the lowest MAPE and MASE values. The MAPE and MASE values at this stage are only used for relative comparison of each input; detailed values are included in Table A4.
Table A4. MASE and MAPE values for the predictions of the neural network for different inputs. The optimal window length for each setup is highlighted in bold numbers.
Table A4. MASE and MAPE values for the predictions of the neural network for different inputs. The optimal window length for each setup is highlighted in bold numbers.
GroupMeasureWindow Length for Historical Data
0234611121314
Variables 1MASE 1.371.841.891.401.510.961.30
MAPE 208.40323.61338.95216.47239.71125.29195.46
Variables 2MASE 1.481.331.241.741.181.571.41
MAPE 232.67200.02181.64298.99168.57255.76219.49
Variables 3MASE 1.691.291.641.131.461.551.170.901.84
MAPE284.77189.63273.50159.02228.54251.75170.30113.33325.35
Variables 3 shuffledMASE 1.291.641.131.461.551.170.901.84
MAPE 190.43273.41158.92228.55251.78170.62113.49325.33
Variables 3 differencingMASE 0.520.510.510.560.580.520.500.47
MAPE 260.37266.29178.26208.37168.86199.41156.64119.84
Variables 4MASE 1.341.221.341.341.861.141.71
MAPE 202.43175.95201.76203.67331.46162.83290.18
No VarMASE 1.621.441.471.821.321.531.65
MAPE 265.75226.23231.74318.53197.06247.24275.67
Figure A2 illustrates the variation in MASE values for the different inputs.
Figure A2. MASE value for the predictions of the neural network for different inputs. The minimum error for each group of variables occurs with 11 to 14 months of historical data.
Figure A2. MASE value for the predictions of the neural network for different inputs. The minimum error for each group of variables occurs with 11 to 14 months of historical data.
Analytics 04 00027 g0a2
For each of the best combinations of variable group and window length, i.e., for the minimum MASE, we then ran the overall prediction, i.e., the trend and irregularities predictions were multiplied by predictions from the cyclic models. We obtained an MAPE and MASE value, shown in Table A5, for each of the testing years and one for the overall testing period. The best combination of inputs was the group “Variables 3” with a 13-month window for historical data, and the inputs were normalised only.
Table A5. Accuracy of the overall model for different inputs in the neural network.
Table A5. Accuracy of the overall model for different inputs in the neural network.
MAPE 2019MAPE 2020MAPE 2021Overall MAPEOverall MASE
Variables 1,
12 months
2.086.533.824.150.70
Variables 2,
11 months
2.468.014.805.090.86
Variables 3,
13 months
2.176.013.363.850.65
Variables 3,
differencing,
14 months
3.214.345.904.480.80
Variables 4,
12 months
2.687.744.354.920.83
No Var,
11 months
2.828.765.595.720.96

Appendix B.2. Testing Different Network Architectures

The MLP model used in the sensitivity study (Figure A1) can be improved first by trying different numbers of hidden layers with different numbers of neurons each. The MLP shown in Figure A3 has improved MASE and MAPE values.
Figure A3. MLP neural network.
Figure A3. MLP neural network.
Analytics 04 00027 g0a3
Working with Chat GPT [34], we tried the following steps to improve from the simple MLP architecture:
  • Dropout Layer: Helps prevent overfitting by randomly setting a fraction of input units to 0 at each update during training time.
  • Batch Normalisation: Normalises the output of a previous activation layer by subtracting the batch mean and dividing by the batch standard deviation.
  • Additional Hidden Layers: Increasing the depth of your network can allow it to capture more complex patterns in the data.
  • ReLU Activation Function: Often used instead of sigmoid due to better performance and faster convergence.
The improved network is shown in Figure A4.
Figure A4. Improved MLP neural network.
Figure A4. Improved MLP neural network.
Analytics 04 00027 g0a4
The next type of network considered is a convolutional neural network. It is traditionally used with images to detect lines, patterns or edges, allowing image classification. Applied to time series, it can capture patterns or relationships within the time series data. The convolutional layer acts as a preprocessing of the inputs before feeding the information into a fully connected neural network.
By trial and error, we settled on the architecture shown in Figure A5.
Figure A5. Convolutional neural network (CNN).
Figure A5. Convolutional neural network (CNN).
Analytics 04 00027 g0a5
Finally, we looked at the Long Short-Term Memory (LSTM) network for its capability to learn long-term dependencies. Taking inspiration from Mathematica Tech Note on Sequence Learning and NLP with neural networks [35], we tried different combinations of layers with LSTM and retained the network shown in Figure A6.
Figure A6. LSTM neural network.
Figure A6. LSTM neural network.
Analytics 04 00027 g0a6
For each of these network architectures, we compared the MAPE and MASE values, shown in Table A6, for each of the testing years and for the overall testing period. The neural network contributing to the best overall predictions is the improved MLP network (Figure A4).
Table A6. Accuracy of the overall model for different architectures of the neural network.
Table A6. Accuracy of the overall model for different architectures of the neural network.
MAPE 2019MAPE 2020MAPE 2021Overall MAPEOverall MASE
MLP (Figure A3)2.265.633.073.660.63
MLP improved (Figure A4)1.694.833.283.270.56
CNN (Figure A5)2.626.131.943.560.61
LSTM (Figure A6)2.247.984.544.920.83

Appendix B.3. Neural Network Parameters

We used the Mathematica function ‘NetTrain’ [36], which trains the specified neural net with the given input and minimises the discrepancy between the given output and the actual output of the net using an automatically chosen loss function. The Wolfram Language automatically tries to pick the best method for a particular computation. Table A7 shows the actual parameters used. ADAM is a stochastic gradient descent using an adaptive learning rate that is invariant to diagonal rescaling of the gradients.
Table A7. Summary of the training parameters of the neural network.
Table A7. Summary of the training parameters of the neural network.
Short-Term Predictive Model, Monthly and Hourly Resolution Long-Term Predictive Model, Monthly ResolutionLong-Term Predictive Model, Hourly Resolution
Learning rate0.0010.0010.001
Batch size616464
Number of epochs10,00071127591
Method“ADAM”, “Beta1”→0.9, “Beta2”→0.999,
“Epsilon”→1/100,000, “GradientClipping”→None,
“L2Regularization”→None, “LearningRate”→Automatic,
“LearningRateSchedule”→None, “WeightClipping”→None
Figure A7, Figure A8, Figure A9 and Figure A10 show the convergence curve of the loss function for the training and validation sets during the evaluation of the short-term/long-term models on monthly/hourly data.
Figure A7. Convergence curve of the loss function for the training (orange line) and validation (blue line) sets during the evaluation of the short-term model on monthly data over 10,000 epochs.
Figure A7. Convergence curve of the loss function for the training (orange line) and validation (blue line) sets during the evaluation of the short-term model on monthly data over 10,000 epochs.
Analytics 04 00027 g0a7
Figure A8. Convergence curve of the loss function for the training (orange line) and validation (blue line) sets during the evaluation of the long-term model on monthly data over 7112 epochs.
Figure A8. Convergence curve of the loss function for the training (orange line) and validation (blue line) sets during the evaluation of the long-term model on monthly data over 7112 epochs.
Analytics 04 00027 g0a8
Figure A9. Convergence curve of the loss function for the training (orange line) and validation (blue line) sets during the evaluation of the short-term model on hourly data over 10,000 epochs.
Figure A9. Convergence curve of the loss function for the training (orange line) and validation (blue line) sets during the evaluation of the short-term model on hourly data over 10,000 epochs.
Analytics 04 00027 g0a9
Figure A10. Convergence curve of the loss function for the training (orange line) and validation (blue line) sets during the evaluation of the long-term model on hourly data over 7591 epochs.
Figure A10. Convergence curve of the loss function for the training (orange line) and validation (blue line) sets during the evaluation of the long-term model on hourly data over 7591 epochs.
Analytics 04 00027 g0a10

Appendix C. Comparison with SARIMA Model

We compared the merits of the multiplicative decomposition method with a Seasonal Auto-Regressive Integrated Moving Average (SARIMA) model.
SARIMA [37] is a stochastic model that traditionally uses seasonal difference, in our case, a 12-month differencing, followed by traditional linear modelling.

Appendix C.1. SARIMA Model Explained

The Seasonal Auto-Regressive Integrated Moving Average (SARIMA) model is suited to modelling complex time series with trend and cyclical components. The core principle, similar to our proposed model, is to distinguish the seasonal and non-seasonal components:
S A R I M A p , d , q ( P , D , Q ) S
where
  • p , d , q : Non-seasonal parameters.
  • ( P , D , Q ) : Seasonal parameters.
  • S : Length of the seasonal cycle.
With this definition, we can see that a SARIMA model is a combination of two Auto-Regressive Integrated Moving Average (ARIMA) models. ARIMA models are, in turn, a combination of AR and MA models defined as follows [37]:
  • Auto-Regressive: AR(p), the value of the signal at t is determined by its own past p values plus some random noise ϵ with a variance ν :
x t = a 1 x t 1 + a 2 x t 2 + . . . + a p x ( t p ) + ϵ ν ( t )
  • Moving Average: MA(q), the value of the signal at t is affected by the past q values of the forecast error plus some random noise ϵ with a variance ν :
x t = b 1 ϵ t 1 + b 2 ϵ t 2 + . . . + b q ϵ ( t q ) + ϵ ν ( t )
  • Auto-Regressive Integrated Moving Average: ARIMA(p, d, q), the signal exhibits a trend of order d, d = 1 represents a linear trend. By taking the differences between successive values, the treated signal can now be modelled using an ARMA(p, q) process.

Appendix C.2. Results from Baseline SARIMA Model on Monthly Data

In this section, we modelled the signal using a SARIMA model. We used the Auto-Correlation Function (ACF) and the Partial Auto-correlation Function (PACF) plots to understand the nature of the signal:
  • By taking successive differences in the data, the signal becomes stationary. This indicates that an integrated model of order 1 would be a good model for the data. Taking the successive difference in the data 12 months apart also results in a stationary time series. A seasonal model of period 12 months would also be a suitable model for the data. Both the integrated and seasonal components may not be required in the model.
  • From the ACF plot on the signal, Figure A11, we note that we have a strong seasonal pattern repeating at 12 lags (month).
  • The PACF plot on the signal, Figure A12, shows potentially an order 2 on the auto-regressive model with spikes at lag 1 and lag 3. The rapid decay from lag 1 to lag 2 is an indication that there is no moving average component.
Figure A11. Auto-correlation factor (ACF) for the signal at different time lags.
Figure A11. Auto-correlation factor (ACF) for the signal at different time lags.
Analytics 04 00027 g0a11
Figure A12. Partial auto-correlation factor (PACF) for the signal at different time lags.
Figure A12. Partial auto-correlation factor (PACF) for the signal at different time lags.
Analytics 04 00027 g0a12
Table A8 shows the suitable models identified by Wolfram Mathematica, ranked based on AIC (Akaike Information Criterion) [37], which considers how well a model represents the data and how many parameters the model has. The lower the AIC, the better the model.
Table A8. Top 10 SARIMA models computed by Mathematica to model the signal. For the top three models, the moving average component is null (third digit in the first bracket of numbers). For all models, there is no integrated component (second digit in the first bracket of numbers). All models adequately capture the 12-month period of the seasonal pattern (subscript number after second bracket of numbers).
Table A8. Top 10 SARIMA models computed by Mathematica to model the signal. For the top three models, the moving average component is null (third digit in the first bracket of numbers). For all models, there is no integrated component (second digit in the first bracket of numbers). All models adequately capture the 12-month period of the seasonal pattern (subscript number after second bracket of numbers).
Candidate ModelAIC
1SARIMA (1,0,0), (0,1,2)123425.87
2SARIMA (1,0,0), (0,1,3)123429.1
3SARIMA (1,0,0), (1,1,1)123429.51
4SARIMA (1,0,1), (0,1,2)123431.19
5SARIMA (1,0,0), (0,1,1)123431.96
6SARIMA (2,0,0), (0,1,2)123432.62
7SARIMA (2,0,0), (0,1,1)123432.94
8SARIMA (1,0,0), (1,1,2)123434.31
9SARIMA (1,0,0), (1,1,3)123436.3
10SARIMA (1,0,0), (0,1,2)123438.6
Table A9 shows that not all the parameters for the first model are significant, as indicated by a p-value less than 0.05. a 1 is the coefficient for the auto-regressive part of the non-seasonal model and α 1 and β 1 are the coefficients for the seasonal model.
Table A9. Parameters of the SARIMA [{1,0,0}, {0,1,2}12] model.
Table A9. Parameters of the SARIMA [{1,0,0}, {0,1,2}12] model.
EstimateStandard Errort-Statisticp-Value
a10.3820170.3458811.104480.135798
α1−0.8391470.0885299−9.478681.50274 × 10−16
β10.2439150.08852992.755170.00339046
Figure A13 shows a representation of the predictions from the SARIMA model (first candidate from Table A9) over the testing period 2019 to 2020. The mean MAPE for 5000 realisations of the SARIMA model is 7.11% over the testing period.
Figure A13. SARIMA model predictions (blue line) over the testing periods 2009–2021 with a monthly resolution and actual demand (grey line).
Figure A13. SARIMA model predictions (blue line) over the testing periods 2009–2021 with a monthly resolution and actual demand (grey line).
Analytics 04 00027 g0a13
The residuals from this model could be considered random (auto-correlation test = 0.47 > 0.05, the null hypothesis that the data are uncorrelated is not rejected at the 5 percent level based on the Ljung–Box test), indicating a good fit to the data.
The scatter plot in Figure A14 shows the predictions from a realisation of the SARIMA model versus the actual data.
Figure A14. Predicted versus actual value for the test period—example of realisation of the SARIMA model.
Figure A14. Predicted versus actual value for the test period—example of realisation of the SARIMA model.
Analytics 04 00027 g0a14

Appendix C.3. Results from Baseline SARIMA Model on Hourly Data

For comparison, we also ran the baseline model on hourly data. Mathematica proposes a SARIMA (3,0,0), (3,0,0)12 model. The mean MAPE for 1000 realisations of the SARIMA model is 42.57% over the testing period 2019–2021.
Figure A15 shows the SARIMA model being unable to accurately predict the hourly total of the UK electricity demand.
Figure A15. Predictions from the traditional SARMA model with hourly resolution (blue line) and actual demand (grey line).
Figure A15. Predictions from the traditional SARMA model with hourly resolution (blue line) and actual demand (grey line).
Analytics 04 00027 g0a15

Appendix D. Estimate Step Function for Pandemic Modelling

Interesting fact about the UK consumption of electricity [38]: “it actually falls on Christmas Day, the reason being that very few businesses and industrial premises are working”. The same phenomenon occurred during the 2020 lockdowns: The electricity demand reduced drastically due to industry and businesses shutting down, albeit for a longer period than during the Christmas break. We can use our understanding of one to model the other.
We reproduced the technique developed in [39] to obtain an average drop of 18% of the UK electricity demand during Christmas; see Figure A16.
Figure A16. We estimated an 18% reduction in electricity demand over Christmas due to businesses and industries shutting down. We used the ratio of the average demand for each day x ( i ) and the running average x i 14 +   x i 7 + x i + x i + 7 +   x ( i + 14 ) 5 . Unusual events depart from 1, the corresponding dates have been highlighted in orange.
Figure A16. We estimated an 18% reduction in electricity demand over Christmas due to businesses and industries shutting down. We used the ratio of the average demand for each day x ( i ) and the running average x i 14 +   x i 7 + x i + x i + 7 +   x ( i + 14 ) 5 . Unusual events depart from 1, the corresponding dates have been highlighted in orange.
Analytics 04 00027 g0a16

References

  1. Department for Energy Security and Net Zero; Department for Business, Energy; Industrial Strategy. Net Zero Strategy: Build Back Greener. Available online: https://www.gov.uk/government/publications/net-zero-strategy (accessed on 4 January 2025).
  2. Department for Energy Security; Net Zero. 2022 UK Greenhouse Gas Emissions, Final Figures. Available online: https://assets.publishing.service.gov.uk/media/65c0d15863a23d0013c821e9/2022-final-greenhouse-gas-emissions-statistical-release.pdf (accessed on 4 January 2025).
  3. O’Callaghan, B.; Hu, E.; Israel, J.; Llewellyn Smith, C.; Way, R.; Hepburn, C. Could Britain’s Energy Demand Be Met Entirely by Wind and Solar? Smith School of Enterprise and the Environment: Oxford, UK, 2023; Working Paper 23-02. [Google Scholar]
  4. Cavus, M. Advancing Power Systems with Renewable Energy and Intelligent Technologies: A Comprehensive Review on Grid Transformation and Integration. Electronics 2025, 14, 1159. [Google Scholar] [CrossRef]
  5. National Grid ESO. Future Energy Scenarios. Available online: https://www.neso.energy/document/264421/download (accessed on 4 January 2025).
  6. National Energy System Operator. Historic Demand Data. Available online: https://www.nationalgrideso.com/data-portal/historic-demand-data?page=0 (accessed on 4 January 2025).
  7. González-Romera, E.; Jaramillo-Morán, M.A.; Carmona-Fernández, D. Monthly electric energy demand forecasting with neural networks and Fourier series. Energy Convers. Manag. 2008, 49, 3135–3142. [Google Scholar] [CrossRef]
  8. Fumi, A.; Pepe, A.; Scarabotti, L.; Schiraldi, M.M. Fourier Analysis for Demand Forecasting in a Fashion Company. Int. J. Eng. Bus. Manag. 2013, 5, 30. [Google Scholar] [CrossRef]
  9. Li, R.; Jiang, P.; Yang, H.; Li, C. A novel hybrid forecasting scheme for electricity demand time series. Sustain. Cities Soc. 2020, 55, 102036. [Google Scholar] [CrossRef]
  10. Filik, Ü.B.; Gerek, Ö.N.; Kurban, M. A novel modelling approach for hourly forecasting of long-term electric energy demand. Energy Convers. Manag. 2011, 52, 199–211. [Google Scholar] [CrossRef]
  11. Hunt, L.C.; Judge, G.; Ninomiya, Y. Underlying trends and seasonality in UK energy demand: A sectoral analysis. Energy Econ. 2003, 25, 93–118. [Google Scholar] [CrossRef]
  12. Bowerman, B.; O’Connell, R.; Koehler, A. Forecasting, Time Series, and Regression: An Applied Approach, 4th ed.; Thomson Brooks/Cole: Belmont, CA, USA, 2005; p. 326. [Google Scholar]
  13. Iftikhar, H.; Turpo-Chaparro, J.E.; Rodrigues, P.C.; López-Gonzales, J.L. Day-Ahead Electricity Demand Forecasting Using a Novel Decomposition Combination Method. Energies 2023, 16, 6675. [Google Scholar] [CrossRef]
  14. Iftikhar, H.; Bibi, N.; Rodrigues, P.C.; López-Gonzales, J.L. Multiple Novel Decomposition Techniques for Time Series Forecasting: Application to Monthly Forecasting of Electricity Consumption in Pakistan. Energies 2023, 16, 2579. [Google Scholar] [CrossRef]
  15. Tzortzis, A.M.; Pelekis, S.; Spiliotis, E.; Karakolis, E.; Mouzakitis, S.; Psarras, J.; Askounis, D. Transfer Learning for Day-Ahead Load Forecasting: A Case Study on European National Electricity Demand Time Series. Mathematics 2023, 12, 19. [Google Scholar] [CrossRef]
  16. Fields, N.; Collier, W.; Kiley, F.; Caulker, D.; Blyth, W.; Howells, M.; Brown, E. Long-Term Forecasting: A MAED Application for Sierra Leone’s Electricity Demand (2023–2050). Energies 2024, 17, 2878. [Google Scholar] [CrossRef]
  17. Elexon. Best View Prices. Available online: https://www.elexonportal.co.uk/BESTVIEWPRICES (accessed on 5 January 2025).
  18. Department for Energy Security and Net Zero; Department for Business, Energy; Industrial Strategy. Historical Electricity Data. Available online: https://www.gov.uk/government/statistical-data-sets/historical-electricity-data (accessed on 5 January 2025).
  19. National Grid ESO. Historic GB Generation Mix. Available online: https://www.nationalgrideso.com/data-portal/historic-generation-mix/historic_gb_generation_mix (accessed on 5 January 2025).
  20. CEDA Archive. HadUK-Grid Gridded Climate Observations on a 5 km Grid over the UK, v1.2.0.Ceda (1836–2022). Available online: https://catalogue.ceda.ac.uk/uuid/adf1a6cf830b4f5385c5d73609df8423/ (accessed on 5 January 2025).
  21. Statista. Largest Urban Agglomerations in the United Kingdom in 2023. Available online: https://www.statista.com/statistics/294645/population-of-selected-cities-in-united-kingdom-uk/ (accessed on 5 January 2025).
  22. Britannica. Greater London. Available online: https://www.britannica.com/place/Greater-London (accessed on 5 January 2025).
  23. Office for National Statistics. Population Estimates for the UK, England, Wales, Scotland, and Northern Ireland: Mid-2022. Figure 3: Interactive Map Comparing Local Authority Median Age and Population Density in UK: Mid-2022. Available online: https://www.ons.gov.uk/peoplepopulationandcommunity/populationandmigration/populationestimates/bulletins/annualmidyearpopulationestimates/mid2022 (accessed on 5 January 2025).
  24. Office for National Statistics Geography. Local Authority Districts (December 2022) Boundaries UK BFC. Available online: https://geoportal.statistics.gov.uk/maps/305779d69bf44feea05eeaa78ca26b5f (accessed on 5 January 2025).
  25. Worldometer. United Kingdom GDP. Available online: https://www.worldometers.info/gdp/uk-gdp/ (accessed on 5 January 2025).
  26. Wolfram. Country Data. Available online: https://reference.wolfram.com/language/ref/CountryData.html (accessed on 5 January 2025).
  27. Department for Energy Security and Net Zero. Energy Trends: UK Gas. Natural Gas Supply and Consumption (ET 4.1-Quarterly). Available online: https://www.gov.uk/government/statistics/gas-section-4-energy-trends (accessed on 5 January 2025).
  28. Office for National Statistics. Census 2021: How Homes are Heated in Your Area. Available online: https://www.ons.gov.uk/peoplepopulationandcommunity/housing/articles/census2021howhomesareheatedinyourarea/2023-01-05 (accessed on 5 January 2025).
  29. Office for National Statistics. House Building Data, UK: January to March 2023. House Building, UK: Permanent Dwellings Started and Completed by Country. Available online: https://www.ons.gov.uk/peoplepopulationandcommunity/housing/articles/ukhousebuildingdata/januarytomarch2023 (accessed on 5 January 2025).
  30. Office for National Statistics. Energy Efficiency of Housing, England and Wales, Five Years Rolling. Available online: https://www.ons.gov.uk/peoplepopulationandcommunity/housing/datasets/energyefficiencyofhousingenglandandwalesfiveyearsrolling (accessed on 5 January 2025).
  31. Department for Energy Security and Net Zero. Household Energy Efficiency. Available online: https://assets.publishing.service.gov.uk/media/6656084d8f90ef31c23ebb57/HEE_Stats_Release_-_MAY_2024.pdf (accessed on 5 January 2025).
  32. Downey, A.B. Think Stats, Exploratory Data Analysis, 2nd ed.; O’Reilly Media Inc.: Sebastopol, CA, USA, 2015; p. 79. [Google Scholar]
  33. Gonzalez, R.C.; Woods, R.E. Digital Image Processing, 4th ed.; Pearson: New York, NY, USA, 2018. [Google Scholar]
  34. Chat GPT. Neural Networks for Time Series. Available online: https://chatgpt.com/c/86ecec9e-9212-4e33-8118-c15123657ba5 (accessed on 25 January 2025).
  35. Wolfram Mathematica. Sequence Learning and NLP with Neural Networks. Available online: https://reference.wolfram.com/language/tutorial/NeuralNetworksSequenceLearning.html#825325933 (accessed on 25 January 2025).
  36. Wolfram Mathematica. NetTrain. Available online: https://reference.wolfram.com/language/ref/NetTrain.html (accessed on 18 August 2025).
  37. Hyndman, R.J.; Athanasopoulos, G. Forecasting: Principles and Practice, 2nd ed.; OTexts: Melbourne, Australia, 2018. [Google Scholar]
  38. National Grid. Powering up Christmas: 12 Festive Facts from National Grid. Available online: https://www.nationalgrid.com/powering-christmas-12-festive-facts-national-grid (accessed on 5 January 2025).
  39. Yukseltan, E.; Yucekaya, A.; Bilge, A.H. Forecasting electricity demand for Turkey: Modeling periodic variations and demand segregation. Appl. Energy 2017, 193, 287–296. [Google Scholar] [CrossRef]
Figure 1. By the end of 2022, renewable energies took the lead from fossil energies in the UK’s electricity supply. Fossil fuels include coal and natural gas, and renewable energies include wind, hydro, and solar. Other electricity sources not included are nuclear, biomass, storage, imports and other.
Figure 1. By the end of 2022, renewable energies took the lead from fossil energies in the UK’s electricity supply. Fossil fuels include coal and natural gas, and renewable energies include wind, hydro, and solar. Other electricity sources not included are nuclear, biomass, storage, imports and other.
Analytics 04 00027 g001
Figure 2. Decomposition of the UK electricity demand time series (a) reveals a yearly trend (b), seasonal variations (c), weekly variations (d), and a daily pattern (e).
Figure 2. Decomposition of the UK electricity demand time series (a) reveals a yearly trend (b), seasonal variations (c), weekly variations (d), and a daily pattern (e).
Analytics 04 00027 g002
Figure 3. Computational pipeline consisting of four main stages: data collection, preprocessing, model training, and evaluation.
Figure 3. Computational pipeline consisting of four main stages: data collection, preprocessing, model training, and evaluation.
Analytics 04 00027 g003
Figure 4. An accurate measure of the UK electricity demand includes both the Transmission System Demand (TSD) and the energy generated by embedded power plants like wind turbines and solar panels. The time series plotted shows monthly totals of electricity demand.
Figure 4. An accurate measure of the UK electricity demand includes both the Transmission System Demand (TSD) and the energy generated by embedded power plants like wind turbines and solar panels. The time series plotted shows monthly totals of electricity demand.
Analytics 04 00027 g004
Figure 5. Visualisation of connectivity between independent variables.
Figure 5. Visualisation of connectivity between independent variables.
Analytics 04 00027 g005
Figure 6. Using the monthly total of the electricity demand data, we calculate the standard deviation for each year. The standard deviation is not constant and broadly decreases over the years, as does the average (Figure 2b). The multiplicative decomposition model is the preferred approach to handle data with variable seasonality [12] as opposed to additive decomposition.
Figure 6. Using the monthly total of the electricity demand data, we calculate the standard deviation for each year. The standard deviation is not constant and broadly decreases over the years, as does the average (Figure 2b). The multiplicative decomposition model is the preferred approach to handle data with variable seasonality [12] as opposed to additive decomposition.
Analytics 04 00027 g006
Figure 7. Monthly total of the electricity demand data (blue line) with its long-term trend (orange line) derived from a Gaussian low-pass filter of radius 12.
Figure 7. Monthly total of the electricity demand data (blue line) with its long-term trend (orange line) derived from a Gaussian low-pass filter of radius 12.
Analytics 04 00027 g007
Figure 8. The blue line shows the scaled detrended signal, and the orange line shows the modelled detrended signal using an optimal number of Fourier components.
Figure 8. The blue line shows the scaled detrended signal, and the orange line shows the modelled detrended signal using an optimal number of Fourier components.
Analytics 04 00027 g008
Figure 9. ACF plot of the electricity demand detrended of the first cyclical component. A periodicity is still detectable.
Figure 9. ACF plot of the electricity demand detrended of the first cyclical component. A periodicity is still detectable.
Analytics 04 00027 g009
Figure 10. The combined long-term trend and short-term variability signal (blue line) is modelled by a neural network (orange line).
Figure 10. The combined long-term trend and short-term variability signal (blue line) is modelled by a neural network (orange line).
Analytics 04 00027 g010
Figure 11. The blue line shows the observed signal (monthly total electricity demand), and the orange line shows the final predicted signal with the multiplicative decomposition model.
Figure 11. The blue line shows the observed signal (monthly total electricity demand), and the orange line shows the final predicted signal with the multiplicative decomposition model.
Analytics 04 00027 g011
Figure 12. The structure of this network was optimised according to the mean absolute percentage error (MAPE) and the mean absolute scaled error (MASE) (the results detailed in Appendix B.2).
Figure 12. The structure of this network was optimised according to the mean absolute percentage error (MAPE) and the mean absolute scaled error (MASE) (the results detailed in Appendix B.2).
Analytics 04 00027 g012
Figure 13. The monthly electricity demand data is detrended and scaled, with the cycles centred around 1.
Figure 13. The monthly electricity demand data is detrended and scaled, with the cycles centred around 1.
Analytics 04 00027 g013
Figure 14. Fourier spectrum of the detrended, scaled signal. We observed a fundamental frequency at 3.17 × 10 8 Hz, which corresponds to a period of 12 months, and higher frequency harmonics at periods of 6, 4, 3, and 2.4 months.
Figure 14. Fourier spectrum of the detrended, scaled signal. We observed a fundamental frequency at 3.17 × 10 8 Hz, which corresponds to a period of 12 months, and higher frequency harmonics at periods of 6, 4, 3, and 2.4 months.
Analytics 04 00027 g014
Figure 15. By plotting the predictions from the first cyclic model against the normalised detrended signal, we noticed a constant shift between the two time series.
Figure 15. By plotting the predictions from the first cyclic model against the normalised detrended signal, we noticed a constant shift between the two time series.
Analytics 04 00027 g015
Figure 16. The number of Fourier components for the first cyclic model was arbitrarily set at 5 components, and we calculated the MAPE for each value of the time shift. The MAPE reached a minimum at a lag of 1 month and 13 months.
Figure 16. The number of Fourier components for the first cyclic model was arbitrarily set at 5 components, and we calculated the MAPE for each value of the time shift. The MAPE reached a minimum at a lag of 1 month and 13 months.
Analytics 04 00027 g016
Figure 17. MAPE values for the predictions of the first cyclic model for different numbers (#) of Fourier components.
Figure 17. MAPE values for the predictions of the first cyclic model for different numbers (#) of Fourier components.
Analytics 04 00027 g017
Figure 18. The number of Fourier components for the second cyclic model was arbitrarily set at 5 components, and we calculated the MAPE for each value of the time shift. The MAPE reached a minimum at a lag of 13 months.
Figure 18. The number of Fourier components for the second cyclic model was arbitrarily set at 5 components, and we calculated the MAPE for each value of the time shift. The MAPE reached a minimum at a lag of 13 months.
Analytics 04 00027 g018
Figure 19. MAPE values for the predictions of the second cyclic model for different numbers (#) of Fourier components. The MAPE reached a local minimum with 5 and 9 components for the second cyclic model and seemed to stabilise with 14 components. To balance model accuracy and complexity, we selected the first 9 Fourier components, which offered a practical compromise between reducing error and avoiding overfitting.
Figure 19. MAPE values for the predictions of the second cyclic model for different numbers (#) of Fourier components. The MAPE reached a local minimum with 5 and 9 components for the second cyclic model and seemed to stabilise with 14 components. To balance model accuracy and complexity, we selected the first 9 Fourier components, which offered a practical compromise between reducing error and avoiding overfitting.
Analytics 04 00027 g019
Figure 20. Comparison of the original signal with the signal detrended from the cyclic components after the first and second cyclical components.
Figure 20. Comparison of the original signal with the signal detrended from the cyclic components after the first and second cyclical components.
Analytics 04 00027 g020
Figure 21. Multiplicative decomposition model predictions over the training, validation, and testing periods with a monthly resolution. With an excellent fit over the training and validation periods, the model also shows a good fit over the testing period from 2019 to 2021 with an overall error of 3.47% (all error values are MAPE).
Figure 21. Multiplicative decomposition model predictions over the training, validation, and testing periods with a monthly resolution. With an excellent fit over the training and validation periods, the model also shows a good fit over the testing period from 2019 to 2021 with an overall error of 3.47% (all error values are MAPE).
Analytics 04 00027 g021
Figure 22. Predicted versus actual value—multiplicative decomposition model. Monthly electricity demand for testing period 2009–2021.
Figure 22. Predicted versus actual value—multiplicative decomposition model. Monthly electricity demand for testing period 2009–2021.
Analytics 04 00027 g022
Figure 23. Illustration of the recursive function on the first two predictions from the neural network.
Figure 23. Illustration of the recursive function on the first two predictions from the neural network.
Analytics 04 00027 g023
Figure 24. Modified neural network to improve recursive prediction accuracy by including an additional normalisation layer and a scaling layer before the output layer.
Figure 24. Modified neural network to improve recursive prediction accuracy by including an additional normalisation layer and a scaling layer before the output layer.
Analytics 04 00027 g024
Figure 25. Comparison of the monthly electricity demand time series detrended from cyclical patterns M i m (blue line) with its estimate from long-term predictive model 1 (orange line), according to Figure 12, without independent variables, and long-term predictive model 2 (green dashed line), according to Figure 24.
Figure 25. Comparison of the monthly electricity demand time series detrended from cyclical patterns M i m (blue line) with its estimate from long-term predictive model 1 (orange line), according to Figure 12, without independent variables, and long-term predictive model 2 (green dashed line), according to Figure 24.
Analytics 04 00027 g025
Figure 26. The year 2013 was chosen as the typical hourly pattern of electricity demand over a week. The average hourly electricity demand over a week for the years 2009 to 2023 was within ±5% of the pattern for 2013.
Figure 26. The year 2013 was chosen as the typical hourly pattern of electricity demand over a week. The average hourly electricity demand over a week for the years 2009 to 2023 was within ±5% of the pattern for 2013.
Analytics 04 00027 g026
Figure 27. Predictions for the scaled hourly demand within a week.
Figure 27. Predictions for the scaled hourly demand within a week.
Analytics 04 00027 g027
Figure 28. Predictions from the multiplicative decomposition model with hourly resolution. All error values are MAPE.
Figure 28. Predictions from the multiplicative decomposition model with hourly resolution. All error values are MAPE.
Analytics 04 00027 g028
Figure 29. Predictions (blue line) with the proposed model for hourly electricity demand and actual demand (grey line) with a zoom in on the week marked by the narrow rectangle in Figure 28.
Figure 29. Predictions (blue line) with the proposed model for hourly electricity demand and actual demand (grey line) with a zoom in on the week marked by the narrow rectangle in Figure 28.
Analytics 04 00027 g029
Figure 30. Predicted versus actual value for the test period—multiplicative decomposition model on hourly data.
Figure 30. Predicted versus actual value for the test period—multiplicative decomposition model on hourly data.
Analytics 04 00027 g030
Table 1. Summary of the key methodologies that informed the approach presented in this paper.
Table 1. Summary of the key methodologies that informed the approach presented in this paper.
ReferenceMethodInput VariablesOutput Variable
González-Romera et al. [7]Additive decomposition model:
-
Fourier series for the fluctuations,
-
Neural network (multi-layer perceptron) for the trend
-
5-year historical data for the Fourier model
-
12 months past values for the neural network
Monthly electric energy demand in Spain—one-month-ahead prediction
Fumi et al. [8]Fourier series4-year historical sales dataWeekly sales of a medium- to large-sized Italian fashion company
Filik et al. [10]Multiplicative decomposition model:
-
Polynomial function for the trend,
-
Fourier series for the weekly variations,
-
2D discrete cosine transform for the week template
-
Entire dataset (1982–2007) for the polynomial function and Fourier series,
-
Average hourly shape of 52 weeks in the year 2002 for the week template
Hourly forecasting of long-term electric energy demand in Turkey—descriptive model
Our
proposed
approach
Multiplicative decomposition model:
-
Fourier series for the fluctuations,
-
Neural network (multi-layer perceptron) for the trend and irregularities components
-
Historical data from 2009 to 2018 for the Fourier model
-
Real GDP, average temperature, percentage renewables, electricity CPI, housing efficiency, number of new builds, population growth + 13 months past values for the neural network
Hourly forecasting of long-term electric energy demand in the UK—true long-term predictions
Table 2. Tally of periods with zero demand.
Table 2. Tally of periods with zero demand.
DateNumber of Settlement Periods with Zero Demand
29 August 200946
30 August 20092
9 July 201046
10 July 20102
13 July 201046
14 July 20102
29 May 201246
30 May 201248
31 May 201248
1 June 201248
2 June 201248
3 June 201248
4 June 20122
11 June 201246
14 October 20121
Table 3. Descriptive statistics of half-hourly electricity demand data.
Table 3. Descriptive statistics of half-hourly electricity demand data.
StatisticsElectricity Demand (MW)
Max60,672
75%40,329
Median34,776
25%29,220
Min18,356
Table 4. List of potential independent variables.
Table 4. List of potential independent variables.
Independent VariableData
Resolution
Context
Bid price [17]
(GBP per megawatt-hour)
Half-hourly,
27 March 2001–
13 June 2024:
406,999 data points
The UK energy market is a so-called deregulated market where the price of energy is governed by the laws of supply and demand. In addition to contracts for the supply of electricity agreed between producers of electricity and the National Grid, there is also a short-term bidding process to keep the grid in balance every 30 min. The bid price can be quite volatile and is eventually reflected in the price paid by the consumers.
We selected this factor to explore whether the bid price influences consumers’ behaviour: using less electricity to minimise expenses. The bid price was broadly stable with low volatility until 2020, after which both prices and volatility rose sharply, peaking in 2022 before easing but remaining above historical norms.
SBP represents the System Buy Price and SSB, the System Sell Price. Since Thu 5 November 2015, the SBP and SSP are identical at each period.
Consumer price index (CPI) for electricity [18]
(GBP)
Yearly,
1970–2022:
53 data points
The Department for Energy Security & Net Zero produced a historical time series of the electricity component for the consumer price index (CPI) in real terms. This is a proxy for the change in the electricity net selling value to all consumers, indexed on the year 2010 and integrating inflation.
The logic for selecting this factor is the same as for the bid price: the consumer may be influenced by the price of electricity. Bid price and CPI are, however, different measures.
The CPI rose in the 1970s–1980s, fell steadily through the 1990s, then began recovering in the 2000s, and surged sharply after 2020 to record highs.
Percentage renewables [19]
(Percentage of electricity produced)
Half-hourly,
1 January 2009–
29 May 2024:
270,123 data points
In terms of mode of operation, the wind and solar energy sources have the advantage that no additional energy is required to operate the plant. The station load mentioned earlier (Section 2.1) is reduced when a larger portion of electricity is sourced from renewable sources.
In addition, a higher percentage of renewables in the electricity mix may raise awareness of a more mindful consumption of electricity and influence consumers’ behaviour.
Based on these considerations and the fact that the percentage of renewables has been steadily increasing across the time span considered (see Figure 1), we selected this factor to explain the decreasing trend in electricity demand in an inverse relationship.
Average temperature [20]
(Celsius Degrees)
Monthly,
January 2009–
December 2022:
168 data points
Climate change affects countries in different ways, and in the UK, the yearly average temperature has been increasing steadily from 8.9 degrees in 2010 to 9.8 degrees in 2021 (detailed calculations are available in the supporting coding notebook on independent variables). This may impact the amount of heating required during winter while not yet creating a significant need for cooling in the summer. Hence, it may contribute to an overall decrease in electricity demand.
The average temperature in the UK has been weighted by the population density of London, Birmingham, Manchester, Leeds, and Glasgow.
Additional information includes the following:
List of the UK’s largest agglomerations [21]. List of London boroughs [22]. Population density per Local Authority [23]. Local Authority Districts [24].
Real GDP [25]
(USD)
Yearly,
1993–2022:
30 data points
The Gross Domestic Product (GDP) is often used as an indicator to explain consumers’ behaviour, with an increasing GDP often correlated with an increasing electricity demand. In our case, given that the electricity demand is decreasing, an increase in GDP may indicate that consumers can make a choice for more energy-efficient products.
We selected this factor as it is traditionally used in studies on electricity demand. It was increasing linearly until 2007, with a first anomaly showing a plateau in 2008, followed by a drop in 2009. The GDP resumed its increasing trend after 2009 until a second anomaly with a sharp drop in 2020.
The term ‘real’ indicates that the GDP is inflation-adjusted.
Population growth rate [26]
(Percentage per year)
Yearly,
2009–2023:
15 data points
While the UK population has been constantly increasing since 2009, a more interesting indicator to follow is the population growth rate. Since 2012 the UK population has been increasing less each year, with a steep drop in 2020–2021, recovering from 2022 onwards. We selected the population growth as an indicator of reduced demand on the housing market and, therefore, on the domestic energy demand.
The growth rate is calculated as the successive differences in the population data.
Gas demand [27]
(GW per hour)
Yearly,
1998–2023:
26 data points
According to the 2021 Census [28], mains gas central heating was by far the most common way that households heated their homes. Around three in four households (74%) in England and Wales said it was their only central heating source.
Looking at gas demand will help understand whether the decrease in electricity demand is due to fuel switching.
The UK gas demand is irregular with a broadly decreasing trend since 2001.
The total gas demand includes transformation (electricity generation + heat generation), energy industry use, losses, and final consumption. Electricity generation from gas is already included in the electricity demand data; to avoid double accounting, we removed the electricity generation from the total gas demand.
Number of new builds [29]
(no unit)
Yearly—financial year,
2009–2022:
14 data points
Through building regulations for new homes, the UK government aims to significantly reduce carbon emissions by focusing on improving heating, hot water systems, and reducing heat waste.
These regulations have been increasingly ambitious. Part L Volume 1, released in 2021, focused on minimum levels of efficiency or performance in a building’s design, construction, and services. An uplift to Part L released in June 2022 mandated a further reduction of carbon emissions by at least 31% compared to previous regulations.
These measures contribute to reducing the demand for electricity.
The number of new builds has been increasing since 2009, with a period of sharper increase between 2013 and 2015.
Measure of housing energy efficiency [30]
(no unit)
Yearly—5-year rolling,
2010–2020:
11 data points
Efficiency of existing housing is being improved, the same as for new builds. The Energy Company Obligation (ECO) [31] is a government energy efficiency scheme for low-income and vulnerable energy customers, which aims to reduce energy bills and carbon emissions. ECO measures, started in 2013, include cavity wall, solid wall and loft insulation, smart heating controls, and micro-generation such as air source heat pumps and photovoltaics.
These measures contribute to reducing the demand for electricity.
The Energy Performance Certificate (EPC) is a measure of the energy efficiency of a building, based on its features such as the building materials used, heating systems and insulation. The average EPC ratings were flat or declining until 2018, but have since improved steadily, peaking around 2022 before levelling off.
Each data point is set to the middle of the 5-year rolling period.
Table 5. Spearman’s correlation coefficient between each of the independent variables listed in Table 4 and the electricity demand downward trend (Figure 2b). The underlined numbers indicate statistically significant results with a significance level of 5%.
Table 5. Spearman’s correlation coefficient between each of the independent variables listed in Table 4 and the electricity demand downward trend (Figure 2b). The underlined numbers indicate statistically significant results with a significance level of 5%.
Independent VariablesCorrelation with the Signal’s Yearly Trend
Bid price0.61
Electricity CPI−0.95
Percentage renewables−0.95
Average temperature−0.83
Real GDP−0.80
Population growth0.92
Gas demand0.57
Number of new builds−0.99
Housing efficiency−0.72
Table 6. Top 10 Fourier components by amplitude for the scaled detrended signal.
Table 6. Top 10 Fourier components by amplitude for the scaled detrended signal.
AmplitudePhaseFrequencyPeriod (Months)
1.00 × 1000.0000.00 × 100-
7.30 × 10−30.0533.17 × 10−812.00
1.30 × 10−31.1501.58 × 10−72.40
8.70 × 10−40.5426.33 × 10−86.00
6.20 × 10−42.8109.50 × 10−84.00
5.60 × 10−40.6171.27 × 10−73.00
3.90 × 10−4−1.6705.38 × 10−87.06
3.70 × 10−4−1.6101.36 × 10−72.79
3.30 × 10−4−1.8001.08 × 10−73.53
3.10 × 10−41.0204.75 × 10−88.00
Table 7. Top 10 Fourier components by amplitude for the scaled detrended signal after the first cyclical component is removed.
Table 7. Top 10 Fourier components by amplitude for the scaled detrended signal after the first cyclical component is removed.
AmplitudePhaseFrequencyPeriod (Months)
1.00 × 1000.0000.00 × 100-
5.20 × 10−40.7112.85 × 10−813.30
3.90 × 10−4−1.7005.38 × 10−87.06
3.90 × 10−4−2.3804.12 × 10−89.23
3.60 × 10−4−1.6001.36 × 10−72.79
3.60 × 10−40.0053.48 × 10−810.90
3.20 × 10−4−1.7701.08 × 10−73.53
3.20 × 10−41.0304.75 × 10−88.00
3.00 × 10−40.8601.61 × 10−72.35
2.90 × 10−4−1.6106.97 × 10−85.45
Table 8. MAPE for the overall model predicting monthly electricity demand using different models for the long-term trend and short-term variability components.
Table 8. MAPE for the overall model predicting monthly electricity demand using different models for the long-term trend and short-term variability components.
Overall Training Period 2009–2016Overall Validation Period 2017–2018Overall Testing Period
2019–2021
201920202021
Short-term predictive model, monthly resolution1.171.633.522.495.352.71
Long-term predictive model 1, monthly resolution1.171.634.622.296.515.06
Long-term predictive model 2, monthly resolution1.391.664.162.156.843.48
Table 9. Cyclic models optimisation parameters for hourly data.
Table 9. Cyclic models optimisation parameters for hourly data.
Time LagNumber of Fourier Components
Cyclic component model 11312
Cyclic component model 252
Table 10. MAPE for the overall model predicting hourly electricity demand using different models for the long-term trend and short-term variability components.
Table 10. MAPE for the overall model predicting hourly electricity demand using different models for the long-term trend and short-term variability components.
Overall Training Period 2009–2016Overall Validation Period 2017–2018Overall Testing Period
2019–2021
201920202021
Short-term predictive model, hourly resolution6.276.517.517.2213.3614.20
Long-term predictive model 1, hourly resolution6.276.518.627.3213.7614.51
Long-term predictive model 2, hourly resolution6.296.509.797.6014.2914.96
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Baillon, M.; Romano, M.C.; Ullner, E. Multiplicative Decomposition Model to Predict UK’s Long-Term Electricity Demand with Monthly and Hourly Resolution. Analytics 2025, 4, 27. https://doi.org/10.3390/analytics4040027

AMA Style

Baillon M, Romano MC, Ullner E. Multiplicative Decomposition Model to Predict UK’s Long-Term Electricity Demand with Monthly and Hourly Resolution. Analytics. 2025; 4(4):27. https://doi.org/10.3390/analytics4040027

Chicago/Turabian Style

Baillon, Marie, María Carmen Romano, and Ekkehard Ullner. 2025. "Multiplicative Decomposition Model to Predict UK’s Long-Term Electricity Demand with Monthly and Hourly Resolution" Analytics 4, no. 4: 27. https://doi.org/10.3390/analytics4040027

APA Style

Baillon, M., Romano, M. C., & Ullner, E. (2025). Multiplicative Decomposition Model to Predict UK’s Long-Term Electricity Demand with Monthly and Hourly Resolution. Analytics, 4(4), 27. https://doi.org/10.3390/analytics4040027

Article Metrics

Back to TopTop