# Eliminating the sawtooth edges in an image and improving the rending [duplicate]

RegionPlot3D[(x - 45/2)^2 + y^2 + z^2 >= 25/
4 && (x - 15)^2 + y^2 + z^2 >= 25 && (x - 35/2)^2 + y^2 + z^2 <=
225/4, {x, -5, 35}, {y, -15, 15}, {z, -15, 15}, PlotPoints -> 50,
PlotRange -> All]


The image output by this code is of very poor quality. How can I improve it.

• PlotPoints->250 or PlotPoints->500 but then you will perhaps reply "why does it take so long to produce textbook or art quality images and how can I make it do it instantly?"
– Bill
Jan 25, 2020 at 7:23
• If you use contourRegionPlot3D[] from this answer, you'll get a better picture. Jan 25, 2020 at 12:54

Draw extra boundary. Is slightly faster.

cond = (x - 45/2)^2 + y^2 + z^2 >= 25/4 && (x - 15)^2 + y^2 + z^2 >=
25 && (x - 35/2)^2 + y^2 + z^2 <= 225/4;

cond2 = List @@ (Equal @@ # & /@ cond)

rp = RegionPlot3D[cond, {x, 10, 25}, {y, 0, 8}, {z, -8, 8},
PlotPoints -> 100];

cp = ContourPlot3D[
Evaluate[cond2], {x, 10, 25}, {y, 0, 8}, {z, -8, 8},
PlotPoints -> 50];

Show[cp, rp]