123456789101112131415161718192021222324252627 |
- function modelmat=creat_l_r_model
- th=linspace(0,2*pi,17);
- th=th(1:16);
- for a=1:length(th)
- for b=1:length(th)
- dife=(abs(angdiff(th(a),th(b)))); %minor difference since we are using euclidean distance
- m0(a,b)=abs((angdiff(th(a),th(b)))); %minor difference since we are using euclidean distance
- if th(a)>=0*pi&th(a)<1*pi
- if th(b)>=0*pi&th(b)<1*pi
- modelmat(a,b)=0;
- else
- modelmat(a,b)=1;
- end
- else
- if th(b)>=0*pi&th(b)<1*pi
- modelmat(a,b)=1;
- else
- modelmat(a,b)=0;
- end
- end
- end
- end
- % figure;imagesc(modelmat);
- end
|