%%% file to generate figure opt_strat_cher91
%%% arrow.m needed
%%% http://www.mathworks.de/matlabcentral/fileexchange/278-arrow-m
clc; clear;

c10=3.3; c20=5.5;
c1f=9.04; c2f=0.64;
b0=63.42; b1=-12.439; b2=-7.836;
C1=logspace(log10(10),log10(25),60);
C2=1./exp((b0 + b1 + b2 + b1*log(C1))/b2);
plot(C1,C2,'.','MarkerSize',15); hold on
axis([0 25 0 6])

for i=1.5:1:5.5
    arrow([1/exp((b0 + b1 + b2 + b2*log(i))/b1)-.2;i],...
        [1/exp((b0 + b1 + b2 + b2*log(i))/b1);i],'length',12,'tipangle',12);
    k1=linspace(0,1/exp((b0 + b1 + b2 + b2*log(i))/b1),80/i);
    plot(k1,i*ones(size(k1)),'k','LineWidth',0.1);
end

k=c2f/c1f; phi=atan(k);
plot([25;0.9],[k*25;0.9*k],'--k')
arrow([2;2*k],[0.9;0.9*k],'length',12,'tipangle',12);

k=tan(2*phi);
plot([25;0.8],[k*25;0.8*k],'--k')
arrow([2;k*2],[0.8;0.8*k],'length',12,'tipangle',12);

k=tan(3.5*phi);
plot([6/k;0.7],[6;0.7*k],'--k')
arrow([0.8;k*0.8],[0.7;0.7*k],'length',12,'tipangle',12);

k=tan(6*phi);
plot([6/k;0.6],[6;0.6*k],'--k')
arrow([0.7;k*0.7],[0.5;0.5*k],'length',12,'tipangle',12);

k=tan(9.5*phi);
plot([6/k;0.4],[6;0.4*k],'--k')
plot(5,k*5,'rs','MarkerSize',8)
arrow([0.6;k*0.6],[0.35;0.35*k],'length',12,'tipangle',12);

legend('S(c_1,c_2)=0','Location','SouthEast')
plot(c10,c20,'go','MarkerSize',8)
plot(c1f,c2f,'rx','MarkerSize',10)
xlabel('c1'); ylabel('c2');