I am trying to make a figure in Mathematica using some graphic primitives:
rod[l_, r_] := GraphicsGroup[{Opacity[.1], {Disk[{-l/2 + r, 0},
r, {\[Pi]/2 , 3 \[Pi]/2}]}, {Disk[{l/2 - r, 0},
r, {-\[Pi]/2, \[Pi]/2}]}, Rectangle[{-l/2 + r, -r}, {l/2 - r, r}]}]
when I run:
Graphics[rod[3, .5]]
I get:
where there is a clear missallignment with the rectangle and hemicircles, what can I do to allign them in a proper way?
cheers,



Exportfunction and few turned out to be a bug. However, you can try increasing the resolution of the output withExport["graphics.svg", Graphics[rod[3, .5]], ImageSize -> 2000]. This works on my machine. – ercegovac Oct 10 '17 at 10:33ImageResize[ Rasterize[ Graphics[rod[3, .5]], "Image", ImageResolution -> 20*72 ], Scaled[1/20] ]. – Szabolcs Oct 10 '17 at 12:40