Relplot: a general equation plotter

Relplot constructs high-resolution PostScript or PDF plots of the solutions to equations on two variables. Unlike most other plotters, it can handle general equations and inequations, not just functions, and it can plot multiple equations at once.

What can you plot?


x^3 + y^3 = 3xy,  r^2 = 9/2

Some interesting equations to try:

x^2 * y^2 = 1                          x^3 + y^3 = 3xy
x^y = y^x                              (r-1/2)^5 = 4yx^3 - 4xy^3
ln r = sin 4x^2 + cos 5y^2 + x/4       ((xy(x-y)(x+y)(x^2+y^2-4))^2 - 1) < 1
y>|x| & y<sqrt(exp x + exp(-x) - 2)    y = 3 * x * sin(pi r)
x^2 <= floor|2y|, x^2>|2y|             0 = (x^2+(y-(x^2)^(1/3))^2) mod 1
(5x mod 1 = 0 || 5y mod 1 = 0) & r<2   x+y < sin (5x-5y) && |x| < 2, |r| > 2
f(1)=-x, f(2)=0, f(4)=-4x where f(n)=(r+cos(10th))^2-n^2

Equation(s) to plot (see above for examples):

Hint: Relplot expects equation(s) such as y=x^2 rather than just a formula like x^2.

Region of the X–Y plane to show:

X value of left side:
X value of right side:
Y value of bottom:
Y value of top:
X/Y aspect ratio is 1:1

Got feedback? Give suggestions or vote on proposed changes.


Relplot was written by Andrew Myers at Cornell University. It is written in SML and PostScript. The source code is freely available for noncommercial use, subject to academic integrity constraints; please contact the author.