closeall;
clearall;
i4=imread('1.jpg');
i5=imread('2.jpg');
i6=imread('2.png');
i1=rgb2gray(i4);
i2=rgb2gray(i5);
i3=rgb2gray(i6);
s1=reshape(i1,[1,256*256]);
s2=reshape(i2,[1,256*256]);
s3=reshape(i3,[1,256*256]);
s=[s1;s2;s3];sig=double(s);
aorig=rand(size(sig,1));
mixedsig=aorig*sig;
ms1=reshape(mixedsig(1,:),[256,256]);
ms2=reshape(mixedsig(2,:),[256,256]);
ms3=reshape(mixedsig(3,:),[256,256]);
figure;
subplot(331),imshow(i1),subplot(332),imshow(i2),subplot(333),imshow(i3);
subplot(334),imshow(uint8(ms1)),subplot(335),imshow(uint8(ms2)),subplot(336),imshow(uint8(ms3));
%mixedsig=zeros(size(mixedsig));
%%%中心化(去均值)
meanValue=mean(mixedsig')';
mixedsig=mixedsig-meanValue*ones(1,size(mixedsig,2));
%%%白化PCA白化
covarianceMatrix=cov(mixedsig',1); %cov()求协方差
[E,D]=eig(covarianceMatrix);&n