C++ Neural Networks and Fuzzy Logic
by Valluru B. Rao
MTBooks, IDG Books Worldwide, Inc.
ISBN: 1558515526 Pub Date: 06/01/95
Previous Table of Contents Next
Comments on Your C++ Program
Notice the use of input stream operator cin>> in the C++ program, instead of the C function scanf in several
places. The iostream class in C++ was discussed earlier in this chapter. The program works like this:
First, the network input neurons are given their connection weights, and then an input vector is presented to
the input layer. A threshold value is specified, and the output neuron does the weighted sum of its inputs,
which are the outputs of the input layer neurons. This weighted sum is the activation of the output neuron, and
it is compared with the threshold value, and the output neuron fires (output is 1) if the threshold value is not
greater than its activation. It does not fire (output is 0) if its activation is smaller than the threshold value. In
this implementation, neither supervised nor unsupervised training is incorporated.
Do'stlaringiz bilan baham: |