Question 1. [100 points]
Implement an RBF network for a one-dimensional input variable, one-dimensional output variable,
and Gaussian basis functions. Generate a set of 75 data points by sampling the function h(x) =
0.5 + 0.4sin(2πx) with added uniform noise in the interval [-0.1, 0.1] and with x values taken
randomly from a uniform distribution in the interval [0.0, 1.0]. Determine the Gaussian centers by
the K-means algorithm, and set the variance of each cluster accordingly. If a cluster contains only
one sample point, use as its variance the mean variance of all the other clusters. Use the LMS rule
for weight update (note a bias term is needed). Perform the following:
• Vary the number of bases in the range of 2, 4, 7, 11, and 16.
• Use two values of η: 0.01 and 0.02.
For each of the above 10 cases, stop training after 100 epochs. Plot for each case a graph that shows
the data points, the original function where the data points are sampled from, and the function
generated by the RBF network.
Comment on the dependence of the network performance on the number of bases. Also comment
on the choice of η.
In addition, repeat the above implementation but use the same variance for all clusters as described
in the lectures. Comment on the comparative advantages of the two methods of determining cluster
What you need to turn in:
1. A summary report that is at least two-pages long, which contains your test results, along
with a description and explanation of those results.
2. Your Jupyter notebook that contains your code and results.