Download as pdf or txt
Download as pdf or txt
You are on page 1of 28

Graphical Abstract

Fuzzy Time Series Models for the Development of Predictive Elec-


tricity Demand
José Manuel Rubio-Cienfuegos, José Miguel Rubio-León, Cristian Vidal-Silva
Highlights
Fuzzy Time Series Models for the Development of Predictive Elec-
tricity Demand
José Manuel Rubio-Cienfuegos, José Miguel Rubio-León, Cristian Vidal-Silva

• Research highlight 1

• Research highlight 2
Fuzzy Time Series Models for the Development of
Predictive Electricity Demand
José Manuel Rubio-Cienfuegosa , José Miguel Rubio-Leónb , Cristian
Vidal-Silvac
a
Departamento de Ingenierı́a Eléctrica, Universidad de Chile, Tupper 2007,
Santiago, Santiago, 8320000, Santiago, Chile
b
Escuela de Computación e Informática, Universidad Bernardo O’Higgins, Av. Viel
1497, Santiago, 8320000, Santiago, Chile
c
School of Videogame Development and Virtual Reality Engineering, Faculty of
Engineering, University of Talca, Av. Lircay S/N, Talca, 3460000, Maule, Chile

Abstract
Electric power has been one of the significant engines of humanity since the
end of the 18th century. Managing the produced energy to assist industries
and different human activities is highly relevant. Companies in the elec-
tricity markets of each country analyze the generation, transmission, and
distribution of energy to satisfy all the energy needs required by each sec-
tor and industry. One of the essential variables to analyze is the demand
for electrical energy, which indicates how much energy is required to satisfy
consumers’ needs. But, energy consumption often has a random behavior
and a complex analysis to develop prediction models. The analysis and un-
derstanding of energy consumption are essential for energy generation. It
is necessary to develop models that allow forecasting the demand because
it would allow better management of energy generation and consumption.
Given the stochastic nature of this variable, the main objective of this work
is to develop an electric power demand prediction model using fuzzy logic, ex-
ploring different configurations and parameters through the use of specialized
libraries in Python and Google Colaboratory, to compare their performance
with previously proposed machine learning systems, such as neural networks
or random forests, to develop a high-precision prediction model of the fol-
lowing demand values. The information used in this work is data collected


Correspondence: cvidal@utalca.cl; Tel.: +56-9-62002702

Preprint submitted to Journal of the Franklin Institute July 15, 2023


by the European Network of Transmission System Operators of Electricity
(ENTSO-E) from 2015 to 2019. This work presents a model that exceeded
the predictive performance of previous solutions. The results of this work
using Mean Absolute Percentage Error MAPE show the importance of set
weighting on an excellent performance of fuzzy models since more relevant
fuzzy sets will be available when generating the inference rules and, later,
performing demand forecasts.
Keywords: Electricity, ENTSO-E, MAPE, fuzzy logic models, machine
learning.

1. Introduction
Electric power has been one of the significant engines of humanity since
the end of the 18th century [10]. Currently, each industry requires electricity,
which creates a great need to manage the energy generated to maintain and
develop all human activities requiring its use. Electrical markets arise to
economically analyze everything related to the generation, transmission, and
distribution of energy [14]. One purpose of electrical markets is to satisfy all
the energy needs that each sector and industry requires [35], and an essential
variable to see that behavior is the electric energy demand [11]. This
information indicates how much energy is required for an entity or series of
consumers to supply their needs [33].
Since human activities are subject to many external factors, the energy
demand is not exempt from this. Analyzing and understanding the energy
demand is essential for developing the energy sector [1, 19]. That is highly
relevant for the field of energy generation [2], where this last activity is still
carried out, for most non-renewable resources (Oil: 32.89%, Coal: 29.16%,
Natural Gas: 23.40% are the three most used energy sources in the world [6]).
This characteristic shows that it is necessary to develop models that allow
forecasting the demand since, in this way, it would allow better management
of energy generation and consumption.
When analyzing the electricity demand as a time series, seeing this vari-
able’s evolution around time, we can find exciting behaviors [22]. Let us
analyze the annual energy demand values. The growth through the years
can represent the consequence of the development of industries: population
and technology increase, and economic development (see figure 1). On the
other hand, if the demand is analyzed with values recorded per hour, then

2
(b)

Figure 1: (a) The increase in energy demand and Spanish GDP, an economic value, shows
how demand increases as the economy grows [12]. (b) Evolution of population, electricity
consumption, and CO2 emissions in the last decades. As in the previous case, there is an
increase in demand as the population grows [26].

an increase is observed during the day and a reduction during the night,
indicating a close relationship of this variable with the development of work
and daily activities [20]. However, when analyzing the demand in this last
time range, some records do not obey this behavior on several occasions, and
even values exceed the maximum recorded in previous days. As previously
mentioned, the demand depends to a large extent on the development of hu-
man activities, where these are subject to a large number of factors which, in
many cases, have stochastic behaviors (failures in electrical systems, events
of great convocation, economic evolution of the industry, climate, to give
some examples). Hence, the demand often has a random behavior, making
it challenging to analyze when developing prediction models [18].
Due to these characteristics and the importance of demand, many systems

3
have been developed that predict this variable, using all kinds of techniques,
through supervised machine learning, deep learning, and auto-regressive sys-
tems [4, 7, 23]. Within all the models that perform regressions, the use of
fuzzy series have been systems that have had better performance in this
field [31, 30]. Those models, in addition to being very varied, allow the infor-
mation of related variables to be easily incorporated since, within its training
process, there is a deep analysis of the relationships between the variables
processed [3].
The main objective of this work is to develop an electric power demand
prediction model using fuzzy logic, exploring different configurations and
parameters through the use of specialized libraries in Python and compare
the performance of these. fuzzy models with some systems that have already
been developed in state of the art such as neural networks or random
forests. That is to develop a model to predict the following demand values
more precisely. For this, in the following sections of this work, the following
will be presented:

• A review of the most important concepts for understanding the work


developed in the Theoretical Framework.
• In-depth database analysis, showing the peculiarities of the available
information, especially demand and the data most related to it.
• The methodology used to develop the models, highlighting the prepro-
cessing and training performed.
• Results obtained after the application of 35 models with different con-
figurations together with the analysis of the yields obtained.
• Conclusions on the results obtained, more points to be developed in
future work to improve these values.

The rest of this paper is organized as follows. Section 2 summarizes and


exemplifies time series and fuzzy time series. Section 3 describes the main
features and models of fuzzy time series. Section 4 outlines the source data for
training and testing solutions, programming tools for applying fuzzy series
models, and computational implementation details. Section 5 details the
main results obtained for each applied fuzzy series model. Section 6 describes
previous research and tools for similar purposes. Section 7 concludes this
work and summarizes the main contributions.

4
Figure 2: Time series of the Monthly Index of Economic Activity (IMACEC) of the mining,
non-mining and joint sectors between 2019 - 2039

2. Time Series.
A time series is a succession of data ordered chronologically in defined
time intervals [5, 34]. The data may be evenly spaced (for example, the record
of daily solar generation from a photovoltaic plant) or different (number of
annual earthquakes in a defined area). This type of representation offers
many advantages since its analysis allows us to find underlying relationships
in the data (they can be from various time series or within itself). These
can be used to extrapolate the behavior towards the past, periods of data
loss, and future. They have two relevant characteristics: the seasonality
that shows if it has a pattern around time and the trend that indicates the
evolution of this variable (if the values grow, decrease, or remain in the same
range).
Figure 2 shows the temporal representation of an economic indicator,
where a seasonality of around one year and a trend that shows the growth of
these values can be seen.

2.1. Fuzzy Logic and Fuzzy Time Series


Fuzzy logic is a type of paraconscious logic (a system of logic that deals
with contradictions in an attenuated way) that does not take all expressions
as entirely true or false as the main difference from classical logic [27]. Fuzzy
logic allows approaching decision problems very interestingly since, in the
real world, it is impossible to abstract everything into a binary system [9].

5
(a)

(b)

Figure 3: Differences between the association of the height to the sets of tall and short
through classical logic (a) and fuzzy logic (b), the x-axis in both examples corresponds to
the height. In contrast, the y-axis corresponds to the membership degree or mem-
bership.

For example, consider a record of the height of people to know who is tall
or small in this data set (figure 3), and take the value of 1.70 Mts as the
division point; that is, people with equal or higher height is tall and with
lower is short. With standard logic, it is assumed that all the data will be
in one of these sets; however, would it be correct to say that someone with a
height of 1.69 mts is small or 1.71 mts is tall?
Fuzzy logic allows establishing a degree of membership to the defined
sets; that is, the variables can belong to more than one set [17]. Fuzzy logic
operates on so-called fuzzy sets, where the values are in a range [0,1] instead of
the binary terms. These values are controlled by the membership function
of a set to each element belonging to the universe of discourse [38]. Thus,
a fuzzy set A is characterized by its membership function µA : X −→ [0, 1]

6
and A = {(x, µA (x))}.
As its name indicates, a fuzzy time series corresponds to a time series
that uses fuzzy logic to convert each series value into elements belonging to
fuzzy sets [13]. A time series in the fuzzy domain further strengthens the
series analysis by applying fuzzy set relationship analysis to the original data
[21].

3. Fuzzy Models
3.1. Fuzzy time series
Fuzzy time series models use fuzzy logic to predict data in time intervals
with no records [16]. Many fuzzy models exist since Fuzzy Logic theory and
time series analysis are extensive. However, they all share characteristics
that allow them to be grouped. Some relevant characteristics of fuzzy time
series models are:

• Order (Ω): It indicates how much-passed information is needed to


obtain the next value. It should be noted that the more previous data
is taken, the more likely it is to obtain a model with better performance
(figure 4)

Figure 4: Predicted behavior of a sine function using fuzzy models of different orders.

• Partition ( ): This parameter controls how temporary data is pushed


Q
to the fuzzy sets. There are two relevant characteristics for this param-
eter: the type of Partition (the general form that the Partition will
have) and the number of fuzzy sets (number of sets in the fuzzifi-
cation process (assignment of values diffuse)
Q of information). Figure 5
exemplifies the second characteristic f .

7
Figure 5: Predictions of a fuzzy model for a sine function with different numbers of
partitions.

• Membership function (µ): This parameter controls the type of map-


ping done to the partition. Thus it controls how the data is associated
with fuzzy sets.

3.2. Univariable and multivariable models


As fuzzy logic analyzes the degrees of membership of the variables to fuzzy
sets, the information to be processed can have data not only of an objective
variable but also of the information related to this variable. Therefore, these
models can be categorized into univariable and multivariable as follows.

3.2.1. Univariable models


• HOFTS (High Order Fuzzy Time Series): models whose main param-
eter for the creation of the rules is the order, it does not carry out
weightings of the developed sets, assuming that each one is equally
important.

• WHOFTS (Weighted High Order Fuzzy Time Series): a model that,


after obtaining the partition rules, weights the fuzzy sets so that more
influential values will be obtained when making the predictions.

• PWFTS (Probabilistic Weighted Fuzzy Time Series): model that also


weights the importance of each fuzzy set; however, this not only takes
into account the rules obtained but also the initial configuration of the
partition and performance of models without weights, so the inclusion

8
of these weights is done probabilistically. It should be noted that this
model works better when having a larger amount of data, so an increase
in order can be counterproductive when using this model.
3.2.2. Multivariable models
• MVFTS (MultiVariable Fuzzy Time Series): is a system that analyzes
the relationships between variables and does not add importance to
the fuzzy sets created, being similar to the HOFTS model but with the
ability to have a more robust analysis when obtaining a prediction, due
to the presence of information related to the objective variable.
• Weighted MVFTS : similar to the previous model; however, it adds
importance to the sets so it has a better analysis when developing
predictions.
• FIG-FTS (Granular Multivariate Weighted Fuzzy Time Series): These
are models that emphasize obtaining the relationships of the variables
through clustering algorithms; in addition, they incorporate weightings
in the fuzzy sets created.

4. Methodology
The information used in this work is data compiled by the European
Network of Electricity Transmission Network Operators (ENTSO-E), an
organization of electricity managers that contains records on various variables
related to the electricity market in several European countries [15]. The data
shown correspond to the Spanish consumption and generation information
during 2015 and 2019. The dataset format is shown in Table 1.
Generation Forecast Price Fore- Price ac- Total load Total load
time biomass ... solar ... cast [Eur/ tual [Eur/ forecast actual
[MW] [MW] MWh] MWh] [MW] [MW]
2015/01/01
00:00:00 + 447 ... 17 ... 50.1 65.41 26118 25385
01:00
2015/01/01
01:00:00 + 449 ... 16 ... 48.10 64.92 24934 24382
01:00
... ... ... ... ... ... ... ... ...
2018/12/31
23:00:00 + 290 ... 26 ... 64.27 69.88 24424 24455
01:00

Table 1: Summary information available in the database used, due to the large number of
columns, only these data were displayed.

9
In total, there is a dataset with 29 features and 35064 samples. This in-
formation contains data for the recorded date (in yyyy/mm/dd - hh/mm/ss
format), 21 sources of energy generation (renewable and non-renewable, re-
newable energy generation forecasts in MW), the price of energy together
with its forecasts (in EUR/MWh) and, finally, the data of interest for this
work: the demand for hourly electrical energy together with values pre-
dicted by Spanish TSO models (Transmission System Operator, commercial
company that manages the operation of the electricity sector).
The most used data were those of the demand and the values predicted
by the TSO. These were used to compare the performance of the models with
the systems used by this body until 2019.

4.1. Exploratory analysis of available demand.


The information of most significant interest is demand that Table 2 shows.

Registered dates From 01/01/2015 - 00:00:00 to 12/31/2018 - 23:59:59


Demand range Minimum: 18041 [MW], Maximum: 41015 [MW]
MAPE TSO forecast 1.096%

Table 2: Interesting data on available demand.

4.2. Data preprocessing.


Data preprocessing was done given the information available in the database
(synthesized in the table 1). All this process was carried out in python, where
using the functions of the pandas library, it was possible to obtain a clear
visualization of the dataset.
The first filter eliminated the columns with more than 90% of null in-
formation using the function defined in the code 1. This small algorithm
removes the characteristics of a dataframe whose percentage of null values
is more significant than a specified limit (nan threshold). So, to carry out
the process mentioned at the beginning, only the data was loaded at the input
of this function, and the value of nan threshold was adjusted to 0.9, where
the samples that did not have information in the rest were also removed, of
remaining columns.

Listing 1: Column removal function with little information.


import pandas as pd

def nans_remove(df, nan_threshold, reset_index=True):

10
df_process = df.copy()
assert nan_threshold < 1 and nan_threshold > 0 , (’nan threshold
must be between 0 and 1’)
cols_names = df.columns
for name in cols_names:
len, drop_len = df_process[name].__len__(),
df_process[name].dropna().__len__()
difference_reason = (len - drop_len)/(len)
if difference_reason > (1-nan_threshold):
df_process.drop(columns=[name], inplace=True)
else:
continue
df_process.dropna(inplace=True)
df_process.reset_index(drop=reset_index, inplace=reset_index)
return df_process

After the application of this data cleaning, pre-processing was carried


out for each model that was tested, building various time series (table 3) or
applying partitions to the data.
time load-72h load-71h ... load-1h load actual
2015/01/02 00:00:00+01:00 25385 24382 ... 26798 27070
2015/01/02 01:00:00+01:00 24382 22734 ... 27070 24935
... ... ... ... ... ...
2018/12/31 22:00:00+01:00 29145 26934 ... 28071 25801
2018/12/31 23:00:00+01:00 26934 24312 ... 25801 24455

Table 3: Time series created from the demand data and the registration date.

Although there is a large amount of information, the data used were the
registration date (time), the demand (total load actual ), and the forecast
made by the Spanish TSO (total load forecast), therefore the values of
these columns were selected, thus forming a dataset which can be seen in the
table 4.
time total load actual total load forecast
2015/01/01 00:00:00 + 01:00 25385 26118
2015/01/01 01:00:00 + 01:00 24382 24934
... ... ...
2018/12/31 22:00:00 + 01:00 25801 25450
2018/12/31 23:00:00 + 01:00 24455 24424

Table 4: Demand registered by the Spanish TSO, together with this forecast and its date.

11
4.3. Definition of training and test sets.
The distribution of these sets can be seen in the table 5. The training set
contained 70% of the data, leaving the rest for model evaluation.

Set Size Start End


Training 24519 2015/01/01 00:00:00 2017/10/19 23:00:00
Test 10509 2017/10/20 00:00:00 2018/12/31 23:00:00

Table 5: Data distributions for the training and test sets

The results obtained used data from the test set. One point to consider
is that extra preprocessing was done depending on the model used based on
the data in this section.
The central systems of the research carried out in this report correspond
to computationally implemented fuzzy time series models, which were applied
to the energy demand data explained in the previous chapter. This section
explains the computational implementation of these models and a detailed
theoretical explanation of the training process.
The models described below were taken from the doctoral thesis Scal-
able Models for Probabilistic Forecasting with Fuzzy Time Series
by Petronio Candido e Silva. In this work, there are many more fuzzy mod-
els than those shown in this chapter, but some of the most important are
described below.

4.4. Fuzzy models with one variable


For these models, only the demand values (table 4, column total load actual)
were used for their construction, training, and testing.

4.4.1. High Order Fuzzy Time Series Method (HOFTS)


The model presented here corresponds to a development made by Petronio
e Silva [29]. The High Order Fuzzy Time Series or HOFTS method defines
its rules using the form LHS −→ RHS, that is, as antecedent and consequent
considering the order for the prediction process. That is, follow the following
expression.

f (t − L(Ω − 1)), ..., F (t − L(0)) −→ f (t + 1) (1)

When implementing this system, there are defined values for its use: the
order Ω and the number of partitions the user must define k.

12
Parameter Value
Ω User Defined
k
Q User Defined
Grid
µ triangle
α cut 0
L {1, ..., Ω}

Table 6: Hyperparameters defined for HOFTS and WHOFTS models

4.4.2. Computational Implementation.


The library pyFTS, developed in 2018 by the Data Science and Com-
putational Intelligence Laboratory of the Minas Gerais University in Belo
Horizonte, is specialized in processing fuzzy time series [28]. PyFTS offers
excellent versatility when using fuzzy time series of several types, so all fuzzy
model implementations were done using this library.
The procedure for using fuzzy systems to make time series forecasts fol-
lows the following points [8].
1. Data preprocessing: It is a generic step when using prediction mod-
els. Here all the cleaning and filtering of the information is done to
take it to the models.
2. Partition configuration: This is the most important step when
using fuzzy models. A precise analysis must be conducted on the objec-
tive variable to know the most appropriate partition type and number
of fuzzy sets. Also, the model type to be used and its order are config-
ured.
3. Fuzzyfication of the data: In this step, the data is transferred to
the fuzzy domain, so the fuzzy time series are generated at this point.
4. Generation of fuzzy rules: At this point, temporary transition rules
are obtained, depending on the parameters with which the partition was
configured. Depending on the model, the importance of the generated
sets and the relationships between the processed variables are obtained.
5. Forecast: The predictions take a series of values whose length must
be at least the order configured in the partition to predict the following
periods.
6. Data defuzzification: Opposite process to fuzzification; at this point,
the data returns to its original domain.

13
It should be noted that, depending on the models used for fuzzy rule
generation, point 4 may have more than one process.
The primary metric used to evaluate the Performance of the models was
the MAPE, which was applied after obtaining the predictions of each model
trained with the information from the test sets.

5. Results
The fuzzy models previously defined were applied to the test set, where
the demand visualizations were between December 22 and 23, 2019. It should
be noted that these were the results of applying the triangular Grid Partition
(figure ??).

5.1. Univariable models.


5.1.1. HOFTS

Figure 6: Demand predictions made by the HOFTS univariate model for three orders

This model obtained a MAPE equal to 6.90%, 3.61% and 2.94% for
orders 1, 2, and 3, respectively. A part of their predictions can be seen in
figure 6

5.1.2. WHOFTS
This model had more correct answers than the HOFTS, and the MAPE
obtained was 3.89%, 2.54%, and 2.33% for orders 1, 2, and 3, respectively.
Figure 7 shows a part of the behavior of its predictions.

14
Figure 7: Demand predictions made by the WHOFTS univariable model for three orders

Figure 8: Demand predictions made by the PWFTS univariable model for three orders

15
5.1.3. PWFTS
The hits increased significantly with this system, to such an extent that
the model of order 1 has a remarkable similarity with the actual demand.
The MAPE obtained were 0.87%, 2.46%, and 2.83% for orders 1, 2, and
3, respectively. A part of their predictions can be seen in the figure 8.

5.1.4. Performance of one-variable models.


Ordering the Performance of the models according to the MAPE ob-
tained, the table 7 is obtained.

Model Order MAPE (%)


PWFTS 1 0.8783
TSO forecast Does not apply 0.9590
WHOFTS 3 2.3359
PWFTS 2 2.4677
WHOFTS 2 2.5408
PWFTS 3 2.8389
HOFTS 3 2.9445
HOFTS 2 3.6125
WHOFTS 1 3.8930
HOFTS 1 6.9030

Table 7: Absolute Mean Percentage Error obtained by the univariable fuzzy models.

The PWFTS model outperformed the predictions made by the TSO; a


better overall performance was obtained for the higher-order fuzzy models
(except for the PWFTS).

5.2. Multivariate models.


Different performances were obtained by incorporating the temporal par-
tition into the dates and including them in the prediction process. The
predictions shown were made between October 21 and 26, 2017.

16
5.2.1. MVFTS

Figure 9: Demand predictions made by the MVFTS multivariable model

This system had a MAPE of 3.60%. A part of the predictions of this


model can be seen in the figure 9.

5.2.2. Weighted MVFTS

Figure 10: Demand predictions made by the multivariate model WeightedMVFTS

Incorporating the weights in the fuzzy sets partially improves the Perfor-
mance. This system obtained a MAPE of 3.48%, where part of its predic-
tions can be seen in Figure 10.

17
5.2.3. FIG-FTS

Figure 11: Demand predictions made by the FIG-FTS multivariate model, up to 3 neigh-
bors using KNN.

Searching for pools improves Performance. A MAPE of 1.70%, 1.54%,


and 1.58% was obtained for 1, 2, and 3 neighbors using KNN to calculate
relationships between variables. Part of their predictions can be seen in figure
11

5.2.4. Performance of multivariable models.


Ordering the models according to the MAPE obtained as in the previous
section, the table 8 is obtained.

Model MAPE (%)


TSO forecast 0.9590
FIG - FTS (k=2) 1.5421
FIG - FTS (k=3) 1.5866
FIG - FTS (k=1) 1.7079
WeightedMVFTS 3.4820
MVFTS 3.6086

Table 8: Mean Absolute Percentage Error obtained by multivariable fuzzy models.

In this case, a model with a higher performance than the TSO was not
obtained. However, the predictions of these systems generally had a lower
error than that of the univariable models.

18
5.3. Overall Performance.
The results shown above only used the triangular membership function.
Tests were also carried out with another type of membership function, order-
ing the performance obtained by these models and the results of the previous
sections. The ranking of models shown in the table 9 is obtained.
In most of these systems, the performance did not differ significantly when
only the membership function was changed. Therefore, the graphic behavior
is expected to be similar to that already shown for each model.

6. Related Work
Many prediction models exist, already computationally implemented in
various programming language libraries. Some of them are described below.

6.1. Scikit-Learn and Pytorch


Scikit Learn is a project driven by the collaboration of various data sci-
entists and developers worldwide [37]. The Scikit Learn project receives
institutional and private grants to ensure sustainability [25]. Scikit Learn
represents one of the most popular machine learning libraries, from linear
regressors to complex assembled models for classification, regression, and
clustering tasks in Python [32].
On the other hand, deep learning modules and functions permit features
transformation [36]. A recommended Python library for adapted deep learn-
ing transformers is Pytorch [24].
The authors of these paper also implemented Scikit Learn and Pytorch
solutions for predicting electricity demand obtaining results with lower pre-
cision than applying fuzzy models.

7. Conclusions
This research found a model that could exceed the predictive performance
of the TSO with a lower order. While this is encouraging, the PWFTS system
is still under development and revision.
The theory indicated the little relevance of the membership function and
the importance of the order when configuring a fuzzy time series model.
Therefore, the results obtained support that. However, cases were obtained
where there was a notable difference between the same models but with a
different membership function, although that behavior is not the majority.

19
Model Type Order Partition MAPE (%)
PWFTS single 1 Grid Partition tri 0.8738
PWFTS single 1 Grid Partition gauss 0.8779
PWFTS single 1 Grid Partition trap 0.8851
TSO forecast Not applicable Not applicable Not applicable 0.9590
FIG-FTS (k=2) multi 2 Grid Partition tri 1.5421
FIG-FTS (k=3) multi 2 Grid Partition tri 1.5866
FIG-FTS (k=1) multi 2 Grid Partition tri 1.7079
WHOFTS single 3 Grid Partition tri 2.3359
WHOFTS single 3 Grid Partition trap 2.3359
PWFTS single 2 Grid Partition trap 2.3936
PWFTS single 2 Grid Partition tri 2.4677
WHOFTS single 2 Grid Partition tri 2.5408
WHOFTS single 2 Grid Partition trap 2.5408
WHOFTS single 3 Grid Partition gauss 2.6005
PWFTS single 2 Grid Partition gauss 2.6868
PWFTS single 3 Grid Partition trap 2.7710
PWFTS single 3 Grid Partition tri 2.8389
WHOFTS single 2 Grid Partition gauss 2.9332
HOFTS single 3 Grid Partition trap 2.9445
HOFTS single 3 Grid Partition tri 2.9445
PWFTS single 3 Grid Partition gauss 3.0015
WeightedMVFTS multi 2 Grid Partition tri 3.4820
HOFTS single 3 Grid Partition gauss 3.6079
MVFTS multi 1 Grid Partition tri 3.6086
HOFTS single 2 Grid Partition trap 3.6125
HOFTS single 2 Grid Partition tri 3.6125
WHOFTS single 1 Grid Partition tri 3.8930
WHOFTS single 1 Grid Partition trap 3.8930
WHOFTS single 1 Grid Partition gauss 3.9295
HOFTS single 2 Grid Partition gauss 4.7830
HOFTS single 1 Grid Partition tri 6.9030
HOFTS single 1 Grid Partition trap 6.9030
HOFTS single 1 Grid Partition gauss 8.0617
Table 9: Performance of fuzzy models tested.

20
It is assumed that this characteristic is the product of the peculiarities of
training the models and the data used.
One of the most significant difficulties was using high-order models. The
results indicate a better performance when increasing the order; however,
increasing the value of this characteristic also makes it more computationally
expensive. The same consequence happened when incorporating variables
related to the demand in the multivariable models.
This work showed that it is still helpful to develop predictive models,
where the PWFTS model was the most prominent. This model was the most
complex system from the theoretical side implemented in this work, despite
the computational simplicity with which it was applied to the demand data.
That model obtained better results. Therefore, this system corresponds to
the most efficient fuzzy model to make predictions of energy demand. In
addition, its characteristics allow it to be present within other more complex
systems such as FIG-FTS. Due to this, this memory served to validate its
effectiveness. However, it is not convenient to say that it is one of the best
models to develop prediction models because, in this field, many systems
carry out this work. These are updated daily with improvements in different
fields such as deep learning. Given this, as future work in this field, it is
expected to be able to implement a more significant number of regressors
that use this type of learning, apart from the adapted transformer developed
in this report, since these models are among the best that exists in the
industry.
Another fascinating point to develop is adapting this system for process-
ing local demand data. One of the difficulties was obtaining data for the
development of this model; due to this, this work was carried out with a
more experimental than practical approach. Therefore, a point to be devel-
oped consists in adapting this system for local and practical use, where the
pre-processing of the information has the most relevant role in the work used
in the models presented in this report.

References
[1] Abbasi, K.R., Hussain, K., Abbas, J., Adedoyin, F.F., Shaikh, P.A.,
Yousaf, H., Muhammad, F., 2021. Analyzing the role of industrial sec-
tor’s electricity consumption, prices, and gdp: A modified empirical
evidence from pakistan. Aims Energy 9, 29–49.

21
[2] Ahmad, T., Zhang, D., 2020. A critical review of comparative global
historical energy consumption and future demand: The story told so
far. Energy Reports 6, 1973–1991.

[3] Alagbe, V., Popoola, S.I., Atayero, A.A., Adebisi, B., Abolade, R.O.,
Misra, S., 2019. Artificial intelligence techniques for electrical load fore-
casting in smart and connected communities, in: Computational Science
and Its Applications–ICCSA 2019: 19th International Conference, Saint
Petersburg, Russia, July 1–4, 2019, Proceedings, Part V 19, Springer.
pp. 219–230.

[4] Almaghrebi, A., Aljuheshi, F., Rafaie, M., James, K., Alahmad, M.,
2020. Data-driven charging demand prediction at public charging sta-
tions using supervised machine learning regression methods. Energies
13, 4231.

[5] Arafet, K., Berlanga, R., 2021. Digital twins in solar farms: An approach
through time series and deep learning. Algorithms 14, 156.

[6] Arriols, E., 2020 https://www.ecologiaverde.com/


cuales-son-las-fuentes-de-energia-mas-utilizadas-en-el-mundo-1426.
html. Cuales son las fuentes de energı́a más utilizadas
en el mundo. URL: https://www.ecologiaverde.com/
cuales-son-las-fuentes-de-energia-mas-utilizadas-en-el-mundo-1426.
html.

[7] Aslam, M.S., Ghazal, T.M., Fatima, A., Said, R.A., Abbas, S., Khan,
M.A., Siddiqui, S.Y., Ahmad, M., 2021. Energy-efficiency model for
residential buildings using supervised machine learning algorithm. Intell.
Autom. Soft Comput 30, 881–888.

[8] Castillo, O., Melin, P., 2020. Forecasting of covid-19 time series for
countries in the world based on a hybrid approach combining the fractal
dimension and fuzzy logic. Chaos, Solitons & Fractals 140, 110242.

[9] Chandrasekaran, S., Durairaj, S., Padmavathi, S., 2021. A performance


evaluation of a fuzzy logic controller-based photovoltaic-fed multi-level
inverter for a three-phase induction motor. Journal of the Franklin
Institute 358, 7394–7412.

22
[10] Erenoğlu, A.K., Erdinç, O., Taşcıkaraoğlu, A., 2019. His-
tory of electricity , 1–27URL: https://www.sciencedirect.
com/science/article/pii/B9780081025925000016, doi:https:
//doi.org/10.1016/B978-0-08-102592-5.00001-6.

[11] Filippov, S., Malakhov, V., Veselov, F., 2021. Long-term energy demand
forecasting based on a systems analysis. Thermal Engineering 68, 881–
894.

[12] Forecasting, A.E., Enero 2021 https://bit.ly/3qNMkKO. La eficiencia


energética en España o cómo ha cambiado el uso de la energı́a desde el
récord de demanda de 2007. URL: https://bit.ly/3qNMkKO.

[13] Gautam, S.S., Abhishekh, 2019. A novel moving average forecasting ap-
proach using fuzzy time series data set. Journal of Control, Automation
and Electrical Systems 30, 532–544.

[14] He, W., King, M., Luo, X., Dooner, M., Li, D., Wang, J., 2021.
Technologies and economics of electric energy storages in power sys-
tems: Review and perspective. Advances in Applied Energy 4,
100060. URL: https://www.sciencedirect.com/science/article/
pii/S2666792421000524, doi:https://doi.org/10.1016/j.adapen.
2021.100060.

[15] Kaggle, July 2023. Hourly energy demand generation and weather 2015
- 2019. URL: https://www.kaggle.com/datasets/nicholasjhana/
energy-consumption-generation-prices-and-weather.

[16] Khanesar, M., Branson, D.T., 2021. Prediction interval identification


using interval type-2 fuzzy logic systems: Lake water level prediction
using remote sensing data. IEEE Sensors Journal 21, 13815–13827.

[17] Khater, A.A., El-Nagar, A.M., El-Bardini, M., El-Rabaie, N.M., 2019.
Online learning of an interval type-2 tsk fuzzy logic controller for non-
linear systems. Journal of the Franklin Institute 356, 9254–9285.

[18] Koot, M., Wijnhoven, F., 2021. Usage impact on data center electric-
ity needs: A system dynamic forecasting model. Applied Energy 291,
116798.

23
[19] Laimon, M., Mai, T., Goh, S., Yusaf, T., 2019. Energy sector develop-
ment: System dynamics analysis. Applied Sciences 10, 134.
[20] Moral-Carcedo, J., Pérez-Garcı́a, J., 2019. Time of day effects of tem-
perature and daylight on short term electricity load. Energy 174, 169–
183. URL: https://www.sciencedirect.com/science/article/pii/
S0360544219303573, doi:https://doi.org/10.1016/j.energy.2019.
02.158.
[21] Najariyan, M., Pariz, N., 2022. Stability and controllability of fuzzy
singular dynamical systems. Journal of the Franklin Institute 359, 8171–
8187.
[22] Niu, Z., Wu, J., Liu, X., Huang, L., Nielsen, P.S., 2021. Understanding
energy demand behaviors through spatio-temporal smart meter data
analysis. Energy 226, 120493.
[23] Olu-Ajayi, R., Alaka, H., Sulaimon, I., Sunmola, F., Ajayi, S., 2022.
Building energy consumption prediction for residential buildings using
deep learning and other machine learning techniques. Journal of Build-
ing Engineering 45, 103406.
[24] Paszke, A., Gross, S., Massa, F., Lerer, A., Bradbury, J., Chanan,
G., Killeen, T., Lin, Z., Gimelshein, N., Antiga, L., Desmaison, A.,
Kopf, A., Yang, E., DeVito, Z., Raison, M., Tejani, A., Chilamkurthy,
S., Steiner, B., Fang, L., Bai, J., Chintala, S., 2019. Pytorch:
An imperative style, high-performance deep learning library, in:
Advances in Neural Information Processing Systems 32. Curran Asso-
ciates, Inc., pp. 8024–8035. URL: http://papers.neurips.cc/paper/
9015-pytorch-an-imperative-style-high-performance-deep-learning-library.
pdf.
[25] Pedregosa, F., Varoquaux, G., Gramfort, A., Michel, V., Thirion, B.,
Grisel, O., Blondel, M., Prettenhofer, P., Weiss, R., Dubourg, V., Van-
derplas, J., Passos, A., Cournapeau, D., Brucher, M., Perrot, M., Duch-
esnay, E., 2011. Scikit-learn: Machine learning in Python. Journal of
Machine Learning Research 12, 2825–2830.
[26] Prevención, I., Septiembre 2020 https://bit.ly/3Hyiq45. El dato del
dı́a: evolución del consumo de energı́a en los últimos cincuenta años.
URL: https://bit.ly/3Hyiq45.

24
[27] Samonto, S., Kar, S., Pal, S., Atan, O., Sekh, A.A., 2021. Fuzzy
logic controller aided expert relaying mechanism system. Journal of
the Franklin Institute 358, 7447–7467.

[28] Severiano, C.A., e Silva, P.C.d.L., Cohen, M.W., Guimarães, F.G., 2021.
Evolving fuzzy time series for spatio-temporal forecasting in renewable
energy systems. Renewable Energy 171, 764–783.

[29] Silva, P., Diciembre 2018 https://bit.ly/3BTGlro. A short tutorial


on fuzzy time series. URL: https://bit.ly/3BTGlro.

[30] Song, C., Wang, L., Xu, Z., 2022. An optimized logistic regression
model based on the maximum entropy estimation under the hesitant
fuzzy environment. International Journal of Information Technology &
Decision Making 21, 143–167.

[31] Song, C., Xu, Z., Song, C., Xu, Z., 2021. Regression analysis models
under the hesitant fuzzy environment. Techniques of Decision Making,
Uncertain Reasoning and Regression Analysis Under the Hesitant Fuzzy
Environment and Their Applications , 83–124.

[32] Tran, M.K., Panchal, S., Chauhan, V., Brahmbhatt, N., Mevawalla, A.,
Fraser, R., Fowler, M., 2022. Python-based scikit-learn machine learn-
ing models for thermal and electrical performance prediction of high-
capacity lithium-ion battery. International Journal of Energy Research
46, 786–794.

[33] Twenergy, Agosto 2019. La demanda eléctrica.


URL: https://twenergy.com/eficiencia-energetica/
como-ahorrar-energia-casa/la-demanda-electrica-953/.

[34] Wang, Q., Zhao, Y., Hu, J., 2021. Reset output feedback control of
cluster linear multi-agent systems. Journal of the Franklin Institute
358, 8419–8442.

[35] Wang, S., Sun, L., Iqbal, S., 2022. Green financing role
on renewable energy dependence and energy transition in e7
economies. Renewable Energy 200, 1561–1572. URL: https://www.
sciencedirect.com/science/article/pii/S0960148122015592,
doi:https://doi.org/10.1016/j.renene.2022.10.067.

25
[36] Xu, J., Yang, J., Xiong, X., Li, H., Huang, J., Ting, K., Ying, Y., Lin,
T., 2021. Towards interpreting multi-temporal deep learning models in
crop mapping. Remote Sensing of Environment 264, 112599.

[37] Zhu, Q., Xiong, Q., Wang, K., Lu, W., Liu, T., 2020. Accurate wifi-
based indoor localization by using fuzzy classifier and mlps ensemble in
complex environment. Journal of the Franklin Institute 357, 1420–1436.

[38] Zou, Y., Yan, F., Wang, X., Zhang, J., 2020. An efficient fuzzy logic
control algorithm for photovoltaic maximum power point tracking under
partial shading condition. Journal of the Franklin Institute 357, 3135–
3149.

26

You might also like