Synthetic High Resolution Solar Data
Department of Mechanical Engineering
Synthetic High Resolution Solar Data
Author: David Alexander McCracken
Supervisor: Dr Nick Kelly
A thesis submitted in partial fulfilment for the requirement of the degree
Master of Science
Sustainable Energy: Renewable Energy Systems and the Environment
2011
Copyright Declaration
This thesis is the result of the author‟s original research. It has been composed by the
author and has not been previously submitted for examination which has led to the
award of a degree.
The copyright of this thesis belongs to the author under the terms of the United
Kingdom Copyright Acts as qualified by University of Strathclyde Regulation 3.50.
Due acknowledgement must always be made of the use of any material contained in,
or derived from, this thesis.
Signed: David McCracken
Date:8/09/2011
2
Abstract
In the modern world the collation of data relating to a field of study is the key to
improving and advancing that field of study. This statement rings true for the study of
how the variability of solar radiation impacts on dependent systems such as
photovoltaic‟s and systems which are intrinsically linked to solar radiation levels such
as lighting and heat gains and thus energy usage, within the built environment.
However, for years the analysis of energy generation using photovoltaic‟s and the
modelling of energy usage within the built environment have been studied using
hourly averages of solar radiation data. This for a long time was deemed adequate but
as the drive to reduce global warming has intensified, so too has research in these
areas and it has become abundantly clear that to truly improve and understand the
effect solar variability has on these dependents , higher temporal solar radiation data
is needed. Only now have institutions and universities started to measure solar data to
such a resolution that it can be used in detailed investigations, and currently only a
small number of places are doing so limiting the locations of these studies. As such a
method of turning the abundantly available hourly averages of solar data into high
resolution data sets would be extremely useful to the science and engineering
community. Consequently the aim of this project was to develop a simple method
which could be utilised to generate 5 minute resolution data using hourly means as a
basis.
In order to achieve this aim the model constructed used an approach that utilised a
number of transition probability matrixes in conjunction with a first order Markov
chain process, which would allow for the stochastic generation of synthetic high
resolution data.
It is shown within this report that this method achieves good correlation with
measured data when a frequency distribution is considered over the period of a year.
This is achieved not only for the location of Reading where the original data to
construct the transition probability matrixes was sourced but also for locations outside
of Reading.
3
The model described within this report is provided freely and is available for
download from the Energy systems research unit (ESRU), University of Strathclyde
website.
4
Acknowledgements
This thesis simply would not have been possible without the support and help of a
good number of people.
I would like to thank my Mum and Dad for their continued support, without which i
simply would not have been able to undertake this master‟s degree. I would also like
to thank my sister, niece and nephew who broke up my research with little bits of fun.
A big thank you must be given to my academic supervisor for this project, Dr Nick
Kelly, who kept me on track and provided focus and help when needed.
Also my appreciation must be given to Michael Roy Stroud of the University of
Reading and Martin of Hebrides weather, as without their help, and data this project
would have been simply impossible.
A final thank you should be given to my friend Kimberly Roan, who took the time to
proof read this report.
Thank you all.
5
Table of Contents
1.0 - Introduction ....................................................................................................... 10
1.1.
Increase in renewable energy and Photovoltaic‟s ......................................... 12
1.2 - Reducing energy usage in the built environment ............................................ 14
1.3 – The need for high temporal resolution in solar data ....................................... 14
1.3.1 - Supply and demand ................................................................................... 15
1.3.2 - Solar inverter and variable solar irradiance ............................................ 19
2.0 - Background information ................................................................................... 22
2.1 - Solar Energy .................................................................................................... 22
2.2 - Solar radiation and its components .................................................................. 22
2.3 - Generation of electricity using Photovoltaic‟s ................................................ 23
2.4 - Solar measurement .......................................................................................... 25
2.5 - Cloud cover...................................................................................................... 26
2.5 - Aim s & Objectives ......................................................................................... 30
3.0 -Literature review ................................................................................................ 31
3.1 - Solar models and studies of low resolution ..................................................... 31
3.2 - Existing computational models ....................................................................... 32
3.3 - Current High resolution models ...................................................................... 34
4.0 - Model Construction ........................................................................................... 37
4.1 - User input ........................................................................................................ 38
4.2 - Generation of Clear sky index ......................................................................... 39
4.2.1 - Clear Sky Radiation(Rso) .......................................................................... 39
4.2.2 - Clear Sky model equations and operation ................................................ 41
6
4.2.3 - Clear sky index calculations ..................................................................... 49
4.3 - Generation of 5-minute resolution Global horizontal radiation data ............... 50
4.3.1 - Transition probability matrix (TPM) construction ................................... 50
4.3.2 - First order Markov Chain process ............................................................ 52
4.3.3 - The generation of 5-minute resolution global horizontal radiation data . 53
4.4 – Splitting Global horizontal radiation into direct and diffuse components ...... 56
5.0 - Model Validation ............................................................................................... 61
5.1 – Method used and frequency distribution graphs ............................................. 62
5.2 – Input data from different location ................................................................... 64
6.0 – Conclusion and Further work.......................................................................... 66
6.1 – Conclusion ...................................................................................................... 66
6.2 – Further work.................................................................................................... 67
7.0- References............................................................................................................ 69
8.0 - Bibliography ....................................................................................................... 74
9.0 - Appendixes ......................................................................................................... 75
7
List of Figures
Figure 1: CO2 emissions by source ............................................................................ 11
Figure 2: UK energy production by fuel type ............................................................. 11
Figure 3: Installed capacity Photovoltaic‟s ................................................................. 13
Figure 4: Summer and winter demand profiles ......................................................... 16
Figure 5:Supply/demand profile ................................................................................. 18
Figure 6: Supply/demand profile ................................................................................ 18
Figure 7: Characteristic I-V curves of PV arrays ........................................................ 20
Figure 8: String inverter ............................................................................................. 21
Figure 9 : Micro inverter ............................................................................................. 21
Figure 10: Solar spectrum ........................................................................................... 22
Figure 11: Solar spectrum ........................................................................................... 24
Figure 12: Shaded Pyranometer .................................................................................. 26
Figure 13: Pyranometer ............................................................................................... 26
Figure 14: Types of cloud ........................................................................................... 28
Figure 15: Overview of generation procedure ............................................................ 37
Figure 16: User interface ............................................................................................ 38
Figure 17: Comparison of measured and modelled data ............................................ 40
Figure 18: Comparison of measured and modelled data (ASCE) method only ......... 41
Figure 19: Solar altitude angle (β) .............................................................................. 44
Figure 20: Solar Azimuth (γs) .................................................................................... 44
Figure 21: Solar Zenith angle (θz) .............................................................................. 45
Figure 22: Clear sky Index (5 minute intervals) ......................................................... 50
Figure 23: Transition probability matrix example ...................................................... 52
8
Figure 24: Operational process of model .................................................................... 54
Figure 25: Global horizontal radiation calculation procedure .................................... 56
Figure 26: Comparison of calculated and measured direct components .................... 60
Figure 27: Comparison of calculated and measured diffuse components .................. 60
Figure 28: Stochastic generation difference (Good fit to measured data) .................. 61
Figure 29: Stochastic generation difference ............................................................... 62
Figure 30: Frequency distribution for Reading (2008) ............................................... 63
Figure 31: Frequency distribution for Reading (2010) ............................................... 64
Figure 32: Frequency distribution for Lewis (2010) .................................................. 65
List of Tables
Table 1: Generation tariffs for solar PV .....................................................................14
Table 2: Transmittance of different types of cloud.....................................................29
9
1.0 - Introduction
Since the 1980‟s when scientists and engineers started to show that instead of the
expected global cooling the world was in fact entering a period of global warming a
vast amount of resources have been invested into firstly determining a reason for
such a rise and secondly investigating ways of combating the rise in annual mean
temperature [1].
The first issue as to what in fact causes global warming has been a contentious subject
since the issue was first reported, there have been many theories over the last 30 years
but the most compelling and convincing of these is the fact that humans are at least
partly to blame through a process known as the greenhouse effect[2].
The greenhouse effect is the process by which greenhouse gases absorb and re-emit
thermal radiation. Greenhouse gases are gaseous constituents of the atmosphere that
effectively absorb and re-emit radiation at specific wavelengths, as the radiation is
emitted on all sides part of this radiation is therefore emitted back towards the earth‟s
surface thus giving the effect that greenhouse gases trap heat within the surface
troposphere system [3]. The primary greenhouse gases are water vapour (H2O),
carbon dioxide (CO2), nitrous oxide (N2O), methane (CH4) and ozone (O3) however
there are a number of entirely man made gases which also contribute to the
greenhouse effect these include halocarbons(CFCs) and other chlorine and bromine
containing substances , hydrofluorocarbons (HFCs) and perfluorocarbons (PFCs) [3].
The reason humans are to blame for this increase in annual mean temperature is that
since the industrial revolution the amount of greenhouse gases being put into the
atmosphere has increased significantly. This is evident for all greenhouse gases but
carbon dioxide is often focused on as it has the biggest percentage contribution to the
greenhouse effect due to the concentration of it within the atmosphere (CO2 makes up
approximately 29% of all greenhouse gases [4]) this increase is also something that
has been caused mainly due to the activities of humans.
Since the industrial revolution the CO2 concentration has increased by approximately
39% from 280 to 390 parts per million (ppm)[5]. In the UK carbon dioxide accounted
for approximately 84% of the UK‟s total greenhouse gas emissions in 2009
10
(approximately 473.7 metric tonnes)[6].As would be expected the CO2 emission
discussed previously are emitted from a variety of different sources ranging from
energy to transport, figure 1 however shows that the biggest single contributor to the
CO2 output of the UK is the energy sector with 38.82%, this is because currently
73.5% of the UK‟s energy comes from either the burning of coal or natural gas[7],
both of which produce large quantities CO2 when burned, the energy sector is
followed closely by the CO2 emissions emitted from the built environment (i.e.
residential & business) with a combined total of 33.13% of the UK‟s Co2 emissions, a
breakdown of these figures can be seen in figure 1 & 2.
CO2 emission by Source (UK 2010)
3.46%
Energy Sector
15.85%
38.82%
Transport
Residential
17.28%
Buisness
Other
24.59%
[7]
Figure 1: CO2 emissions by source
Uk energy production by fuel type
(UK 2009 - 2010)
6.60%
1.90%
25.80%
18.00%
Coal
Natural gas
Nuclear
Renewables
other
47.70%
[8]
Figure 2: UK energy production by fuel type
11
As such it stands to reason that a reduction in these sectors would help the UK in
reducing its greenhouse gas emissions and tackle global warming. In an aim to
achieve this, a variety of government legislation has been implemented with the
specific objective of reducing the CO2 output of the country. The first major piece of
legislation was the “Kyoto protocol” this aimed to reduce the greenhouse gas
emissions of the world‟s major countries (referred to as Annex 1 countries) which the
UK is a constituent of, by 5.2% from 1990 levels [9]. However this has since been
superseded in most cases by greenhouse gas emission targets set by the individual
constituent countries which make up Annex 1. In the UK a number of different targets
exist as emission targets can be set by the devolved governments therefore Scotland
has a slightly different target from the rest of the UK. The current target set by the UK
government is outlined within the “climate change act 2008”, this document proposes
a target of reducing the greenhouse gas emission of the UK by at least “80% by 2050,
compared to 1990 levels” it also implements an interim target of reducing greenhouse
gas emission by 34% by 2020, again this target is against a 1990 baseline [10].
Scotland like the rest of the UK also plans on reducing CO2 emission by 80% from
1990 levels by 2050 however the interim target for 2020 has been increased from 34%
to 42% [11].
1.1.
Increase in renewable energy and Photovoltaic‟s
Both the greenhouse gas emissions targets set out in the UK climate change act and
the fact that the largest share of these emissions stems from the production of energy
has resulted in renewable energy becoming increasingly popular within the UK as this
is seen as a way of reducing our reliance on fossil fuels and therefore reducing overall
CO2 emissions. Since 2005 the generation capacity of electricity from renewable
sources has increased by 49% (from 16936 GWh to 25222 GWh [12]). This
generation capacity has been made up of wind (both onshore and offshore), hydro
(both small scale and large scale), biomass, wave, tidal and solar photovoltaics. The
majority of this generation to date is produced by older technologies such as wind,
hydro and Biomass. However other technologies such as photovoltaics are gaining
popularity and generation capacity in this area is increasing. Over the last 5 years the
total generation capacity of photovoltaic‟s in the UK has increased fivefold this is
shown in figure 3 below.
12
Installed Capacity Photovoltaics (MW)
90.0
80.0
70.0
MW
60.0
50.0
40.0
Installed Capacity (MW)
30.0
20.0
10.0
2006
2007
2008
2009
2010
Year
Figure 3: Installed capacity Photovoltaic’s[12]
As can be seen from figure 3, there has been significant increase in recent years of
generation capacity from Photovoltaic‟s this has been brought about by increased
support from government incentives which has seen non-commercial scale
photovoltaic installations increase dramatically. By generating electricity using
photovoltaic‟s the owner of the building/land will be eligible for the government
incentive scheme called “feed in tariffs” this scheme, which was introduced on the 1st
of April 2010 pays the owner a fixed rate of income called a “Generation tariff” for
every kWh of electricity that is generated. The amount paid varies dependent on the
scale of the installed device, table 1 below shows the various generation tariffs
currently available for solar PV. If this generated power is then exported to the grid a
further “export tariff” of 3.1 p/kWh is paid to the owner. This type of incentive
scheme has been utilised throughout Europe and like the UK has seen dramatic
increase in the amount of PV installation installed across the board [13][14].
13
Energy
Source
Solar
PV
Solar
PV
Solar
PV
Solar
PV
Solar
PV
Scale
Tariff
Duration
(P/KWh) (Years)
≤4 kW
new
≤4 kW
retrofit
>410kW
37.8
25
43.3
25
37.8
25
>10 100kW
32.9
25
>100kW
- 5MW
30.7
25
Table 1: Generation tariffs for Solar PV [15]
1.2 - Reducing energy usage in the built environment
The solar radiation used in the production of energy via photovoltaic‟s also plays its
part in the reduction of energy usage within the built environment which as shown in
section 1 is also a key contributor to the UKs overall greenhouse gas emissions, this is
being achieved by understanding how solar radiation and natural light can be best
utilised within a building, and how buildings and structures can be improved to
further utilise this resource and reduce energy. These sorts of tasks are being
investigated more and more during the design phase of buildings and structures via
modelling, were integrated energy modelling tools such as ESP-r are used.
1.3 – The need for high temporal resolution in solar data
Thorough investigations into photovoltaic‟s and building energy usage are generally
carried out in conjunction with measured solar radiation data which is used to
stipulate the intensity of the sun throughout the simulations. Until fairly recently it has
been felt it is adequate to use hourly averages of solar radiation data for these
activities. As the drive for reduction of greenhouse gas emissions continues and the
amount and detail of the modelling of PV output and energy usage simulations
increase it has been widely realised that hourly averages of solar radiation are no
longer sufficient as they mitigate the majority of the variability of the sun brought
about by cloud coverage which is experienced at higher temporal resolutions.
14
As such there has been a greater call from the science and engineering community for
higher resolution solar measurements to become the norm. A technical report realised
in early 2008 by the National Renewable Energy Laboratory (NREL) titled “Solar
resource assessment” [16] aims to explore the availability of solar data and review
models which can generate accurate solar data which are pertinent to the
implementation of distributed solar PV, although this report mainly focuses on the
United States of America and hones in on PV its findings are indicative to the state of
affairs seen throughout the world for solar measurement data. It states that the
resolution of current data is “inadequate” for analysing systems which are dependent
of solar radiation and that “high quality ground measurement stations that can
provide adequate time series data are very limited in number”, to this end it
concludes and recommends, among other things, that there is a need for highresolution (15 minutes or less) resource data that has “either been derived from hourly
measured or modelled results and/or for additional high quality measurement
stations”[16].Many other reports for example Vijaykumar et al [17], Skartveit and
Olseth [18], Janark[19], Suehrcke and McCormick [20,21,22], Walkenhorst, O [23],
,Gansler et al. [24], Jurado et al. [25] Olmo et al [26] and Tovar et al. [27,], have also
shown important and critical differences between low resolution (hourly) and high
resolution solar data (15 minute or less) and its effects on a variety of systems which
are dependent on solar irradiance.
The subsequent section of the report aims to explore the issues relating to the inherent
variability of solar energy and how this in turn impacts on a variety of issues such as
supply and demand, thus justifying that there is a major need for high resolution solar
data for use in a variety of industries.
1.3.1 - Supply and demand
All national electricity supply structures have variations in their power demand over
the course of a day, these demand characteristics can be fairly predictable over a 24
hour period with a minimum usually occurring during the night and peaks usually
occurring in the morning and evening when most of the population is preparing for or
arriving home from work. These peaks and troughs also vary seasonally with the
winter periods requiring more energy as a result of heating loads which are obviously
15
not experienced to the same extent during the summer months; national grid demand
profiles are shown below in figure 4 to give an example of the variations which are
experienced.
Figure 4: Summer and winter demand profiles [28]
The area under the curve in figure 4 represents the daily energy demand of the UK it
shows that the base load in the UK is of the order of 25GW during the summer, rising
to just under 35GW during the winter. However this rises to a peak of approximately
44GW and 56GW in summer and winter respectively due to the daily variations
which were discussed previously.
It is the National Grids duty to ensure that the supply of electricity matches the
demand shown in figure 4 at all times, failure to do so can result in voltage dips,
surges, frequency oscillation, harmonics and even blackouts. To ensure this does not
occur a mixture of generation plant is utilized [29]. Some of these generation plant
operate continually, these are generally used to provide the “base load” (i.e. the load
which always need to be met). Other plant is kept on a “spinning standby” this is
where it is connected to the grid and operating at part load so as to ensure stability of
connection , this is most often done with steam plant such as coal and gas and allows
for rapid increase of generation so as to match demand within an adequate time scale.
Additional power stations are available for “instant start-up” this is when the plant is
started from cold to match demand although the ability to do this is heavily dependent
on fuel type so power stations such as hydro, gas and diesel plants are normally used
for this type of generation [ 29].
Most renewable energy systems however cannot be controlled in the same way as the
power plants that are discussed above, as they only operate when the natural resource
16
they exploit allows them to (i.e. when the sun is shining or the wind is blowing etc),
this variability therefore increases the need for further spinning standby as backup.
The solar energy which is discussed throughout this project falls within this bracket as
it can be highly variable dependent on the meteorological conditions observed, this
would therefore affect the supply of any generation from Photovoltaic devices both
embedded and on a commercial scale. A recent report by the North American Electric
Reliability Corporation (NERC) [30] suggested that the output of some of their larger
multi- MW photovoltaic plants currently operation in the United States can change by
“more than 70% in five to ten minutes on partly cloudy days” [31] therefore if a
installation of this size was to be modelled it can be clearly seen that it would be
highly inappropriate to use hourly averages of solar radiation data.
Currently however no single generation site within the UK is to the same scale as the
plants discussed within the NERC report, although this is something which is rapidly
changing, for instance planning approval has recently been given for a 5MW
installation at Bodmin, near Cornwall [32]. On the whole however the UK‟s
photovoltaic generation is mostly decentralised unlike these commercial projects,
although this decentralised approach has been shown to have a smoothing effect on
the variability of power output as the PV panels are located over a wide geographic
area and thus exposed to a wide variety of meteorological conditions[33], these
localized effects should not be discounted, the graphs below show the net resultant
effect of an average demand profile (Taken from annex 42[34] ) and a simple
domestic PV installation of 5 m2 on the horizontal plain, as can be seen the variability
of the high resolution data produces a vastly different profile from the graph were
hourly averages are used(Positive is supply to the grid / negative demand from the
grid). This would inevitably have an impact on the grid and if considered over the
lifespan of the installation the output and therefore savings/profit would be very
different.
17
Figure 6: Supply/demand profile
Figure 5: Supply/demand profile
As well as the impact on supply of electricity due to the variability of solar irradiance
the demand for electricity also varies, this is mainly due to the increased use of
devices which are intrinsically linked to the outdoor irradiance levels, such as lighting
and heating. As passing clouds reduce interior light levels and solar gains humans will
react by switching on artificial lighting and heating to compensate, this can be highly
dependent on the task they are carrying out at the time, as humans also have the
ability differentiate between passing clouds and constant dull skies. Quantifying to
what degree this will affect the buildings energy usage can be extremely difficult, in
an effort to calculate these affects it has become increasingly popular for structures to
undergo a period of simulation during their design phase. This is where integrated
energy modelling tools such as ESP-r and RADIANCE are used so as to establish
thermal, visual and acoustic performance. Simulation programs like this however tend
to use hourly data or have limited high resolution data for specific sites thus
underestimating the amount of energy and light available to the occupants the author
envisages that the model developed throughout this report could be used to generate
high resolution data in such cases giving better estimates of the variable light levels
and solar gains during a typical day and thus there impact on energy usage of the
structure. [35][36]
As supply and demand are increasingly effected by the variability of renewables the
national grid can be exposed to problems in terms of predicting demand and security
of supply, however National grid fully encourages the increase in renewable
18
generation and has developed ways of combating the variability brought about by this
increase, besides increasing spare generation capacity. Currently the national grid
intends to implement a combination of schemes to tackle not only the variability of
renewables but also the expected and unexpected plant shutdowns which are
experience throughout the national electricity supply structure. These include “better
forecasting, interconnectors to the European network, electricity storage, smart grids
and use of flexible generation”. For this project the emphasis on better forecasting is
important as this is another area the model being developed by the author may be
useful. Currently most of the forecasting work done by the national grid has been in
the area of wind power this is entirely understandable as this is currently the biggest
variable source of power within the UK, but as has been shown in previous sections
embedded generation using photovoltaic‟s is increasing and if current trends continue
this could rise to approximately 3500MW of generation capacity within the UK [37]
this is also been recognised in the national grids consultation paper “Operating of
electricity transmission network in 2020” which aims to explore ways of dealing with
the changing supply and demand market [37].
With greater availability to high resolution solar data there will be greater ability to
model and predict the likely hood of energy generation from devices such as
Photovoltaic‟s. Conversely the ability to determine the likelihood and usage
characteristics of demand side devices such as lighting will increase thus inevitably
resulting in a decrease in the amount of “spinning standby” which needs to be put in
place to ensure stability to the grid.
1.3.2 - Solar inverter and variable solar irradiance
As has been explored in the previous section photovoltaic installation outputs are
obviously majorly affected by solar variability. At the heart of these grid-connected
photovoltaic devices is the “Inverter”. The inverter is the photovoltaic‟s arrays
connection to the grid and performs a number of functions. Firstly the main function
of the inverter is to covert direct current (DC) into alternating current (AC) which can
be delivered to the grid , secondly the inverter also provides a maximum power
tracking function (MPPT) , this is the method used to get the maximum possible
power from the PV array, known as the Maximum power point (MPP). As solar
irradiance and PV temperature change, so too does the output efficiency known as an
19
I-V curve, the maximum power point is located on the “knee” of the I-V curve (see
figure 7) therefore in order to get the most from the PV array as the conditions
experienced by the array change maximum power point tracking is used. This is done
by complex algorithms which sample the output and apply a resistance so as to always
remain at the maximum power point.
Figure 7: Characteristic I-V curves of PV arrays [38]
Thirdly, for safety and grid stability the inverter is responsible for grid disconnection
in the case of the frequency or voltage being different from pre-determined standards,
or in the case of an “island” meaning the grid has suffered an outage [38].
Currently in the UK there are two architectures used when it comes to inverters these
are “String inverters” and “Micro inverters”. By far the most popular of these two is
the string inverter approach mainly due to it being the cheaper option, unfortunately
this approach can be effected by the variability of cloud cover when considering a
photovoltaic array consisting of a number of solar panels. To understand how this
occurs the difference between a “string inverter” setup and “micro inverters” setup
must first be explored.
Sting Inverters receives DC power from an number of different solar panels or a
“string” of panels this DC power then flows into a single inverter which converts the
direct current in to alternating current (see figure 8), “Micro inverters” on the other
20
hand make use of smaller inverters which are attached to individual panels or small
groups of panels (see figure 9).
Figure 8: String inverter [39]
Figure 9 : Micro inverter [39]
Utilizing a string inverter, the panels are effectively connected in series therefore
whatever happens to one of the panels will inevitably have an impact on all of the
panels, when passing clouds partially shades just one of the panels connected in series
the overall output of all the panels in the array is effected, this is not the case with the
micro inverter.
The solar variability caused by passing clouds also has an effect on the predicted
output of any PV installation, if the solar variability causes the output to drop below a
certain level the inverter shuts down and enters a standby mode, upon the cloud
clearing the inverter will enter a start up procedure during which it monitors AC
voltage and frequency before eventually going online, during this time there is no
power being supplied, furthermore the inverter actually draws power from the grid.
The use of hourly averages of solar radiation data during any analysis of a proposed
system will not take into account this variability and thus any points at which the
installation enters the shutdown/start-up procedure will not be fully accounted for,
thus inevitably leading to incorrect predictions of output. Therefore a method of
generating high resolution data from these hourly means would be beneficial for
manufacturers and installers of PV devices who wish increase the accuracy of their
predictions.
21
2.0- Background information
2.1 - Solar Energy
The amount of solar energy which reaches the earth‟s outer atmosphere is 1367 W/m2
this number is referred to as the “Solar constant”, however as the solar energy passes
through the atmosphere it is absorbed and reflected by the atmosphere itself , clouds
and particles in the sky thus meaning when the energy arrives at the surface of earth
it has a maximum intensity of approximately 1000 W/m2.The wavelength of this solar
radiation ranges from 0.3μm to 2.5 μm this incorporates ultraviolet, visible and
infrared light, figure 10 shows the solar spectrum of solar radiation of both
extraterrestrial and terrestrial radiation [40].
Figure 10: Solar spectrum [40]
2.2 - Solar radiation and its components
The above section makes many references to solar radiation which is incident on the
earth‟s surface by this the author is typically referring to global radiation (It). Global
radiation however is made up of two distinct components which it is important to
distinguish between at this point, these are the direct beam radiation and the diffuse
radiation.
Direct beam radiation (Ib) is the portion of global radiation which travels in a straight
line and reaches a specific geographic location direct from the sun. Whereas diffuse
radiation (Id) is the portion of global radiation which is scattered in the atmosphere by
22
clouds and particulates and therefore does not arrive direct from the sun. They are
related such that the combination of direct and diffuse is equal to the global radiation
reaching a point on the earth‟s surface as shown in equation 1 [40].
(Equation 1)
2.3 - Generation of electricity using Photovoltaic‟s
Photovoltaic devices respond to both direct and diffuse radiation, however by their
very method of construction they have a fundamental limit as to the amount of solar
radiation which can produce energy, this limit is imposed due to the physics within
the PV cell itself.
To produce energy a PV cell is constructed in a certain way so as to encourage the
flow of electrons. A complete cell consists of two pieces of a semiconductor material
placed one above the other. One of the sections will be doped (the process of treating
a semiconductor material with chemicals to acquire special properties) using a
substance with 3 outer electrons (such as Boron) this will create a shortage of
electrons leaving behind “holes” thus creating a positive charge; this section is
referred to as the “P-type layer”.
The other section will be doped with a substance with 5 outer electrons (such as
Phosphorous), this creates a excess of electrons and gives the layer a negative charge,
This section is referred to as the “N-type layer” [41][42].The area between the P-type
layer and the N-type layer is called the P-N junction, the P-N junction has a strong
reverse electric field that acts to maintain the separation between electrons and holes.
When a light photon from incoming solar radiation with sufficient energy hits the PV
panel it excites an electron which then has the ability to break free and move into a
“conduction band”. Once free electrons are swept to the N-type region, conversely the
holes left by the absence of the electrons are swept into the P-type region. If metal
contacts are connected to both the positive and negative sides an electrical current can
be taken and used to run a load.
23
However as mentioned previously there is a fundamental limit which relates to the
energy required to free an electron from the atom so as it can enter the conduction
state. This relates to the effect the absorption of a photon has on an electron. Electrons
tend to form valence bonds with other atoms to create an element, when light photons
excite an electron it can move from its stable energy level to a higher energy level, at
this higher energy level the electron is capable of conduction hence why it is generally
called the conduction band. The difference in energy between the valance band
(Stable energy level) and the conduction band is called the “Bandgap” energy
therefore it stands to reason that only photons with energy level greater than this
“Bandgap” energy can excite electrons enough so as to move them from the valence
band to the conduction band. This provides a fundamental limit to the efficiency of
the solar panel as it means that only a fraction of the solar radiation incident on the
earth‟s surface has enough energy to promote an electron to the conduction band,
figure 11 shows the solar spectrum shown in figure 10 with the “Bandgap” energy
limit taken into account [41].
Figure 11: Solar spectrum [40]
24
2.4 - Solar measurement
When a photovoltaic array is proposed the energy which can be generated is usually
calculated using modelling tools this requires the use of solar data, the most common
type of this data is termed “Global horizontal radiation” which as discussed in section
2.2 consists of both a direct and diffuse component, when global horizontal radiation
is measured it is done so by use of a device called a Pyranometer.
Pyranometer
As discussed previously the device used to measure total global radiation (It) on a
planar surface is known as a Pyranometer. Pyranometer‟s consist of a white metallic
housing and two hemispherical glass domes inside of which a black metal plate and a
thermopile sensor are located.
As solar radiation falls onto the Pyranometer it passes through the glass hemispherical
domes, the purpose of these domes besides protecting the components inside from the
influences of wind and rain etc, are to limit the spectral response to between 0.3μm
and 2.8μm while at the same time ensuring that the Pyranometer still has a field of
view of 180°.Once the solar radiation passes through the hemispherical domes it then
falls onto the black metal plate absorption surface thus the solar radiation is absorbed
and the radiation is converted to heat.
The heat generated within the Pyranometer therefore directly depends on the
irradiance falling onto the metal plate absorber thus it can be used to determine the
broadband solar radiation. This is done by the use of the component called a
thermopile [43]. A thermopile is a device which consists of a number of
thermocouples generally connected in series. The thermocouples allow the thermopile
to convert thermal energy into electrical energy; this is done by utilizing a junction of
two dissimilar metals which when heated or cooled produce a voltage which is
proportional to the temperature change, through the use of a voltmeter it is then
possible to calculate the total global radiation incident on the Pyranometer.
By modifying a Pyranometer it can also be used to measure diffuse radiation only.
This is done by installing a shade ring which will block out the direct beam radiation
coming from the sun, however some diffuse radiation is also generally blocked out
25
and this would need to be accounted for when using such measurements. Images of a
Pyranometer and shaded Pyranometer are shown below in figure12 & 13.
Figure 13: Pyranometer [44]
Figure 12: Shaded Pyranometer [44]
2.5 - Cloud cover
When looking at solar measurements using devices such as a pyranometer it is
important to note the change in intensity of the radiation recorded, although a number
of things can influence the recorded values such as shadows of buildings and trees etc
the predominant reasons for rapidly changing values of solar radiation is cloud cover.
Clouds can be classified into many types and sub-types dependent on their height and
appearance however it is possible to place most clouds into four different categories
based on their altitudes, these are; High level, medium level, low level and vertical
clouds. However the naming convention within these divisions is generally based on
how the clouds are formed, so clouds formed by localized vertical currents were the
moist air is carried upwards above the point where condensation occurs are termed
“Cumli-form” clouds, whereas clouds formed without strong localized vertical
currents but instead by the lifting of entire layers of air are called “Strati-form” clouds
, these cloud types are often spread out in layers [45]. In addition to the wording
describing how the cloud is formed the words “nimbus” and “Fractus” often prefix or
suffix. “Nimbus” indicates a cloud which is likely to precipitate and “Fractus” is used
to describe a cloud which has been fractured into pieces by strong winds. The four
different categories of clouds are further explained below.
26
High level clouds generally form above 6000 meters and consist of predominantly ice
crystals rather than water droplets due to the low temperatures at these altitudes; this
division includes cirrus, cirrocumulus, and cirrostratus clouds. Cirrus clouds are white
clouds which have a feather like appearance and a found at height of about 7000m ,
cirrocumulus clouds are small clumps of cloud which appear in rows often between
heights of 6000m – 13000m. They are sometimes called “mackerel sky” due to them
covering the sky in such a way that they resemble fish scales , another key attribution
of this cloud is its unlikely-ness to join together to form more substantial cloud
body‟s. Cirrostratus clouds are clouds which often form around the sun or the moon
but in such a way that the sun or moon is still visible giving a halo effect [46]. (See
figure 14)
Medium level clouds form between 2000 – 6000 meters and can consist of both water
and ice particles depending on the temperature and height of formation. Medium level
clouds include Altocumulus and Altostratus. Altocumulus clouds are a grayish white
and can appear as irregular cloudlets or in bands or rows, often with one side of the
cloud being darker than the other. Altostratus clouds are a grey, grayish-blue which
often cover the entire sky allowing the sun to shine through only dimly.
Low level clouds form below 2000 meters and generally comprise of water droplets
although at colder temperatures can comprise of snow and ice particles. Again there
are two types of low cloud these are Nimbostratus cloud and the stratus/stratocumulus
cloud. The Nimbostratus cloud form a grey, dark layer and often blanket the entire
sky and are responsible for continues precipitation. Stratus/Stratocumulus clouds are
common and widespread clouds, which form a low uniform layer with a dull grey
appearance [45]
Vertical clouds can form anywhere below 2000m to above 12000m, there are two
types of vertical cloud, the Cumulus cloud and the Cumulonimbus Cloud. The
Cumulus cloud is a cloud which highly resembles a floating cotton-ball and are
recognized by the flat bases and sharp outlining, they are often isolated or in small
groups. The Cumulonimbus Cloud is a cloud which is characterised by its flat anvil
like formation this cloud is also known as the “thunderhead” due to its likelihood of
27
producing heavy thunderstorms the higher the vertical development of such a cloud
normally dictates the severity of the thunderstorm, these clouds often bring thunder
and lightning as well as heavy precipitation. Figure 14 below clearly shows all of the
clouds described in this section.
Figure 14: Types of cloud [47]
As discussed previously cloud formations are the main cause of reductions in the
amount of solar radiation that is experience at a specific geographic location, this is
because as the direct beam solar radiation attempts to pass through the cloud it is
scattered rather efficiently by the droplets of water and ice that make up the cloud,
this scattering transforms intense direct beam radiation into less intense diffuse
radiation thus the intensity of the solar radiation decreases dependent on the depth of
the cloud as more scattering occurs. As each type of cloud has its own set of
characteristics the amount of solar radiation which is scattered is partly dependent on
which type of cloud the radiation passes through. Table 2 gives an estimation of
transmittance dependent on cloud type [48].
28
Table 2: Transmittance of different types of cloud [48]
However it should be noted that these figures are very dependent on a number of
different parameters such as water and ice content, height, depth and solar elevation
angles therefore should only be taken as a rough reference also the fact that the
different types of cloud may occur at the same time thus on occasion overlapping
further effecting the values given in table 2.
The sky condition may also be varying degrees of clear, overcast and partly cloudy
this also has a significant impact on the amount of direct beam radiation which freely
reaches the surface.
29
2.6 - Aim s & Objectives
The aim of this project is to establish a simple, easy to use model which will have the
ability to transform hourly averages of global horizontal radiation into 5 minute
resolution global horizontal radiation which is representative of the base hourly data.
To achieve this a method is developed which utilises transition probability matrixes
constructed form data graciously provided by the University of Reading and a Markov
chain process. The model construction, operation and validation are shown in the
subsequent sections of this report
Objectives

Develop a simple, easy to use model which will have the ability to transform
hourly averages of global horizontal radiation into synthetic high resolution(5
minute) global horizontal radiation.

Validate the output of the synthetic data against measured data for different
geographic locations.
30
3.0 -Literature review
This section aims to explore the work that has been carried out in relation to the
generation, adaptation and understanding of solar data along with investigating a
number of methods used presently which attempt to generate solar radiation data at
varying degrees of resolution both through the use of input values of different time
periods (I.e. yearly, monthly, hourly) and through methods such as the use of satellite
imagery and meteorological characteristics related to weather and solar variability ,
this is done in an attempt to convey the amount of different methods currently used
and there complexity and to show that there is a need for the authors method which
aims to be simple and easy to use and will be made freely available.
3.1 - Solar models and studies of low resolution
Over the years there has been a number of studies and models produced and verified
by engineers and scientists concentrated on the production of solar data, either
attempting to predict the variability of solar irradiance of the future, or investigating
trends in measured solar data so as to better understand the available resource and its
dependencies, most of these models are predominately concerned with generating
low to medium resolution data of monthly, daily and hourly time serious values.
Although the aim of the authors model is to generate high resolution data (5-minute
resolution) the concepts and procedures introduced within these reports are extremely
important therefore a number of low resolution models are discussed here. These
models take a variety of forms including, statistical and numerical models, analytical
models, neural network approaches and empirical models [49].
Numerical and statistical models such as the reports presented by Mustacchi. C et al
[50] and Aguiar. RJ et al [51] attempt to generate stochastic global radiation data at
low degrees of resolution namely hourly and daily averages respectively, these reports
utilizing such methods as moving average (MA) , auto regressive (AR) , auto
regressive moving average (ARMA) and Markov chains in order to analyse and
generate data. These reports establish a significant amount of important aspects
regarding the generation of stochastic solar data, through analysis of these reports it is
also evident that approaches using auto regressive methods and similar techniques
contain “pitfalls” in that such methods are “unable to describe the statistical features
31
of solar radiation”[50] and an inability to produce “some of the basic features of
probability occurrence of radiation values”[51] however techniques which utilize a
simple Markov transition-matrix approach provides a “simple yet effective simulation
device”[50] for establishing solar radiation values.
Other methods for instance analytical approaches, which are contained within papers
such as Paulescu. M et al [52] and approaches which utilize neural networks [53, 54,
55] have also been made use of in the past with an aim to generating low resolution
global horizontal radiation data, however these methods tend to be complex in the
method they use.
All of the reports mentioned above do not adequately take into account the variability
of solar data at higher temporal resolutions, this on the whole is to do with when the
majority of the models were written as there may not have been as great a need as
there is currently for high resolution data.
However ,the low resolution models are similar in respect to the model developed
within this report, in that they predominantly generate global horizontal radiation; as
such they also give reference to methods and fundamental principles relating to the
decomposition of global radiation into its direct and diffuse components which the
author will use in subsequent sections of the report, In particular reports by Orgill and
Hollands [56] and Erbs et al [57] appear constantly throughout these reports, these
studies establish empirical methods to estimate the direct and diffuse components of
global radiation, these fundamental principles are investigated in subsequent sections
of the report along with revised and modern methods for achieving the same goal.
3.2 - Existing computational models
There are at present a number of computer based databases and atlases which are used
to deliver geographic and time varying solar radiation values throughout the world in
general these databases comprise of ground measurements, maps, reference years and
geographical information, they are sometimes referred to as “integrated information
systems” [58]. Databases and software packages such as METEONORM™, the
European solar radiation atlas and the Server Satal-light program would fall under this
category each of these software packages operates in a different manor and can
generate different outputs.
32
METEONORM™ is a commercial package which provides ground source
measurements from databases which were collated between 1986 to 2005, It has the
ability to display information relating to temperature, humidity, precipitation etc as
well as to display a variety of solar radiation values for a particular geographic
location, these values are derived from monthly values and generally displayed as
hourly time steps however the METEONORM™ package does contain the ability to
produce high resolution data of 1 – minute time steps, as this is a commercial
package there is a cost, with each licence for this software retailing at 480 Euros.
The European solar radiation atlas (ESRA) is a computational instrument which
provides knowledge and helps exploitation of the solar resource available across
Europe [58] this software and database package can be run in two modes the first is
“maps” mode and the second is “Station” mode. In map mode the software provides
maps of average monthly global, beam and diffuse radiation, using 10 years of data as
basis. In station mode the software can be used to search for data from a individual
station , the maximum resolution of this data is generally hourly however some station
do have data at “half hourly resolution”[58]. This software like METEONORM™
also comes at a cost retailing at approximately 380 Euros per licence.
The Server Satal – light program is free to use online service which provides only
maps of mean daily irradiation, frequency of skies being one of three states (i.e.
sunny, intermediate or cloudy) and a number of options allowing comparison between
certain years. Although these maps may be useful for general information about a
particular site or location they do not provide data as the other maps do and the
highest resolution contained on the maps is of an average daily irradiance which in
turn has been derived from monthly data.
Most of these programs currently do not provide the required resolution of data and
the programs which have the ability to provide such resolution are all payment
services which is unlikely to be useful for students and academics, these systems can
also be complex in the user interface with the professional systems having a vast array
of settings.
33
3.3 - Current High resolution models
As has been shown continually throughout this section, scientist and engineers have
studied solar energy, its decomposition and its variability in many different reports,
most of the reports however have focused on the study and generation of low to
medium resolution data in monthly, daily and hourly time steps, such as those shown
in section 3.1, this is mainly due to the worldwide measurement of solar data being
generally stored in these low to medium resolutions.
It has also been shown that as the world moves towards more sustainable means that
high resolution data will become more important, this again has been shown in a
number of reports, were particular attention has been paid to exploring the difference
between hourly and minutely solar radiation data such as Suehrcke et al [22] and
Gansler et al [24] these reports state quite clearly that the difference in variability
between hourly and minutely data when taken in the context of solar systems such as
photovoltaic‟s will lead to the electrical energy output being “significantly different
when using minutely data” as opposed to hourly data, “due to the variability” which is
not accounted for [24]. Therefore the aim of the author‟s project is to generate
stochastic high resolution data of 5-minute time steps from an hourly input thus taking
account of this variability as best we can.
As the problems of solar variability and its impact on systems which rely, or are
dependent on the sun have been further explored, attempts by a number of groups
have been made to achieve a similar goal in respect to the generation of high
resolution data, in particular reports by Skartveit and Olseth[18], Walkenhorst, O et al
[23] and Richardson and Thomson[59] have laid the foundations for the work the
author is attempting within this report, what these reports achieve and how this relates
to the authors project will be shown here.
The report by Skartveit and Olseth [18] sets out, and satisfactorily achieves the
production of realistic time serious data of high resolution global and beam irradiance,
with hourly averages provided as an input. It achieves this by using probability
distributions of the short term irradiance data, and combining this with an
autoregressive model thus producing intra-hour short term, time series outputs.
Although the modelled results displayed within this paper show good correlation to
the measured results, which are also displayed within the paper, it has been shown in
34
preceding sections of this report that autoregressive models taken as a whole can find
it “difficult to describe the statistical features of solar radiation”[50].Furthermore the
output resolution of the values produced by the model have a maximum resolution of
15 minutes, although this time step will display a large majority of the solar
variability experienced it will inevitably mitigate some of the short term variability.
The impact of this would be minimal when taken into consideration over a singular
day but over a longer period, such as a month or year; this could have an impact on
reactive and dependent systems.
The paper by Walkenhorst, O et al [23] is titled “Dynamic annual daylight simulation
based on one –hour and one-minute means of irradiance” it aims to investigate the
influence of short term solar variability on daylight availability within a building, it
does so by utilizing building modelling software called DAYSIM which is a
RADIANCE based dynamic daylight simulation tool, however due to the lack of
available high resolution data it encounters problems and thus it uses an adapted
version of the Skartveit and Olseth model to generate high resolution data of 1minute resolution from hourly means, it deduces that the utilization on high resolution
data reduces the underestimation of artificial lighting demand over the year from 27%
to 8% respectively. This report typifies how high resolution data can be used outside
of the field of solar power and photovoltaic‟s but , as previously described the use of
autoregressive models can provide “pitfalls”[50]. This is one of the main reasons why
the authors model uses a Markov chain approach which utilizes a transition
probability matrix.
The final journal and model which attempts the generation of high resolution
irradiance data is a report by Richardson. I and Thomson. M [59] the irradiance model
contained within thus report is only one part of what is a bigger model including an
electricity demand model, occupancy model and PV model.
The irradiance model contained within is intrinsically linked to both the electricity
demand model taking into account lighting and the PV model from which energy
output is calculated thus an accurate portrayal of how well the photovoltaic panel
matches the energy usage of the dwelling is gained.
The irradiance model exploited by Richardson and Thomson does not include any
means of inputting base irradiance data , thus the high resolution data generated is
totally synthetic and is not intended to represent what occurred but merely what could
35
have occur based on previous trends, to achieve this a first order Markov-chain is
used in conjunction with a transition probability matrix.
The model described within the authors report aims to use a similar technique in that
the use of a Markov chain and transition probability matrix will be utilized as opposed
to any other type of approach (i.e. an autoregressive model).
This however will be accompanied by the ability for the user to input hourly values
which will be used as a basis for the stochastic generation of high resolution global
horizontal radiation data, furthermore the transition probability matrixes utilized by
the authors model will be expanded extensively so as to include multiple transition
probability matrix representing monthly periods. This approach should allow for the
generation of high resolution data from hourly means which is simple and robust yet
yields good accuracy in correlation to measured results.
36
4.0 - Model Construction
In this section of the report the methodology, equations, procedures and techniques
which are used in the construction of the model discussed above are examined and
explained. The spreadsheet model which is contained within this report consists of a
number of worksheets and Visual basic codes which are linked within Microsoft
Excel to provide an easy to use method of stochastically generating high resolution
solar data from hourly means, a general overview of the entire process is shown in
figure 15 below. Each of the processes listed in figure 15 requires greater explanation
as to their operation and construction; these will be explained in subsequent sections
of the report the layout of which will follow in the same order as they are show in
figure 15 below.
User Input
(Hourly Averages)
Clear sky Index
calculated
Markov chain
utilises clear sky
index to generate
5-minute global
horizontal
radiation data
Global horizontal
radiation data split
up into its direct
and diffuse
components.
Output of 5-minute
solar radiation data
Figure 15: Overview of generation procedure
37
4.1 - User input
Before any calculations or operations are carried out a number of key parameters need
to be set by the user, these parameters are used consistently throughout all the
subsequent calculations. The information required from the user relates mostly around
the entering of the global horizontal radiation hourly means which are used as a basis
for the model to generate higher resolution data, the location of the site in question
(i.e. latitude and longitude) and the start date and end date of the hourly data is also
required as the model can generate up to one month‟s worth of data and the day of the
year needs to be ascertained for each day of data entered to undertake the calculations
required. Without this information the model will obviously not operate as desired. A
further section located on the user interface allows for the changing of the start and
end date of summer , this is used by subsequent sections of the model to correct time
variations brought about by the change to British summer time (BST) , however these
should not need to be changed from the default values for operation within the UK.
The final section allows for the input of average temperatures and relative humidity‟s
for each month for the location in question this will increase the accuracy of the
model for that location. Figure 16 shows a screenshot of the user interface of the
model.
Start date and
End date
Up to one
month’s worth
of data can be
entered
Monthly
temperature
and relative
humidity
Location
(Latitude &
Longitude)
Average hourly
global horizontal
radiation
Click buttons that
run VBA code
Figure 16: User interface
38
4.2 - Generation of Clear sky index
Part of the user input consists of hourly averages of measured global horizontal
radiation, previous sections of this report have explored the problems related to use
hourly averages as opposed to higher resolution time series data, thus this model has
been created to easily generate high resolution solar radiation data from these hourly
means. This process requires a number of steps which were shown in figure 15, the
first of these steps is the generation of clear sky index (Kc) as proposed by Skartveit,
A. & Olseth, J. A [18].
The generation of clear sky index itself can be split into two parts, firstly the
calculation of the Clear sky radiation (Rso) is needed, this being the radiation that
would be experienced in a given location if it was a totally clear day (i.e. no cloud
cover) this is calculated through the use of a series of equations which are further
explored in section 4.2.2. The second step is to calculate the Clear sky index (Kc), the
clear sky index is a simple method used to take account of the attenuation of the solar
radiation due to cloud cover, this negates the need for the use of extremely complex
meteorological calculations, it also allows for the analysis and generation of trends in
the transition between different degrees of cloud cover which is key to this project.
The clear sky index is further discussed in section 4.2.3 below.
4.2.1 - Clear Sky radiation (Rso)
One of the most critical parts of the algorithm constructed by the author is the
calculations related to the clear sky radiation or the clear sky model, as stated
previously the clear sky model is a mathematical derivation used to determine the
global horizontal radiation (W/ m2) that would occur on any given day at any location
on a clear, cloudless day.
The output of this model is used in the determined the hourly Clear sky index (Kc),
these hourly clear sky indexes are in turn used as the input for subsequent sections of
the model which determine the characteristics of the cloud cover of the proceeding
hour, a detailed overview of this procedure is discussed at length later in the report
however as the clear sky model is such a key component to the functionality of the
model it is important to explore the method and equations used to calculate the clear
sky global horizontal radiation(Rso).
39
Currently there are a variety of methods which can be used to generate estimations of
clear sky radiation, each of these methods share some crucial equations relating to the
position of the sun and solar angles however the actual calculation of the clear sky
global horizontal radiation is achieved in a different manor for each, in order to ensure
that the best method was used three separate methods for calculating the clear sky
radiation were tested and then subsequently checked against measured data. The three
methods compared were the Ashrae method [60], a method proposed by Duffie and
Beckman [61] and a method proposed by the Environmental and water resource
institute (EWRI) of the American society of Civil engineers (ASCE) [62 – 63].
Although all three methods gave good results for most of the year , on some occasions
the Ashrae and Duffie and Beckman methods underestimated the clear sky radiation
this is most likely to do with their simple procedure and the fact they do not take into
account temperature and relative humidity of the location in question. As such it was
determined that the method proposed by the American society of civil engineers
(ASCE) consistently gave the best results. This can be clearly seen in figure 17 below
which shows a comparison of all three methods tested to measured data recorded in
Belfast on 1st of May 2011. Figure 18 shows the ASCE method only.
Comparison of Measured and Modeled(1/5/2011)
400
350
Global horizontal radiation (w/m2)
Measured
300
250
Ashrae
method
200
150
Duffie
and
Beckman
method
100
ASCE
method
50
0
0 1 2 3 3 4 5 6 7 8 8 9 10 11 12 13 13 14 15 16 17 18 18 19 20 21 22 23 23
-50
Time(hour)
Figure 17: Comparison of measured and modelled data
40
Comparison of Measured and Modelled data(1/5/2011)
400
350
Global horizontal radiation (w/m2)
300
250
Measured
200
150
ASCE
method
100
50
0
0 1 2
3 3 4 5 6 7 8 8 9 10 11 12 13 13 14 15 16 17 18 18 19 20 21 22 23 23
-50
Time(hour)
Figure 18: Comparison of measured and modelled data (ASCE) method only
Henceforth when the clear sky method/radiation is referred to the author will be
referring the ASCE method as opposed to the Ashrae or Duffie and Beckman method.
As the ASCE method was the only method utilised after the initial analysis it will be
the only method explained in full for this report as it would be impractical and
unnecessary to explain all three methods.
4.2.2 - Clear Sky radiation model equations and operation
The clear sky radiation model is used to determine the solar radiation that would
occur at any given site if it was a cloudless clear day this value however does not
remain constant, the value of solar radiation hitting any location will vary dependent
on the location of the sun with respect to the site in question, this value further
changes over time as the earth rotates, not only about the sun but about its own axis.
In order to determine these values knowledge of solar angles and the geometry of the
sun in relation to the earth is needed. The first thing that is required is the location of
the site in question where Latitude (La) is the angle north or south of the equator and
Longitude (Lo) is the angle east or west of the Prime meridian Greenwich, this
information must be given by the user in the authors model, also needed from the
user is the date which in turn is used to determine the day of the year (DOY) where 1st
of January has a DOY number of 1 and 31st of December has a DOY number of 365
this information is used in a number of equations that are explored in this section.
After these values have been entered key information can be calculated which will
41
give the solar position and angle which are then utilized in determining the clear sky
radiation (Rso) on the horizontal plain. The information required to achieve this is the
declination (δ), Hour angle (h), solar altitude (β), Solar azimuth (γs) and Zenith angle
(θz) the equations used in these calculations are shown below in detail.
Declination (δ) - The angular position of the location in question, north or south of the
celestial equator is called the declination. It ranges from -23.5 to +23.5 as the earth
rotates about the sun and its own axis. There are a number of ways to calculate
declination with varying degrees of accuracy the equation used for this report is
shown in equation 2 below.
 = 0.006918 - 0.399912 cos  + 0.070257 sin  - 0.006758 cos 2
+ 0.000907 sin 2 - 0.002697 cos 3 + 0.00148 sin 3
(Equation 2 [64])
Where П is the day angle calculated by:
2 * ( DOY  1)
365
(Equation 3 [64])
And DOY is an abbreviation for day of the year.
Hour angle (h) - The angular position of the sun east or west as it moves across the
sky from the local meridian is called the hour angle, at solar noon when the sun is
directly overhead the hour angle is equal to 0°, each hour from the solar noon
corresponds to an angular motion of the sun of 15°. The hour angle is calculated by
firstly calculating the equation of time (EOT) (equation 4) this formula is an empirical
relationship which corrects the eccentricity experienced due to the way the earth
orbits the sun and earths axial tilt, sequentially a time correction factor (TC) (equation
6) is calculated thus taking into account of the variations in local solar time (LST)
over the year. After the time correction factor has been calculated the local solar time
(LST)(Equation 7) itself can then be calculated , finally the hour angle is derived
from use of equation 8[65] these equations are shown below.
42
EOT  9.87 sin ( 2 B)  7.53COS(B)  1.5Sin(B)
(Equation 4)
Where EOT id the equation of time
B 
360
( DOY  81)
365
(Equation 5)
TC  4(Lo  LSTM)  EOT
(Equation 6)
Where TC is time correction factor
Lo is Longitude
EOT is equation of time
LSTM is local standard time meridian
LST  LT 
TC
60
(Equation 7)
Where LST is Local solar time
LT is the local time
TC is the time correction factor calculated in equation 5
h  15  ( LST  12)
Where h is the hour angle
LST is the Local solar time calculated in equation 7.
43
(Equation 8)
Once the declination and hour angle has been calculated the solar altitude (β), solar
azimuth (γs) and zenith angle (θz) may be calculated.
Solar altitude angle (β) – is the angle between the solar radiation and the horizontal as
shown in figure 19, It is calculated by the use of equation 9.
Figure 19: Solar altitude angle (β)
  Sin 1[Cos ( La )Cos (h)Cos ( )  Sin( La ) Sin( ) ]
(Equation 9)
Where La is latitude
h is hour angle
δ is declination
Solar azimuth (γs) – is the angle between the north and south and the solar radiation
as shown in figure 20, it is determined by equation 10.
Figure 20: Solar Azimuth (γs)
44
s 
Sin ( La ) COS (h) Cos ( )  Cos ( La ) Sin ( )
Cos (  )
(Equation 10)
Where La is latitude
h is hour angle
δ is declination
and β is the solar altitude angle
Zenith angle (θz) – Is the angle between the solar radiation and the vertical as shown
in figure 21. The zenith angle is calculated using the equation 11.
θz
Figure 21: Solar Zenith angle (θz)
z  Cos 1[Cos ( La )Cos (h)Cos ( )  Sin( La ) Sin( ) ]
OR
90  
(Equation 11)
Where La is latitude
h is hour angle
δ is declination
The cosine of the above solar zenith angle (θz) is another key parameter which is
utilised in a number of equations, used to calculate the clear sky radiation; it is
calculated by the method shown in equation 12 below.
Cos θ  Sin(La)Sin(δ )  Cos(La)Cos(h)Cos(δ )
45
(Equation 12)
Clear sky radiation (Rso) - Through the use of the equations above, the position and
angle of the sun can be determined at each time step this information is then used in
the calculation of Clear sky radiation (Rso) using the method proposed by the
American society of civil engineers as discussed previously [62].
Rso  ( K B  K D ) Ra
(Equation 13)
Where:
KB is Clearness index for the direct beam component of the solar radiation
KD is the transmissibility index for the diffuse component of the solar radiation
Ra is the extraterrestrial radiation [W/m2]
The derivation of Ra, KB and KD are further explored below.
Extraterrestrial radiation (Ra) - is the radiation that would be experienced if there
were no atmosphere present and is calculated by:
Ra 
Gsc Cos
d2
(Equation 14)
Where :
Gsc is the solar constant of 1367 W/m2
Cosθ is the cosine of the solar zenith as calculated in equation 12
And d2 is a function of the day of the year (DOY) as specified by Duffie and
Beckman [61] and is calculated using equation 15.
d2 
1
 DOY 2 
1  0.033Cos 

 365 
46
(Equation 15)
Clearness index for the direct beam component (KB) is calculated by:
0 .4
  0.00146 P
 W  
K B  0.98 exp 
 0.075 
 
Kt
Sin

Sin


 

(Equation 16)
Where:
Kt is the turbidity coefficient where 0 < Kt < 1 , however for a clear day Kt = 1
W is Perceptible water [mm], calculated by equation 17
P is Atmospheric pressure [kPa] an is calculated by equation 19
And Sinβ is the sun angle β above the horizontal
Through the use of equations 17 – 21, KB takes into account the elevation of the site,
sun angle, water vapour and atmospheric pressure and how these factors influence
both the absorption and scattering of solar radiation.
The derivation of W, P and Sinβ are further explored below.
Perceptible water (W) - is calculated by equation 17 and determines the volume of
perceptible water in the atmosphere in millimetres [mm]:
W  0.14 e a P  2.1
(Equation 17)
Where ea is the Actual vapour pressure [kPa]
e a  eo
Rh
100
(Equation 18)
Rh is relative humidity
And eo is a saturated vapour pressure coefficient, which analysis the ability of the air
to hold water vapour.
 17.27 T 
e o  0.618 exp

 T  237.5 
Where T is temperature
47
(Equation 19)
Atmospheric pressure (P) - is calculated by equation 20 and determines the mean
atmospheric pressure at the site utilising the site elevation and a simplified version of
the Universal gas law [62].
 293  0.0065 Z 
P  101.3

293


5.26
(Equation 20)
Where
Z is site elevation above sea level (m)
Sinβ - is the Sin of the sun angle β above the horizontal calculated by use of equation
9
Transmissibility index for the diffuse component (KD) - is a function of the clearness
index of the direct beam component KB and is calculated using equations 21 & 22
dependent on the value of KB.
K D  0.35  0.36 K B For K B  0.15
K D  0.18  0.82 K B For K B  0.15
48
(Equation 21)
(Equation 22)
4.2.3 - Clear sky index calculations
Once the clear sky radiation Rso has been calculated the clear sky index can be
generated by the use of equation 24 below. As stated before the clear sky index is a
useful method which is utilised to identify the amount of cloud cover in a location and
alleviates the need for more complex meteorological calculations. In this model the
clear sky index ranges from 0 to 1, with 1 representing a clear day with no cloud
cover and 0 representing times were no solar radiation is incident on the site (i.e.
night-time) , a clear sky index of 0.5 for example would represent a day were only
half the global radiation that could have potentially reached the site in question
actually did due to attenuation caused by the clouds. The clear sky index (Kc) is
defined as the ratio of measured global horizontal radiation and the calculated Clear
sky radiation on the horizontal plain.
KC 
I gh
(Equation 24)
Rso
Where:
Igh is the measured global horizontal radiation [W/m2]
Rso is the clear sky radiation [W/m2]
For the model which accompanies this report the hourly clear sky index is calculated
using the hourly means of measured data, provided by the user and the hourly mean of
the clear sky radiation which is calculated through the use of equations 2 – 23. These
hourly clearness index are used as the input into the third section of the model as
shown in figure 15. In this section the hourly clear sky index generated by the process
explained above are used in combination with a Markov chain process and transition
probability matrix in the generation of 5-minute global horizontal radiation, However
the initial construction of the transition probability matrixes also requires the use of
the clear sky index although at a higher temporal resolution, how these processes
operate and their initial construction is explained in detail in section 4.3 below.
49
4.3 - Generation of 5-minute resolution Global horizontal radiation data
As has been discussed previously the process used to generate 5 minute resolution
global horizontal data from hourly means utilizes a method which uses transition
probability matrixes in combination with a first order Markov chain process. In order
to make the model operational the transition probability matrixes first had to be
constructed, to achieve this the clear sky index explained in section 4.2.3 was used in
combination with measured 5 minute resolution global horizontal radiation data which
was provided by the meteorological department of the University of Reading, thus
meaning that unlike the process described in section 4.2.3 the clear sky index was
generated at 5 minute time steps as opposed to hourly. This section aims to explore
how the transition probability matrix were constructed and operate, and how the
Markov chain process is used to generate the 5 minute resolution data from hourly
means.
4.3.1 - Transition probability matrix (TPM) construction
In order to generate stochastic solar radiation data a transition probability matrix has
to be constructed. A transition probability matrix is a method which is used to take
into account the probability of transition from one possible state to any other possible
state, in this model the transition probability matrix takes account of the likelihood of
transition between the clear sky index‟s at 5 minute time intervals which are
generated using the process described in section 4.2.3 in conjunction with 5 minute
resolution measured global horizontal radiation data as shown in figure 22.
Measured Global
horizontal radiation
(5-minute
intervals)
†
Clear sky radiation
(Rso)
(5-minute intervals)
=
Clear sky Index
(5 minute intervals)
Figure 22: Clear sky Index (5 minute intervals)
50
The global horizontal radiation observations used for this process were obtained by
the automatic measurement system of the Department of Meteorology at University of
Reading using a Kipp & Zonen CM11 Pyranometer, in total 4 years of data was used
to build the transition probability matrixes resulting in a long time series of data, this
long time series of 420480 entries was then split up into 12 separate data series
corresponding to the months of the year with each separate data series consisting of
between 32256 to 35712 values dependent on the month. This approach was used as
it is not expected that every month would have the same transition probabilities
therefore the aim of this approach was to take account of any changes in probability
of transition that would occur dependent on the month and there different
characteristics in weather patterns which ultimately has an effect on cloud cover.
The use of 4 years worth of data is also important in an aim to average out the
likelihood of a single year with abnormal weather patterns (i.e. a very hot summer or
cold winter) overly effecting the transition probabilities between states thus a more
standard picture of the transition probabilities is gained using multiple years.
After the long time series of data has been split into monthly data sets, the probability
of transition is then determined by counting the number of times a value is followed
by another number and dividing by the number of times the value appears in the time
series of data. For instance the probability that a clear sky index of 1 will remain at 1
(i.e. clear sky) at the next time interval (i.e. 5 minutes) is determined by counting the
number of times a clear sky index of 1 is directly followed in the data series by
another clear sky index of 1 and then dividing by the number of times the clear sky
index of 1 appears throughout the entire data series thus determining the likelihood of
transition, each transition probability matrix is constructed with a range of 0.01 to 1
along the horizontal and vertical axis of the matrix. The probability of transition
between the values on the vertical axis and the values on the horizontal axis are then
determined, thus generating a transition probability matrix were the probability of
transition between each possible clear sky index is quantified. A shortened example of
the transition probability matrix for the month of March can be seen in figure 23
below, as can be seen the highest probability is either for the clear sky index to remain
the same or for it to increase or decrease only slightly, giving the TPM on the whole a
trend were the largest probabilities occur diagonal to one another , towards the clear
51
sky end of the TPM this trend is also evident however there is also a greater
probability that the clear sky index at the next time step will be 1 (clear sky).
Figure 23: Transition probability matrix example
4.3.2 - First order Markov Chain process
The transition probability matrix‟s which are constructed using the method discussed
above are used in conjunction with a first order Markov chain so as to generate 5
minute resolution data. A Markov chain is a process which is said to have the
“Markov property” , that being a memory-less property were the present state is only
defined by a specified degree of the past. The concept of a first order Markov chain
(as opposed to a second, third… order) is a technique were the current state is
determined based only on the previous state and the probability of transition, which
in the authors model are held within the transition probability matrix explained above.
Whereas a second and third order Markov chain would determine the current state
based on the previous two or three states respectively. The first order Markov chain
process has been widely and successfully used to generate stochastic data in the past
[59] and generally provides good correlations to the distributions which are
52
experienced in measured data. This was discussed in the literature review were it was
shown that a Markov chain process provide a “simple yet effective simulation device”
[50] for the generation of solar radiation data.
The particular process used for the authors model utilises a random number (between
0 and 1), together with the above mentioned transition probability matrix and the
current clear sky value in its operation and generation of data, this type of first order
Markov chain is more commonly referred to as a Markov Chain Monte Carlo
(MCMC). The detailed operation of this process is explained below in section 4.3.3.
4.3.3 - The generation of 5-minute resolution global horizontal radiation data
The model discussed within this report is constructed using Microsoft Excel, and
visual basic for applications (VBA) for excel is used extensively throughout, The
method within this project builds upon the initial work of Richardson, I & Thomson,
M [59].
The VBA code used by the model is freely available to examine within the model
itself but can also be viewed in the appendix section of the report (Appendix 1 - 3).
Figure 24 below shows the operational process of the model, and the steps that are
involved, the model in this flow chart is colour coded with each colour representing a
different part of the model Blue is represented as the user input, Orange is related to
the calculation of clear sky radiation and Hourly clear sky index which is used as the
input for the third section of the model which is represented in green were the hourly
input is turned into a 5 minute resolution data through use of the Markov chain
process and transition probability matrix.
53
Input of Data by User
(Date (DOY & month), Location, Hourly average
global horizontal radiation)
Clear sky radiation(RSo) calculated for specified time scale
Useing the inputted data the month and number of days entered are determined and the
calculations shown in section 4.2 are carried out for this time period
Clear sky Index are calculated
The hourly average clear sky index are calculated using the hourly average global horizontal data
entered by user and the clear sky radiation (Rso)
Selection of appropriate Transition probability matrix (TPM)
From the user data the month is determined thus the appropriate TPM is selected and read into the
model.
For the hour in question the Hourly Clear sky Index is read into the model
Hourly clear sky index set as starting value
Each hourly clear sky index is set as the starting value for that hour
For each hour 12 transition steps are determined (Including starting value). To do this a
Markov chain Monte Carlo(MCMC) process is used
MCMC process - A random number is selected
Process
is
repeated
for full
hour
a random number between 0 and 1 is selected for use in the Markov chain Monte Carlo process
State of Transition is determined
The transition probabilities are added cell by cell along the row in question. When the random number is <= the cumulative
probability a state of transition is defined by determining the corresponding clear sky index of that point
Clear sky index is then used as current state
Process is carried out 11 times for each hour of data required and the 12 clear sky index
are written to the workbook
Figure 24: Operational process of model
54
The user input, calculation of clear sky radiation (Rso) and calculation of clear sky
index (blue and orange sections) have been discussed at length in previous sections of
this report. The operation of the green section however which relates to how the
hourly clear sky index is turned into 5 minute resolution data has only briefly been
mention and requires further explanation.
The first steps of the code highlighted by the green section are fairly self explanatory
from figure 24 and have been discussed above in section 4.3.1: “transition probability
matrix construction” in that the transition probability matrix is selected dependent on
the month, therefore from the user input the month is determined and the
corresponding TPM is read into the model were it is stored as an array. Taking the
process one hour at a time the model progresses to the next step were the hourly clear
sky index that have been generated in the previous sections of the model using the
calculations and process described in section 4.2 are read into the model, every hour
clear sky index calculated is used as the starting position from where the model
generates 11 further clear sky index this therefore means that each hour will have in
total 12 clear sky index (i.e. one every 5 minutes of the hour).
To achieve this a Markov Chain Monte Carlo process is used, this relies on the
selection of a random number, and the use of the transition probability matrix. Once a
random number (between 0 & 1) has been generated the code cycles through the row
which corresponds to the previous 5-minute clear sky index or if at the start of the
hour the starting clear sky index taken from the section above, as it does this it adds
up the probabilities, when the cumulative probabilities is greater than or equal to the
random number generated at the start of the process the corresponding clear sky value
for that column is used as the current time step clear sky index, this is written to the
sheet and the process continues and repeats until all values for that hour have been
generated , Once that hour is complete the process is repeated for each subsequent
hour until all hours have been processed. Therefore at the end of this process all hours
initially entered by the user will have 12 clear sky indexes generated.
55
To calculated the Global horizontal radiation at each time step the generated clear sky
indexes at 5 minute intervals are multiplied by the clear sky radiation also calculated
for 5 minute intervals through the equations shown in section 4.2 to give global
horizontal radiation were the attenuation of solar radiation due to cloud cover has
been taken account of by the clear sky index, and the input hourly data has been used
as a basis for the process.
Clear sky
radiation (RSo)
X
Clear sky Index
=
Global
horizontal
radition(W/m2)
Figure 25: Global horizontal radiation calculation procedure
4.4 - Splitting Global horizontal radiation into direct and diffuse
components
The global horizontal radiation output from the above process is useful in a number of
applications, and resembles the type of readings that would be measured by a
Pyranometer. Global horizontal radiation however is made up of two constituents
these being direct beam radiation (Id), the portion of the radiation direct form the sun
and diffuse radiation (Id) the portion of global radiation which is scattered in the
atmosphere by clouds and particulates such that .
Where:
It = Global radiation
Ib = Direct beam radiation
Id = Diffuse radiation
For other applications, such as calculations involving photovoltaic systems it is useful
if the direct a diffuse components of the horizontal radiation are known, as this is a
common problem, in that the most common type of measured data is global horizontal
radiation and there is a requirement to know the ratios of direct and diffuse radiation
which make up this global radiation there have been a number of studies which have
developed equations which aim to split up Global radiation into its direct and diffuse
56
components. As each of these studies relies on measured data form pyranometers and
shaded pyranometers from a variety of locations the equations derived are in some
ways dependent on the characteristics of the site the measured data was collected, as
such it was decided to explore a number of these methods and choose the most
accurate for the UK.
In total three methods were selected for analysis these being the methods reported in
Erbs et al [57], Orgil and Holland [56] , and Louch et al[66] these methods calculate
the direct and diffuse component in a slightly different manner to each other.
However, all of these methods utilise a factor called the “Clearness index”, the
clearness index is very similar to the clear sky index used extensively throughout this
project and in some reports the name Clearness index is used in place of the Clear sky
index however in this report there is a distinct difference between the two. The
clearness index (Kt) is represented by equation 25 were extraterrestrial radiation Ra
on the horizontal plain (I.e. the radiation on the horizontal plain as if there was no
atmosphere affecting it) is used rather than the clear sky radiation Rso.
Where:
Kt 
I gh
(Equation 25)
Ra
Kt is the Clearness index
Igh is the global horizontal radiation [W/m2]
Ra is the Extraterrestrial radiation calculated using equation 13 [W/m2]
The three methods analysed are further explained below, the Erbs et al and Orgill and
Holland correlations are similar in respect that both calculate the diffuse component
and subtract this from the global radiation to calculate the direct component, the
Louche correlation on the other hand calculates the direct component and then by
subtracting this from the global radiation the diffuse component is derived.
57
Erbs et al Method
1.0  0.09 Kt For Kt  0.22


2
I d 0.9511  0.1604 Kt  4.388Kt

I gh  16.638Kt 3  12.336 Kt 4


0.165
For Kt  0.80
For 0.22  Kt  0.80
(Equation 26)
Orgill and Holland Method
1.0  0.249 Kt
Id 
 1.55  1.84 Kt
I gh 
0.177
For Kt  0.35
For 0.35  Kt  0.75
For Kt  0.75
(Equation 27)
Where:
Id is the diffuse radiation,
Igh the Global horizontal radiation
And Kt is the clearness index.
Louche Method
The Louche method unlike the Erbs and Orgill and Holland methods calculates the
direct beam component as opposed to the diffuse component. This is done through the
use of equation 28 & 29
Kb  10.627 Kt 5  15.307 Kt 4  5.205 Kt 3  0.994 Kt 2  0.059 Kt  0.002
(Equation 28)
The Direct beam radiation is then calculated by:
Ib  Kb  Ra
Where:
Ib is the Direct beam radiation on the horizontal plain [W/m2]
Ra is the Extraterrestrial radiation [W/m2]
58
(Equation 29)
For all three methods the direct beam normal radiation (Ibn) can be calculated by use
of equation 30 below this is useful for a number of applications and as such is
provided within the model.
(Equation 30)
Where:
Ib is direct beam radiation on the horizontal plain[W/m2]
Sinβ is the sun angle β above the horizontal
After analysis it was decided that the most consistent best fit was achieved by the use
of the Louche method, this was further verified by analysis carried out by Battles et al
[67] which arrived at the same conclusion. However none of the three methods
provided exact fits, this is mainly to do with the fact that the Direct and Diffuse
components are derived from the global horizontal radiation this means that any peaks
and troughs which are experienced in the global radiation are propagated through to
both the diffuse and direct radiation, in measured data anomalies cased by the passing
of clouds may not necessarily have an impact on the measured diffuse component at
such short time intervals, a comparison of measured data compared to the data
calculated using each of the three methods is shown in figures 26 & 27 below. Taking
into account that the Pyranometer used to measure the data can have an error of up to
+- 10% [68] then it is shown that Louche method generally provides the best fit.
59
1000
900
800
700
600
500
400
300
200
100
0
Global Horizontal
radiation(measured)
Direct componenet
measured
Direct componet (Erbs
method)
00:04:00
01:29:00
02:54:00
04:19:00
05:44:00
07:09:00
08:34:00
09:59:00
11:24:00
12:49:00
14:14:00
15:39:00
17:04:00
18:29:00
19:54:00
21:19:00
22:44:00
Direct component (Orgill
and hollands method)
Direct component (Louch
Methed)
Time
Figure 26: Comparison of calculated and measured direct components
Comparison of diffuse Compnents
1000
900
800
700
600
500
400
300
200
100
0
00:04:00
01:34:00
03:04:00
04:34:00
06:04:00
07:34:00
09:04:00
10:34:00
12:04:00
13:34:00
15:04:00
16:34:00
18:04:00
19:34:00
21:04:00
22:34:00
W/m2
W/m2
Comparison of direct Compnents
Global Horizontal
radiation(measured)
Diffuse componenet
measured
Diffuse componet (Erbs
method)
Diffuse component (Orgill
and hollands method)
Diffuse component (Louch
Methed)
Time
Figure 27: Comparison of calculated and measured diffuse components
60
5.0 - Model Validation
The model presented in this paper generates 5-minute resolution solar data based on
hourly inputs using a stochastic process, therefore the output of the model will not
exactly match what actually occurred at 5 minute time steps on that day as such it is
difficult to gain an idea of accuracy of the model based on comparison between
Generated data and measured data over short time periods such as individual days.
For example dependent on the random numbers chosen by the program during the
Markov chain Monte Carlo process the eventual outcome of the solar radiation data
may well differ, this of course is one of the key points of the model as it is not merely
a tool which replicates what happens on a given day, it is a tool which looks at the
characteristics of the cloud cover on a particular hour and generates radiation values
accordingly based on 4 years of data, thus mitigating any abnormalities in the weather
for that particular period (i.e. Extreme summer and winters) . Figure 28 and 29 show
two profiles of measured data compared to generated data, both these graphs have the
same average hourly input values but it can be clearly seen that the output values can
be very different due to the stochastic nature of the model, with figure 28 having
generated data which matches the measured data well, and figure 29, having some
over and under estimations of global horizontal radiation at points throughout the day.
Figure 28: Stochastic generation difference (Good fit to measured data)
61
Figure 29: Stochastic generation difference
(Over an underestimation compared to measured data)
As individual days are not compariable dirrectly the accuracy of the generated data
has to be considered useing a frequency based approch over a longer time span . As
such it was decided to compare the generated data to measured data over the period of
a year, the idea being that the over and under estimations which occur in individual
days would average out over the year and thus the yearly frequency distribution of
global horizontal radiation values should match.
5.1 – Method used and frequency distribution graphs
In order to validate the output of the model the frequency distribution of 1 years worth
of generated 5-minute global horizontal radiation is compared, via a histogram to the
mesured 5-minute global horizontal radiation for the same year for the location of the
University of Reading. This validation process was caried out for two seperate years
namely 2008 & 2010 , using two separate years for validation helped ensure that the
results given by the model were consistent and not only accurate because of the input
values used, the input values used in these validation runs are the hourly averages of
the meausred 5 minute gloabl horizontal radiation for the years 2008 & 2010.
Thouroughout this comparison the measured results used were constrained by the
calculation of the clear sky radiation Rso as sometimes for instance when the sun is
appearing from or entering behind a cloud the global horizontal radiaion measured
62
can be enhanced due to increased reflected radiation, in these cases the measured
radiation is set equal to the clear sky radiation Rso at that time as currently the model
presented within this paper is unable to take into account these cloud enhancements.
The graphs of frequency distribution are shown below in figures 30 & 31. The
histograms presented show frequency of occurrence VS solar radiation in bins of 20
W/m2 (i.e. each column represents a range of 20 W/m2 for instance the first column is
the amount of occurrences between 1 – 20 W/m2, the second column is the amount of
occurrences between 11-40 W/m2 and so on).
Looking at figure 30 & 31 it can be seen that the modelled results generated provide a
very accurate representation of the measured global horizontal radiation for both 2008
and 2010 with R2 values 0.97 for each. The model results generated do not exactly
match the measured results however it was not expected that they would, there is a
tendency for the model to slightly underestimate the lower end of the spectrum
however when analysing the data there is no definitive trend to this and it seems to be
an artefact of the stochastic nature of the model.
Figure 30: Frequency distribution for Reading (2008)
63
Figure 31: Frequency distribution for Reading (2010)
5.2 – Input data from different location
The above frequency distribution graphs use hourly averages calculated from the data
which was provided by the University of Reading, in other words the input data is
averages of the same data which was used to construct the transition probability
matrix which make up part of the model therefore if the model approach gives good
correlations it would be expected that a good correlation between measured and
modelled data for Reading should be seen.
However, as part of the further analysis of the author‟s model it was important to
determine how accurately solar radiation data could be generated for locations outside
of Reading based on the utilisation of the transition probability matrix constructed
from the Reading data. In order to investigate this, data from the Isle of Lewis, 515
miles North West of Reading [69] was used as an input, this data was graciously
provided by Hebrides weather (hebwx.co.uk) and a similar process of calculating the
frequency distribution over a year was carried out. The results of this process are
shown in figure 32 below. As can be seen even though the model is not constructed
64
from any of the data the correlations between the measured and generated data are
still very accurate with an R2 value of 0.942 this proves that the model constructed
can be used for locations other than Reading. It is the authors opinion that the method
used in that the hourly inputs are used as a base for the generation of data and the fact
that the model utilises clear sky index rather than the generation of actual global
horizontal radiation values allows the model to accurately reproduce values for
outside of Reading, as although the maximum and minimum values of solar radiation
experienced at the locations will be different the transition between cloud conditions
is likely to be similar on the whole throughout the UK.
Figure 32: Frequency distribution for Lewis (2010)
65
6.0 – Conclusion and Further work
6.1 – Conclusion
In the modern world one of the key components to understanding and improving any
field is the collation of data relating to that field of study, for years the generation of
power via photovoltaic‟s and the understanding of energy usage within the built
environment and its relationship with solar radiation has been based on the usage of
hourly averages of solar data, this for a long time has thought to have been adequate.
However as the increase in power generation from solar photovoltaic„s has grown and
the popularity of energy efficient construction and design within the built
environment along with ideas of how to best utilise natural lighting and the usage of
solar gains to heat a structure have become more mainstream it has become
abundantly clear that the use of these hourly averages is no longer adequate. Only
now have institutions and universities started to measure solar data with high enough
resolutions so as to be useful in these fields of study, and even so only a handful of
places are doing so, this in some ways is severely affecting the ability for the science
and engineering community to truly understand the effects of solar variability on these
subjects.
The aim of this project was to establish a simple, easy to use model which would have
the ability to transform hourly averages of global horizontal radiation into 5 minute
resolution global horizontal radiation which is representative of the base hourly data.
To achieve this a method was developed which utilised transition probability matrix
constructed from data graciously provided by the University of Reading and a Markov
chain process, this being a well understood and proven technique for generating
stochastic data which is representative of an input.
It has been shown that the method used in the construction of this model works well
when considering the frequency distribution of solar radiation over a year, for the
same location were the transition probability matrix was derived, However it has also
been shown that this method can work equally well for locations which are vastly
different in terms of overall solar duration and maximum solar radiation which is
66
experienced this is thought to be a result of the utilisation of clear sky index rather
than the use of radiation measurements directly as discussed above. However this is
based on limited testing carried out using a single data set from the Isle of Lewis
therefore to truly establish how robust the approach taken actually is may require
further testing and modelling using different data sets.
The model described within this report is provided freely and is available for
download with a creative commons licence from the Energy Systems Research Unit
(ESRU), University of Strathclyde website and may be feely used and adapted by
anyone who wishes to do so.
6.2 – Further work
From the outset of this project it has been evident that the project lends itself to being
used as bases for further work, both in the improvement of the model itself and in the
utilisation of the model in investigating the variability of solar radiation and its impact
on a number of sectors.
This section of the report aims to explore the authors opinions on were this model
could be best utilised and further improved.
Higher resolution – The current model constructed generates 5 minute resolution
global horizontal radiation; this in many ways is high enough resolution to take
account of the vast majority of variability experienced within an average day.
However the model could be further improved to generate up to a resolution of 1
minute this would take into account very fast moving cloud which may not be fully
taken account of in the 5 minute resolution model constructed, However the major
problem with this is the availability of accurate and consistent 1 minute resolution
data to construct the transition probability matrix, at the time of writing of this report
the 1 minute data which is freely available is either not of sufficient quality or there is
not enough of it to accurately construct a good transition probability matrix ( i.e. there
is only a maximum of 1 years worth of data), as more institutions and universities
increase their measurement resolutions the construction of a similar model with a 1
minute resolution would be easily achievable.
67
Ability to account for cloud enhancement - The current model does not have the
ability to account for so called cloud enhancement, this being were the transition
between clear sky and clouds actually increases the solar radiation measured above
the point of clear sky radiation due to the extra reflected radiation experienced due to
the nearby clouds albedo. A further project could investigate how/if this could be
taken account in the model.
Investigate PV model - A further investigation into the variability of photovoltaic
output with the use of high resolution data compared to the use of hourly averages
could be implemented into the model, in particular a PV model in its own right could
be implemented into the model were the user could input the size, location and
efficiency of a planned PV array along with the hourly averages of solar radiation and
the variability of this radiation could be taken account of. This could also include an
investigation into the impact of the variability of the solar radiation on the inverter .
Implementation of model into ESP-r and Merit - The implementation of the model
into modelling software such as ESP-r and merit could be advantageous, as this would
allow the use of hourly weather files to be converted into high resolution data if the
user wished thus easily investigating the impact of solar variability on their building
model.
Investigate worldwide accuracy - During the model validation section it was shown
that although the models transition probability matrixes were constructed using only
data from the location of Reading, the model also provided a good fit when the
location and input data from the Isle of Lewis was used. Further investigation could
be undertaken to see how far afield this good correlation is achieved and if the model
still achieves these results for a location which has drastically different weather from
the UK, it could also be explored how this model could take account of these
differences for instance with different transition probability matrix for different
locations (i.e. tropical, temperate regions etc)
68
7.0- References
[1]. Enzler, S.M., History of greenhouse gas effect and global warming , [online]
Available: http://www.lenntech.com/greenhouse-effect/global-warming-history.htm
[6/6/11].
[2]. IPCC , The physical science basis of climate change [online],
Available: http://www.ipcc.ch/pdf/presentations/COP15presentations/stocker09unfcccCopenhagen_delegate_new.pdf, [6/6/11]
[3]. IPCC, Greenhouse effect definition, [online]
Available: http://www.ipcc.ch/publications_and_data/ar4/syr/en/annexessglossary-ei.html [6/6/11]
[4]. Kiehl, J.T., Trenberth, K.E. (1997). Earth’s Annual Global Mean Energy Budget,
Bulletin of the American meteorological society Vol. 78, No. 2, February 1997
[5]. Earth science research laboratory, Trends in carbon dioxide ,[online],
Available: http://www.esrl.noaa.gov/gmd/ccgg/trends/ [6/6/11]
[6]. Department of energy and climate change, 2010 greenhouse gas emissions
[online]Available:http://www.decc.gov.uk/assets/decc/Statistics/climate_change/1515
-statrelease-ghg-emissions-31032011.pdf, [6/6/11]
[7]. Department of energy and climate change, UK fuel mix (2009 – 2010) [online],
Available:http://www.decc.gov.uk/en/content/cms/statistics/energy_stats/fuel_mix/fue
l_mix.aspx, [8/6/11]
[8]. Beagely Brown , UK fuel mix 2010 , [online]
Available: http://www.beagleybrown.com/wp-content/uploads/2011/03/uk-fuelmix.gif [8/6/11]
[9]. BBC, 2003, Kyoto treaty, [online]
Available: http://news.bbc.co.uk/1/hi/world/europe/2233897.stm [8/6/11]
[10]. Department of energy and climate change , 2008, Climate change act 2008,
available:http://www.decc.gov.uk/en/content/cms/legislation/cc_act_08/cc_act_08.asp
x [8/6/11]
[11]. Scottish Government, Climate change Scotland act (2009), 2009,
Available: http://www.scotland.gov.uk/Topics/Environment/climatechange/scotlandsaction/climatechangeact, [8/6/11]
[12]. Department of energy and climate change, 2010, Renewables statistics: capacity
of and energy generated from renewable sources (DUKE 7.4), [online]
Available:http://www.decc.gov.uk/en/content/cms/statistics/energy_stats/source/rene
wables/renewables.aspx, [8/6/11]
69
[13]. Yougen, 2010, Solar PV farms,[online]
Available: http://www.yougen.co.uk/blog-entry/1587/Solar+PV+farms++are+they+good+for+the+UK'3F/ [9/6/11]
[14]. Pricewaterhousecoopers (PWC) , 2010, On the brink of a bright future,[online],
Available:http://www.ukmediacentre.pwc.com/imagelibrary/downloadMedia.ashx?M
ediaDetailsID=1748 [9/6/11]
[15]. Feedintarrifs.co.uk, 2010, Tariff level tables, [online]
Available: http://www.fitariffs.co.uk/eligible/levels/ [10/6/11]
[16]. Renné, D., George, R., Wilcox, S., Stoffel, T., Myers, D., and Heimiller D.,
2008, Solar resource assessment, National renewable energy laboratory, US
department of energy.
[17] Vijayakumar, G., Klein, S., Beckman, W., Analysis of short term solar radiation
data, 2002, [online] , available:
http://sel.me.wisc.edu/publications/conference/asespaper044a1.pdf
[18]. Skartveit, A. and Olseth, J. A.,19992, The Probability Density and
Autocorrelation of Short-Term Global and Beam Irradiance, Solar Energy Vol. 49.
No. 6. pg. 477 - 487
[19]. Janark M. , 1997, Coupling building energy and lighting simulation. 5th int.
IBPSA conference 1997
[20]. Suehrcke, H. and McCormick, P.G., 1989, Solar radiation utilizability. Solar
Energy 1989;4, Pg:339–45.
[21]. Suehrcke, H. and McCormick, P,G., 1992, A performance prediction method for
solar energy systems. Solar Energy1992, Pg:169–75.
[22]. Suehrcke, H. and McCormick, P,G., 1988, The frequency distributions of
instantaneous insolation values, Solar Energy 1988, Pg:413–22.
[23]. Walkenhorst, O., Luther, J., .Reinhart, C., Timmer, J., 2002, Dynamic Annual
Daylight Simulations based on One-hour and One-minute Means of Irradiance Data,
National research council of Canada
[24]. Gansler, R,A., Klein, S,A. and Beckman, W,A.,1995, Investigation of minute
solar radiation data. Solar Energy 1995, Pg: 21–7.
[25] Jurado, M., Caridad, J,M. and Ruiz, V., 1995, Statistical distribution of the
clearness index with radiation data integrated over five minute intervals. Solar
Energy 1995 Pg: 469–73.
[26]. Olmo, F,J., Alados-Arboledas, L., Tovar, J. and F Batlles C,L., 2001,
Dependence of one-minute global irradiance probability density distributions on
hourly irradiation, Solar energy 2001, Pg: 659–668
70
[27]. Tovar, J., Olmo, F, J. and Alados-Arboledas, L., 1998, One-minute global
irradiance probability density distributions conditioned to the optical air mass. Solar
Energy 1998, PG: 387–93.
[28]. BBC, 2008, National grid Demand data ,[online]
Available: http://news.bbc.co.uk/1/hi/sci/tech/7268832.stm [21/611]
[29]. Godfrey Boyle, 2008, Renewable electricity and the grid: the challenge of
variability, London, Earthscan.
[30]. North American Electric Reliability Corporation (NERC), 2009,
Accommodating high levels of variable generation. Reliability issues white paper,
Princeton
[31]. - Mills, A., Wiser, R., 2010, Implications of Wide-Area Geographic
Diversity for Short-Term Variability of Solar Power, Ernest Orlando Lawrence
Berkeley National Laboratory, Available: http://eetd.lbl.gov/ea/EMS/reports/lbnl3884e.pdf [23/6/11]
[32]. Sky shades,2011, UK gets largest solar farm,[online]
Available: http://www.skyshades.co.uk/component/myblog/uk-gets-its-largest-solarfarm.html [21/6/11]
[33]. Jewell, W., Ramakumar, R., 1987, The effects of moving clouds on electric
utilities with dispersed photovoltaic generation. IEEE Transactions on Energy
Conversion
[34]. European Electrical Standard Profiles, Annex 42 demand data , [online]
Available: http://www.ecbcs.org/annexes/annex42.htm, [17/8/2011]
[35] Artificial lighting guide, 2011, Artificial lighting guide[online],
Available: http://www.except.nl/consult/artificial-lighting-guide/index.htm#5
[36] ESRU, 2011, ESP-r introduction, [online],
Available: http://www.esru.strath.ac.uk/Programs/ESP-r.htm
[37]. National grid, 2011, Operating of electricity transmission network in 2020,
Available: http://www.nationalgrid.com/NR/rdonlyres/DF928C19-9210-4629-AB78BBAA7AD8B89D/47178/Operatingin2020_finalversion0806_final.pdf [21/6/11]
[38]. Worden, J., Zuercher-Martinson, M., How an Inverter works , solar pro[online]
Available: http://solar.gwu.edu/index_files/Resources_files/How-Solar-InvertersWork-With-Solar-Panels.pdf [23/6/11]
[39]. Jasper electronics, string inverters Vs micro inverters for the solar power plant,
comparison of Micro Vs. String inverters, 2010
[40]. Dr Kelly, N.J., Solar energy conversion lecture notes 1, 2010,University of
Strathclyde
71
[41]. - Dr Kelly, N.J., 2010, Solar energy conversion lecture notes 4, University of
Strathclyde, [14/6/11]
[42]. Viridian solar, 2011, A guide to solar energy,[online]
Available: http://www.viridiansolar.co.uk/Solar_Energy_Guide_5_2.htm [14/6/11]
[43]. Deutsche Gesellschaft für Sonnenenergie ,2008, Planning and installing
photovoltaic systems: a Guide from installers, architects and engineers, Earthscan
[44]. Photoblog geography, 2011, Picture of Pyranometer, [online]
Available: http://geoearth-gallary.blogfa.com/8504.aspx [17/6/11]
[45]. Schroeder, M. J., Buck, C. C., 1970. Fire Weather: Agriculture Handbook 360.
Department of Agriculture: Forest Service., Washington, DC, U.S.
[46]. Priya Johnston, Buzzel.com, 2010, Types of clouds ,[online]
Available: http://www.buzzle.com/articles/types-of-clouds.html [ 17/6/11]
[47]. Distance education technologies, weather resources for teachers, 2011, Cloud
types.jpg,[online], Available: http://www.dlt.ncssm.edu/resources/wxresources.htm
[18/6/11]
[48]. Joseph Bartlo, 1997, Influence of clouds on solar energy ,
Available: http://joseph-bartlo.net/articles/051297.htm [18/6/11]
[49]. Mellit, A., Eleuch, H., Benghanem, M., Elaoun, C. and Massi-Pavan, A. 2010,
An adaptive model for predicting of global, direct and diffuse hourly solar irradiance
, Energy Conversion and Management , PG:771–782
[50]. Mustacchi, C., Cena, V., Rocchi, M., 1979, Stochastic simulation of hourly
global radiation sequences. Sol Energy 1979; Pg:47–51.
[51]. Aguiar, R,J., Collares-Perrira, M., and Conde, J,P., 1988, Simple procedure for
generating sequences of daily radiation values using library of Markov transition
matrices, Sol Energy 1988, Pg: 269–79.
[52]. Paulescu, M., Fara, L., and Tulcan-Paulescu E. Models for obtaining daily
global solar irradiation from air temperature data. Atmos Res 2006, Pg: 227–40.
[53]. Hontoria, L., Aguilera, J., and Zufiria, P., Generation of hourly irradiation
synthetic series using the neural network multilayer perception. Sol Energy
Pg: 441–6.
[54]. Elminir, H,K., Azzam, Y,A., and Younes, F,I., 2007, Prediction of hourly and
daily diffuse fraction using neural network, as compared to linear regression models.
Energy 2007, PG: 1513–23.
72
[55]. Moustrisa, K., Paliatsos, A,G., Bloutsos, A., Nikolaidis, K., Koronaki, I., and
Kavadias, K,. Use of neural networks for the creation of hourly global and diffuse
solar irradiance data at representative locations in Greece. Renew Energy
2008, Pg: 928–32
[56]. Orgill, J. F., and Hollands, K. G, T., 1977, Correlation equation for
hourly diffuse radiation on a horizontal surface. Solar Energy.
[57]. Erbs, D,G., Klein, S,A,. and Duffie J,A.,, 1982, Estimation of the diffuse
radiation fraction for hourly, daily and monthly-average global radiation. Solar
Energy 1982 Pg: 293–302
[58]. - Sylvain Cros Didier Mayor and Lucien Wald,The availability] of irradiation
data, Photovoltaic power systems programme ,Report IEA-PVPS T2–04:2004
[59]. - Richardson, I., and Thomson, M., Integrated simulation of photovoltaic micro
– generation and domestic electricity demand: A One minute resolution open-source
model, CREST (Centre for renewable energy and electrical engineering),
Loughborough university.
[60]. ASHRAE, 1985, Handbook of Fundamentals. Atlanta, Georgia: American
Society of Heating, Refrigeration, and Air-Conditioning Engineers.
[61]. Duffie, J. A., and Beckman, W. A., 1991. Solar Engineering of Thermal
Processes. New York: Wiley.
[62]. ASCE, Standardized Reference Evapotranspiration Equation. American Society
of Civil Engineers, Reston, Virginia, USA. 2005. (Clear sky equations contained
within Draft main report and Appendix D. )
[63]. Allen, R, G., Trezza, R., Tasumi, M., Analytical integrated functions for daily
solar radiation on slopes, Agricultural and Forest Meteorology 139 (2006) Pg:55–7
[64]. Illustrating shadows , declination calculation,[online]
Available:http://www.illustratingshadows.com/www-formulae-collection.pdf
[11/7/11]
[65]. Honsberg, C., Bowden, S., PVEducation.org, Solar equations
Available:http://www.pveducation.org/pvcdrom/properties-of-sunlight/solar-time,
[6/6/2011]
[66]. Louche, A., Notton, G., Poggi, P., and Simonnot G.1991, Correlations for
direct normal and global horizontal irradiation. Solar Energy 1991, Pg: 261–6.
[67]. Batlles, F, J., Rubio, M,A., Tovar, J., Olmo, F,J., and Alados-Arboledas,
L.,2000, Empirical modelling of hourly direct irradiance by means of hourly global
irradiance. Energy 2000, Pg:675–88
73
[68]. Stoffel, T., Wilcox, S., National renewable energy laboratory, 2004 , Solar
radiation measurements, [online], Available:
http://www.nrel.gov/docs/gen/fy04/36831p.pdf
[69]. Free map tools., 2011 , Distance calculator, [online],
Available: http://www.freemaptools.com/how-far-is-it-between.htm
8.0 - Bibliography
Petroutsos, E.,1996, Mastering Visual basic 6 , Alemeda, Sybex,ISBN0-7821-2272-8
Walkenbach,J., Microsoft excel VBA programming for dummies, New York John
Wiley & sons Inc, ISBN: 978-0-470-50369-0
Duffie, J. A., and Beckman, W. A., 1991. Solar Engineering of Thermal Processes.
New York, John Wiley & sons Inc, ISBN: 0-471-51056-4
Clarke, J,A., 2001, Energy simulations in building design, Oxford, ButtrtworthHeinemann, ISBN: 0-7506-5082-6
Boyle, G., 2008, Renewable electricity and the grid: the challenge of variability,
London, Earthscan, ISBN:978-1-84407-418-1
74
9.0 - Appendixes
Appendix 1
Sub Row_count()
Dim count As Integer, myRange As Range
Dim B As Integer
Dim i As Integer
Dim t As Integer
Sheets("Data_Input").Select
Set myRange = Columns("c:c")
count = Application.WorksheetFunction.CountA(myRange)
B = count - 5
i = (B * 12) + 34
t = 35
Worksheets("Clear").Range("D37:BN8975").ClearContents
Sheets("Clear").Select
Range("D" & t & ":BN" & t).Select
Selection.AutoFill Destination:=Range("D" & t & ":BN" & i), Type:=xlFillDefault
Range("D" & t & ":BN" & t).Select
Sheets("Data_Input").Select
End Sub
75
Appendix 2
Sub avg_1()
Dim i As Long
Dim count As Integer, myRange As Range
Dim B As Integer
Dim s As Integer
Dim t As Integer
Dim U As Integer
Worksheets("Hourly_Calculations").Range("D:D").ClearContents
Sheets("Data_Input").Select
Set myRange = Columns("c:c")
count = Application.WorksheetFunction.CountA(myRange)
B = count - 5
s = (B * 12) + 34
t=B+1
U=3
For i = 35 To s Step 12
Worksheets("Hourly_Calculations").Range("D"
Rows.count).End(xlUp).Offset(1).Value
WorksheetFunction.Average(Worksheets("Clear").Range("AR" & i).Resize(12))
Next i
Worksheets("Hourly_Calculations").Range("E4:G745").ClearContents
Sheets("Hourly_Calculations").Select
Range("E3:G3").Select
Selection.AutoFill Destination:=Range("E" & U & ":G" & t), Type:=xlFillDefault
Range("E" & U & ":G" & U).Select
Sheets("Data_Input").Select
End Sub
76
&
=
Appendix 3
Sub SimulateClearnessIndex_month_Click()
Randomize
Dim NxtTimeInt As Integer
Dim fRand As Double
Dim fRand2 As Double
Dim CumulativeProb As Double
Dim iRow As Integer
Dim Colref As String
Dim x As Integer
Dim y As Integer
Dim iMonth As Integer
Dim dKArray(1 To 100, 1 To 100) As Double
For y = 1 To 100
For x = 1 To 100
Colref = Cells(1, x + 2).Address(True, False, xlA1)
Colref = Left(Colref, InStr(Colref, "$") - 1)
iMonth = Worksheets("Clear").Range("E4").Value
dKArray(y, x) = Range("'TPM" & CStr(iMonth) + "'!" + Colref + CStr(y +
9)).Value
Next x
Next y
Dim c As Variant
Dim B As Variant
Dim off1 As Variant
Dim off2 As Variant
Dim off3 As Variant
Dim count As Integer, myRange As Range
Dim s As Integer
Sheets("Data_Input").Select
Set myRange = Columns("c:c")
count = Application.WorksheetFunction.CountA(myRange)
77
s = count - 5
For c = 1 To s
off1 = (c * 12) - 10
off2 = (c * 12)
off3 = (c * 12) - 11
Dim vSimulationArray(1 To 12, 1 To 1) As Variant
Dim CurrentCSI As Integer
CurrentCSI = Worksheets("Hourly_Calculations").Range("G" & c + 1) * 100
If CurrentCSI <= 0 Then
With Worksheets("5min_Output")
.Range(.Cells(off3, 9), .Cells(off2, 9)).Value = 0
End With
Else
Worksheets("5min_Output").Range("I" & off3).Value = CurrentCSI / 100
For NxtTimeInt = 1 To 12
fRand = Rnd()
CumulativeProb = 0
Dim i As Integer
For i = 1 To 100
CumulativeProb = CumulativeProb + dKArray(CurrentCSI, i)
If fRand <= CumulativeProb Then
78
CurrentCSI = i
Exit For
End If
Next i
Dim dk As Double
If CurrentCSI = 100 Then
dk = 1
Else
dk = (CurrentCSI / 100)
End If
vSimulationArray(NxtTimeInt, 1) = dk
Next NxtTimeInt
With Worksheets("5min_Output")
.Range(.Cells(off1, 9), .Cells(off2, 9)).Value = vSimulationArray
End With
End If
Next c
End Sub
79
Was this manual useful for you? yes no
Thank you for your participation!

* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project

Related manuals

Download PDF

advertisement