Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I need a simple explanation about what is the radial basis function? And what is the relationship between the radial basis function and neural networks?

And are there any simple examples to explain radial basis function on Matlab?

Tracking too many sites for a week, I didn't find a single simple explanation for a beginner, since all of the answers expected that you have previous knowledge about neural networks and radial basis functions.

share|cite|improve this question
What makes you think these two are related? – Hui Yu Oct 20 '12 at 13:42
So why don't you ask the someone? – Hui Yu Oct 20 '12 at 13:52
@HuiYu RBFs and neural networks are intricately related. This is a fair question. – Emily Oct 20 '12 at 14:23
The net is literally swarming with the answers, but LMGTFY. Be sure to check the Wikipedia. – dtldarek Oct 20 '12 at 17:19
up vote 4 down vote accepted

I'll give a very high-level overview of both RBFs and artificial neural networks, so maybe this will help you find what you're looking for.

At its simplest form, an artificial neural network is just a complicated function mapping some input variables to some output variables. These input/output variables can belong to any space, but for simplicity, let's assume we're mapping from $\Bbb R^n$ to $\Bbb R^m$. This means that $f: \Bbb R^n \to \Bbb R^m$ is an artificial neural network taking $n$ inputs and giving $m$ outputs. That is, $\bf f(x) = y$.

However, the key to neural nets is that somewhere between the input layer $\bf x$ and the output layer $\bf y$ is one or more hidden layers. In the simplest ANN, the feedforward ANN, Each node in each hidden layer takes some number of inputs from the layer before -- each input in the hidden layer is the output of a previous layer. Each node in the hidden layer is basically just another function, $\bf f_{ij}(x_k)$, where $\bf x_k$. Any given node in a hidden layer may use a previous node's output as an input in $\bf x_k$, or not -- there is no requirement that every output be used as an input.

The type of ANN depends on the class of function used in the hidden layer. One simple method is to use a multivariate polynomial. This is called a Polynomial Neural Network (PNN). In a PNN, your output is just a very complicated polynomial of your inputs.

For example, consider the PNN with 1 input layer, 2 hidden layers, with the following structure:

  • Input: $x$
  • Hidden Layer 1:
    • Node 1: $x_1 = 2x$
    • Node 2: $x_2 = x^2$
  • Hidden Layer 2:
    • Node 1: $x_3 = 3x_1-4x_2$
  • Output Layer: $y = x_3$

Final function: $y = 3x_1-4x_2 = 6x-4x^2$.

This is all very basic, simple stuff. The interesting thing about ANNs is that we don't specify the weights of the hidden layers (in the above example, the weights in the first hidden layer are 3 and 1, respectively). And sometimes, we don't even specify how the hidden layers connect (if layers don't connect, we can consider the weight to be 0). This is where machine learning comes into play -- training an ANN involves computing the weights of the network.

A Radial Basis Function is a nice way of approximating some other function. Consider a Gaussian function $\phi(x) = \exp \left(-(x-\mu)^2/(2\sigma^2)\right)$. This has nice properties: a center $\mu$ at which the value is a maximum; a measure of width, $\sigma$, and the property that $\phi(x) \to 0$ as $x \to -\infty, \infty$. In other words, $\phi$ vanishes sufficiently far away from $x = \mu$.

If you take a sum of these over different values of $\mu$ and $\sigma$, say $\sum_n \exp \left( -(x-\mu_n)^2/(2\sigma_n^2)\right)$, then you might be able to approximate some other function.

This is very similar to, say, a Taylor series, where we approximate functions by polynomials. However, polynomials are inconvenient. As $x \to \infty$, $P(x) \to -\infty$ or $\infty$ for every polynomial you can imagine. This means the domain for which a polynomial can approximate a function is always bounded.

Radial basis functions use Gaussians to avoid this complication.

An ANN that uses Radial Basis Functions is sometimes called a Radial Basis Function (Neural) Network, or RBFN/RBFNN.

As with the PNN described above, the function at every node is just an RBF -- its output is the output of some RBF where $\mu$ and $\sigma$ are computed according to some training algorithm. The composition of many of these allows you to approximate your data.

At its core, developing ANNs usually involves taking a set of data with known inputs $\bf \hat{x} \to \hat{y}$. The general process is you find some initial ANN structure, feed in $\bf \hat{x}$, find the output $\bf y$, and compute the error $\bf e = |\hat{y}-y|$. Then, you update your network weights according to some algorithm. These algorithms are quite complex, generally, and present the biggest learning curve in understanding ANNs. If you can understand the Levenberg-Marquardt algorithm, however, that's a good start.

Also, you might search for "RBFN MATLAB" to find some pre-packaged code on File Exchange.

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.