Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

ANN: Fixing polygon-based plots

2 views
Skip to first unread message

Will Robertson

unread,
Oct 31, 2007, 7:34:58 AM10/31/07
to
Hello,

Some have remarked recently on the poor quality of graphics produced
by ContourPlot and RegionPlot due to the fact that polygons are drawn
for every single mesh element rather than for contiguous shapes.

Announcing FixPolygons:
<http://library.wolfram.com/infocenter/MathSource/7029/>

The solution I've implemented loops through polygons, joining them
together if they're adjacent. This allows interior holes and
discontiguous objects. The big downside is that it's slow. But not so
slow to be unusable.

The syntax is easy; something like
RegionPlot[x^2+y^2<2,{x,-2,2},{y,-2,2}] // FixPolygons

The quality of output for exported diagrams is greatly improved and
the filesize dramatically reduced. It needs optimising and there are
edge cases that give funny results, but in general it works. Comments
and suggestions are greatly appreciated.

All the best,
Will Robertson


0 new messages