• No results found

Predicting electricity consumption and cost for South African mines

N/A
N/A
Protected

Academic year: 2021

Share "Predicting electricity consumption and cost for South African mines"

Copied!
109
0
0

Bezig met laden.... (Bekijk nu de volledige tekst)

Hele tekst

(1)

Predicting electricity consumption and cost

for South African mines

Dissertation submitted in partial fulfillment of the requirements for the degree Magister Engineering in Computer and Electronics

at the Potchefstroom Campus of the North-West University

by

S.S. (Stephen) Cox supervised by

Dr. J.F. (Johann) van Rensburg

(2)

My cousin who I shared a large part of my childhood Donovan Jansen (1988-2011)

A mentor who helped develop a large part of this dissertation Dougie Velleman (1943-2012)

(3)

To God the glory alone.

I want to thank the following entities:

Centre for Research and Continued Engineering Development

For giving me the opportunity to pursue my masters degree in engineering. Their dedication over weekends and after hours is highly appreciated. Their years of experience makes it an excellent environment for post graduate studies.

TEMM International

For giving me the opportunity to get experience in the engineering field and graciously providing a bursary to help pay the tuition fees. Working with professional engineers is an excellent learning experience.

HVAC International

For providing access to the mining industry for investigations and gathering of data. They also sponsored visits to mines for first hand experience in energy management.

LaTeX community

For providing endless examples to help write this dissertation. The quality of a LaTeX generated document is unmatched.

Additionally I want to thank the following individuals: Jorene Cox (My wife)

I must thank my dear wife for putting up with me during the development of this dissertation. Her support was endless and she never complained. My words fall short when expressing my feelings and gratitude towards her, but I can only say that I love you, Jorene, Forever and ever!

My parents

Thank you for slaving away so that I could have a fighting chance which you did not have. Your love and support helped me accomplish what I have done so far.

(4)

reviewed my work endless times, so I would also like to thank his wife and family for the time he spend on reviews. Johann has taught me a lot throughout this dissertation and it will be remembered.

Dr. Carol MacDonald

For editing my work and helping me as engineer to improve my professional writing. Dr. Ruaan Pelzer

For his help with Chapter 1 and his attention to details are priceless. His financial insight help a lot in discussing the impact on the economy. I learned a lot from Ruaan on software development.

Oswald van Ginkel

For his idea and implementation to extract data from emails. He implemented the algorithm to check and process email. His insight to neural networks helped a lot and the quality of the neural networks in this dissertation would be much worse without his insight. He also reviewed some of the mathematics used in the dissertation.

Dougie Velleman

For making time to review my writing wherever he was. One of my chapters was edited by him when he was on vacation in the Kruger National Park. His knowledge for writing academic material is extensive and I learned a huge amount from him. My condolences for his family as he passed away during the writing of this dissertation in a freak accident. Dr. Werner Bouwer

For his expertise and limitless insight in everything about engineering. He has the ability to direct one in discovering a solution to a problem, without revealing the solution. The amount of experience he gained throughout the years is difficult to convey to someone else, but Werner finds a simple and yet effective way to do this.

TEMM International colleagues

For all the support from each of you. It is really the little things you do that makes a big influence.

(5)

Electricity costs in South Africa have risen steeply; there are a number of factors that have contributed to this increase. The increased costs have a considerable influence on the mines and mining sector in general. It requires considerable planning to assist mines in such management. The present study addresses the development of a way to predict both electricity consumption and costs, which general involves a large range of personnel.

The majority of planning personnel can be more usefully employed in other ways. The goal is not to replace such planners but make them more task effective. Automation, which will reduce their workload, may have little or no effect on performance. In some cases, however, automation may produce better results.

There is a complex system to be analysed in the prediction of electricity consumption and costs. The existing prediction methodology is investigated in this study; the investigation highlights the need for a new methodology. The new method should be automated, easier to use and more accurate. Such a model is developed.

The new prediction methodology extracts data from the monthly Eskom bills and stores it in a database. The data is grouped according to a new model and then normalised. An artificial neural network is used to “learn” the dynamics of the data to calculate new future electricity consumption. Electricity costs are predicted by multiplying the predicted electrical consumption with a calculated factor based on cost per electricity unit of the previous year with the expected increase added.

The new methodology is integrated in a commercial energy management platform named Management Toolbox, which offers a range of functionality. In this study the prediction of electricity consumption and costs are implemented. The implementation is executed with simplicity in mind and care is taken to present the user with the optimal amount of data. The performance of the electricity consumption prediction is sensitive to production changes and the quality of the data history. Performance of the electricity costs prediction model is an improvement over the existing prediction method. The proposed methodology has greater accuracy and uses less personnel, which can lead to using most of the personnel on more important tasks.

Keywords: Energy management, electricity consumption, prediction, artificial neural networks, electricity cost, programming.

(6)

Page

Acknowledgements . . . ii

Abstract . . . iv

Table of Contents . . . v

List of Figures . . . vii

List of Tables . . . ix

List of Source Code Listings . . . x

1 Introduction . . . 1

1.1 Mining sector overview and the effect of increasing electricity costs . . . 2

1.2 Planning for future energy consumption and costs . . . 7

1.3 Requirements for energy consumption and costs prediction techniques . . . . 8

1.4 Overview of the dissertation . . . 11

2 Overview of energy prediction methodologies . . . 12

2.1 Introduction . . . 13

2.2 The complexity of the energy prediction environment . . . 13

2.3 Existing energy budget calculation methodologies . . . 14

2.4 Prediction methodologies survey . . . 17

2.5 Design parameters of the new energy prediction methodology . . . 29

2.6 Conclusion . . . 32

3 Implementation of the new energy prediction methodology . . . 33

3.1 Introduction . . . 34

3.2 Prediction methodology development . . . 34

3.3 Integration of prediction methodologies in an energy management solution . 39 3.4 Software design and development . . . 45

3.5 Conclusion . . . 58

4 Application of the new energy prediction methodology . . . 59

4.1 Introduction . . . 60

4.2 Application on a South African mine . . . 60

4.3 Conclusion . . . 65

5 Conclusion . . . 66

5.1 Summary . . . 67

5.2 Recommendations for future work . . . 69

Bibliography . . . 70

Appendix A Algorithms . . . 77

A.1 The email checking script . . . 78

A.2 The data extraction routine . . . 79

(7)

Appendix B Source code . . . 81

B.1 Single variable linear regression using gradient descent . . . 82

B.2 Multi variable linear regression using gradient descent . . . 83

B.3 Artificial neural network using back-propagation . . . 84

B.4 Artificial neural network using resilient back-propagation . . . 87

(8)

1.1 Value contributed by the mining sector to the GDP [2] . . . 2

1.2 GDP breakdown of the South African economy in 2011 [2] . . . 3

1.3 South African employment breakdown [3] . . . 3

1.4 Average earning statistics of the mining sector [3–7] . . . 4

1.5 Operating expenses breakdown of typical mine . . . 5

1.6 Inflation (Basing year 2005 as 100%) [10–13, 15–21] . . . 5

1.7 Electricity usage breakdown [13] . . . 7

1.8 Electricity cost and consumption prediction components . . . 8

1.9 Linear fitting of a quadratic function . . . 9

2.1 Illustration of complex motion . . . 13

2.2 Fictional commonalities of a project or system . . . 14

2.3 Typical electricity flow diagram for a mine . . . 15

2.4 Typical energy management data flow . . . 15

2.5 Analogue electricity meter . . . 16

2.6 Eskom electricity bill example . . . 16

2.7 Illustration of a Boxplot . . . 18

2.8 Distribution curves used in normalisation . . . 19

2.9 Electricity consumption prediction for July using the present method . . . . 20

2.10 Linear regression approximation of non-linear data . . . 21

2.11 Example error surface of Equation 2.4 . . . 22

2.12 Example surface with multiple minima locations . . . 23

2.13 Energy consumption prediction for July 2012 using linear regression . . . 25

2.14 Artificial neural network structure . . . 26

2.15 Energy usage prediction using artificial neural networks . . . 27

2.16 Electricity consumption prediction summary . . . 28

2.17 Conceptual design of the user interface . . . 31

3.1 Electricity consumption yearly trends . . . 35

3.2 Data model development summary . . . 39

3.3 Flow of data within the developed application . . . 40

3.4 Prediction process used in the developed application . . . 41

3.5 Result calculation process used in the developed application . . . 43

3.6 User interface used in the developed application . . . 44

3.7 Illustration of charting tools used . . . 45

3.8 Application architecture . . . 45

(9)

3.10 User interface presented to the user when opening the application . . . 52

3.11 Operation of the prediction solution in the developed application . . . 53

3.12 Chart section of the user interface . . . 54

3.13 Information section of the user interface . . . 55

3.14 Adjust section of the user interface . . . 55

3.15 User interface with adjusted prediction . . . 55

3.16 Control section of the user interface . . . 56

3.17 Extra information in shown in user interface . . . 56

3.18 Historical data displayed in user interface . . . 57

3.19 Yearly data changes displayed in kWh within the user interface . . . 57

3.20 Yearly data changes display in percentage within the user interface . . . 58

4.1 Mine X electricity consumption prediction (2012) . . . 61

4.2 Mine X production comparison . . . 62

4.3 Mine X electricity consumption prediction error (2012) . . . 63

(10)
(11)

3.1 Using PHP to connect to a MySQL database [83] . . . 47

3.2 Using JavaScript to open and resize a window [93] . . . 49

3.3 Using JQuery to assign onclick events to HTML elements [94] . . . 49

3.4 Using CSS to style a HTML table [95] . . . 50

3.5 XML used to generate a chart [96] . . . 51

B.1 Single variable linear regression implemented in Octave . . . 82

B.2 Multi variable linear regression implemented in Octave . . . 83

B.3 Artificial neural network using back-propagation implemented in the C language 84 B.4 Artificial neural network using resilient back-propagation implemented in the C language . . . 87

B.5 Autoconf configuration script source code for Non-Windows operating system 91 B.6 JavaScript configuration script source code Windows operating system . . . 92

B.7 Skeleton extension header file source code . . . 92

(12)

”Imagination is more important than knowledge. For knowledge is limited, whereas imagination embraces the entire world, stimulating progress, giving birth to evolution. It is, strictly speaking, a real factor in scientific research.” Albert Einstein

(13)

1.1

Mining sector overview and the effect of increasing

electricity costs

The mining sector forms an integral part of the South African economy. The activity of a sector in the country’s local economy can be characterised by comparing each sector’s Gross Domestic Product (GDP). This is a general accepted way of measuring the local economic activity [1]. The GDP is an indication of a country’s standard of living. In economic terms, it is the market value of the officially recognised goods produced or services delivered within the country for each sector respectively [1].

When comparing any sector’s historical economic presence, there is an important factor to account for namely cost inflation, which is determined by calculating the Consumer Price Index (CPI). All of the different formulae used for calculating the GDP delivers the answer as the nominal GDP which contains cost inflation [1]. When one is doing a historical comparison, the GDP needs to be independent of inflation.

Removing the influence of cost inflation from the nominal GDP is referred to as real GDP and can be used as an objective yearly comparison of the GDP [1]. In Figure 1.1 the real GDP for the mining sector is shown from the year 2002 until the first quarter of the year 2012, where the year 2005 is used as a reference for inflation [2]. The mining sector’s contribution has declined from 2003.

2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 5.5 6.0 6.5 7.0 Year V alue con tributed to the GDP (%)

Figure 1.1: Value contributed by the mining sector to the GDP [2]

In the first quarter of 2012, the mining sector contributed 4.75% to the real GDP of South Africa [2]. Figure 1.2 illustrates the GDP distribution of South Africa by key sectors for

(14)

comparing the mining sector to rest of the economy. The mining sector’s portion according to the real GDP distribution is not substantial, but important.

Mining 5.4%

Manufacturing and Electricity

17% Transport and construction

12.2% Wholesale 12.3% Financial 21.1% Government 13.6%

Community and Agriculture

7.7% Tax

10.7%

Figure 1.2: GDP breakdown of the South African economy in 2011 [2]

The real GDP of the mining sector has been steady at an average of 5% since 2008. The indirect contribution from the mining sector can best be described by the number of other sectors dependent on the mining sector and the amount of mining sector’s employees. As other sectors depend on the mining sector, the indirect real GDP contribution is larger than the direct contribution. Taking this into account and the stability of the mining sector’s GDP, this sector can be marked as an important part of the South African economy. In March 2012 the mining sector employed 6.2% of the South African employees and they received 6.3% of the total earnings for South Africa [3]. The employment distribution for all the sectors is shown in Figure 1.3.

Mining 6.2%

Manufacturing and Electricity

14.5% Wholesale

20% Transport and construction

9.5%

Financial

21.9%

Community 27.8%

Figure 1.3: South African employment breakdown [3]

(15)

employee in the mining sector is shown in Figure 1.4 [3–7]. An adjustment is made to the employee earnings so that no inflation is reflected. The mining sector shows steady growth of employment and an exponential increase in earnings per employee. This raises the cost to company to employ more workers, making the costs higher to expand a mine.

2004 2005 2006 2007 2008 2009 2010 2011 20,000 22,000 24,000 26,000 28,000 30,000 32,000 Year Av erage mon thly earnings p er emplo y ee (Rand)

Figure 1.4: Average earning statistics of the mining sector [3–7]

In recent events at the Marikana mine an illegal strike lead to an increase in illegal strikes throughout South Africa [8]. The strikes spread to other mines as the demands were met when pressure from the media increased [9]. These strikes demanded a salary increase above inflation, which can lead to an increase in the cost per employee. The result of this increase in salaries may result in the cost per employee increasing exponentially when compared to the previous three years.

The growth in assets and resources adds an extra emphasis on management thereof. A large portion of managing a mine is spent on efficient and effective asset and resource management. An essential resource that needs to be efficiently managed is finances. Financial management is very time consuming, requires financial insight and great attention to detail, especially when taking into account the complexity of the operations.

Part of financial management is analysing expenses. Figure 1.5 illustrates the most important expenses incurred at a mine. One of these factors is the electricity costs that have experienced an average cost inflation of 27% from 2008 until 2011 [10–13]. Using the year 2005 as reference, the cumulative inflation from 2008 to 2011 is 146% and the electricity cost inflation for that same period is 293%.

(16)

Payroll 52% Consumables 23% Electricity 15% Contractors 10%

Figure 1.5: Operating expenses breakdown of typical mine

The national energy regulator of South Africa, NERSA, signed off on a 24.8% increase for 2010/2011, a 25.8% increase for 2011/2012 and a 16% increase for 2012/2013. [12–14]. Electricity and cost inflation is plotted in Figure 1.6. The average yearly electricity cost inflation from 2001 to 2007 was 5% [15–21]. By contrast, the average yearly electricity cost inflation from 2008 to 2011 was 27% [10–13].

2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 100 150 200 250 300 Year Cum ulativ e inflation (%)

Consumer price index Electricity cost inflation

Figure 1.6: Inflation (Basing year 2005 as 100%) [10–13, 15–21]

The significant increase in electricity inflation may lead to the closure of the less profitable mines as they will not be a viable investment option. South Africa is a mineral-rich country and it would be a substantial reduction in effective resource use to close the less profitable

(17)

mines. Less profitable mines may be bought by other companies, but there will be extra costs involved in the owner transfer and in some cases a loss in expertise, reducing the mine’s overall efficiency.

These factors can increase the country’s unemployment rate if the mines are left vacant and can adversely affect the economy, which has been affected by the 2008/2009 worldwide recession [22]. Conducting business in the present economic state is not easy and is worsened by the increase in electricity prices.

Because of the reduced reserve margin in electrical power supply, Eskom has introduced a power plan to reduce electricity usage by penalising excessive users. A Power Conservation Program (PCP) is the proposed solution. This program has two main subcomponents namely Energy Conservation Scheme (ECS) and Energy Growth Management (EGM).

To encourage the reduction on the electricity supply the ECS will be used by introducing penalties on all excessive electricity users. Under the ECS agreement, large consumers can also buy unused allocated electricity from smaller consumers. Buying unused electricity can help consumers exceeding the limits set by these penalties but at a price.

EGM will be used to prioritise the availability of new electrical services that could affect the electricity supply [23–25]. By prioritising the initiation of new electrical services, it will affect new developments. By reducing the uptake of new electrical services, it can control the future increase in demand apart from the present increases of existing customers. The correlation between economic growth and energy usage is well documented [26, 27]. Restricting energy growth will slow down the rate of economic growth. The present rate of the increase in electricity demand has exceeded the rate of the increasing electricity supply. It is expected that this demand for electrical energy will continue to increase indefinitely if not haltered by price hikes [28].

The economic growth will create a growth in electricity consumption and the penalty programs will slow the growth of electricity consumption [26–28]. The mining sector accounted for 14.5% of the electricity consumption in South Africa during the year 2010 [13]. It is expected that penalty programs will slow the energy consumption growth rate temporarily, but will struggle to keep the energy consumption in bounds. In Figure 1.7 the electricity breakdown is illustrated. These penalty programs are expected to have a large influence on the mining sector, making the existing alternatives that are more expensive at present a more viable option for the mining sector to continue economic growth.

(18)

Foreign and Residential 10.6%

Municipalities

40.8%

Industry and Railway

29.9%

Mining 14.5%

Commercial 6.2%

Figure 1.7: Electricity usage breakdown [13]

1.2

Planning for future energy consumption and costs

Accurate planning plays an important role in any business when the resources are limited and competition is high. At present, the economic recovery is very slow. The economic crisis in Greece and other Eurozone countries during the year 2011 has only exacerbated the situation [29]. Facing these problems without any extensive planning could result in further economic setbacks. Proper financial planning and management is required by the mining sector in the present economic climate.

Many of the South African mines have not used a strict electrical cost and consumption budget for governing their operations until just before the financial crisis of 2008. Before 2008 electricity costs were included in the budget, but were not closely monitored. At present the electricity consumption and costs are monitored with the respective budget allocations on a monthly basis.

Some mining groups have implemented financial planning for managing monthly electricity usage. These groups have seen improvements in the reduction of electricity usage. When there is an event where an energy user has exceeded the budget, it will be handled in such a way that the effect on the overall budget is attenuated. The evaluation of the budget comparison is mostly on a monthly base except where real time energy meters are installed. These meters ensures that any anomalies can be handled immediately and will result in a minimal effect the budget.

At the lower level of planning, the individual electricity users of the sub-systems like hoisting or pumping are required to estimate their electrical energy usage. Electricity consumption and costs are estimated for a predefined number of financial years. The number of financial years are defined by estimating the viable operation lifetime of a mine. Each of the sub-system electricity users applies their own safety margin and expectations of their operations. A system manager reviews these estimations.

(19)

After all the sub-system planning has been reviewed, there is a final process where this planning is put into perspective. All the components are integrated to bring into account the effect of individual system interactions. As an example, these interactions can include that separate systems share a common compressor ring or that they are geographically located close to each other but operate as different systems. This creates a scenario where the exact energy usage cannot be determined and thus must be accounted for statistically. These planning figures will then be amended and an extra safety margin will be included. This whole process is susceptible to human error and over estimation as there are many

different planning methodologies for each system. Most of these systems operate in a

predictable yearly trend, but there are months where unexpected energy usage will exceed the budget’s limit.

1.3

Requirements for energy consumption and costs

prediction techniques

1.3.1

Functional requirements

The techniques for predicting energy consumption and costs have common components and are shown in Figure 1.8. The three common components are data, prediction and result.

A. Data B. Prediction C. Result

Figure 1.8: Electricity cost and consumption prediction components

Data: In order to make any prediction or future decision regarding energy consumption and costs there must be some historic data in order to base a decision or prediction on. The same rule applies to interpolation and extrapolation, where data must be available to derive an equation. The larger the data sample the more accurate the analysis will be and the more accurate the decision or prediction can be. However, as the data can contain anomalies such as inaccurate measurements or malfunctioning equipment. Anomalies can influence the accuracy of the prediction.

Prediction: There are a number of methods to choose from and the pros and cons must be weighed on each application as it can differ from mine to mine and industry to industry. The best equation for the method is directly dependent on the complexity of the data being fitted. As an example, in Figure 1.9 a linear function, y(x) = 12x−20, is used to approximate the quadratic function, y(x) = x2. The domain, 0 ≤ x ≤ 12, and linear regression is used

(20)

to create the linear function. In creating the linear function the domain, 12 < x ≤ 24, is intentionally withheld when using linear regression to demonstrate the extrapolation error made on a under fitted function.

0 2 4 6 8 10 12 14 16 18 20 22 24 0 100 200 300 400 500 600 x y y(x) = 12x − 22 y(x) = x2

Figure 1.9: Linear fitting of a quadratic function

The linear function interpolates the quadratic function with a small error in the domain, 0 ≤ x ≤ 12. Using the same linear function to characterise the quadratic function in the domain, 12 < x ≤ 24, cannot be considered to have the same accuracy. Thus the second order of complexity cannot be approximated with a first order function, without losing information.

Result : The result of the process delivers the predicted value. This result needs to be represented in a simplistic manner. There is no need to show every data point calculated or used for the calculation if the user is only interested in certain data points and therefore a smaller number of data points would be out of context.

1.3.2

Non-functional requirements

Automation will relieve resources that can be utilised elsewhere and will be monitored by the user until sufficient confidence in the method has been acquired. Automation however cannot replace human experience and expertise in understanding the underlying operations. Automation can only account for the mathematical phenomenon where the underlying operations have mathematical and logical components.

(21)

Automation can include mathematical models. Mathematical models are able to describe almost all the energy consumer subcomponents of mining operations. Each component can be represented by an approximate mathematical model so that the energy usage can be determined if every parameter in the formula is known. These properties make it possible to use a complex algorithm to determine the energy consumption and costs. It is not always possible to determine all the required parameters of the mathematical model, making an algorithm more suitable to determine or approximate the parameters automatically.

Improved accuracy can result in more accurate planning wherever there is room for improvement. Improving the accuracy of the prediction method will improve the future

estimation and can help in effectively managing energy. There is a trade-off between

improved accuracy and unexpected events. Large variations in unexpected events will

negatively affect the accuracy. Conversely, increasing the accuracy will reduce the ability to predict unplanned events. If energy consumption and costs are predicted accurately, they form an excellent base for accurate planning.

When the basis of the planning is solid, a successful outcome can be expected. Focusing more on planning, instead of the preparation will deliver improved results. If there is a feedback component in the method, it can result in improved predictions.

A prediction method is highly unlikely to have a zero error. There will always be some event that has not been accounted for or the method biases towards the wrong characteristics in the data. This method cannot predict uncommon or irregular events, for example when new equipment is installed or when unplanned production changes occur. Equipment failure or periodically scheduled maintenance is more likely to be accounted for.

A prediction method will only be based on mathematical properties that emulate the

operations and components of the system. For example, when expressing the electrical

consumption of a sub-component by using a mathematical formula. The electricity

consumption of this sub-component can affect the electricity consumption of the entire system. Formulating electricity consumption for every component in a mine is a tremendous task. By using only the largest electricity consumption components can account for up to eighty percent of the electrical consumption of a mine.

Ease of use will promote the new method within the energy management sector. The user interaction must correlate to a familiar system, a different design will increase the learning curve. If the learning curve is too high the new method will not be used. Creating a more familiar environment can reduce the learning curve.

(22)

1.4

Overview of the dissertation

This research will investigate methods to predict electricity consumption and costs for South African mining groups. The underlying logical and mathematical components predicting electricity consumption and costs will be investigated. Design fundamentals of a new electricity consumption and costs prediction method will be affected by this investigation.

The investigation will examine the present method in detail to emulate the prediction method. Systems engineering will be used to analyse the prediction of a mine’s electricity consumption and costs [30].

In this chapter the background, motivation, objectives and direction of the problem are discussed. The background of this research is provided by discussing the mining sector in general and the influence of the increasing electricity costs on the mining sector. Planning for future energy consumption is discussed by highlighting the present methodologies from where the basic requirements are defined. The final part of this chapter is to define the purview of this dissertation.

In Chapter Two the complexity of the prediction environment and the present methodologies of predicting electricity consumption and costs are discussed in more detail. The requirements are formulated by taking a closer look at selected prediction methodologies and then these requirements are evaluated.

In Chapter Three the development of the new prediction model is discussed. The

implementation of this design is highlighted and the design will then be applied to data of operational mines.

In the final chapter, Chapter Four, the dissertation conclusions are presented. This will commence with an overview of the dissertation followed by a discussion of the results and what problems were seen in the development of the new electricity consumption and costs

prediction method. Thereafter the possibility of future research on the subject will be

(23)

prediction methodologies

”Whether you can observe a thing or not depends on the theory which you use. It is the theory which decides what can be observed.” Albert Einstein

(24)

2.1

Introduction

Electricity prediction is part of the energy management process which is related to the project management process. Project management plays a vital role in the mining sector. It has become a forte in the engineering field and is a simple methodology of managing complex systems. However, these systems can also have complex interactions amongst them. Some of this complexity can be described by considering Chaos Theory [31].

2.2

The

complexity

of

the

energy

prediction

environment

Chaos Theory states that small changes in initial conditions can have a large influence on the outcome. More specific to the scenario of predicting electricity consumption and costs is that the prediction made can have a large influence on the expenses of the mine. Small variances on the budget allocations of large energy consumers can increase the total costs of a mine.

Underestimating the budget for a large energy consumer may result in unnecessary penalties for exceeding the maximum notified demand. In some cases these penalties may be greater than the total energy cost of a smaller consumer. An over-estimation of a budget for a larger energy consumer may result in unused resources that could have been utilised more effectively by smaller consumers.

Consider the double pendulum experiment shown in Figure 2.1a [32]. This will help to explain the complexity of energy consumption in the mining industry. The result of an action can be complex, but the inherent properties can be simple. When the system has been modelled relative to each component’s function the result can be explained more clearly.

For example, the movement of m2 in the double pendulum experiment is illustrated in

Figure 2.1b. This movement appears to be chaotic. When visualised relative to m1 the

movement of m2 becomes much easier to understand as illustrated in Figure 2.1c.

(a) Double pendulum (b) Chaotic motion (c) Relative motion

(25)

There are many components of project management that help to reduce this complexity.

All of them have an impact on each other and is interrelated. Figure 2.2 makes use

of Venn diagrams to provide a fictional example of how various components in project management can impact each other. Where the diagrams overlap, a commonality between

the components is identified. Interactions between the components can be deduced by

studying the commonalities. Interactive decision Theory, or more commonly known as Game Theory, can be used to effectively control these interactions [33].

It should be noted that Game Theory can over-complicate the management of the project, which will then lead to the need to use of more experienced personnel or additional training. This will increase the cost and can outweigh the benefits of using Game Theory.

Cost management

Project control Time management

Work authorisation

Quality management

Figure 2.2: Fictional commonalities of a project or system

Project management can be divided into phases namely planning-, control- and the action-phase [34]. Electricity prediction forms part of the planning phase.

2.3

Existing energy budget calculation methodologies

The energy prediction procedures of a mine was investigated to understand the inherent techniques. This process, although different for each mining company, will have certain

similarities. Electricity consumption and cost prediction in the mining environment is

structured according to the electricity distribution. Electricity distribution is shown in Figure 2.3.

Eskom only records the electricity consumption at their meter. Distribution to the subdivisions are generally approximated by the mine’s internal metering system. Subdivisions can include but is not limited to hoisting, compressors, fridge plants, buildings and pumping. Subdivisions

(26)

Eskom Mine Subdivisions Components

Figure 2.3: Typical electricity flow diagram for a mine

are formed by components used in that specific division. Components consists of individual compressors, fans and pumps or third party consumers such as the hostel bar.

Energy management relates, in part, to the allocation and tracking of electricity consumption in this structure and is shown in Figure 2.4. Different methodologies have been developed over the course of time, but future methodologies will be constrained by ISO 50001. ISO 50001 is a voluntary international standard developed by International Organisation of Standardisation and is designed specifically for the application of energy management systems [35].

Electricity distribution approximation Internal

metering Eskom meter

Database of samples Present electricity consumption Budget comparison Action Planning

Figure 2.4: Typical energy management data flow

Data for energy management is collected from internal electricity meters and Eskom electricity bills. Internal electricity meter readings are measured from analogue- and digital meters. Due to the hostile environment the protective glass cover is usually scratched and covered in dirt, making accurate readings difficult and can result in unnecessary errors and inaccurate readings. A typical analogue electricity consumption meter is shown in Figure 2.5.

(27)

Figure 2.5: Analogue electricity meter

The internal meter readings record individual energy users within the mine’s structure. These readings are then used to determine the electricity usage of subdivisions within the mine as it is not specific on the Eskom bill. Only the larger energy consuming components are measured as the smaller energy consuming components contribute to less than 1% of the total consumption.

Each month the Eskom electricity bill is received for the total energy consumption and costs of the mine for a specific month and is shown in Figure 2.6. The data on the bill is recorded for historical comparison and future predictions purposes. Electricity consumption is the more important item on these Eskom bills and is measured in kilowatt-hour (kWh). Samples are drawn from this data for prediction calculations.

Figure 2.6: Eskom electricity bill example

At present the historical data is typically kept in Microsoft Excel in a monthly summary

of the electricity usage. The historic data is used for comparing existing energy usage

with the assigned budget or to predict electricity consumption and costs. Monthly budgets are compared to the allocated budget and if the budget is exceeded, the reasons will be

(28)

investigated and corrective action will be taken to rectify the event and to ensure that the annual budget is not exceeded.

The existing electrical consumption prediction is done by taking into account the historical electricity consumption and personal experience. Personal experience gained by repeating this process plays an important role in calculating the expected future energy usage.

Electricity consumption prediction as used by the mine at present begins by dividing a system into all major energy consuming components. Each of these components are then simulated

by using their specifications to determine their energy consumption. The simulation is

done over hourly intervals and by using operating conditions as close as possible to actual conditions.

The simulation results are reviewed by all the accountable personnel and submitted for evaluation. These results are evaluated in the global scope of the mine. Adjustments are made until all the targets are met. These targets range from production numbers to energy savings targets. Finally a safety margin is added to each system’s predicted consumption and this is labelled as their energy consumption budget.

Predicting electricity costs are much simpler once the electricity consumption is known. The average cost per energy unit is calculated for different electricity pricing plans. For South Africa’s largest energy consumers there are different pricing plans. The common factor between these pricing plans is that the cost per energy unit for the winter months is much larger than the summer months. The price difference is due to the supply shortage being greater during the winter months.

For the electricity cost prediction, the energy consumption prediction per system for a specific month is multiplied by the cost per energy unit. The cost per energy unit is different for standard, off-peak and peak hours. There can be up to six different costs per energy unit. Each of these costs per energy unit is multiplied by the respective electricity consumption. The result is the electricity cost for a specific month and excludes all the additional charges like the notified maximum demand charge, reactive energy charge or any other administration charges.

2.4

Prediction methodologies survey

2.4.1

Accuracy measurement

To be able to compare different prediction methods there must be a standard of accuracy measurement. Many accuracy measurement methodologies are available, of which Mean

(29)

Squared Error (MSE) is used frequently. For the comparison of different MSE values, skill score (SS) is used.

The forecast error (Et) is defined as Et = Yt− Ft, where Yt is the actual value, Ft is the

forecast value and t is the time interval. MSE is the sum of the squared forecast errors divided by the number of values and is shown in Equation 2.1. Skill score uses MSE as a measuring unit and the formula can be seen in 2.2 where M SEf is the MSE of the forecast

data and M SEr is the MSE of the reference data [36].

M SE = PN t=1E 2 t N (2.1) SS = 1 − M SEf M SEr (2.2)

Box plots will be used to display and illustrate the result of the new prediction method in this dissertation. In Figure 2.7 an example box plot is illustrated. This plot is used to show extra information on a normal line chart. The extra information shown in this plot are the minimum, maximum, first quartile, median and third quartile. This can be used where multiple data points where consolidated to form only a single data point. Box plots makes it possible to restore some of the lost information.

Third quartile

Maximum

Median

Minimum First quartile

Figure 2.7: Illustration of a Boxplot

2.4.2

Data preparation

The data will be retrieved from the MySQL database. Further conversion is required so that the effect of uneven distributions can be attenuated. The most common method to even out the distribution differences is data normalisation. Data normalisation converts selected data to a specific distribution.

(30)

variable, z, is calculated using the formula shown in Equation 2.3 [37]. In this formula x is the data value, µ is the statistical mean of the data and σ is the statistical standard deviation of the data. The standard normal distribution is illustrated in Figure 2.8a.

z = x − µ σ (2.3) −3 0 3 0 0.1 0.2 0.3 0.4 χ ϕµ,σ 2(χ )

(a) Standard normal

0 0.5 1 0.5 1 1.5 2 2.5 χ ϕµ,σ 2 (χ )

(b) Modified standard normal

Figure 2.8: Distribution curves used in normalisation

The standard normal distribution is suitable in most cases, but for simplicity of calculations this distribution is modified from a 0 mean and standard deviation of 1 to a 0.5 mean and standard deviation of 1/6 using z = (x−µσ + 3µ)/6µ. This modified distribution is illustrated

in Figure 2.8b. Using this distribution simplifies calculations as 99.74% of the values are within the range of 0 < x < 1 [37].

2.4.3

Existing method

Presently the energy prediction method used in the mines are the Delphi method [38]. The Delphi method is a recursive method where an experienced opinion weighs more than any other. This method is used to reduce the human calculation errors present in the simulation of the sub-system components. This can be beneficial for applications using a large amount of information to base a decision on. The downside of this method is that it is time consuming and requires experienced personnel. A proposed solution is to combine the Delphi method with a more automated method to reduce the time spend by personnel on simulations. In Figure 2.9 the annual production and energy consumption data are visualised over a seven year period. These datasets will be used as input in the sections that follow. The prediction data shown in orange is the result of the present method used by the mine.

(31)

2008 2009 2010 2011 2012 0.2 0.3 0.4 0.5 0.6 Year Normalised v alue

Consumption prediction Production Consumption

Figure 2.9: Electricity consumption prediction for July using the present method production trend from the year 2008 to the year 2010 and from 2011 to 2012. In general the electricity consumption tends to follow the production trend. In this example however that is only true for the selected periods. The scale of the trend is disturbed from the year 2010 to the year 2011, which signifies a change in operations.

Let the intensity of the mining operations be the energy used to excavate earth or kWh per ton milled. The average intensity from the year 2008 to the year 2010 is 187 kWh/ton where as the average intensity from the year 2011 to the year 2012 is 269 kWh/ton. This can signify the mine’s end of life, where it is no longer financially viable to continue mining. The existing electricity consumption prediction methodology wrongfully predicted a decrease in consumption for July 2012 whereas the actual consumption increased. This increase in consumption can be explained by an expected decrease in production in the year 2012, thus continuing the downward trend from the year 2009. The actual kWh/ton ratios from the year 2011 and the year 2012 barely changed which signifies that the assumption that the intensity will continue to decrease is wrong.

2.4.4

Linear regression method

Linear regression creates a linear equation to approximate the data [37]. This is useful as it can indicate whether the general trend for the data is increasing or decreasing. Linear regression will however not be accurate enough when the data has non-linear characteristics which will cause the linear regression to incorrectly approximate the data. This can be

(32)

validated by using a non-linear approximation and comparing the MSE of both approximations. The non-linear approximation will have a smaller MSE than the linear approximation when.

In Figure 2.10 a linear regression approximation is illustrated. The data to be approximated is e(x) and the linear approximation is f (x). The function f (x) has the Equation 2.4, where a and b are scalars. The scalar a can be calculated using Equation 2.5 and b using Equation 2.4 when a is known. To determine the accuracy of the approximation, the MSE is calculated as in Equation 2.6. 0.3 0.35 0.4 0.45 0.5 0.55 0.6 0.65 0.7 0.75 0.8 0.85 0.45 0.50 0.55 0.60 0.65 0.70 0.75 0.80 0.85 x Normalised electricit y consumption f(x) e(x)

Figure 2.10: Linear regression approximation of non-linear data

Equation 2.5 will become more computational intensive as the number of data points increases. To reduce the computational complexity and create a methodology applicable for both single-and multi variable linear regression, the steepest descent is used for approximating a single-and b [39]. f (x) = ax + b (2.4) a = Pn i=1(xif (xi)) − ( Pn i=1xi Pn i=1f (xi))/n Pn i=1x 2 i − ( Pn i=1xi)2/n (2.5) M SE = Pn i=1(f (x) − e(x)) 2 n (2.6)

Approximating parameters a and b using steepest descent can have multiple solutions, there can be multiple minima as illustrated in Figure 2.11. The blue coloured surface highlights the

(33)

possible solutions where the MSE is the lowest. Parameters a and b are randomly initialised on the solution surface as a0 and b0.

−0.4 −0.2 0 0.2 0.4 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 0 0.2 0.4 0.6 a b M S E

Figure 2.11: Example error surface of Equation 2.4

Steepest descent is used to change each parameter with Equation 2.7, where α is the step size and ∇M SE is the gradient of the solution surface at that specific point. If α is too large, the parameters will not converge; however an acceptable range is within 0 < α < 1. Steepest descent will move the parameters to the minimum MSE. The change in each parameter can be calculated by using the batch update method. Equation 2.8 and Equation 2.9 must be calculated consecutively for each step. The process is repeated until Equation 2.7 is almost zero. −α∇M SE (2.7) an+1= an− α d daM SE = an− α d da  Pn i=1(f (xi) − e(xi)) 2 n  (2.8) = an− α 2 n n X i=1 xi(f (xi) − e(xi)) bn+1= bn− α d dbM SE = bn− α d db  Pn i=1(f (xi) − e(xi))2 n  (2.9) = bn− α 2 n n X i=1 (f (xi) − e(xi))

(34)

Due to Equation 2.7 converging to zero in most cases, the relative zero is chosen as the goal. For instance if the parameters fall between 0 and 10, the goal zero for Equation 2.7 will be 1 × 10−1. If the goal is chosen to be 1 × 10−20 it can take much longer to converge. The accuracy gained by using a smaller error is, in most cases, not significant.

In Figure 2.12 a more complex solution surface is illustrated. In this Figure multiple minima exist and depending on where the parameters are initialised, different minimums can be found. This is one of the drawbacks of steepest descent and can be solved with different approaches depending on the scenario. For simplicity steepest descent in the original form will be used in the calculations.

0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 0 0.2 0.4 0.6 0.8 1 0.5 1 1.5 x y M S E

Figure 2.12: Example surface with multiple minima locations

Data is approximated using Equation 2.4 where f (x) is electricity consumption and x is the date. The parameters a and b are calculated using steepest descent. The difference between steepest descent and statistically determining the parameters is trivial.

By using a single trivial variable to determine electricity usage, there is a limitation as it cannot detect variations in other influences that is not it’s own. To account for other influences a multiple regression model must be used to create a more non-linear fit. An example of multiple linear regression is shown in Equation 2.10; where z is the data and x is the total tons milled. Parameters a, b and c are determined with the steepest descent method.

y = θ2x2+ θ1x1+ θ0 (2.10)

For multiple variable regression it is recommended to use a matrix formula as shown in Equation 2.11; where θnewis the updated parameters and has the definition as in Equation 2.14,

(35)

θold is the previous parameters, α is the learning rate, X is defined in Equation 2.12 and Y is defined in Equation 2.13 [39]. θnew = θold−  2α m  (XT(Xθ − Y )); (2.11) Xm,n =       1 x(1)1 x(1)2 · · · x(1)n 1 x(2)1 x(2)2 · · · x(2)n .. . ... ... . .. ... 1 x(1)m x(2)m · · · x(n)m       (2.12) Ym,1 =       y(1) y(2) .. . y(m)       (2.13) θn,1 =       θ(1) θ(2) .. . θ(n)       (2.14)

Equation 2.11 is used iteratively to update θ and determine the accuracy. The parameter θ will initially change in larger amounts than when closer to convergence, which is due to the gradient being used as step size. When the gradient is small, closer to convergence, the step size is also small.

The normal equation shown in Equation 2.15 can be used without gradient descent, but will result in being slower when using a large number of inputs. When the number of samples are relatively small, the normal equation is the more effective solution.

θn,1 = X−1× Y (2.15)

In Figure 2.13 linear regression is used to predict annual changes for a specific month’s electricity consumption by using a single variable linear regression (SVLR) with the steepest descent algorithm and multiple variable linear regression (MVLR) [37]. For SVLR the input is time and the output is energy consumption. For MVLR the inputs are time and tons milled, the output is energy consumption.

The Octave source code for the single variable linear regression is illustrated in Listing B.1 and multi variable linear regression is illustrated in Listing B.2.

(36)

2008 2009 2010 2011 2012 0.35 0.40 0.45 0.50 0.55 Year Normalised prediction SVLR MVLR Consumption

Figure 2.13: Energy consumption prediction for July 2012 using linear regression as the SLVR prediction. The SVLR prediction only captures one important characteristic which is the linear trend that the consumption data is increasing over time. The MVLR prediction captures a small amount of the non-linearity of the data.

The denormalised MVLR prediction error is 0.7% or 172 MW larger than the SVLR prediction in predicting the energy consumption for January 2012. SVLR made a denormalised 4.5% error which is an underestimation of 1.11 GW. MVLR made a denormalised 5.2% error which is an underestimation of 1.28 GW.

This method is not suited as it is not able to account for non-linear characteristics. Non-linear characteristics can include the impact of the climate on fridge plants or unplanned increases in production. Both these influences will affect the electricity consumption of the normal operational values.

2.4.5

Artificial neural network method

An artificial neural network is a simplified computational implementation of a human brain [40, 41]. In Figure 2.14 a multilayer feedforward neural network is illustrated. Relative to multiple variable linear regression it is almost identical, but there are however a larger number of parameters to solve and the parameters can influence each other.

Neural networks can account for non-linear trends in data. Training a network consists of feeding the network data points and in doing so the algorithms will “learn” from the data [42].

(37)

Hidden layer Input layer Output layer

Figure 2.14: Artificial neural network structure

There are specialised methods for training a neural network, each with varying degrees of accuracy and complexity. The complexity of the data is dependent on the complexity of the network, amount of data used and training algorithm [43].

In Figure 2.14 the different layers are visible which are named input-, hidden- and output-layers. The input layer has neurons representing the number of input parameters. There can be multiple hidden layers and the optimal number of hidden layers is dependant on the complexity of the data. The output layer has neurons representing the number of output parameters.

Between two layers all the neurons are connected with each other. These connections are governed by an activation function. The influence of a specific neuron is determined by using the calculated weight and the activation function for all the paths connected from that neuron to the output layer.

There are a number of training algorithms for artificial neural networks and they are classified into three major paradigms namely supervised-, unsupervised- and reinforcement-learning. Supervised learning is where the input and output is known. Unsupervised learning is where data needs to be classified and only the input is known. Reinforcement learning is where input and output is generated by exploring the solution surface.

In this dissertation the focus will be on the back-propagation learning algorithm [44]. This algorithm is very similar to the steepest descent algorithm. This algorithm first calculates the error of the output layer and this error is then fed back to the previous layer. The weights in the the layers are updated using a generalised delta rule which is also found in steepest descent. This is repeated for all the layers. This process is repeated until the error converges or a specified number of iterations has been calculated.

(38)

A neural network was created and trained using the time and energy consumption. This network is labelled Single Variable Artificial Neural Network (SVANN). Another neural network is created and trained by using time, tons milled and energy consumption. This network is labelled Multiple Variable Artificial Neural network (MVANN). The results of both these networks are illustrated in Figure 2.15. The C language source code for the simple artificial neural network is illustrated in Listing B.3.

2008 2009 2010 2011 2012 0.35 0.40 0.45 0.50 0.55 Year Normalised prediction

SVANN MVANN Consumption

Figure 2.15: Energy usage prediction using artificial neural networks

In Figure 2.15 the MVANN prediction encapsulates more of the electrical consumption data characteristics than the SVANN prediction. The SVANN prediction captures a non-linear trend where the consumption increases over time, but the rate of increase is declining. The MVANN prediction captures the non-linearity of the data and correctly predicted a large increase in consumption data for the year 2012.

The denormalised SVANN prediction error is 1.1% or 282 MW larger than the MVANN

prediction in predicting the energy consumption for January 2012. SVANN made a

denormalised 5.1% error which is a underestimation of 1.27 GW, whereas MVLR made a denormalised 5.2% error which is a underestimation of 0.98 GW.

2.4.6

Summary of methods

The example predictions made in this chapter are assuming that there is previous data points available to “learn” from and that the production figures are known for the predicted year. These predictions are invalid in a real life application as future production figures is not

(39)

known.

In Figure 2.16 the most suited correlation from each tested method is plotted for comparison. This figure illustrates that the Multiple Variable Artificial Neural Network (MVANN) method and the Multiple Variable Linear Regression (MVLR) method found equally good data characteristics. This can be attributed to the small number of input parameters. If the input parameters are to be increased to achieve better accuracy, the MVANN will outperform the MVLR. 2008 2009 2010 2011 2012 0.35 0.40 0.45 0.50 0.55 Year Normalised prediction MVLR MVANN

Existing method Actual consumption

Figure 2.16: Electricity consumption prediction summary

In Figure 2.16 the prediction errors for the year 2012 are all below 5%. The production and consumption data for the year 2010 has the largest error and it is also where the normalised values for each of these parameters correlates the closest to unity.

The performance of all the methods are summarised in Table 2.1 below. The best performing methods are the multiple variable artificial neural network and the multiple variable linear regression. These methods have a normalised mean squared error below 3 × 10−3 and a skill score above 95%.

The single variable methods were less accurate than the multiple variable methods and this was expected. It highlights the complexity of the data and the need for a non-linear solution for the prediction of electricity. The MVANN method will be used to predict the electricity usage and costs for the implementation as the neural network is more likely to find the global minima when the input parameters increases or when the solution surface becomes more complex.

(40)

Method July 2012 error (Denormalised %) Mean squared error (×10−3) Forecast skill (Denormalised %) Existing Delphi-like method 3.377 8.505 n/a Single variable linear regression method using gradient descent 4.482 4.417 91.601 Single variable linear regression method using statistical formula 4.474 4.411 91.611 Artificial neural network - Single variable 3.298 3.998 92.397 Artificial neural network - Multi variable 4.061 2.516 95.216

Multi variable linear regression using the

normal equation

3.412 2.210 95.797

Multi variable linear regression using gradient descent

3.408 2.208 95.802

Table 2.1: Summary of prediction methods’ statistics

2.5

Design parameters of the new energy prediction

methodology

2.5.1

Data

Data used in this dissertation will be collected from a South African mine which shall be named Mine X as the privacy of the mine is protected. Mine X is one of the company’s largest electricity consumers. Mine X has one shaft and is more than 2 km deep.

Initial data is received for a specific mine in a digitally protected PDF document which makes it difficult to process. Commercial solutions are available, but at a price that outweighs their usefulness. An open source project namely XPDF, developed a utility named “pdftotext”

(41)

and is presently maintained by the freedesktop project named Poppler [45–47]. This utility has a Command Line Interface (CLI) and is capable of extracting the data within the digitally protected PDF document.

When the data is extracted, the data labels can be identified and collected using regular expressions. This process can be automated with a script executing the “pdftotext” utility and then parsing the output to retrieve the required data. Parsing the data is to apply a filter to the data using regular expressions and to extract the needed information [48]. Automating the data extraction saves time and money which makes it more efficient. The extracted data must be stored for future reference and auditing purposes. Many data storage options are available, but there is a need for a redundant and cloud scalable solution which narrows down the options. Creating an application which is cloud ready makes future options available when the user demand exceed the physical limitations of a single computer. It is convenient if the database software is compatible with the integration software solution. MySQL is reliable, decentralised and a commercial grade product for storing data [49]. Using Structured Query Language (SQL), statistics can effectively be extracted from the database [50]. Most cloud based solutions also use MySQL, thus the data will be ready for any cloud based solution in the future. Data can be extracted from the database using any programming language that has a MySQL client implementation.

The PHP language is used as the programming language for the software solution [51]. PHP can be used for example to execute the pdftotext utility, parsing the data and extract markers during the parsing with the built- in regular expressions.

2.5.2

User interface

The user interface (UI) forms an integral role of any product as it is the “face” of the product and the usability thereof is of high importance. There are multiple sources for UI design. Apple and Google strongly motivate developers to adhere to their mobile operating systems’ application UI design standards [52, 53].

The conceptual UI is illustrated in Figure 2.17 and will be used in designing the UI for the implementation in the energy management solution.

The results of a prediction should be converted back to the original distribution so that the data can be understood in the original context. These results should be displayed for the user so it can be analysed and used for planning. Excessive data in a UI can confuse a user while insufficient information cannot help a user in interpreting the result.

(42)

Figure 2.17: Conceptual design of the user interface

solution. Microsoft Excel has a limited programming language, Visual Basic for Applications (VBA), compared to modern programming languages. There are existing libraries to retrieve data from MySQL using Microsoft Excel and VBA, but it will be more time consuming to implement as opposed to using modern programming languages. By creating a stable application in Excel and integrating this into the energy management solution will be more time consuming.

It is feasible to create an application that translates the results to Microsoft Excel. Building an user interface with modern programming languages will be much more time effective. Most modern programming languages makes use of an external framework or library and it must be included in the installation of that application. This requires the installation of third party software on the client’s computer which is not desirable. An alternative and better option would be to develop a web based application, which only uses the standard Internet browser.

A popular cross platform and cloud ready programming language is PHP which has native extensibility as it supports extensions in the C and C++ language. There are also active on-line collaboration of frameworks and libraries that is written in PHP. PHP is also an open source project, so it can be customised for specific scenario and individual needs. PHP, HTML and JavaScript will be used to create the UI.

jQuery is a popular JavaScript library which is compatible with most popular web browsers [54]. jQuery can be used to greatly ease the use of client side scripting. jQuery also has user interface element which makes designing a modern user interface much easier.

(43)

2.6

Conclusion

The mining environment is a complex system and predicting electricity consumption and costs adds more complexity. Prediction is such a complex environment that a non-linear algorithm is the best fit. As the mining environment has a large number of variables which have an influence on the electricity consumption and costs, the most suitable option would be to use an artificial neural network. The data model chosen is of great importance when using an artificial neural network.

(44)

new energy prediction methodology

”Knowledge is necessary, too. An intuitive child couldn’t accomplish anything without some knowledge. There will come a point in everyone’s life, however, where only intuition can make the leap ahead, without ever knowing precisely how. One can never know why, but one must accept intuition as a fact.” Albert Einstein

(45)

3.1

Introduction

The data model is crucial when using artificial neural networks as the data used for training greatly influences the accuracy of the results. Once a data model is chosen the prediction process can be integrated into an energy management platform. The user interface will be the front-end of the application and will largely influence the users opinion about the application. The company Apple uses the user experience as a large influence on their products.

3.2

Prediction methodology development

3.2.1

Using models

Crucial to development of a prediction methodology is the prediction model. The prediction model determines what data is used, how the training of the neural networks are handled, what software is used and how a sufficient training is determined. Each model iteration improves upon the previous model and in most cases a small change is done in each new model to reduce the effect the changes may have on each other.

3.2.2

Model 1 - Interpolation

This initial artificial neural network prediction model was developed by using the total energy consumption as provided by the mining company. This information was used to calculate the accuracy using interpolation. The result was an accurate correlation but this neural network could not predict electricity consumption due to larger extrapolation errors.

The electricity consumption for the previous twelve months was captured as input so that the neural network can learn how to calculate the following twelve months as output. Twelve months were chosen as there is an annual cycle followed by the electricity consumption data as illustrated in Figure 3.1.

This artificial neural network is over trained as it was trained until a certain number of iterations has been reached, which in this case was 500 iterations. Over training a network is when interpolation of a network has smaller errors than extrapolation, the network is localised on the data used for training. This is not optimal for use in prediction as the accuracy of a prediction can increase if the network is trained until it has generalised a solution on the data [55]. Over training biases the network on the training data and fails to accurately account for data samples not in the population [55].

(46)

1 2 3 4 5 6 7 8 9 10 11 12 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8

Month of the year

Normalised

v

alue

2006 2007 2008 2009

2010 2011 Average

Figure 3.1: Electricity consumption yearly trends

This model was implemented in the C# programming language using the Encog library [56, 57]. The data in this model was scaled by subtracting the minimum value and dividing the answer by the maximum value to improve the learning convergence and control the numerical range of the error. The model used back-propagation in the training of the neural network to speed up training [58]. Back-propagation uses gradient decent which can be negatively impacted by using large step sizes in search for minima [59]. The hidden neurons of the neural network were chosen to be a constant value of 1000, as the data is assumed to have a high order of complexity. The Encog library implements back-propagation complies with the requirements and can be used in this scenario.

The downside of Model 1 includes that the error of the neural network was smaller when using interpolation as opposed to extrapolation, i.e over-training. Numerically the data sample count was insufficient for accurate training; only four data sets could be extracted from five years of data. Most significantly of Model 1 is the inability to extrapolate values, making prediction using this model not feasible.

3.2.3

Model 2 - Extrapolation

Model 2 is improved by generating more training samples from the available data and using entries from a single mine instead of summarised entries representing all the mines as used in Model 1. These data samples were arranged so that it would be able to use it in predicting values. For example, if previous values of x, y and z influence future values of d, the neural

(47)

network can be trained by arranging data to have sufficient information to form the equation axi−1+ byi−1+ czi−1 = di. After training the network, the values for xi, yi and zi can be

used to calculate the value of di+1.

The data samples used in training were increased by moving the 24 month data window 1 month ahead for a single sample. In Model 1 the 24 month data window is moved ahead 12 months for a single sample. This change in the data sample generation created about 36 data samples from the data history spanning 5 years. More data samples can increase the ability to find more data characteristics. Each mine has a unique energy consumption profile and it is not feasible to train a network that generalises on data samples from all the mines. Such a network can not be used to predict electricity consumption and costs for an individual mine.

The most significant drawback of Model 2 is the large data window as this required a large data history for more accurate predictions. Model 2 can predict values using extrapolation better than Model 1, but the accuracy is not in a range where it is implementable.

3.2.4

Model 3 - Reduced data window

Model 3 is improved by using a smaller data window data samples used to train the neural network. Using a smaller data window can decrease data characteristics detection ability but would allow the network to be trained with a smaller data history.

The minimum number of months needed for a prediction with the same range of prediction errors as Model 2 was found to be four months. With less than four months the data characteristics fails to be detected. Four months of electricity consumption was used as input and the fifth month was used as an output for the neural network. Using the smaller data window generated about 55 training samples from the data history spanning 5 years. Insufficient data characteristics detection was the most significant drawback of Model 3. Some months made larger prediction errors than others as the neural network could not detect data characteristics for individual months using the smaller data window.

3.2.5

Model 4 - Increased inputs

Model 4 is improved by using extra input parameters other than the date and previous energy consumption in an attempt to detect more data characteristic for individual months. There were a number of factors to consider when predicting energy consumption and costs for example the weather conditions, the price of commodities such as gold or platinum and production figures [60].

Referenties

GERELATEERDE DOCUMENTEN

Just like Wilson’s theory of persuasive message production advances the notion that pursuit of goals is the underlying drive in persuasion, it became clear from my study

Effect of Number of Styles on Comparability, Influence, Valuation, Versatility, and Competence of the Artist, and Transgression and Attractiveness of the Focal Painting.. There is

Voorde,t van die simptome binne dio kenlewe van die dislektiese kind afgestap word en na die versteurings in die emosionele en (::ltrewingslewe verwys word 9

In this section the algorithm that is used for the scenario analysis is shown. Firstly the initual values are given. This are based on Ortec Finance’s ALM model. Secondly,

One World Trust (reference) uses four practical terms to determine the extent of accountability: being open and transparent about activities and decisions involving internal

(2000) argue that securities litigation and the contracting explanation of earnings conservatism are more applicable to common-law countries, I hypothesize that the effect of

Similarly, Magda in In the Heart of the Country is stuck in the traditional and ideal representation of farm novel female characters, which combines the politics of the African

I have selected six social factors that are more relevant in the case of Iran, namely religious knowledge (or religious human capital), parents’ religiosity, peer groups,