No BSD License
-
A=bpm_dec_bnds(W1, b1, W2, b2...
-
B=colmult(A, vec)
-
B=sgn(A)
function B=sgn(A)
-
C=mk_data(pats)
function C=mk_data(pats)
-
D=gha_chopstak(P,rm,cm)
function D=gha_chopstak(P,rm,cm)
-
I=gha_recompose(coeffs,W,mval)
I=recompose(coeffs,W,mval)
-
I=gha_unchopst(X,r,c,rm,cm)
function I=gha_unchopst(X,r,c,rm,cm)
-
K=gha_dispwe(W,j)
function K=gha_dispwe(W,j)
-
M=thresh(A,ll,ul)
-
W=gha(P,epochs,m,beta,W)
function W=gha(P,epochs,m,beta,W)
-
W=gha_getweights(Image,epochs...
-
W=hop_stor(P)
function W=hop_stor(P)
-
[P, flip]=hop_flip(P, prob, s...
-
[W1, b1, W2, b2, ep_err, init...
-
[W_out, p_out]=som_1d(P, nsof...
-
[W_out, p_out]=som_2d(P, nsof...
-
[cor, uncor, O, dec]=bpm_test...
-
[pesos,vect,b]=svm_rbf2(datos...
% [pesos,vect,b]=svm_rbf(datos,escala,niter,cad,restric);
-
[s, count, M]=hop_test(W,x,up...
-
b=phi(a)
-
b=phi_d(a)
-
c=bsb(x,beta,multi)
function c=bsb(x,beta)
-
coeffs=gha_getcoeffs(Orig,W,p...
function coeffs=gha_getcoeffs(Orig,W,plot_flg)
-
gha_quantcoeffs(C,W,O,n)
-
hop_plotdig(P,r,c,stri)
function hop_plotdig(P,r,c)
-
hop_plotpats(P)
function hop_plotpats(P)
-
out=pl_circ(cen, radius, res,...
function out=pl_circ(cen, radius, res, plot_flag)
-
p=rbf_correct(y,d)
p - percent correct in two class problem
-
pim(Z)
function pim(Z)
-
rbf(x, t, d, sigma, lam)
-
rbf_db(w, t, sigma, st_sz)
-
rbf_mkGF(x,t)
-
rbf_test(w, x, t, sigma)
-
shuffle(n1,n2,n3,n4,n5)
-
som_pl_map(A,p1,p2, P1, P2)
function som_pl_map(A,p1,p2)
-
svm_dec_bnd(pesos, vect, b, e...
function svm_dec_bnd(pesos, vect, b, escala)
-
svm_test(data, pesos, vect, b...
-
y=proymayor(x,threshold,relax)
-
y=proymenor(x,threshold,relax)
-
hop_demo.m
-
ica.m
-
som_2d_demo.m
-
View all files
from
Neural Networks: A Comprehensive Foundation, 2e book Companion Software
by Simon Haykin
Companion Software for Neural Networks: A Comprehensive Foundation, 2e book
|
| ica.m |
% The time period of the signal considered
Tf=0.5;
% The sampling time period
Ts=1e-5;
t=0:Ts:Tf;
Num_iter=100000;
% The source signals
u1=0.1*sin(400*t).*cos(30*t);
u2=0.01*sign(sin(500*t+9*cos(40*t)));
u3=2*rand(1,length(t))-1;
u=[u1; u2; u3];
A=[0.56 0.79 -0.37; -0.75 0.65 0.86; 0.17 0.32 -0.48];
% Mixing the sources
x=A*u;
% Runs the Algorithm for 10 different initial weights
for r=1:10,
flag=0;
% error definition for convergence
error=1e-2;
nu=0.1;
% initialising the weights
W=0.1*rand(3,3);
% storing the initial weights
W_init((r-1)*3+1:r*3,1:3)=W;
for i=1:Num_iter,
% Demixing x with W
y=W*x;
% The activation function
f=(3/4)*y.^11+(25/4)*y.^9+(-14/3)*y.^7+(-47/4)*y.^5+(29/4)*y.^3;
dW=(eye(3)-f*y')*W;
% The weight update
W=W+nu*dW
% Break if Algorithm diverges
if (sum(sum(isnan(W)))>0) flag=1; break; end
max(max(abs(dW)));
% Break if Algorithm converges-- max weight update is less than error
if (max(max(abs(dW)))<error & i>10) break; end;
end
% Number of iterations taken
if (~flag) num(r)=i; else num(r)=0; end
% store the final weights
W_end((r-1)*3+1:r*3,1:3)=W;
i
end
%save all values
save NUM8 num -ascii
save W_init8 W_init -ascii
save W_end8 W_end -ascii
|
|
Contact us at files@mathworks.com