91av视频/亚洲h视频/操亚洲美女/外国一级黄色毛片 - 国产三级三级三级三级

  • 大小: 3KB
    文件類型: .zip
    金幣: 2
    下載: 0 次
    發(fā)布日期: 2021-06-09
  • 語言: Matlab
  • 標簽: LDPC??

資源簡介

構(gòu)造圍長8列重4的準循環(huán)的LDPC碼的MATLAB源碼

資源截圖

代碼片段和文件信息


%?This?program?constructs?coumn-weight?four?girth?8?quasi-cyclic?LDPC?codes?given
%?k(?row?weight?j(column?weight)?is?fixed?at?4)?and?m?(size?of?each?sub-matrix).?The
%?program?constructs?a?distance?graph?first?then?converts?it?into?a?matrix.
%?For?details?of?the?algorithm?see?PhD?thesis?by?G.Malema?LDPC?codes:?Construction?and?Implementation
%(University?of?Adelaide?2007)?and?other?publications.
%?Author?:?Dr.?Gabofetswe?Alafang?MalemaUniversity?of?Botswana??
%?Department?of?Computer?science.?e-mail:?malemag@mopipi.ub.bw

j=4;?%?column-weight?should?be?fixed?at?4.
k=8;?%?row-weight?is?variable.
m=130;?%?size?of?each?sub-matrix.is?variable.
M=j*m;?%?total?number?of?rows.
shift=zeros(kj);?%?stores?shift?values?for?each?sub-matrix.
rows?=?struct(‘connect‘0‘counter‘0‘con‘0);?%?structure?used?for?storing?connections.
emptyset?=?[];
for?y?=?1:M???????%?connections?and?number?of?connections?for?rows?and?columns?are?initialized.
????rows(y).counter?=?0;
????rows(y).con?=?intersect(emptysetrows(y).con);
????rows(y).connect?=?intersect(emptysetrows(y).connect);
????%rows(y).mem?=?intersect(emptysetrows(y).mem);
end
group1?=?[1:m];??%row?group?one
group2?=?[m+1:2*m];??%?row?group?two
group3?=?[2*m+1:3*m];?%?row?group?three?these?groups?are?connected?to?group?one.
group4?=?[3*m+1:4*m];

g=?1;?%?determines?the?girth?of?the?code?in?these?case?8.
found_code?=?1;?%?true?if?algorithm?does?not?fail.

%?the?for?loop?finds?a?rows(from?groups?123)?that?are?apart?at?atleast?a?distance
%?of?8.?They?are?then?connected.?The?rest?of?the?groups?are?connected
%?according?to?this?first?connection.?The?process?is?repeated?k?times?which
%?is?the?number?of?connections?for?each?row.
for?kk?=?1:k
????r1?=?ceil(rand*length(group1));?%?randomly?choose?a?row?from?group1
????i?=?group1(r1);
????%while?rows(i).counter?????????mem=[];?mem1?=?rows(i).con;
????????mem2?=?[];
????????for?y?=?1:g
????????????%mem2?=?[];
????????????for?x?=?1:length(mem1)
????????????????x1?=?mem1(x);
????????????????mem2?=?union(mem2rows(x1).con);
????????????end
????????????mem?=?union(mem1mem2);
????????????mem1=mem;
????????end
????????
????%?find?row?not?in?mem?in?the?given?range.
????
????A?=?intersect(memgroup2);
????A?=?setxor(Agroup2);
????if?(isempty(A)~=1)
????????r1?=?ceil(rand*length(A));
????????row1?=?A(r1);
????else
????????disp(‘Row?two?not?found‘);
????????found_code?=?0;
????????break;
????end
????
????%?create?list?of?neighbors?at?a?distance?of?6?or?less?for?row1.
????mem3?=?[];?mem1=rows(row1).con;
????mem2?=?[];
????for?b?=?1:g
????????%mem2?=?[];
????????for?x?=?1:length(mem1)
????????????x1?=?mem1(x);
????????????mem2?=?union(mem2rows(x1).con);
????????end
????????mem3?=?union(mem1mem2);
????????mem1?=?mem3;
????end
????mem3?=?union(mem3row1);
????
????%?Find?row?2?not?in?mem?or?mem3?at?a?distance?of?atleast?7.
????
????????????check1?=?intersect(memgroup3);
????????????chec

?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????文件????????6444??2009-05-20?07:28??girth84rr.m
?????文件????????1338??2009-05-20?07:28??license.txt

評論

共有 條評論