Commit 50bc9152 authored by Sergey Kireev's avatar Sergey Kireev
Browse files

bug fixed

parent 080a6318
......@@ -254,7 +254,7 @@ int CA2D<State,hood_type>::find_groups_sqr4(std::function<bool(const State &)> m
{ const int ix = nx-1;
for (int iy=0;iy<ny-1;iy++)
if (match(get(ix,iy))) {
XY n1(ix,iy-1); hood.fix(n1,nx,ny);
XY n1(ix,iy-1); hood.fix(n1,nx,ny);
XY n2(ix-1,iy); hood.fix(n2,nx,ny);
XY n3(ix+1,iy); hood.fix(n3,nx,ny);
int label = k;
......@@ -349,8 +349,8 @@ int CA2D<State,hood_type>::find_groups_sqr8(std::function<bool(const State &)> m
int sum = 1;
int lbl1 = group[xy1d(n1.x,n1.y)];
int lbl2 = group[xy1d(n2.x,n2.y)];
int lbl4 = group[xy1d(n4.x,n2.y)];
int lbl6 = group[xy1d(n6.x,n2.y)];
int lbl4 = group[xy1d(n4.x,n4.y)];
int lbl6 = group[xy1d(n6.x,n6.y)];
group_traverse(sum,label,lbl1,{});
group_traverse(sum,label,lbl2,{lbl1});
group_traverse(sum,label,lbl4,{lbl1,lbl2});
......@@ -379,10 +379,10 @@ int CA2D<State,hood_type>::find_groups_sqr8(std::function<bool(const State &)> m
int lbl1 = group[xy1d(n1.x,n1.y)];
int lbl2 = group[xy1d(n2.x,n2.y)];
int lbl3 = group[xy1d(n3.x,n3.y)];
int lbl4 = group[xy1d(n4.x,n3.y)];
int lbl5 = group[xy1d(n5.x,n3.y)];
int lbl6 = group[xy1d(n6.x,n3.y)];
int lbl8 = group[xy1d(n8.x,n3.y)];
int lbl4 = group[xy1d(n4.x,n4.y)];
int lbl5 = group[xy1d(n5.x,n5.y)];
int lbl6 = group[xy1d(n6.x,n6.y)];
int lbl8 = group[xy1d(n8.x,n8.y)];
group_traverse(sum,label,lbl1,{});
group_traverse(sum,label,lbl2,{lbl1});
group_traverse(sum,label,lbl3,{lbl1,lbl2});
......@@ -418,10 +418,10 @@ int CA2D<State,hood_type>::find_groups_sqr8(std::function<bool(const State &)> m
int lbl1 = group[xy1d(n1.x,n1.y)];
int lbl2 = group[xy1d(n2.x,n2.y)];
int lbl3 = group[xy1d(n3.x,n3.y)];
int lbl4 = group[xy1d(n4.x,n3.y)];
int lbl6 = group[xy1d(n6.x,n3.y)];
int lbl7 = group[xy1d(n7.x,n3.y)];
int lbl8 = group[xy1d(n8.x,n3.y)];
int lbl4 = group[xy1d(n4.x,n4.y)];
int lbl6 = group[xy1d(n6.x,n6.y)];
int lbl7 = group[xy1d(n7.x,n7.y)];
int lbl8 = group[xy1d(n8.x,n8.y)];
group_traverse(sum,label,lbl1,{});
group_traverse(sum,label,lbl2,{lbl1});
group_traverse(sum,label,lbl3,{lbl1,lbl2});
......@@ -458,11 +458,11 @@ int CA2D<State,hood_type>::find_groups_sqr8(std::function<bool(const State &)> m
int lbl1 = group[xy1d(n1.x,n1.y)];
int lbl2 = group[xy1d(n2.x,n2.y)];
int lbl3 = group[xy1d(n3.x,n3.y)];
int lbl4 = group[xy1d(n4.x,n3.y)];
int lbl5 = group[xy1d(n5.x,n3.y)];
int lbl6 = group[xy1d(n6.x,n3.y)];
int lbl7 = group[xy1d(n7.x,n3.y)];
int lbl8 = group[xy1d(n8.x,n3.y)];
int lbl4 = group[xy1d(n4.x,n4.y)];
int lbl5 = group[xy1d(n5.x,n5.y)];
int lbl6 = group[xy1d(n6.x,n6.y)];
int lbl7 = group[xy1d(n7.x,n7.y)];
int lbl8 = group[xy1d(n8.x,n8.y)];
group_traverse(sum,label,lbl1,{});
group_traverse(sum,label,lbl2,{lbl1});
group_traverse(sum,label,lbl3,{lbl1,lbl2});
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment