# why is the plot like this?

Does anybody know the problem?

why is the plot hatched ? I just want a simple plot.

g[z_, t_] := 1 + t*z + z^3

Plot[Residue[1/(1 + t*z + z^3), {z, Root[Function[z, g[z, t]], 1]}], {t, 0, 10}]

• Please show us the code text as you've done in your first question, rather than posting a screenshot. Mar 17, 2020 at 8:56
• @Dear xzczd, my original problem is about polynomials of degree 4 which coefficient are functions of temperature as like as screenshot which have mentioned above. I want to plot T-dependence of roots and residue of them. sorry for posting many screenshots Mar 17, 2020 at 9:15
• I mean, please post the code text instead of the screenshot. Currently we'll have to transcribe the code from your screenshot if we want to test it. Mar 17, 2020 at 9:24
• @xzczd thank you so much, yes, you are right, I should have sent code instead of it's screenshoot Mar 17, 2020 at 9:39
• -1×2, will retract my downvotes as soon as the code text are added to the questions. Mar 17, 2020 at 9:58

## 1 Answer

Root cann't handel the additional parameter t! Try

g[z_, t_] := 1 + t z + z^3
root[t_] := Root[Function[z, g[z, t]], 1]
Plot[Evaluate[Residue[1/g[z, t], {z, root[t]  }]], {t, 0, 10} ]


• @Dear Ulrich Neumann, thank you so much, it was very clear. Mar 17, 2020 at 9:42
• @Arian You're welcome! Mar 17, 2020 at 9:43
• The solution works, but the explanation is incorrect. This is a matter of precision. Try Plot[Residue[1/g[z, t], {z, Root[Function[z, g[z, t]], 1] }], {t, 0, 10},WorkingPrecision->16 ]. Mar 17, 2020 at 10:06
• @xzcd Thanks for your clarification. Nevertheless in my opinion a numerical solution which doesn't need high workingprecision is quite reliable. Mar 17, 2020 at 10:40
• That's true, your solution is the better choice for resolving the problem. Mar 17, 2020 at 11:17