setdefault;

% Enter the range of k here
k = [200:1:1200];
ss = zeros( length(k), 3 );

for j = 1:length(k)
   M = [    r/k(j)    r/k(j)       b;
            r/k(j)*a  r/k(j)       b-eps;
            c*b       c*(b-eps) 0       ];
   temp = inv(M) * [r;r;d];
   ss(j,1) = temp(1);
   ss(j,2) = temp(2);
   ss(j,3) = temp(3);
end

plot3(ss(:,1),ss(:,2),ss(:,3));
xlabel('N_1^*');ylabel('N_2^*');zlabel('P^*');
title('Nontrivial fixed point as parametrized by k');
grid on;
