clear
close all
% Enter functions
f = @(z) z.^2;
lambda = @(t) t + t.^2*i;   
Lam =  @(t) t.^2 -t.^4 + t.^3*i; 

t0=2;
t=linspace(-3,3,100);
dlambda=(1 + 2*t0*i);
dLam=(2*t0 -4*t0^3 + 6*t0^2*i);


subplot(1,2,1)
plot(lambda(t),'k','LineWidth',1)
axis( [-4,4, 0,8] )
axis square; 
hold on
plot(lambda(t0),'bo','LineWidth',1)
plot(lambda(t0)+((dlambda))*t,'r','LineWidth',1)
line([0, real(lambda(t0))], [0, imag(lambda(t0))],'LineStyle','--')
title({['Arg(z0) = ' num2str(angle(lambda(t0)))], ['Arg(\lambda'') = ' num2str(angle(dlambda))]})


subplot(1,2,2)
plot(f(lambda(t)),'k','LineWidth',1)
axis( [-40,40, -40,40] )
axis square; 
hold on
w0=f(lambda(t0));
plot(w0,'bo','LineWidth',1)
plot(w0+((dlambda))*t,'r','LineWidth',1)
plot(w0+((dLam))*t,'b','LineWidth',1)
diff=angle(dLam)-angle(dlambda);
title({['Arg(\Lambda'') = ' num2str(angle(dLam))], ['Arg(\Lambda'') - Arg(\lambda'') = ', num2str(diff)]})

hold off



