Hello everyone!) Guys, help with advice and example please =))
I understand with neural networks in matlab. "Designing" manually, here's the code:
function net = myNET() INP =[]; %входной вектор OUTP = []; %выходной вектор k=1; for i=-1.5:0.1:1.5 INP(k)= i; OUTP(k)=sin(i); %хочу обучить сеть для вычисления синуса.. просто для понятия того, как это вообще делается =) k=k+1; end net= newff(INP,OUTP,10); net= train(net,INP,OUTP); net.trainParam.epochs = 1200; net.trainParam.show = 25; After that in the Command Window I do the following:
a= myNET Here the parameters of the NA were highlighted. Next, I enter:
>> b= sim(myNET,1) % т.е вычисление значения в точке "1", я правильно понял!?) Result:
b = 0.8117
It turns out quite wrong ((
Please tell me where I am wrong and how can I fix it? =) Thank you very much in advance!
ps As an example yuzal: http://freestee.ru/index.php/programming/neuralnetworks/10-matlabgreenwave?format=pdf