(*Instantón para el caso escalar, M=1*)

V[ϕ_,c_]=0.5 ϕ^2-0.5 ϕ^3+(c/8) ϕ^4;

Plot[{V[ϕ,0.8],V[ϕ,0.85],V[ϕ,0.9],V[ϕ,0.95]},{ϕ,-1,4},AxesLabel->{ϕ,V[ϕ]},AxesLabel->{ϕ,"V[ϕ]"},PlotStyle->{{RGBColor[0,1,1],Thickness[0.005]},{RGBColor[0,0.7,1],Thickness[0.005]},{RGBColor[0,0.4,1],Thickness[0.005]},{RGBColor[0,0,1],Thickness[0.005]}},AxesStyle->{{Arrowheads[{0.,0.03}],{Thickness[0.005]}},{Arrowheads[{0.0,0.03}],{Thickness[0.005]}}},LabelStyle->Black,TicksStyle->Thick]

(*Condiciones de contorno y Taylor para evitar la singularidad en x=0*)
xi=10^-5;xf=12;
ϕini[x_,ϕ0_,c_]=ϕ0+(1/8) V'[ϕ0,c] x^2;

(*Solución para todas las condiciones iniciales*)
ParameterSolution=ParametricNDSolve[{ϕ''[x]+3 ϕ'[x]/x-D[V[ϕ[x],c],ϕ[x]]==0,ϕ'[xi]==D[ϕini[xi,ϕ0,c],x],ϕ'[xf]==-BesselK[2,xf]/xf},ϕ,{x,xi,xf},{c,ϕ0},Method->{"Shooting","StartingInitialConditions"->{ϕ[xi]==ϕ0,ϕ'[xi]==D[ϕini[xi,ϕ0,c],x]}}];
start={{0.01,(ϕ[0.01,5.77]/.ParameterSolution)[xi]},{0.02,(ϕ[0.02,5.74]/.ParameterSolution)[xi]}};

(*Extrapolamos*)
Do[tem=2 start[[i-1,2]]-start[[i-2,2]];
new={N[i/100],(ϕ[i/100,tem]/.ParameterSolution)[xi]};
AppendTo[start,new],{i,3,86}];

(*Valores de prueba*)
c1=0.2;c2=0.3;c3=0.4;c4=0.5;c5=0.6;c6=0.7;c7=0.8;c8=0.86;

(*Búsqueda del valor de ϕ0 para los valores de prueba*)
position1=Part[Part[Position[start,c1],1],1];
position2=Part[Part[Position[start,c2],1],1];
position3=Part[Part[Position[start,c3],1],1];
position4=Part[Part[Position[start,c4],1],1];
position5=Part[Part[Position[start,c5],1],1];
position6=Part[Part[Position[start,c6],1],1];
position7=Part[Part[Position[start,c7],1],1];
position8=Part[Part[Position[start,c8],1],1];

ϕsol1=ϕ@@start[[position1]]/.ParameterSolution;
ϕsol2=ϕ@@start[[position2]]/.ParameterSolution;
ϕsol3=ϕ@@start[[position3]]/.ParameterSolution;
ϕsol4=ϕ@@start[[position4]]/.ParameterSolution;
ϕsol5=ϕ@@start[[position5]]/.ParameterSolution;
ϕsol6=ϕ@@start[[position6]]/.ParameterSolution;
ϕsol7=ϕ@@start[[position7]]/.ParameterSolution;
ϕsol8=ϕ@@start[[position8]]/.ParameterSolution;

(*Plot de los instantones*)
Plot[{ϕsol1[ρ],ϕsol3[ρ],ϕsol6[ρ],ϕsol8[ρ]},{ρ,xi,xf},PlotRange->All,PlotStyle->{{RGBColor[0,1,1],Thickness[0.005]},{RGBColor[0,0.75,1],Thickness[0.005]},{RGBColor[0,0.5,1],Thickness[0.005]},{RGBColor[0,0,1],Thickness[0.005]}},FrameLabel->{r,ϕ},Frame->True,FrameStyle->{{Thickness[0.005],Black},{Thickness[0.005],Black},{Thickness[0.005],Black},{Thickness[0.005],Black}}]