Adytzu04

rnlf l5 p4

Mar 23rd, 2015
322
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.55 KB | None | 0 0
  1. clear all
  2. close all
  3. clc
  4.  
  5. load opamp_wh.mat
  6. uuu1 = 2 * ones(size(uuu2));
  7. t = 0:0.01:5;
  8. R = 100;
  9. P=[uuu1 ;uuu2 ;uuu3];
  10. T=yyy;
  11.  
  12. net=newlind(P,T);
  13. w = net.IW{1,1};
  14.  
  15. R1d = -R/w(1)
  16. R2d = -R/w(2)
  17. R3d = -R/w(3)
  18.  
  19. lr = maxlinlr(P);
  20. lin=newlin(minmax(P),1,[0],lr); % neuronul liniar creat este pregatit pt a fiantrenat cu subrutina "learnwh"
  21.  
  22. lin.trainParam.epochs=1000;
  23. lin.trainParam.goal=0.0005;
  24. lin.trainParam.show=inf;
  25.  
  26. [lin,tr] = train(lin,P,T);
  27. w = lin.IW{1,1};
  28.  
  29. R1t = -R/w(1)
  30. R2t = -R/w(2)
  31. R3t = -R/w(3)
  32.  
  33. figure (1)
  34. plot(t,P,t,T);grid;
Advertisement
Add Comment
Please, Sign In to add comment