A Novel based Prolog Programming for Mean Wind Speed ...
Transcript of A Novel based Prolog Programming for Mean Wind Speed ...
47 Mahesh K1*
., M V Vijaykumar 2., Gangadharaiah.Y.H
3
International Journal of Computer & Mathematical Sciences
IJCMS
ISSN 2347 – 8527
Volume 3, Issue 6
August 2014
A Novel based Prolog Programming for Mean Wind Speed &
Weibull Distribution at Hiregudda, Karanataka, India
Mahesh K1*
., M V Vijaykumar 2., Gangadharaiah.Y.H
3
1*
Researcher Scholar JAIN University CSE dept and Faculty at
New Horizon College of Engineering Bangalore-560103, India.
2 Department of Computer Science Engineering, Dr AIT, India.
3 Department of Mathematics, New Horizon College of Engineering, India.
Abstract: The main objective of this paper is to estimate annual mean wind speeds at 10 m, 30 m
and 50 m. The annual mean wind speed is determined by PROLOG SWI platform using wind data
obtained from measurements for the 5 years period of 2006 to 2010 at Hiregudda, Bagalkot district
in Karnataka state, South India. The wind speed at heights of 10 m, 30 m and 50 m above ground
level were measured using 3- cup anemometers attached to booms on a 50 m lattice met tower. The
recording interval was 10 min. The results of mean wind speed data is the first step of prediction of
wind speed data of the site under consideration and a PROLOG program was designed and
developed to calculate the Annual mean wind speed data of the site. The statistical wind data set was
also analyzed using Weibull distributions in order to investigate the Weibull shape and scale
parameters.
Keywords: Prolog, Mean wind speed, Weibull Distribution, Weibull shape and Scale parameters.
1. Introduction
Wind data measurements over a period of five-years are required to obtain an
accurate assessment of the wind regime of an area. Over a period, the height of wind turbines
have seen phenomenal upward trend and thus it was also necessary to increase the height of wind
monitoring masts to the hub height. Presently 50 m tall tubular masts are used with instrumentation
at 10, 30 and 50 m AGL [1]. The data loggers from M/s NRG Systems, USA and M/S second wind
Inc, USA are used and theses units have multi-channel data logging capability along with facilities
for down loading data remotely. The averaging interval presently considered is 10 minutes, the
industry standard. Time series data are stored in removable memory cards collected manually form
the sites periodically. The respective State Nodal Agencies (SNAs) also have active role in the
implementation of the program. Fully automated data logger housed in shelter box with adequate
protection vandalism is used for data collection. Wind speed is measured using cup generator
anemometers and the rotational speed (frequency) of the cups is proportional to the wind speed. Wind
direction is referred to north in terms of degrees from north and the direction sensor consists of a
potentiometer giving proportional voltage signal. Data is sampled at a frequency of 0.5 Hz (2 seconds)
48 Mahesh K1*
., M V Vijaykumar 2., Gangadharaiah.Y.H
3
International Journal of Computer & Mathematical Sciences
IJCMS
ISSN 2347 – 8527
Volume 3, Issue 6
August 2014
and averaged over one hour or 10 minutes. The data logger is set to store the wind speed in the meter
per second and direction in degrees. The data presentation is mainly based on the analysis carried out
on hourly values of wind speed and directions [2]. Methodologies on wind farm design rely on these
data from the measuring station and careful analysis of wind flow, which takes into account the
topography and the roughness level of the surrounding land. Unless the data on wind speed,
direction, topographical features and roughness classes are accurate calculations may result in
significant errors in estimating the wind speed, which may lead to even greater errors in
energy estimation especially in complex terrains. In all of above cases, the first step is to estimate
the mean value of the wind speed that is expected on a site and afterwards, the wind energy that a
proposed wind farm would produce in an average year, is estimated. In this paper a model is
developed to estimate annual mean wind speed for a given period using PROLOG [3]. To develop
this model a sufficient set of unpublished wind data of the given site is taken into consideration.
There are several works that deal with the use of probability density functions to describe wind
speed frequency distribution [4].In general, the Weibull probability density function can be used to
estimate a site’s probability distribution of wind speed. The Weibull distribution technique is
widely accepted and used in the wind energy industry as the preferred method for describing wind
speed variations at a given site; some claim the Weibull distributions the best fit for describing
wind speed distribution [5].The Weibull probability density function is a two-parameter function
characterized by a dimensionless shape (k) parameter and scale (c) parameter (in unit of speed ).
These two parameters determine the wind speed for optimum performance of wind conversion
system as well as the speed range over which the device is likely to operate[6].In principle, this
opens up the need to estimate the model parameters, namely, k and c, from the measured data of
any location. This paper study also examines statistical wind data using Weibull distribution,
investigating various Weibull shape and scale parameters for the wind speed at heights of 10m,
30m, 50m for the site under consideration.
2. Prolog
PROLOG is a simple, yet powerful programming language, based on the principles of first
order predicate logic. The name of the language is an acronym for the French `PROgramma-tion en
LOGique'. About 1970, PROLOG was designed by A. Colmerauer and P. Roussel at the University
of Marseille, influenced by the ideas of R.A. Kowalski concerning programming in the Horn clause
subset of first order predicate logic. The name of PROLOG has since then been connected with a
new programming style, known as logic programming
Until the end of the seventies, the use of PROLOG was limited to the academic world. Only
after the development of ancient PROLOG interpreter and compiler by D.H.D. Warren and F.C.N.
Pereira at the University of Edinburgh, the language entered the world outside the research
institutes. The interest in the language has increased steadily. However, PROLOG is still mainly
used by researchers, even though it allows for the development of serious and extensive programs in
a fraction of the time needed to develop a C or Java program with similar functionality. The only
49 Mahesh K1*
., M V Vijaykumar 2., Gangadharaiah.Y.H
3
International Journal of Computer & Mathematical Sciences
IJCMS
ISSN 2347 – 8527
Volume 3, Issue 6
August 2014
explanation is that people like wasting their precious time. Nevertheless, there are a large number of
fields in which PROLOG has been applied successfully. The main applications of the language can
be found in the area of Artificial Intelligence; but PROLOG is being used in other areas in which
symbol manipulation is of prime importance as well. Some application areas are: Natural-language
processing, Complier construction, The development of experts systems, Work in the area of
computer algebra, The development of (parallel) computer architectures and Database systems [3].
PROLOG is particularly strong in solving problems characterized by requiring complex symbolic
computations. As conventional imperative programs for solving this type of problems tend to be
large and impenetrable, equivalent PROLOG programs are often much shorter and easier to grasp.
The language in principle enables a programmer to give a formal specification of a program; the
result is then almost directly suitable for execution on the computer. More-over, PROLOG supports
stepwise refinement in developing programs because of its modular nature. These characteristics
render PROLOG a suitable language for the development of prototype systems.
There are several dialects of PROLOG in use, such as for example, C-PROLOG, SWI-
PROLOG, Sicstus-PROLOG, LPA-PROLO,. C-PROLOG also called Edinburgh PROLOG was
taken as a basis for the ISO standard. However, there are a small number of dialects which change
the character of the language in a significant way, for example by the necessity of adding data-type
information to a program. A typical example is observed by the version of the PROLOG language
supported by Visual PROLOG. In recent versions of PROLOG, several features have been added to
the ISO standard. Modern PROLOG versions provide a module concept and extensive interfaces to
the operating system, as well as tools for the development of graphical user interfaces. In our
Program we have used SWI-PROLOG [3, 13].
3. Description of Data and Study Area A 50 m lattice met tower was installed near the Hiregudda at Biligi Taluk, Bagalkot District
of Karnataka State in Southern India [12]. The site coordinates are: latitude N 16° 19' 40'' and
longitude E 75° 33' 20''. The elevation of the site is 640m above mean sea level (AMSL). The met
tower was equipped with wind speed and direction sensors, a data logger, an ambient air
temperature sensor, and a lightening arrester for protecting the measuring equipment from a severe
thunder storm. Wind speeds and directions at 10 m, 30 m, and 50 m as well as ambient temperature
at 3 m above ground level (AGL) were measured between January 2006 to April 2010 with a 1 min
sampling interval and a 10 min recording interval. Wind speeds were measured using 3-cup
anemometers and wind directions were measured using standard wind vanes both of which were
attached to the end of booms mounted on the met tower. The instruments were connected to a NRG
data logger which was powered by a PV-battery system.
Table.1. Sample data of the site recorded by NRG data logger
50 Mahesh K1*
., M V Vijaykumar 2., Gangadharaiah.Y.H
3
International Journal of Computer & Mathematical Sciences
IJCMS
ISSN 2347 – 8527
Volume 3, Issue 6
August 2014
The resolution of wind speed measurements were 0.19 m/s and the resolution of wind direction
measurements were 1.4°. Measurement accuracy as specified by the instrument manufacturer was
±3% for wind speeds of 17-30 m/s. The measured wind speeds at 10 m, 30 m, and 50 m AGL were
analyzed using the Weibull distribution technique. Weibull parameters were investigated based on
the analytical method. A sample data obtained is has shown in the Table 1.
4. Programming in PROLOG and SWI PROLOG
Programming in Prolog is distinguished from programming in conventional languages in that
Prolog is a declarative language. Prolog programmers describe known facts and relationships within
the domain of the problem they wish to solve, together with a query defining the problem.
Programmers are freed from the task of prescribing the exact sequence of operations needed to solve
a problem as they must do in imperative languages. A more accurate description of the activity of
programming in Prolog is the development of logical specifications of the knowledge within a
particular domain that is necessary to solve a problem. Prolog allows for a declarative style of
programming and is essentially logic combined with control [15]. The logic part is the statement of
what the problem is that has to be solved. The control part is the statement of how it is to be solved.
Figure 1 indicates the relationship between Prolog and logic programming [13].
51 Mahesh K1*
., M V Vijaykumar 2., Gangadharaiah.Y.H
3
International Journal of Computer & Mathematical Sciences
IJCMS
ISSN 2347 – 8527
Volume 3, Issue 6
August 2014
algorithm = logic + control
what how
Horn resolution
clauses
PROLOG
PROLOG
Database interpreter
Figure 1: The relationship between PROLOG and logic programming.
The Prolog version that is used in the paper is the latest one of SWI-Prolog (5.6.52). SWI-
Prolog is a free software, been developed by Amsterdam University from 1990 to 2008, and despite
being free, it is very powerful and has been widely used for commercial and educational
applications. [14]
The reason for the selection of SWI-Prolog for our paper is basically two-fold. On the one
hand, SWI-Prolog has a convenient and easy-to-learn programming environment; the latter may
miss many of the accessories that other Prolog versions’ GUI environments have, but considering
our paper, which is rather straightforward, a simple one would suffice. On the other hand, SWI-
Prolog has a powerful Object-Oriented Programming extension. Since Object-Oriented
Programming is common sense for large-scale applications, several commercial or not versions of
Prolog, SWI-Prolog being among them, have been given such a scope by incorporating OOP
constructs, giving this way an efficient pseudo-OOP scope to its applications. Figure.2. Shows the
basic prolog flow chart used to estimate the mean annual or monthly wind speed of wind data of the
given site.
52 Mahesh K1*
., M V Vijaykumar 2., Gangadharaiah.Y.H
3
International Journal of Computer & Mathematical Sciences
IJCMS
ISSN 2347 – 8527
Volume 3, Issue 6
August 2014
Figure
2: Flow Chart
5. The Weibull wind speed probability density function
Wind power developers measure actual wind resources, in part, to determine the distribution
of wind speeds because of its considerable influence on wind potential. The Weibull wind speed
distribution is a mathematical idealization of the distribution of wind speed over time. The function
shows the probability of the wind speed being in a 1m/s interval centered on a particular speed (v),
taking into account both seasonal and annual variations for the years covered by the statistics. The
Weibull distribution function is given [7; 10] by:
1k k
k v vP v Exp
v c c
(1)
where p(v) is the frequency of occurrence of wind speed (v), c (in unit of m/s) is the scale factor
which is closely related the wind speed for the location, and k is the dimensionless shape factor
which describes the form and width of the distribution. The Weibull distribution is therefore
determined by the two parameters c and k. The cumulative Weibull distribution P(v) which gives the
probability of the wind speed exceeding the value v is expressed as:
53 Mahesh K1*
., M V Vijaykumar 2., Gangadharaiah.Y.H
3
International Journal of Computer & Mathematical Sciences
IJCMS
ISSN 2347 – 8527
Volume 3, Issue 6
August 2014
k
vP v Exp
c
(2)
Equation (2) above suggests that both k and c could be obtained from a regression analysis of P(v)
– v plot of the wind speed distribution data for a particular location.
However, meteorologists have characterized the distribution of wind speeds for many of the
World’s wind regimes in terms of the speed distribution patterns. For example, in temperate
climate (mid latitudes), a typical shape factor (k) of 2 offers a good approximation. For k = 2,
equation (1) or (2) is called the Raleigh wind speed distribution. Hence, the Raleigh distribution is
a special case of the Weibull function developed for estimation of wind potential in temperate
climate locations. Wind characteristics are essentially location specific and the performance of
wind power systems varies if actual wind conditions at the location differ from those standard
speed distributions.
On the other hand, the shape (k) factor has been suggested [11] to be obtainable using the mean
wind speed data (v) and standard deviation (σ) for the location as:
1.086
kv
(3)
While the scale factor has been given [13] as:
11
c
k
(4)
Where ( ) is the gamma function defined mathematically in general x-variable [5] as:
1
0
x nn e x dx
(5)
Analysis of equation (2) suggests that the wind speed probability density for v is higher if the
shape factor is high for that location. Hence, smaller values of k (k < 1) suggest that there is more
concentration of energy in the wind below the average speed (v) for the site, while higher values of k
(k > 1) could be interpreted that the wind speed in the site is dominated by values above the mean
speed [7]. This shows that knowledge of the exact value of k provides preliminary information on
54 Mahesh K1*
., M V Vijaykumar 2., Gangadharaiah.Y.H
3
International Journal of Computer & Mathematical Sciences
IJCMS
ISSN 2347 – 8527
Volume 3, Issue 6
August 2014
the wind speed regime for which wind turbines should be designed for any given location. On the
other hand the value of c for any location provides preliminary information on the characteristic
wind speed for the site for which a wind turbine should be designed. In this paper, we analytically,
find the empirical values of k and c for the windy site under consideration.
6. Results and Discussion
The annual mean wind speed was estimated by using PROLOG program from the measured
wind speeds at 10m, 30m, and 50m AGL at Hiregudda, Bagalkot district in Karnataka state, South
India. The design and developed PROLOG based Graphs are shown in Figures 4(a-e) respectively
and Weibull probability density functions were also calculated from the measured wind speeds at
10m, 30m and 50m AGL at the same site and are shown in Figures 5(a-e), respectively. It was found
that the annual Weibull shape parameter k, at 10-50 m AGL were in the range of 4.2 to 8.5 and
Weibull scale parameter c, were in the range of 4.0-6.2 m/s, thus corresponding to annual mean
wind speeds in the range of 3–5.6 m/s. A summary of annual Weibull shape and scale parameters
are given in Table 2. The annual mean wind values estimated from the available data for the overall
five years are presented in the Table 2. From the table it is seen that highest wind speeds 5.71m/s, at
the height of 50m in the year 2006, 4.96m/s at the height 30m in the year 2009 and 3.94m/s at height
10m in the year 2006. The variation of the described uses the Weibull two parameter density
functions. This is the statistical method accepted for the evaluation local wind probabilities and
considered as a standard approach.
Table 2: Annual Weibull shape parameter, scale parameter and mean speed obtained for
given site.
Years
K
c
Mean Speed
10 30 50 10 30 50 10 30 50
2006 5.046 8.054 8.1205 4.4128 2.2176 6.3952 3.94 1.98 5.71
2007 4.926 7.5644 8.22 4.2224 3.8976 6.16 3.77 3.48 5.50
2008 4.749 6.6333 7.994 4.1888 5.5104 6.1824 3.74 4.92 5.52
2009 4.666 6.969 8.4704 4.0365 5.5552 6.2608 3.60 4.96 5.59
2010 4.2428 6.8764 8.4518 3.1892 4.76 5.376 2.84 4.25 4.8
55 Mahesh K1*
., M V Vijaykumar 2., Gangadharaiah.Y.H
3
International Journal of Computer & Mathematical Sciences
IJCMS
ISSN 2347 – 8527
Volume 3, Issue 6
August 2014
Fig 4a. Annual mean wind speed for the year 2006
Fig 4b. Annual mean wind speed for the year 2007
56 Mahesh K1*
., M V Vijaykumar 2., Gangadharaiah.Y.H
3
International Journal of Computer & Mathematical Sciences
IJCMS
ISSN 2347 – 8527
Volume 3, Issue 6
August 2014
Fig 4c. Annual mean wind speed for the year 2008
Fig 4d. Annual mean wind speed for the year 2009
57 Mahesh K1*
., M V Vijaykumar 2., Gangadharaiah.Y.H
3
International Journal of Computer & Mathematical Sciences
IJCMS
ISSN 2347 – 8527
Volume 3, Issue 6
August 2014
0 2 4 6 80
0.2
0.4
0.6
0.8
Fig 4e. Annual mean wind speed for the year 2010
Fig 5a. Annual Weibull Distribution for year 2006
Wind speed in m/s
P(v)
58 Mahesh K1*
., M V Vijaykumar 2., Gangadharaiah.Y.H
3
International Journal of Computer & Mathematical Sciences
IJCMS
ISSN 2347 – 8527
Volume 3, Issue 6
August 2014
0 2 4 6 80
0.1
0.2
0.3
0.4
0.5
Fig 5b: Annual Weibull Distribution for year 2007
Fig 5c: Annual Weibull Distribution for year 2008
0 2 4 6 80
0.1
0.2
0.3
0.4
0.5
0.6
P(v)
P(v)
Wind speed in m/s
Wind speed in m/s
59 Mahesh K1*
., M V Vijaykumar 2., Gangadharaiah.Y.H
3
International Journal of Computer & Mathematical Sciences
IJCMS
ISSN 2347 – 8527
Volume 3, Issue 6
August 2014
Fig 5d. Annual Weibull Distribution for year 2009.
Fig 5e. Annual Weibull Distribution for year 2010
30
10
50
0 2 4 6 80
0.5
1.
1.5
0 2 4 6 80
0.1
0.2
0.3
0.4
0.5
0.6
P(v)
P(v)
Wind speed in m/s
Wind speed in m/s
60 Mahesh K1*
., M V Vijaykumar 2., Gangadharaiah.Y.H
3
International Journal of Computer & Mathematical Sciences
IJCMS
ISSN 2347 – 8527
Volume 3, Issue 6
August 2014
7. Conclusion
It is concluded that the designed and developed PROLOG program was successfully
implemented for plotting the annual mean wind speed data measured at different heights of 10m,
30m and 50m at Hiregudda at Biligi Taluk, Bagalkot District of Karnataka State in Southern India.
The Weibull shape parameters and scale parameters were estimated for the annual wind speed data
and tabulated and found that Weibull distribution using the graphical method was a useful technique
to conduct wind speed analysis from observed wind speed data at given site. From the observed
wind speed data during January 2006 to April 2010, the annual Weibull shape parameters, k, at 10-
50 m AGL were in the range of 4.2 to 8.5 and Weibull scale parameters, c, and were in the range of
4.0-6.2 m /s, thus corresponding to annual mean wind speeds in the range of 3–5.6 m /s. Finally,
analysis showed that strong and sufficient wind speed is available at the given site.
Acknowledgments
The authors gratefully acknowledge the Karnataka Renewable Energy Development Limited
(KREDL), a nodal agency by the ministry of non conventional energy resources Govt. of India for
providing the wind data resource assessment. The authors also acknowledge Jain University and
New Horizon College of Engineering for supporting in publishing of this research paper.
References [1] J. Waewsak, C. Chancham, M. Landary and Y. Gagnon, “An analysis of wind speed distribution
at Thasala, Thiland” Journal of Sustainable Energy and Environment 2 (2011) 51-55.
[2] Dr. S .Gomathinayagam, K.Boopathi “ Course Material on Wind Resource Assessment and
Wind technology for State Nodal Agencies(SNAs) India” , organized by C-WET-2013.
[3] M. Balduccini, M. Gelfond and M. Nogueira. A-Prolog as a tool for declarative programming.
In Proceedings of the 12th International Conference on Software Engineering and Knowledge
Engineering (SEKE’2000), 63-72, 2000.
[4] Mert Y, Usta KI, Analysis of wind speed distributions: wind distribution function derived from
minimum cross entropy principles as better alternative to Weibull function, Energy Conversion
and Management 49 (2008) 962-973.
[5] Patel MR, Wind and Solar Power Systems (1999) CRC Press.
[6] Ramchandra, T, V. Rajeev, K. J. Vansee, and Sruthi B, 2005 Energy Education science and
Technology, 14, 61.
[7] Akpinar EK, Akpinar S, Determination of the wind energy potential for Maden, Turkey, Energy
Conversion and Management 45 (2004) 2901–2914.
61 Mahesh K1*
., M V Vijaykumar 2., Gangadharaiah.Y.H
3
International Journal of Computer & Mathematical Sciences
IJCMS
ISSN 2347 – 8527
Volume 3, Issue 6
August 2014
[8] Papoulis A, Pillai SU, Probability, random variables, and stochastic processes (2001) 4th
Edition.
[9] Joseph P, Hennesessey J, Some aspects of wind power statistics, Journal of Applied
Meteorology 16 (1977) 119-128.
[10] Walker, J. F and Jenkins. S (1997): wind Energy Technology, John Wiley and Sons,
Chinchester.
[11] Gipe. P, (2004) : Wind Power: Renewable energy for home farm and businesses, Chelsea
Green USA.
[12] Indumathy. D, Seshaiah. C. V, Sukkiramathi. K, “Estimation of Weibull Parameters for wind
speed calculation at Kanyakumari in India”, IJIRSET, Volume 3, Issue 1, 2014 ISSN. NO.
2319-8753.
[13] I. Bratko. PROLOG Programming for Artificial Intelligence, 3rd ed. Addison-Wesley,
Harlow, 2001.
[14] SWI-Prolog’s Official Web Site. What is SWI-Prolog? http://www.swi-prolog.org/.
[15] Kowalski, R. “Algorithm = logic + control”. Common. ACM 22, 7 (July 1979), 424-436.