I was trying to display an animation of two amortized sinusoids that cross each other, like in the example below:
EB[x_, t_] := Cos[2*Pi*x - t]/(1 + 0.125*x^2)
Animate[ParametricPlot3D[{{u, 0, EB[u, t]}, {5, 5 - u, EB[u, t]}}, {u,
0, 10}, PlotRange -> {{0, 10}, {-5, 5}, {-1, 1}},
ImageSize -> Scaled[0.8], AxesOrigin -> {0, 0, 0},
Boxed -> False], {t, 0, 2*Pi}]
As you can see, the first curve displays as expected, but the second (orange) one is ugly.
How can I sort this out ?
Many thanks for your time.
Yohann
You can try giving the option PerformanceGoal -> "Quality", or PlotPoints->50 or more.
Thank you! That’s exactly what I needed, It did the trick (esp. the second proposition).
However, I don’t understand why the two curves were not treated the same regarding Quality or PlotPoints in the first place. I would have expected both to have the same look (both nice, lucky me then, or both ugly and I would then have to enhance PlotPoints or Quality).
When making an animation we must make a compromise between the smoothness in space of every single frame and the smoothness through time. The internal algorithm chooses what to sacrificed, and it is not always the best for human judgement. With PerformanceGoal -> "Quality" we force Mathematica to give precedence to space accuracy.
Ok, thank you for your insights.