s=30;
N=s*s;
A=zeros(N,N);
for i=1:s
    for j=1:s
        if (i<s)
            x=s*(i-1)+j;
            y=s*(i)+j;
            A(x,y)=1;
            A(y,x)=1;
        end
        if (j<s)
            x=s*(i-1)+j;
            y=s*(i-1)+j+1;
            A(x,y)=1;
            A(y,x)=1;
        end
    end
end

la=diag(sum(A))-A;
[v,d]=eig(full(la));
%diag(d);
i=1;
plot(v(:,i));
hold on;
plot(v(:,i),'o');

