Clear Filters
Clear Filters

Info

This question is closed. Reopen it to edit or answer.

Hi , how can explain this code?

2 views (last 30 days)
fehmi zarzoum
fehmi zarzoum on 19 Sep 2017
Closed: John D'Errico on 19 Sep 2017
Hi ,
how can explain this code?
function [wreduit]=acp1(W)
W1=W'; mx=mean(W1);
stdx=std(W1);ax=zeros(size(W1));
[r1,c1]=size(W1);
for i=1:r1
ax(i,:)=(W1(i,:)-mx)./stdx;
end
cov=ax'*ax/(r1-1);
[v,d]=eig(cov); d=diag(d);
[a,t1]=sort(d);
t1=t1(c1:-1:1);
d=d(t1); v=v(:,t1); t2=ax*v;
xe=ax*v(:,1:4)*v(:,1:4)';
s=t1(1:4,:);
wreduit=W1(:,t1(1:4,:))
end
[S] = acp1(Ws); { for healthy motor}
[BX] = acp1(Wbx); { fault in outer race bearing}
[BI] = acp1(Wbi); { fault in inner race bearing}
[B] = acp1(Wb); { fault in baal bearing}
thanks a lot .

Answers (0)

This question is closed.

Community Treasure Hunt

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

Start Hunting!