Maxima 2D plot -- How to set axes equal

maxima plot discrete points
maxima draw2d
plot circle maxima
plot2d: expression evaluates to non-numeric value everywhere in plotting range.
maxima plot vector field
wxmaxima examples
maxima on android tutorial
maxima help

For example, what is a code for plotting y = x so that y- and x-axis have the same scale ?

Maxima, by default, uses gnuplot to produce 2d graphics.

If you're using this default, then you need to set the gnuplot_preamble, e.g.

plot2d(x, [x,-1,1], [gnuplot_preamble, "set size ratio -1"])$

Note the -1 means that gnuplot tries to set the scales so that the unit has the same length on both axes, while +1 sets the aspect ratio ignoring the axis scales. To make this the default, type

set_plot_option ([gnuplot_preamble, "set size ratio -1"])$

If you want to find out more about the gnuplot size options, run gnuplot from your terminal and type help set size into the console.


n.b. Most basic questions you can have about Maxima can be found somewhere in their mailing list archive: http://maxima.sourceforge.net/maximalist.html

Maxima 5.42.0 Manual: 12. Plotting, draw is a Maxima-Gnuplot and a Maxima-vtk interface. See also axis_bottom , axis_left , axis_top , and axis_right for axis in 2d. When proportional_axes is equal to xy or xyz , the aspect ratio of the axis units will be set to 1:1 resulting in a 4.3 or newer. pdf requires Gnuplot to be compiled with the option --enable-pdf​  Plot option: axes [axes, symbol] Default value: true. Where symbol can be either true, false, x, y or solid. If false, no axes are shown; if equal to x or y only the x or y axis will be shown; if it is equal to true, both axes will be shown and solid will show the two axes with a solid line, rather than the default broken line. This option does

The axes can be made the same size using the same_xy option:

plot2d(x, [x,-1,1], [same_xy]);

or

plot2d(x, [x,-1,1], [same_xy, true]);

There is a same_xyz option for three dimensional plots.

Maxima 5.42.0 Manual: 53. draw, For 2D plots: xlim([xmin xmax]) ylim([ymin ymax]) axis([xmin xmax ymin set for y axis Min and Max limits set for x & y % % % % axis equal axis square axis  Graphic option: proportional_axes. Default value: none. When proportional_axes is equal to xy or xyz, a 2D or 3D scene will be drawn with axes proportional to their relative lengths. Since this is a global graphics option, its position in the scene description does not matter. This option works with Gnuplot version 4.2.6 or greater. Examples

If you're using the draw or draw3d function (or animated versions of those), then you have to pass the proportional_axes graphic option as an argument.

For example proportional_axes = xy in 2D.

See more: http://maxima.sourceforge.net/docs/manual/de/maxima_42.html (Search for "proportional_axes".)

MATLAB¨/Simulink¨ Essentials: MATLAB¨/Simulink¨ for Engineering , Plot titles, axis labels and scales, grid settings, and legend options can be For 2D plots: xlim([xmin xmax]) % Min and Max limits set for x axis ylim([ymin ymax]) can be set up in a few different ways by these following commands: axis equal​  Two y axes in Maxima 2D plots In MATLAB, I occasionally have need for the plotyy() command for making a plot of two different functions with widely varying scales. Turns out Maxima draw has an equivalent functionality by setting the option yaxis_secondary :

Beginning MATLAB and Simulink: From Novice to Professional, Maxima uses the program Gnuplot for depicting graphics [2], which is called automatically, when the set cntrparam spez Controls contour lines in a contour-​plot set view value does not set the ratio of the lengths of the axes, but the ratio of their scales. Thus for gnuplot_preamble enforces equal scales. This can be achieved by asking Maxima to run gnuplot's set view map command before drawing the plot. Indeed, calling Maxima 2D plot — How to set axes equal. 0.

[PDF] Graphics with MAXIMA, use graphics options is to put all the global options first, followed by the non-​global options and the or wxdraw2d command, draw will assume you want 2D graphic objects, and make use xaxis width, xlabel, xrange, xtics, xtics axis, xtics rotate, xy file, xu grid, F(x, y, z), which draw assumes is equal to 0. -- Plot option: axes [axes, <symbol>] Default value: `true' Where <symbol> can be either `true', `false', `x' or `y'. If `false', no axes will be shown; if equal to `x' or `y' only the x or y axis will be shown, and if it is equal to `true', both axes will be shown. This option is used only by plot2d and implicit_plot.

[PDF] The Maxima package draw in the wxMaxima GUI Version 0.40, plot2d() [ in wxMaxima: wxplot2d() ] that produces 2d graphs in a fairly straightforward cover all of our graphics needs for all of Calculus -- both single and multivariable! If you are using plain Maxima in either the command line or xmaxima If you want to plot several functions on the same set of axes, each function gets  8.1 Introduction to Plotting . Maxima uses an external plotting package to make the plots (see the section on Plotting Interfaces below). Maxima calculates set of points to be plotted and pass the to the plotting package together with a set of commands; the commands and plot data are passed to the external program either through a pipe or by saving them into a file with the extension maxout

Comments
  • It surely worked. Is there a way to "set size ratio 1" by default ?