Azzera filtri
Azzera filtri

compute weights by Generalized Hebbian Algorithm

2 visualizzazioni (ultimi 30 giorni)
I have a task to do some calculations in matlab .. I use the Generalized Hebbian Algorithm to compute some weights , here is the functions of Hebbian Algorithm , slice 15 http://www.eit.lth.se/fileadmin/eit/courses/eitn55/Downloads/ICA_Ch6.pdf
here is my code
alfa=0.5;
e=randn(3,5000);
A=[1 0 0;-0.5 0.5 0;0.3 0.1 0.1];
x=A*e;
W=rand(3);
nn=8;
for n=1:nn
y=x*W;
end
k=tril(y'*y)*W;
W(n+1,:)= alfa*(y*x'-k);
In my task I know that x=A*e; but I do not know if I am iterating in correct way or not? is my for loop doing correct? and are those equations below correct?
k=tril(y'*y)*W;
W(n+1,:)= alfa*(y*x'-k);
W(n+1,:) should print out a 3*3 matrix ... Matlab says when I run this code : Error using * Inner matrix dimensions must agree.
  1 Commento
Lisa Linárd Pedersen
Lisa Linárd Pedersen il 17 Nov 2020
I am currently having the same problem.. I am aware this is 5 years old but did you figure it out?

Accedi per commentare.

Risposte (0)

Categorie

Scopri di più su Matrices and Arrays in Help Center e File Exchange

Tag

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by