function phaseportret7
    clear;clf;
    tmax=10;
    %A=[0,-1;4,0];
    %eig(A)
    %[a,b]=solve('-y+1=0','4*x-8=0');
    a=pi/2;
    b=0;
    x=a-5:0.5:a+5;
    y=b-5:0.5:b+5;
    [X,Y]=meshgrid(x,y); %syzdava 2 matrici. V X sa abcisite na x, a v Y ordinatite na y
    for i=1:length(x)
        for j=1:length(y)
            [T,Z]=ode45(@ff,[0,tmax],[X(i,j),Y(i,j)]);
            [T1,Z1]=ode45(@ff,[0,-tmax],[X(i,j),Y(i,j)]);
            hold on
            plot(Z(:,1),Z(:,2),Z1(:,1),Z1(:,2))
            axis([a-15,a+15,b-15,b+15])
        end
    end
    quiver(X,Y,-Y)
    function z=ff(t,y)
        %z=A*y+[1;-8];
        z=[y(2);sin(y(1)+y(2))];
    end
      

end

