Journal of Water Resource and Protection, 2012, 4, 523-527
http://dx.doi.org/10.4236/jwarp.2012.47061 Published Online July 2012 (http://www.SciRP.org/journal/jwarp)
Evaluation of Tigris River by Water Quality Index
Analysis Using C++ Program
Allaa M. Aenab1, S. K. Singh1, Adil Abbas Majeed Al-Rubaye2
1Environmental Engineering Department, Delhi Technological University (DTU), Delhi, India
2Electrical & Communication Engineering Department, Al-Mansour University College, Baghdad, Iraq
Received April 3, 2012; revised May 1, 2012; accepted June 3, 2012
In the capital city of Baghdad, The surface water suffering from effect of conservative pollutants. Baghdad city has two
rivers, the main river Tigris River and Diyala River in boundary of Baghdad city (Jassir Diyala) eastern of Baghdad as
is shown in Figure 1. The present study deals with the evaluation of water quality of Tigris River within Baghdad. In
the case of Tigris River the concentrations of TH, TDS, PO4 and SO4 were found to lie outside the acceptable range of
WHO standards by using WQI analysis and C++ program.
Keywords: Tigris River; Water Quality; WQI; C++ Program and River Evaluation
The main rivers of Iraq, the Tigris and the Euphrates
which cover an area of 126,900 km2 and 177,600 km2
respectively, cross Iraq by their middle and lower reaches,
eventually to confluence in the river Shatt Al-Arab, be-
fore flowing into the Arabian Gulf. The Tigris provides
all the main tributaries within Iraq (Greater Zab, Lesser
Zab, Adhaim and Diyala) with no tributaries sourced
from the Euphrates. The arid regions along the watershed
are characterized by the existence of “wadis” in the upper
reached of Iraq. More than 90% of Iraq’s water depen-
dent needs are met by surface water and 80% of this wa-
ter flow comes from its three neighboring countries .
The Tigris is 1850 km long, rising in the Taurus
Mountains of eastern Turkey about 25 km southeast of
the city of Elazig and about 30 km from the headwaters
of the Euphrates. The river then flows for 400 km
through Turkish territory before becoming the border
between Syria and Iraq. This stretch of 44 km is the only
part of the river that is located in Syria. The remaining
1418 km are entirely within the Iraqi borders . Since
1965, when Horton (1965) proposed the first water qual-
ity index (WQI), a great deal of consideration has been
given to the development of “water quality index” meth-
ods with the intent of providing a tool for simplifying the
reporting of water quality data. However, there is no re-
liable water quality index has been developed in Iraq to
assess water suitability of irrigation . WQI is a set of
standards used to measure changes in water quality in a
particular river reach over time and make comparisons
from different reaches of a river. A WQI also allows for
comparisons to be made between different rivers. This
index allows for a general analysis of water quality on
many levels that affect a stream’s ability to host life .
WQI is an arithmetical tool used to transform large quan-
tities of water quality data into a single cumulatively de-
rived number. It represents a certain level of water qual-
ity while eliminating the subjective assessments of such
quality [5-7]. It is intended as a simple, readily under-
standable tool for managers and decision makers to con-
vey information on the quality and potential uses of a
given water body, based on various criteria . Further
more it turns complex water quality data into information
that is understandable and usable by the public. It gives
the public a general idea of the water quality in a par-
ticular region. Water Quality Index (WQI) is a very use-
ful and efficient method for assessing the suitability of
water quality. It is also a very useful tool for communi-
cating the information on overall quality of water to the
concerned citizens and policy makers. It, thus, becomes
an important parameter for the assessment and manage-
ment of water quality (both surface and groundwater).
WQI reflects the composite influence of different water
quality parameters and is calculated from the point of
view of the suitability of (both surface and groundwater)
for human consumption . Table 1 showing Water
Quality Index Ranges is [9,10].
2. Objectives and Approach
The objectives are important tools, used in a framework
opyright © 2012 SciRes. JWARP
A. M. AENAB ET AL.
Table 1. Water quality index categories.
WQI 0 - 25 26 - 50 51 - 75 76 - 100 >100
Quality Excellent Good Poor Very Poor Unsuitable
Source: Brown et al., 1970 .
Figure 1. Map of Tigris River within Baghdad city.
of provincial and federal environmental assessment, risk
management, and the application of best available treat-
ment technology, which support the management, pro-
tection and enhancement of the surface water resources
of the province . The main objective of this paper is
to develop an index method for assessing water quality to
use this method to assess the general water suitability of
irrigation for use in agriculture. Monitoring water quality
parameters in Tigris River and calculate overall water
quality index (WQI) for evaluate Tigris River water in
study area by using C++ program for this calculation.
3. Materials and Methods
3.1. Study Area
Both Tigris and the Euphrates are international rivers
originating from Turkey. The Tigris river basin in Iraq
has a total area of 253,000 km2, or 54% of the total river
basin area. For the Tigris, average annual runoff as it
enters Iraq is estimated at 21.2 km3. All the Tigris tribu-
taries are on its left bank. From upstream to downstream
The Greater Zab, which originates in Turkey and is
partly regulated by the Bakhma dam. It generates
13.18 km3 at its confluence with the Tigris; 62% of
the 25,810 km2 of river basin is in Iraq;
The Lesser Zab, which originates in Iran and is
equipped with the Dokan dam (6.8 km). The river ba-
sin of 21,475 km2 (of which 74% is in Iraqi territory)
generates about 7.17 km, of which 5.07 km3 of annual
safe yield after the Dokan construction;
The Al-Adhaim (or Nahr Al Uzaym) which drains
about 13,000 km2 entirely in Iraq. It generates about
0.79 km3 at its confluence with the Tigris. It is an in-
termittent stream subject to flash floods;
The Diyala, which originates in Iran and drains about
31,896 km2 of which 75% in Iraqi territory. It is
equipped with the Darbandikhan dam and generates
about 5.74 km3 at its confluence with the Tigris;
The Nahr at Tib, Dewarege (Doveyrich) and Shehabi
Rivers, draining together more than 8000 km2. They
originate in Iran, and bring together in the Tigris
about 1 km3 of highly saline waters;
The Al-Karkha, whose course is mainly in Iran and,
from a drainage area of 46,000 km2, brings about 6.3
km3 yearly into Iraq, namely into the Hawr Al Ha-
wiza during the flood season, and into the Tigris
River during the dry season.
Turkey shares the waters of the Tigris River with the
states of Syria and Iraq. Particularly Iraq relies on the
water of the Tigris River and could almost not have any
agriculture and water supply of urban centers without the
water of Tigris and Euphrates. The fact that the storage
capacity of the proposed Ilisu Dam and other dam pro-
jects is larger (at least 21 Cubic Kilometers) than the
annual water flow of the Tigris (17 Cubic Kilometers)
from Turkey to Iraq, explains the high impact of this
project . The Tigris collects 43% of its flow in Tur-
key and 57% of its flow within Iraq from left-bank tribu-
taries including the Greater Zab, Lesser Zab, Adhaim and
Diyala Rivers. Usage of Tigris water within Iraq includes
agricultural irrigation, and municipal water supply; the
Tigris also has several water storage facilities for flood
control and power generation within Iraq. Between 1928
and 1946, the average stream flow of the Tigris as it en-
tered Iraq was 18 bcm/yr; stream flow in the Tigris in-
creased to 42 bcm/yr (billion cubic meters per year) past
its confluence with the Diyala River; discharges south of
this point reduced flow in the Tigris to 37 bcm/yr at Kut.
Past Kut, the Tigris supplies water for irrigation and pub-
lic water supply and also discharges to the Central Marsh.
Combined, these discharges reduced its flow to 7 bcm/yr
at Amarahh and 3 bcm/yr at Qalat Salih during this same
time period .
3.2. Samples Collection
Water samples were collected from selected eight sta-
tions in Tigris River from January 2004 to December
2010. The samples were collected from just under water
surface for analysis of selected parameters included: pH,
biological oxygen demand (BOD5), nitrate (NO3), phos-
phate (PO4), Total Dissolved Solids (TDS), Total Hard-
ness (TH), Magnesium (Mg), Calcium (Ca), Chlorides
(Cl), Sulphates (SO4), Sodium (Na) and electrical con-
Copyright © 2012 SciRes. JWARP
A. M. AENAB ET AL. 525
3.3. Application of C++ Program
C++ is a statically typed, free-form, multi-paradigm,
compiled, general-purpose programming language. C++
is sometimes called a hybrid language. It is regarded as
an intermediate-level language, as it comprises a combi-
nation of both high-level and low-level language features
. It was developed by Bjarne Stroustrup starting in
1979 at Bell Labs as an enhancement to the C language.
Originally named C with Classes, the language was re-
named C++ in 1983 . C++ is one of the most popular
programming languages [17,18] with application do-
mains including systems software, application software,
device drivers, embedded software, high-performance
server and client applications, and entertainment software
such as video games . Several groups provide both
free and proprietary C++ compiler software. C++ has
greatly influenced many other popular programming lan-
guages, most notably C# and Java. After years of deve-
lopment, the C++ programming language standard was
ratified in 1998 as ISO/IEC 14882:1998. The standard
was amended by the 2003 technical corrigendum, ISO/
IEC 14882:2003. The current standard extending C++
with new features was ratified and published by ISO in
September 2011 as ISO/IEC 14882:2011 (informally
known as C++11) [20,21].
3.3.2. Algorit hms and Steps
In my work using language C++ under window to execu-
tion, and perform some steps to implementation this pro-
Create Project File consist of number of files.
Create dialog boxes that perform to dialog with users.
Read and input Data to system for all stations from
Select type of process from menu (Normality Test,
Z-Test, t_Test, ANOVA (analysis of variance) Test
and Water Quality Index).
Execution algorithm and calculate mathematics for all
process after enter data.
Display Result with high speed (Less than 1 second).
As is shown in Figure 2.
3.3.2. Water Qualit y I nde x Cal cul a tion
The WQI was calculated using the standards of drinking
water quality recommended by the World Health Or-
ganization (WHO). The weighted arithmetic index me-
thod  was used for the calculation of WQI of the sur-
face water. Further, quality rating or sub index (qn) was
calculated using the following expression.
qn = 100 [Vn – Vio ]/[Sn – Vn]
Figure 2. C++ diagram.
(Let there be n water quality parameters and quality
rating or sub index (qn) corresponding to nth parameter
is a number reflecting the relative value of this parameter
in the polluted water with respect to its standard, maxi-
mum permissible value).
qn = Quality rating for the nth water quality parameter.
Vn = Estimated value of the nth parameter at a given
Sn = Standard permissible value of the nth parameter.
Vio = Ideal value of nth parameter in pure water (i.e. 0
for all other parameters except the parameter pH and
Dissolve Oxygen (7.0 and 14.6 mg/L respectively).
Unit weight was calculated by a value inversely pro-
portional to the recommended standard.
value Sn of the corresponding parameter.
Wn = K/Sn.
Wn unit weight for the nth parameters.
Sn = standard value for the nth parameters.
K = constant for proportionality.
The overall WQI was calculated by aggregating the
quality rating with the unit weight linearly.
Table 2 presents the result of the physical parameters of
surface water quality. The result showed that Total Hard-
ness (TH) in very high range and cross WHO limit
(344.4 mg/l) and phosphate (PO4) in highest value and
cross WHO standard (0.3 mg/l). Also we found the elec-
trical conductivity (EC) in high value (1175.7 mg/l) and
that more than WHO standard. WQI for the year of 2004
it was 589.1552 > 100 this means unsuitable for use.
Figure 3 shows all the years (2004, 2005, 2006, 2007,
2008, 2009 & 2010) the result almost same all results of
WQI was above 100 and that makes surface water in
Tigris River unsuitable for use.
The year of 2004 has three parameters out of WHO
standard values, it was TH (344.4 mg/l), PO4 (0.3 mg/l)
and EC (1170.1 mg/l), WQI in total was (589.1552). For
the year of 2005, 2008 & 2009 it has five parameters out
of WHO standard values and that parameters is TH
Copyright © 2012 SciRes. JWARP
A. M. AENAB ET AL.
Table 2. Water Quality Index result by C++ program for
the year 2004.
Figure 3. Water Quality Index (WQI) values for the years
(389.975, 421.225 & 416.575 mg/l), respectively, T.D.S
(611.89, 616.1373 & 626.74 mg/l), SO4 (237.5, 201 &
201.1 mg/l), PO4 (0.325, 0.325 & 0.375 mg/l) and EC
(1170.1, 1175.78 & 1170.1 mg/l), WQI in total was
(638.1017, 638.0811 & 735.7739). In 2006 & 2007 there
is four parameters out of WHO standard values, it was
TH (337.2 & 321.55 mg/l), respectively, T.D.S (618.1 &
583.525 mg/l), SO4 (245.975 & 244.775 mg/l) and PO4
(0.45 & 0.525 mg/l), WQI in total was (881.8434 &
1028.4301). Finally in year of 2010 has two parameters
out of WHO standard limit values, the parameters was
TH (285.6 mg/l) and PO4 (0.463 mg/l), WQI in total
From all above result we can see all of WQI > 100 and
that’s means WQI type is unsuitable for use.
 Geopolicity, “Managing the Tigris—Euphrates Water-
shed: The Challenge Facing Iraq,” 2010, pp. 3-10.
 V. A. Isaev, et al., “The Hydrology, Evolution, and Hy-
drological Regime of the Mouth Area of the Shatt
Al-Arab River,” Water Resources, Vol. 36, No. 4, 2009,
pp. 380-395. doi:10.1134/S0097807809040022
 A. J. K. Al Meini, “A Proposed Index of Water Quality
Assessment for Irrigation,” Engineering & Technology
Journal, Vol. 28, No. 22, 2010, pp. 6557-6561.
 K. Ashwani, et al., “Water Quality Index for Assessment
of Water Quality of River Ravi at Madhopur (India),”
Global Journal of Environmental Sciences, Vol. 8, No. 1,
2009, pp. 49-57.
 N. Štambuk-Giljanović, “Water Quality Evaluation by
Index in Dalmatia,” Water Research, Vol. 33, No. 16,
1999, pp. 3423-3440.
 N. Štambuk-Giljanović, “Comparison of Dalmatian Wa-
ter Evaluation Indices,” Water Environment Research,
Vol. 75, No. 5, 2003, pp. 388-405.
 W. W. Miller, et al., “Identification of Water Quality
Differences in Nevada through Index Application,” Jour-
nal of Environmental Quality, Vol. 15, No. 3, 1986, pp.
 Akoteyon, et al., “Determination of Water Quality Index
and Suitability of Urban River for Municipal Water Sup-
ply in Lagos-Nigeria,” European Journal of Scientific
Research, Vol. 54, No. 2, 2011, pp. 263-271.
 A. Hameed, et al., “Evaluating Raw and Treated Water
Quality of Tigris River within Baghdad by Index Analy-
sis,” Journal of Water Resource and Protection, Vol. 2,
2010, pp. 629-635. doi:10.4236/jwarp.2010.27072
 R. M. Brown, N. I. McClelland, R. A. Deininger and R. G.
Tozer, “A Water Quality Index—Do We Dare?” Pro-
ceedings of the National Symposium on Data and Instru-
mentation for Water Quality Management, Conference of
State Sanitary Engineers and Wisconsin University, Madi-
son, 21-23 July 1970, pp. 364-383.
 EPB 356, “The Surface Water Quality Objectives. Drink-
ing Water Quality Section. Saskatchewan Environment,”
July 2006, pp. 1-15.
 S. Grego, et al., “Water Purification in the Middle East
Crisis: A Survey on WTP and CU in Basrah (Iraq) Area
within a Research and Development Program,” Desalina-
tion, Vol. 165, 2004, pp. 73-79.
 UNESCO, “Background Information on the Petition to
Copyright © 2012 SciRes. JWARP
A. M. AENAB ET AL.
Copyright © 2012 SciRes. JWARP
Save Potential World Heritage on the Tigris River in
Mesopotamia Directed to the World Heritage Committee
of the UNESCO,” 14 March 2012, pp. 1-3.
 The Iraq Foundation, “Draft Report Physical Characteris-
tics of Mesopotamian Marshlands of Southern Iraq,” 2003,
 H. Schildt, “C++ The Complete Reference Third Edi-
tion,” Osborne McGraw-Hill, 1998, pp. 23-28.
 B. Stroustrup, “C++ Faq: When Was C++ Invented,” 7
March 2010, Retrieved 16 September 2010, pp. 11-19.
 “Programming Language Popularity,” 2009, Retrieved 16
January 2009, pp. 2-9. http://www.langpop.com/
 “TIOBE Programming Community Index,” 2009, Retrie-
ved 3 August 2011, pp. 1-2.
 C++ Applications, “What’s CvSDL?” Retrieved 8 March
2010, pp. 2-3.
 ISO, “ISO/IEC 14882:2011,” Retrieved 3 September 2011.
 “Most Popular Programming Languages,” Retrieved 7
September 2011, pp. 2-4. http://langpop.com/