Powerful Google developer tools for immediate impact! (2023-24 C)
An Artificial Neural Network Based Medical Diagnosis of Mental Health Diseases
1. Nathanael Asaam
Founder and CEO @ Equicksales Consulting Ltd | Application Support Officer @ Ashesi University
nataoasaam@gmail.com
1
An Artificial Neural Network Based Medical Diagnosis of Mental Health Diseases
Abstract
In this research paper, we explore Artificial Neural Network (ANN) in Medical Diagnosis of Mental Health
Diseases. The focus area was two mental health conditions, namely Bipolar Disorder and Schizophrenia.
Additionally, we used two main ANN learning algorithms to predict the diagnosis for mental health illness
based on the symptoms for the two mental health diseases we are focusing on. The two algorithms are
Perceptron and Adaline. Also, we implemented the two learning algorithms and four activation functions
that were used to train the ANN. The four activation functions are Binary Step, Linear, Sigmoid Logistic and
Hyperbolic Tangent.
We also trained the Perceptron algorithm using the binary step function, the sigmoid logistic
function and the hyperbolic tangent function. For the Adaline algorithm, we used the linear activation
function, the sigmoid logistic activation function and the hyperbolic tangent activation function for the
training. Results from our work show that perceptron is very effective at predicting the diagnosis for the
two mental health diseases, especially using the binary step activation function. Adaline algorithm was
not very effective at predicting the probability of a patient having any of the two diseases, particularly
using the linear activation function. It performed a little bit okay with the other two activation function
implemented. However, the Perceptron algorithm implemented was able to predict if a patient has any of
the two mental conditions. The output for the perceptron algorithms was a binary value with 1 indicating
that patient has the disease and 0 indicating that patient does not have the disease.
Introduction
Artificial Neural Network is a sub-field of Artificial Intelligence (AI). This branch of AI is widely used in
various branches of Arts, Science and Technology. Lately, there have been several innovations of AI in the
Health sector. For instance, Amason Web Service (AWS) has introduced HealthScribe which lets Health
Care Software Vendors develop applications that automatically generate clinical notes by analyzing Patient
–Clinician conversations. HealthScribe uses Speech Recognition and Generative AI to achieve this. There
have also been some research into using Artificial Neural Network in Medical Diagnosis. Also, ANN has
been used in diagnosis of colorectal cancer, multiple sclerosis lesion, colon cancer, pancreatic disease,
gynecological disease and early diabetes [2].
According to an article about AI in Medical Diagnostics, the global AI in medical diagnostic market
in terms of revenue was estimated to be $ 1.3 billion in 2023 and is expected to reach $ 3.7 billion by 2028
growing at a compound annual growth rate (CAGR) of 23.2% [3]. The article also explains that companies
hoping to use AI to develop medical software need a workforce with a certain skill set for developing,
managing and implementing AI systems [3]. For instance, cognitive computing, machine learning, deep
learning and image recognition [3]. Also integrating AI solutions into existing system needs extensive data
processing for replicating human brain behaviour [3].
This paper is a research paper that seeks to investigate artificial neural network based medical
diagnosis. The focus of this paper is to explore the diagnosis of mental health disease using artificial neural
2. Nathanael Asaam
Founder and CEO @ Equicksales Consulting Ltd | Application Support Officer @ Ashesi University
nataoasaam@gmail.com
2
network. The motivation behind this research paper is to streamline the diagnosis process of mental health
diseases and avoid misdiagnosis. Additionally, Artificial Neural Network can handle diverse kinds of
medical data.
The scope of the paper is two main mental health diseases namely, Bipolar Disorder and
Schizophrenia. Also, with regards to medical data that will be used we will stick to symptoms captured in
patient-doctor conversations. As such, this paper does not discuss anything related to speech recognition.
The aim is to build a neural network that takes a number of symptoms associated with mental health
disease and then uses it to predict the diagnosis for a mental health disease.
Background
In this section we give a concise background about Artificial Neural Network (ANN).
Artificial Neural Network
An ANN is a mathematical representation of the human neural architecture, reflecting its learning and
generalization abilities [2]. ANN is widely used in research because it can model highly non-linear systems
in which the relation among the variables is unknow or very complex [2]. The basic elements of an ANN
are Artificial Neurons, Weight and Biases, activation Functions and Layers of Neurons [1]. There are three
layers of neurons, namely, Input Layer, Hidden Layer and Output Layer [1]. Also, there are two modalities
of ANN. These are Neuron connections, Signal flow. The two categories of neural connection architectures
are monolayer network and multilayer network [1]. The Signal flow categories are feedforward networks
and feedback networks [1]. The types of learning in ANN are Supervised learning and Unsupervised
learning [1]. There are also two stages of learning which are training and testing [1].
Learning Parameters
One important learning parameter is the learning rate. It dictates how strongly the neural weights would
vary in the weights hyperspace. It is denoted by the Greek letter η. The learning process may be and is
expected to be controlled [2].
Another important parameter is the condition for stopping. Usually, the training stops when the
general mean error is reached. However, there are cases where maximum number of iterations or epochs
is the condition for stopping. This is particularly used when the network fails to learn and there is little or
no change in the weights’ values [2].
Activation Function
Let us now look at the activation function. There are four types of activation functions [1]. These are:
• Sigmoid Logistic – Given by the equation: 𝑓(𝑥) =
1
1+𝑒−𝑥
• Hyperbolic Tangent – Given by the equation: 𝑓(𝑥) =
1−𝑒−𝑥
1+𝑒−𝑥
3. Nathanael Asaam
Founder and CEO @ Equicksales Consulting Ltd | Application Support Officer @ Ashesi University
nataoasaam@gmail.com
3
• Hard Limiting Threshold – Given by the equation: 𝑓(𝑥) = {0 𝑖𝑓 𝑥 < 0, 1 𝑖𝑓 𝑥 ≥ 1} Also known as
Binary Step
• Purely Linear – Given by the equation: 𝑓(𝑥) = 𝑥
It must be emphasized that for binary classification problems, a sigmoid logistic activation function can be
used [6]. Also, to predict values that are larger than 1 Sigmoid Logistic and Hyperbolic Tangent are not
suitable as the activation function.
Below is a comparison of various activation functions and their derivatives [6].
Learning Algorithms
Examples of learning algorithms in ANN are Perceptron and Adaline (Adaptive Linear Neuron). Below is a
diagram that compares Perceptron and Adaline.
4. Nathanael Asaam
Founder and CEO @ Equicksales Consulting Ltd | Application Support Officer @ Ashesi University
nataoasaam@gmail.com
4
Error Measurement & Cost Function
Supposed we have a set of records containing a pair of X and T variables.
Let consider developing a ANN as a mathematical function, ANN() that produces Y when feed with X.
For each x value given to the ANN it will produce a y value that when compared to the t value gives an
error e. e=y-t [1]. Note that this is a mere individual error measurement per data point [1].
We should take into account a general error measurement covering all N data pairs because we want the
network to learn all data points and the same weights must produce the data covering the entire data set.
That is the role of a cost function.
C(X,T,W)==
𝟏
𝑵
∑ [𝑨𝑵𝑵(𝒙(𝒊)) − 𝒕(𝒊)]²
𝒏=𝑵
𝒊=𝟎 [1]
The function above is the overall measurement of error between the target output and the neural output
where X are the inputs, T are the target outputs and W the weights, x(i) is the input at point i and t(i) is
the target output at point i. Th cost function should be minimized.
Previous Work
This section will discuss previous work in medical diagnosis using artificial neural network.
Diagnosing Metastatic Carcinoma Using ANN
The first research work that we want to review is about using artificial neural network in diagnosing
metastatic carcinoma in effusion cytology. The data preprocessing stage of building the ANN for this work
was categorized by first saving the training data in a CSV file using Microsoft Excel [10]. According to this
research paper there were 22 variables with 8 being categorical variables and the rest being numerical
variable [10]. With regards to the network design, this research performed heuristic search with hidden
unit range from a minimum of 2 and a maximum of 50 [10]. The number of iterations employed in this
research was at least 500 [10]. Also, the paper applied inverse test error calculations [10].
5. Nathanael Asaam
Founder and CEO @ Equicksales Consulting Ltd | Application Support Officer @ Ashesi University
nataoasaam@gmail.com
5
With regard to the method employed in this work, 114 cases of effusion fluid samples consisting
of 57 benign and metastatic carcinoma diagnosis in a 2-year period were used [10]. The diagnosis of
malignant effusion were as follows: metastatic adenocarcinoma (54), squamous cell carcinoma (1), and
signet ring carcinoma (1) [10]. It must the stated that in all 144 cases, detailed cytological features, image
morphometric data, densitometric data, and chromatin textural data were collected [10].
Results show that, Artificial Neural Network work excellently after adequate training [10]. With
the help of the model developed, it was possible to correctly identify all malignant cases in validation and
test samples [10]. The result for the multivariate Logistic regression (LR) was similar to the ANN model
and all cases were correctly classified [10].
ANN in Pancreatic Disease Diagnosis
The second work to be reviewed is about pancreatic disease diagnosis using artificial neural network. The
method employed in this work is conducting electronic searches reports of published cases of using ANN
for pancreatic disease diagnosis and prognosis [9]. With regards to results of this work, abstracts of 183651
citations were retrieved [9]. 11 articles were systematically reviewed, six examining pancreatitis, and 5
examining pancreatic cancer [9].
According to the research paper, the potential grade of severity of pancreatitis is difficult to
determine using clinical examination alone [9]. However, several predictive scoring scales have been
developed specifically to classify acute pancreatitis [9]. Examples of these scoring scales are Ranson Score,
Glasgow Severity Score and Balthazar Score [9].
Coronary Heart Disease (CHD) Diagnosis Using ANN
The third research paper to be reviewed is about coronary heart disease (CHD) diagnosis using ANN. This
study included 487 patients (425 males and 62 females) [8]. CHD risk factors that were analyzed include
age, gender, total cholesterol, high-density lipoprotein cholesterol, low-density lipoprotein cholesterol,
very-low-density lipoprotein cholesterol, triglycerides, cholesterol ratio, fasting plasma glucose, arterial
hypertension, diabetes mellitus, current tobacco smoking status, obesity, and a family history of CHD [8].
The results of this work show that coronary atherosclerosis was diagnosed in 327 patients (62.7%)
[8]. Also, a total of 160 (32.8%) patients had an intact coronary artery wall and no evidence of CHD [8].
Using different ANN types and a variable of input variables ( 5 to 10) lead to models with 64-94% accuracy
rate [8]. The best result (94%) was in Multilayer Perceptron (MLP) models with 2 buried layers [8].
Methodology
In this research, we develop a neural network using symptoms as inputs and disease as output. We also
train the ANN using Perceptron and Adaline Learning Algorithms. Take note that, for the Perceptron ANN
if any or some, or all of the symptoms are observed, then the diagnosis is the disease for that group of
symptoms. However, if none of the symptoms is observed then, the diagnosis is the patient does not have
the disease. Also, for the Adaline algorithms we assign the value of the output the chance of the patient
having the disease. The chance is a value between 0 and 1 with 1 being the data point when patient is
6. Nathanael Asaam
Founder and CEO @ Equicksales Consulting Ltd | Application Support Officer @ Ashesi University
nataoasaam@gmail.com
6
exhibiting all symptoms and 0 being a data point when patient is not exhibiting any of the symptoms.
Finally, its important to note that during training we varied the values of various learning parameters such
as the learning rate, the number of iterations or epochs and the target error in order to get a neural
network that gives the desired output and also to enable the various weights to vary or change as learning
goes on. Below are tables for the training data set for both Bipolar Disorder and Schizophrenia using the
Perceptron and Adaline learning algorithms.
Bipolar Disorder - Perceptron
Sample Symptom
1
Symptom
2
Symptom
3
Symptom
4
Symptom
5
Symptom
6
Symptom
7
Bipolar
1 0 0 0 0 0 0 0 0
2 1 0 0 0 0 0 0 1
3 0 1 0 0 0 0 0 1
4 0 0 1 0 0 0 0 1
5 0 0 0 1 0 0 0 1
6 0 0 0 0 1 0 0 1
7 0 0 0 0 0 1 0 1
8 1 1 0 0 0 0 1 1
9 1 1 1 0 0 0 0 1
10 1 1 1 1 0 0 0 1
11 1 1 1 1 1 0 0 1
12 1 1 1 1 1 1 0 1
13 1 1 1 1 1 1 1 1
Bipolar Disorder - Adaline
Sample Symptom
1
Symptom
2
Symptom
3
Symptom
4
Symptom
5
Symptom
6
Symptom
7
Bipolar
1 0 0 0 0 0 0 0 0.000
2 1 0 0 0 0 0 0 0.143
3 0 1 0 0 0 0 0 0.143
4 0 0 1 0 0 0 0 0.143
5 0 0 0 1 0 0 0 0.143
6 0 0 0 0 1 0 0 0.143
7 0 0 0 0 0 1 0 0.143
8 1 1 0 0 0 0 1 0.286
9 1 1 1 0 0 0 0 0.429
10 1 1 1 1 0 0 0 0.571
11 1 1 1 1 1 0 0 0.714
12 1 1 1 1 1 1 0 0.857
13 1 1 1 1 1 1 1 1.000
7. Nathanael Asaam
Founder and CEO @ Equicksales Consulting Ltd | Application Support Officer @ Ashesi University
nataoasaam@gmail.com
7
Bipolar Disorder Symptoms Description
Symptom 1 Feeling overly happy or high
Symptom 2 Having a decreased need for sleep
Symptom 3 Talking fast
Symptom 4 Feeling extremely restless or impulsive
Symptom 5 Being easily distracted
Symptom 6 Having over confidence in your abilities
Symptom 7 Engaging in risky activities
Schizophrenia - Perceptron
Sam
ple
Sympt
om 1
Sympt
om 2
Sympt
om 3
Sympt
om 4
Sympt
om 5
Sympt
om 6
Sympt
om 7
Sympt
om 8
Sympt
om 9
Schizophr
enia
1 0 0 0 0 0 0 0 0 0 0.
2 1 0 0 0 0 0 0 0 0 1
3 0 1 0 0 0 0 0 0 0 1
4 0 0 1 0 0 0 0 0 0 1
5 0 0 0 1 0 0 0 0 0 1
6 0 0 0 0 1 0 0 0 0 1
7 0 0 0 0 0 1 0 0 0 1
8 0 0 0 0 0 0 1 0 0 1
9 0 0 0 0 0 0 0 1 0 1
10 0 0 0 0 0 0 0 0 1 1
11 1 1 0 0 0 0 0 0 0 1
12 1 1 1 0 0 0 0 0 0 1
13 1 1 1 1 0 0 0 0 0 1
14 1 1 1 1 1 0 0 0 0 1
15 1 1 1 1 1 1 0 0 0 1
16 1 1 1 1 1 1 1 0 0 1
17 1 1 1 1 1 1 1 1 0 1
18 1 1 1 1 1 1 1 1 1 1
Schizophrenia – Adaline
Sam
ple
Sympt
om 1
Sympt
om 2
Sympt
om 3
Sympt
om 4
Sympt
om 5
Sympt
om 6
Sympt
om 7
Sympt
om 8
Sympt
om 9
Schizophr
enia
1 0 0 0 0 0 0 0 0 0 0.000
2 1 0 0 0 0 0 0 0 0 0.111
8. Nathanael Asaam
Founder and CEO @ Equicksales Consulting Ltd | Application Support Officer @ Ashesi University
nataoasaam@gmail.com
8
3 0 1 0 0 0 0 0 0 0 0.111
4 0 0 1 0 0 0 0 0 0 0.111
5 0 0 0 1 0 0 0 0 0 0.111
6 0 0 0 0 1 0 0 0 0 0.111
7 0 0 0 0 0 1 0 0 0 0.111
8 0 0 0 0 0 0 1 0 0 0.111
9 0 0 0 0 0 0 0 1 0 0.111
10 0 0 0 0 0 0 0 0 1 0.111
11 1 1 0 0 0 0 0 0 0 0.222
12 1 1 1 0 0 0 0 0 0 0.333
13 1 1 1 1 0 0 0 0 0 0.444
14 1 1 1 1 1 0 0 0 0 0.556
15 1 1 1 1 1 1 0 0 0 0.667
16 1 1 1 1 1 1 1 0 0 0.778
17 1 1 1 1 1 1 1 1 0 0.889
18 1 1 1 1 1 1 1 1 1 1.000
Schizophrenia Symptoms Description
Symptom 1 Delusions
Symptom 2 Hallucinations
Symptom 3 Disorganized thinking or speech
Symptom 4 Extremely disorganized or abnormal motor
behaviour
Symptom 5 Withdrawal from friends and family
Symptom 6 Trouble sleeping
Symptom 7 Lack of motivation
Symptom 8 Irritability or depressed mood
Symptom 9 A drop in performance in school
Results
In this project we were able to implement the Perceptron and Adaline learning algorithms. We also
implemented four activation function. These are the binary step, the linear, the sigmoid and the hyperbolic
tangent activation functions. We also trained the Perceptron algorithm for both mental health diseases
using three activation functions and their derivative functions. The three activation functions for the
Perceptron are binary step, sigmoid, and hyperbolic tangent. For the Adaline algorithm, we trained the
ANN using three activation functions and their derivative functions. These activation functions are linear,
sigmoid, and hyperbolic tangent activation functions.
9. Nathanael Asaam
Founder and CEO @ Equicksales Consulting Ltd | Application Support Officer @ Ashesi University
nataoasaam@gmail.com
9
From the training, we realized that high maximum iteration or epochs seems to improve the
performance of both learning algorithms. Also, low target error also helps the ANNs implemented to
predict the desired output using the ANN. Additionally a high learning rate also improves the ability of the
ANN to predict the desired output. For the Perceptron algorithm, a learning rate of 1 often leads to a
hundred percent ability to predict the desired output and a learning rate of 0.6 makes the ANN often
predicts the desired output recording a total of 9 correct prediction out of the data records of about 13
data points.
Conclusion
It is imperative to state that ANNs are effective in medical diagnosis. The results from this work show this
fact, especially for mental health disease diagnosis using symptoms. The techniques described in this
paper are one of the simplest ways of using ANN in medical diagnosis. This work can be improved by using
Multi – Layer Perceptrons (MLP) and Recurrent MLP. Other approaches such as the Backpropagation and
Levenberg Marquardt algorithms may also improve the effectiveness of this work. However, it must be
stated that these algorithms and approaches to ANN are more complex to implement and manage.
Nonetheless this research work shows some of the simplest ways of implementing ANN for
medical diagnosis, which is using a Perceptron or Adaline algorithms with an architecture that is not a
multi-layer architecture. Other data sources such as ECG, CT scans, X-rays, and speech recognition may be
employed in diagnosis using ANN.
References
1. F. M. Soares, A. M. F. Souza Neural Network Programming with Java
https://img1.wsimg.com/blobby/go/389886fb-5e50-4fa8-b2d8-
5849bb0f2b64/downloads/1ca32jha0_704519.pdf
2. F. Amato, A. Lopez, E. M. Pena-Mendez, P. Vanhara, A. Hampl, J Havel Artificial neural networks in
medical diagnosis
https://www.researchgate.net/publication/250310836_Artificial_neural_networks_in_medical_
diagnosis
3. Artificial Intelligence (AI) in Medical Diagnostics Market by Modality(CT, X-RAY, MRI, Ultrasound),
Application (IVD, Radiology, CNS, CVS, Ob/Gyn), User (Hospital, Lab), Unmet Need, Key
Stakeholders, Buying Criteria – Global Forecast https://www.marketsandmarkets.com/Market-
Reports/artificial-intelligence-medical-diagnostics-market-
22519734.html?gad_source=1&gclid=Cj0KCQiAwvKtBhDrARIsAJj-kTgP5p6mDNGEPgB-
rwe9NDVTVZzpFglIk9WqNLS40-RSp0iFYMH_0pMaAorAEALw_wcB
4. M. Banoula What is Perceptron: A Beginner Guide for Perceptron
https://www.simplilearn.com/tutorials/deep-learning-tutorial/perceptron
5. Adaline Concepts and definitions
https://gamco.es/en/glossary/adaline/#:~:text=ADALINE%20(Adaptive%20Linear%20Neuron)%2
0is,uses%20a%20linear%20activation%20function.
10. Nathanael Asaam
Founder and CEO @ Equicksales Consulting Ltd | Application Support Officer @ Ashesi University
nataoasaam@gmail.com
10
6. L. Panneerselvam Activation Functions and their Derivatives – A Quick and Complete Guide
https://www.analyticsvidhya.com/blog/2021/04/activation-functions-and-their-derivatives-a-
quick-complete-guide/
7. E. Alkim, E Gurbuz, E Killic A fast and adaptive automated disease diagnosis method with an
innovative neural network model
https://www.researchgate.net/publication/225048972_A_fast_and_adaptive_automated_diseas
e_diagnosis_method_with_an_innovative_neural_network_model
8. O. Y. Atkov, S. G. Gorokhova, A. G. Sboev, E. V. Generozov, E. V. Muraseyeva, S. Y. Moroshkina, N.
N. Cherniy Coronary heart disease diagnosis by artificial neural networks including genetic
polymorphisms and clinical parameters https://core.ac.uk/download/pdf/82255218.pdf
9. A Bartosch-Harlid, B Andersson, U Aho, J Nilsson, R Andersson Artificial neural network in
pancreatic disease https://academic.oup.com/bjs/article/95/7/817/6142865
10. A Barwad, P Dey, S Susheilia Artificial Neural Network in the Diagnosis of Metastatic Carcinoma in
Effusion Cytology https://onlinelibrary.wiley.com/doi/pdf/10.1002/cyto.b.20632
Appendix 1
The results below show the ability of the Perceptron Algorithm to predict the desired output with
recorded error of only 4 out of 13 data points for a learning rate of 0.6
----------PERCEPTRON PRINT RESULT----------
1.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 Net Output:0.0 Real Output:0.0 Error:0.0
1.0 1.0 0.0 0.0 0.0 0.0 0.0 0.0 Net Output:0.0 Real Output:1.0 Error:1.0
1.0 0.0 1.0 0.0 0.0 0.0 0.0 0.0 Net Output:1.0 Real Output:1.0 Error:0.0
1.0 0.0 0.0 1.0 0.0 0.0 0.0 0.0 Net Output:0.0 Real Output:1.0 Error:1.0
1.0 0.0 0.0 0.0 1.0 0.0 0.0 0.0 Net Output:1.0 Real Output:1.0 Error:0.0
1.0 0.0 0.0 0.0 0.0 1.0 0.0 0.0 Net Output:0.0 Real Output:1.0 Error:1.0
1.0 0.0 0.0 0.0 0.0 0.0 1.0 0.0 Net Output:0.0 Real Output:1.0 Error:1.0
1.0 1.0 1.0 0.0 0.0 0.0 0.0 1.0 Net Output:1.0 Real Output:1.0 Error:0.0
1.0 1.0 1.0 1.0 0.0 0.0 0.0 0.0 Net Output:1.0 Real Output:1.0 Error:0.0
1.0 1.0 1.0 1.0 1.0 0.0 0.0 0.0 Net Output:1.0 Real Output:1.0 Error:0.0
1.0 1.0 1.0 1.0 1.0 1.0 0.0 0.0 Net Output:1.0 Real Output:1.0 Error:0.0
1.0 1.0 1.0 1.0 1.0 1.0 1.0 0.0 Net Output:1.0 Real Output:1.0 Error:0.0
1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0 Net Output:1.0 Real Output:1.0 Error:0.0
11. Nathanael Asaam
Founder and CEO @ Equicksales Consulting Ltd | Application Support Officer @ Ashesi University
nataoasaam@gmail.com
11
The Perceptron algorithms was also able to predict the desired output for all data points when the
learning rate is set to 1.0 with no recorded error for all data points. See data below.
----------PERCEPTRON PRINT RESULT----------
1.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 Net Output:0.0 Real Output:0.0 Error:0.0
1.0 1.0 0.0 0.0 0.0 0.0 0.0 0.0 Net Output:1.0 Real Output:1.0 Error:0.0
1.0 0.0 1.0 0.0 0.0 0.0 0.0 0.0 Net Output:1.0 Real Output:1.0 Error:0.0
1.0 0.0 0.0 1.0 0.0 0.0 0.0 0.0 Net Output:1.0 Real Output:1.0 Error:0.0
1.0 0.0 0.0 0.0 1.0 0.0 0.0 0.0 Net Output:1.0 Real Output:1.0 Error:0.0
1.0 0.0 0.0 0.0 0.0 1.0 0.0 0.0 Net Output:1.0 Real Output:1.0 Error:0.0
1.0 0.0 0.0 0.0 0.0 0.0 1.0 0.0 Net Output:1.0 Real Output:1.0 Error:0.0
1.0 1.0 1.0 0.0 0.0 0.0 0.0 1.0 Net Output:1.0 Real Output:1.0 Error:0.0
1.0 1.0 1.0 1.0 0.0 0.0 0.0 0.0 Net Output:1.0 Real Output:1.0 Error:0.0
1.0 1.0 1.0 1.0 1.0 0.0 0.0 0.0 Net Output:1.0 Real Output:1.0 Error:0.0
1.0 1.0 1.0 1.0 1.0 1.0 0.0 0.0 Net Output:1.0 Real Output:1.0 Error:0.0
1.0 1.0 1.0 1.0 1.0 1.0 1.0 0.0 Net Output:1.0 Real Output:1.0 Error:0.0
1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0 Net Output:1.0 Real Output:1.0 Error:0.0
Appendix 2
The ability of the ANN to change or vary the weights during the learning process is also affected by
the learning rate. With a learning rate of 1.0 the weights initialized seldom change but with a learning
rate of 0.6 the weights are adjusted. See results below for learning rate of 0.6.
----------PERCEPTRON INIT NET----------
## Input Layer ##
Neuron 1
Input Weights
[0.42803140701258136]
Neuron 2
Input Weights
[0.14526815544119032]
Neuron 3
Input Weights
[0.29191402444936543]
Neuron 4