Products & Services Solutions Academia Support User Community Company

Network Architecture

The linear network shown below has one layer of S neurons connected to R inputs through a matrix of weights W.

Note that the figure on the right defines an S-length output vector a.

A single-layer linear network is shown. However, this network is just as capable as multilayer linear networks. For every multilayer linear network, there is an equivalent single-layer linear network.

Creating a Linear Neuron (newlin)

Consider a single linear neuron with two inputs. The following figure shows the diagram for this network.

The weight matrix W in this case has only one row. The network output is

or

Like the perceptron, the linear network has a decision boundary that is determined by the input vectors for which the net input n is zero. For n = 0 the equation Wp + b = 0 specifies such a decision boundary, as shown below (adapted with thanks from [HDB96]).

Input vectors in the upper right gray area lead to an output greater than 0. Input vectors in the lower left white area lead to an output less than 0. Thus, the linear network can be used to classify objects into two categories. However, it can classify in this way only if the objects are linearly separable. Thus, the linear network has the same limitation as the perceptron.

You can create this network using the following command, which specifies typical input vectors of [-1; -1] and [1; 1] and typical outputs of [-1 1]. (These values are arbitrary. For a real problem, use real values.)

The network weights and biases are set to zero by default. You can see the current values with the commands

and

However, you can give the weights any values that you want, such as 2 and 3, respectively, with

You can set and check the bias in the same way.

You can simulate the linear network for a particular input vector. Try

You can find the network output with the function sim.

To summarize, you can create a linear network with newlin, adjust its elements as you want, and simulate it with sim. You can find more about newlin by typing help newlin.


 Provide feedback about this page 

Previous page Neuron Model Least Mean Square Error Next page

Recommended Products

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.

 © 1984-2009- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS