%
% evaluation of simple SISO ANN network
%
% bob newell, sept 1997
%
function y = annnet( u, wij, wjk )
%
n = length(u);
[ i, nnode ] = size( wij );
%
% for each data point
%
  for i = 1:n,
%
% output bias
    y(i) = wjk(nnode+1,1);
%
    for j = 1:nnode,
%     hidden layer
      yj(j) = 1 / ( 1 + exp( - wij(1,j) * u(i) - wij(2,j) ) );
%     output layer
      y(i) = y(i) + wjk(j,1) * yj(j);
    end;
  end;
%
