$\operatorname{LMOpNewtonPolygon}(L, g, x, M, b)$
libname := libname, FileTools:-JoinPath(["maple","lib","dcfun.mla"],base=homedir):
with(dcfun):
b := 2:
$$$$
L := (5*x^4+1)*M^2+(-6*x^6-6*x^5-x^4-1)*M+6*x^4+x^3-4*x^2+x;
$$\left(5 x^{4}+1\right) M^{2}+\left(-6 x^{6}-6 x^{5}-x^{4}-1\right) M +6 x^{4}+x^{3}-4 x^{2}+x$$
pix := LMOpNewtonPolygon(L, 0, x, M, b, scaling = constrained);
$$$$
In the picture structure, we keep only the colored part, i.e. we remove all the black part. Newton's upper and lower polygons are described from left to right (i.e. with points of increasing abscissa).
seq(op(i, remove(has, pix, COLOUR(RGB, 0., 0., 0.))), i = 1..2);
$$\mathit{CURVES}\! \left(\mathit{Matrix}\! \left(3, 2, \left\{\left(1, 1\right)= 1.0, \left(1, 2\right)= 1.0, \left(2, 1\right)= 2.0, \left(3, 1\right)= 4.0\right\}, \mathit{datatype} =\mathit{float}_{8}, \mathit{storage} =\mathit{rectangular} , \mathit{order} =\textit{Fortran\_order} , \mathit{shape} =\left[\right]\right), \mathit{COLOUR}\! \left(\mathit{RGB} , 0.0, 0.0, 1.0\right)\right), \mathit{CURVES}\! \left(\mathit{Matrix}\! \left(3, 2, \left\{\left(1, 1\right)= 1.0, \left(1, 2\right)= 4.0, \left(2, 1\right)= 2.0, \left(2, 2\right)= 6.0, \left(3, 1\right)= 4.0, \left(3, 2\right)= 4.0\right\}, \mathit{datatype} =\mathit{float}_{8}, \mathit{storage} =\mathit{rectangular} , \mathit{order} =\textit{Fortran\_order} , \mathit{shape} =\left[\right]\right), \mathit{COLOUR}\! \left(\mathit{RGB} , 1.0, 0.0, 0.0\right)\right)$$