(* Choose the polynomial P and the exponent n. Nothing else needs to be changed *) P = z(z-12)(z-2-8I)(z-8-7I); n=15; d = Exponent[P,z]; precision=10*d+n; (* Finds the union of the roots of all orders of the derivative of P^n. Note that we remove the multiple roots at the zeros of P when mprecision])];currentFunc=D[Expand[currentFunc],z],{m,1,n-1}] Do[roots=Join[roots,{Re@#,Im@#}&/@(z/.NSolve[currentFunc==0,WorkingPrecision->precision])];currentFunc=D[Expand[currentFunc],z],{m,n,n*d-1}] (* At this point, a simple call to ListPlot is enough to draw a basic shadow; the rest of the code below is just there to draw a more interesting plot, and can be omitted *) (* ListPlot[roots] *) (* Determine some additional points for the final plot *) rootsOfP = {Re@#,Im@#}&/@(z/.NSolve[Expand[P]==0,WorkingPrecision->precision]); rootsOfPPrime = {Re@#,Im@#}&/@(z/.NSolve[D[Expand[P],z]==0,WorkingPrecision->precision]); centerOfMassOfZP = Mean[rootsOfP]; (* Determine branch points of equation (1.4) (in the original paper) in the z-plane; a subset of these points serves as an appoximation of the boundary of the shadow *) resStepLength = 1/100; (* A smaller step length yields more branch points *) FF = Sum[((α-k)/k!)*D[P,{z,k}]*D[w^(d-k)],{k,0,d}]; RES = Expand[Resultant[FF,D[FF,w],w]]; resultantRoots = Table[({Re@#,Im@#}&/@(z/.NSolve[Simplify[RES]==0,WorkingPrecision->precision])),{α,0+resStepLength,d-resStepLength,resStepLength}]; allResultantRoots = {}; For[i=1,iTrue,AxesLabel->{"Re","Im"},Frame->False,AspectRatio->Automatic,AxesOrigin->{Min[roots[[All,1]]]-convHullWidth/30,Min[roots[[All,2]]]-convHullHeight/30},PlotRange->{{Min[roots[[All,1]]]-convHullWidth/30,Max[roots[[All,1]]]+convHullWidth/30},{Min[roots[[All,2]]]-convHullHeight/30,Max[roots[[All,2]]]+convHullHeight/30}}]&@roots] Export[StringJoin["Shadow-n",ToString[n],".pdf"],finalPlot]