# Plotting coefficients for each example

## Mathematica program

 ```(* Plotting coefficients for each example *) sect = "cplot"; entity = "figure"; If[newfigure == True, enplus = enminus = enall = {}; Do[ener = func[[n]]; If[ener != 0, enlog = Abs[ener]; enall = Append[enall, {n, enlog}]]; If[ener > 0, enplus = Append[enplus, {n, enlog}]]; If[ener < 0, enminus = Append[enminus, {n, enlog}]], {n, nm}]; rat = 1/GoldenRatio // N; pntsz = 0.015 30/(15 + nm); pltplus = If[Length[enplus] == 0, {}, LogListPlot[enplus, PlotStyle -> {RGBColor[1, 0, 0], PointSize[pntsz]}, DisplayFunction -> Identity]]; pltminus = If[Length[enminus] == 0, {}, LogListPlot[enminus, PlotStyle -> {RGBColor[0, 0, 1], PointSize[pntsz]}, DisplayFunction -> Identity]]; pltall = LogListPlot[enall, PlotStyle -> {Thickness[pntsz/4], RGBColor[0.5, 0.5, 0.5]}, PlotJoined -> True, DisplayFunction -> Identity]; Off[Display::"pserr"]; plt = Show[pltall, plt0, pltplus, pltminus, AxesLabel -> {"\!\(\* StyleBox[\"n\",\nFontFamily->\"Times\",\nFontSlant->\"Italic\"]\)", "|\!\(\* StyleBox[\(E\_n\),\nFontFamily->\"Times\",\nFontSlant->\"Italic\"]\)|"}, AspectRatio -> rat, PlotRange -> {{0, nm + 0.3}, All}, AxesOrigin -> {0, 0}, DisplayFunction -> Identity]; outfile = ToFileName[dir, sect <> ".gif"]; Export[outfile, plt, "GIF", ImageSize -> 320 {1, rat}, ImageResolution -> 150]; outfile1 = StringReplace[outfile, ".gif" -> ".pdf"]; plt1 = Show[plt, PlotRegion -> {{0.05, 0.95}, {0.05, 0.95}}, (* TextStyle -> {FontSubstitutions -> {"Math2Mono" -> "Times"}}, *) (* Trying to fix incorrect display of "|", but it does not work *) DisplayFunction -> Identity]; Export[outfile1, plt1, "PDF", ImageSize -> Automatic, ImageOffset -> Automatic, ImageRotated -> True]; ]; " sect <> "\">
" // p; "" // p; "" // p; "" <> "
" <> "Coefficients of Moller-Plesset perturbation theory, semilogarithmic plot." <> "
Red/blue dots correspond to positive/negative coefficients
" <> " sect <> ".gif?"<>rndm<>"\" WIDTH=666 HEIGHT=412 ALT=\"Plot of MP coefficients\">
" // p; printprogr[sect]; printnav;```

 All Mathematica programs used to study M. - P. series Work in UMassD Unpublished reports

Designed by A. Sergeev.