資源簡介
彩色圖像的arnold圖像置亂和logistic混沌序列的圖像加密程序matlab源碼
代碼片段和文件信息
A=imread(‘D:\lena.BMP‘);
A=rgb2gray(A);
?subplot(221)
imshow(A);
title(‘原圖‘)
for?k=1:90
for?x=1:131
?????????for?y=1:131
????????????x1=x+y;
????????????y1=x+2*y;
????????????if?x1>131
????????????????x1=mod(x1131);
????????????end
????????????if?y1>131
????????????????y1=mod(y1131);
????????????end
????????????if?x1==0
????????????????x1=131;
????????????end
????????????if?y1==0
????????????????y1=131;
????????????end
????????????A1(x1y1)=A(xy);
????????end
end
A=A1;
end
?subplot(222)
imshow(A1);
title(‘加密后的圖像‘)
for?k=1:90
for?x1=1:131
????for?y1=1:131
????????if?x1 ????????????y2=y1-x1;
????????????if?x1<=y2
????????????????x2=131+x1-y2;
????????????else
????????????????x2=x1-y2;
????????????end
????????end
????????if?x1>y1
???????????
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2012-04-10?17:22??arnold-logistic\
?????文件????????1140??2012-04-05?17:06??arnold-logistic\Arnold.m
?????文件????????1108??2012-04-05?17:06??arnold-logistic\logistic.m
評論
共有 條評論