3.3 openmath

Openmath3.1 is a TCL/Tk GUI plotting program written by W. Schelter.

The following command plots the function $ \cos(2x)+2e^{-x}$

sage: maxima.plot2d('cos(2*x) + 2*exp(-x)','[x,0,1]',\
...   '[plot_format,openmath]')  # optional -- pops up a window.

(Mac OS X users: Note that these openmath commands were run in a session of Sage started in an xterm shell, not using the standard Mac Terminal application.)

sage: maxima.eval('load("plotdf");')
sage: maxima.eval('plotdf(x+y,[trajectory_at,2,-0.1]); ') #optional

This plots a direction field (the plotdf Maxima package was also written by W. Schelter.)

A 2D plot of several functions:

sage: maxima.plot2d('[x,x^2,x^3]','[x,-1,1]','[plot_format,openmath]') #optional

Openmath also does 3D plots of surfaces of the form $ z=f(x,y)$ , as $ x$ and $ y$ range over a rectangle. For example, here is a ``live'' 3D plot which you can move with your mouse:

sage: maxima.plot3d ("sin(x^2 + y^2)", "[x, -3, 3]", "[y, -3, 3]",\
...   '[plot_format, openmath]') #optional
By rotating this suitably, you can view the contour plot.



Footnotes

...Openmath3.1
Not to be confused with OpenMath, an extensible standard for representing the semantics of mathematical objects, http://www.openmath.org/.
See About this document... for information on suggesting changes.