com.aliasi.matrix

• All Implemented Interfaces:
KernelFunction, Proximity<Vector>, Serializable

```public class GaussianRadialBasisKernel
extends Object
implements KernelFunction, Serializable```
A `GaussianRadialBasisKernel` provides a kernel based on a Gaussian radial basis function with a fixed variance parameter. As a kernel function, it unfolds into an infinite-dimension Hilbert space.

The radial basis kernel function of radius `r` is defined between vectors `v1` and `v2` as follows:

``` rbf(v1,v2) = exp(- r * distance(v1,v2)2)
```
where `distance(v1,v2)` is the Euclidean distance, as defined in the class documentation for `EuclideanDistance`. In this formulation, the radius `r` is related to the variance `σ2` by:
` r = 1/(2 * σ2)`

Since:
LingPipe3.1
Version:
3.8
Author:
Bob Carpenter
Serialized Form
• ### Constructor Summary

Constructors
Constructor and Description
`GaussianRadialBasisKernel(double radius)`
Construct a Gaussian radial basis kernel with the specified radius of influence.
• ### Method Summary

All Methods
Modifier and Type Method and Description
`double` ```proximity(Vector v1, Vector v2)```
Returns the result of applying this Guassian radial basis kernel to the specified vectors.
`String` `toString()`
Returns a string-based representation of this kernel function, including the kernel type and radius.
• ### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`
• ### Constructor Detail

`public GaussianRadialBasisKernel(double radius)`
Construct a Gaussian radial basis kernel with the specified radius of influence.
Parameters:
`radius` - The radius of influence for the kernel.
• ### Method Detail

• #### proximity

```public double proximity(Vector v1,
Vector v2)```
Returns the result of applying this Guassian radial basis kernel to the specified vectors. See the class documentation above for a full definition.
Specified by:
`proximity` in interface `KernelFunction`
Specified by:
`proximity` in interface `Proximity<Vector>`
Parameters:
`v1` - First vector.
`v2` - Second vector.
Returns:
Kernel function applied to the two vectors.
Throws:
`IllegalArgumentException` - If the vectors are not of the same dimensionality.
• #### toString

`public String toString()`
Returns a string-based representation of this kernel function, including the kernel type and radius.
Overrides:
`toString` in class `Object`
Returns:
A string representing this kernel.