International Journal of Applied Engineering Research ISSN 0973-4562 Volume 12, Number 23 (2017) pp. 13215-13219© Research India Publications. http://www.ripublication.com

Artificial Neural Network (Narx Algorithm): prediction of dissolved oxygenin the Sinu River (Colombia)
Feria Díaz, John Jairo1; Rodríguez Miranda, Juan Pablo2; Ruiz Ochoa and Mauricio Andres3
1

Sanitary Engineer, Environmental Sciences MSc. Research Group on Environment and Water (GIMAGUAS),
Plant Professor, Department of Civil Engineering, University of Sucre, Sincelejo, Colombia.
2

Sanitary and Environmental Engineer, Environmental Engineering Msc. PhD (Candidate) Engineering,
Associate Professor, Francisco Jose de Caldas University, Director of the AQUAFORMAT research group, Colombia.
3Engineer of the Environment, PhD in Water Resource Engineering,
Associate professor. Technological Units of Santander, Bucaramanga, Colombia.

Abstract
This paper considers the prediction parameter turbidity in theraw water quality specifically the dissolved oxygen in theSinu River (Colombia), from sampling at this body of water, inorder to estimate relevant conditions of raw water quality andaspects in the use of water resources in the river basin.
Keywords: Raw water, artificial neural network, prediction,
dissolved oxygen.

minimum of the function F(x), that is a sum of squares ofnon - linear functions.
12𝐹(𝑥) = ∑𝑚𝑖=1[𝑓𝑖 (𝑥)]2(1)Take the Jacobian fi(x) that is termed as Ji(x), then theLevenberg-Marquardt method seeks the solution of P givenby equation(𝐽𝑘𝑇 𝐽𝑘 + 𝜆𝑘 𝐼)𝑃𝑘 = −𝐽𝑘 𝑓𝑘(2)

where λk are not negative scalars and I is the identity matrix [4].
INTRODUCTION
The technique used was the Artificial Neural Network(ANN). This technique has different algorithms training as
BackPropagation,
Newton,Levenberg
Marquardt (LM), among others. The most commonand used is BackPropagation; but in the case of the present
investigation the best results was obtained with the Levenberg
Marquardt (LM). The artificial LM neural network is a feedforward neural network. This network is composedof individual processing elements called neurons
that resemble as brain neurons [1]. The model ofeach neuron can be represented as A = F (WP + b) where W =[w 1,1, w 1,2, ..., w 1, R] and P = [p 1, p 2, ... ,R p], the P vector
are inputs, W is the vector of weights for each input, theparameters w 1, R and b are adaptive [2]. Each neuron adds theweighted inputs and then apply a linear or nonlinear function to
the resulting sum to determine the outputs. Between the mostused functions are the step function, sigmoid andramp [3]. Neurons are arranged in layers and combine throughexcessive connectivity. This permits specifying multiple
criteria
inputandgenerating
multiple
outputrecommendations[1].
The
LevenbergMarquardt (LM) algorithm is a nonlinear optimization based on
the use of second order derivatives [3]. LM algorithm find theThe artificial intelligence technique “Artificial NeuralNetworks (ANN)”, has been working in centralized airconditioning of ice water, predicting consumption of water andriver flows, in assessing the quality of drinking water, in thecontrol of process water treatment, plant management
wastewater treatment, purification of underground waters andthe identification of water pollution sources, in terms of dioxins
and sediments in rivers [5]. Other results of studies by Hamoda(1999) and Grieu (2005), have established that the performanceof the WWTP can be predicted through a neural network andalso other studies such as Hamed (2004) and Mjalli (2007),Tomenko (2007), have shown that neural networks has
surpassed regression models used in wastewater treatment
plants [6]. Also, studies have been conducted by Lin (2008),
Dogan (2009) and Singh (2009) using neural networks for theprediction of river water quality in river basins. However, it has
also been found in studies conducted by Beck (2005) an
accumulated error effect over a period of several years, which
although it generates a considerable approximation in thecumulative predictions in multiple periods of time, is highly
significant and influential in the quality water in the basin[6]. Another application has been in the analysis and diagnosis
of a wastewater treatment plant (activated sludge technology),13215

International Journal of Applied Engineering Research ISSN 0973-4562 Volume 12, Number 23 (2017) pp. 13215-13219© Research India Publications. http://www.ripublication.com
due to the high variability of the concentration of theparameters of the raw waste water (tributary) and theknowledge of the performance of the processes and unit
biological operations present in wastewater treatment plants,
therefore, an analysis was made through neural networks, todiscover dependencies between the process variables and thebehavior of the wastewater treatment plants and their potential
for application to other treatment plants wastewater [7]. Linear
statistical and neural network models for the application ofwater management in watersheds have been applied, taking into
account the effluents of wastewater treatment plants and nonpoint sources (rainfall run-off). Therefore, in this study theenvironmental quality in the basin of Sinu River (Colombia)
using the technique of artificial neural network with Levenberg
Marquardt algorithm we will be assessed.

MATERIALS AND METHODS
The method used is a combination of real, exact observationand knowledge of an empirical, complex situation andinductive reasoning, which would consist of deriving a newknowledge from particular phenomena and knowledge alreadyobtained, and establishing propositions analyzed from theircauses and real effects, i.e., from the particular to
generally [8, 9]. It is mentioned, that according to the analysis
and scope of the results, the type of research is analytical –quasi- experimental, since analyzes an event and comprising interm s of their obvious aspects, and also discover elements thatmake up the whole and connections that explain theirintegration, i.e., promotes the study and deeper understandingof the event under study [10, 11, 12].
Precipitation information obtained from sampling in the period
2008 to 2014 by the Autonomous Regional Corporation of theSinu and San Jorge Valley (CVS).

RESULTS
The implementation of the artificial neural network using theLevenberg Marquardt, was obtained by importing the data overtime and then environmental quality was estimated according
Dissolved Oxygen data input, for it was established thefollowing design:

Figure 1: Proposed Feedforward Neural Network Model.

13216

International Journal of Applied Engineering Research ISSN 0973-4562 Volume 12, Number 23 (2017) pp. 13215-13219© Research India Publications. http://www.ripublication.com
In figure 1, a block of entries was observe in the first layer, withacceptable results of four layers and can be used in the second
stage of network design, which corresponds to a standard
design of the artificial neural network known as
feedforward, usually having one or more hidden layers with therespective training method, followed by a linear output layer.
In terms of the training layer (hidden) it is characterized by atraining criterion or activation which can explicitly use theLevenberg
Marquardt
algorithm,
which
has
a1
2
function expressed as follows: 𝐹(𝑥) = ∑𝑚[𝑓(𝑥)],
bethe𝑖=1 𝑖
2

Jacobian of 𝑓𝑖 (𝑥) defined as 𝐽𝑖 (𝑥), in such way that thealgorithm searches iteratively, in the given direction, for thesolutions to the required equations: (𝐽𝑘 𝑇 𝐽𝑘 + 𝜆𝑘 𝐼)𝑝𝑘 =−𝐽𝑘 𝑇 𝑓𝑘 , where 𝜆𝑘 are the non-negative scalars and 𝐼
corresponds to the identity matrix. Based on the above, theneuronal network is formed in Matlab and 50 neurons weredefined, the decision of the number can become subjective,
given the fact that, depending on the application, the decisive
factor lies in the result obtained.

Sinu RiverThe Sinu river basin is located in the northwest of Colombia, inSouth America, more specifically in the southwest area of theColombian Caribbean coast, within the Departments ofCordoba and Antioquia. It originates in the Paramillo massif,
which ranges between 7º 8’ 9” and 9º 27’ 2” north latitudes and75 ° 55' 31" and 75 ° 58 '18 " west lengths. The Sinu River isthe main water system in the department of Cordoba, since
besides fertilizing its valley - which is the stage of an intense
agricultural and livestock activity - it represents an important

supplier of fish species, thus becoming one of the main
ecosystems of the Colombian Caribbean coast [14].
The river is stored by the Urra 1 hydroelectric dam, withincoordinates 8º 01´ 10” north latitude and 76º 12´ 08” west
longitude. Along its course, Sinu River has a complex
interaction with streams, marshes and swamps that flow into itand regulate its pikes during maximum flood level
periods [14, 15].
Dissolved Oxygen concentration (DO), biochemical oxygen
demand (BOD) and Total Kjeldahl Nitrogen (TKN) is not
uniform in the Sinu River, either in the stream or throughout
the year. The DO varies between 3.7 mg / L and 5.5 mg /L; BOD between 1.0 mg / L and 2.0 mg / L and TKN is lessthan 1.0 mg / L, near the dam. Nonetheless, in remaining streamof the Sinu River, the DO varies between 6.0 mg / L and 7.0
mg / L; BOD, between 1.0 mg / L and 2.0 mg / L and NTK isless than 1.0 mg / L [16].
The Sinu River is the main source providing water to theaqueduct systems in the department of Cordoba (Colombia)[17]; however, its turbidity levels are higher than 1.200 NTU,
during the rainy season, and even higher than 40 NTU, during
the dry season [18].
In Figure 2, data traffic analyzed, generates high variability andheterogeneity in dissolved oxygen concentrations in the bodyof surface water, indicating a good health condition of the river,which considered a representation of the degree of quality bodyof water along basin and at the same time some scatter points
together cloud data analyzed in the analyzed period 2008-2014

OD Rio Sinu

7.2

7

6.8

6.6

OD

6.4

6.2

6

5.8

5.6

5.4
01-2008

01-2009

01-201001-201101-201201-2013

Tiempo (Meses)

Figure 2: Dissolved Oxygen Data in the sample

13217

01-2014

International Journal of Applied Engineering Research ISSN 0973-4562 Volume 12, Number 23 (2017) pp. 13215-13219© Research India Publications. http://www.ripublication.com
Prediccion OD Hasta Enero 2016

7.2

MedidaPrediccion

7

6.8

6.6

OD

6.4

6.2

6

5.8

5.6

5.4
01-2008.

01-2009

01-201001-201101-201201-201301-201401-2015

Tiempo (Meses)

Figure 3: Prediction of dissolved oxygen.

In Figure 3, is observed how the line features is the indicator ofenvironmental quality of the water body measured as dissolved
oxygen, a volatile fluctuation occurs with a low frequency
turn like in the analyzed period (2008-2014), with a highdispersion results environmental quality for surface water; adecreasing prediction is observed in the following period of theyear 2015 to 2016, but within the condition of good health ofthe river.
This may relate to the conditions of water quantity in the Sinu
River, where it is mentioned that the flow averages river during
the months of March and April are kept in a range of 200 m3/s
to 400 m3/s, with peaks ranging from 70 m3/s up to 600 m3/s,
while in the months from May to August, the average flow rate
ranges from 400 m3/s to 600 m3/s, with peaks from 250 m3/s to
850 m3/s. Finally, during the months of September toDecember, the average flow range is 200 m3/s to 600 m3/s, withpeaks of 70 m3/s to 700 m3/s, which generates a dilution
condition of the pollutants discharged and the adequate selfrecovery of the body of water.

experts based on the results of performance, which serves tomake environmental decisions in any space of time and evenduring interannual analysis periods and used to predict thebehavior of the parameter (oxygen dissolved) in later periods
and establish the quality or health of the body water, to consider
actions for improvement or maintenance of water quality in thewatershed.

ACKNOWLEDGEMENTS
Authors grateful the Regional Autonomous Corporation ofSinu and San Jorge Valleys and Hydrology, Meteorology andEnvironmental Studies Institute (IDEAM) for the information
provided in the basin analyzed.

REFERENCES[1]

X. Zhou, W. Zhang, W. Yuan y Q. Liu, «The
Environmental Quality Evaluation Based on BP Neural
Network and PSO and Case Study,» de 2008
International Symposium on Intelligent Information
Technology Application Workshops, Shanghai, 2008.

[2]

C. Zhu y Z. Hao, «Fuzzy Neural Network Model andIts Application in Water Quality Evaluation,» deInternational Conference on Environmental Science

CONCLUSIONS
By using artificial neural network with the Levenberg
Marquardt algorithm to estimate the environmental quality interms of dissolved oxygen in the body of surface water in thecase of the Sinu River, it is observed that by using a layered
compiled neurons and a layer of training, the result is very
favorable in emulation of the environmental quality of the13218

International Journal of Applied Engineering Research ISSN 0973-4562 Volume 12, Number 23 (2017) pp. 13215-13219© Research India Publications. http://www.ripublication.com
prospección y formulación del plan de Ordenamiento y Manejo
Integral de la Cuenca hidrográfica del río Sinú (Pomca-Rs).
Informe Técnico. Montería. Colombia. pp. 691, 2006.

and Information Application Technology, 2009. ESIAT
2009. , Wuhan, 2009.
[3]

Z. Cano, Alfredo y Estéfano, «Desarrollo de redes
neuronales artificiales para el cálculo del transporte
neoclásico en reactores de fusión,» 2012. [En línea].
Available:
https://earchivo.uc3m.es/bitstream/handle/10016/15279/PFC_EstefanoAlfredo_Zarza_Cano.pdf. [Último acceso: 1707 2017].

[4]

P. Gill, W. Murray y M. and Wright, The LevenbergMarquardt Method in Practical Optimization, London:
Academic Press, 1981, pp. 136-137.

[5]

I. Babea, «El problema del agua y la inteligencia
artificial,» Universidad Carlos III de Madrid, Madrid,
España, 2010.

[6]

West D, «An empirical analysis of neural network
memory structures for basin water quality forecasting,»
International Journal of Forecasting, p. 777–803,
2011.

[7]

Hong Y.S, « Analysis, Analysis of a municipal
wastewater treatment plant using a neural networkbased pattern,» Water Research, p. 1608–1618, 2003.

[8]

G. Vergel, Metodología: un manual para la elaboraciónde proyectos de investigación., Barrranquilla.:
Unicosta, 2010.

[9]

M. Balestrini, Cómo se elabora el proyecto deinvestigación, Caracas, Venezuela: BL Consultores
asociados, 2001.

[16] J. J. Feria, D. Nader, S.J. Meza, “Deoxygenation and reaeration rates of the sinu river”, Ingeniería y Desarrollo, vol.
35, n° 1, pp. 20-28, Enero – Junio, 2017.
[17] A.A. López, L.E. Martínez, J.J. Feria, “Parámetros
hidrológicos y tensores en la dinámica fluvial: estudio encuencas del caribe colombiano”. Ingeniería y Desarrollo, vol.
32, n° 2, pp. 20-28, Julio – Diciembre, 2014.
[18] J.P. Rodiño, J.J. Feria, R.J. Paternina, J.L. Marrugo, “SinúRiver raw water treatment by natural coagulants”. Revista
Facultad de Ingeniería, Universidad de Antioquia, n° 76, pp.
90-98, Sep. 2015.

[10] Hurtado J., Metodología de la investigación holística.,
Caracas: Fundación SYPAL, 2000.
[11] Vergel G., Metodología. Un manual para la elaboraciónde diseños y proyectos de investigación. Compilación yampliación temática., Barranquilla: Publicaciones
Corporación UNICOSTA, 2010.
[12] R. Hernández, Metodología de la investigación.,
México: Mc Graw Hill, 2010.
[13] J. Creswell, Qualitative inquiry & research design:
choosign among five approaches., UK: SAGE
publications, 2007.

[14] J.J. Feria, J.L. Marrugo, H. González, “Heavy metals in
Sinú river, department of Córdoba, Colombia, South America”,
Revista Facultad de Ingeniería, Universidad de Antioquia, n°55, pp. 35-44, Sep. 2010.
[15] Corporación Autónoma Regional de los Valles del Sinú ydel San Jorge (CVS). Universidad de Córdoba. Fases de13219