- What's wrong with postscript in MMA with LaTeX?
- More problems with postscript in MMA with LaTeX.
- How can I permanently change options for Plot[] or ListPlot[]?
- How can I make a movie from within MMA?
- How do I plot vector fields?
- How do I plot polar vector fields?
- How do I get my plot axes to intersect at the origin?
- How do I get my plot to show the entire range of the function?
- Where do I find the functions LogLogPlot[] and LogPlot[]?
- How do I display two plots on the same graph without having them show individually first?

- I want to use Display["filename",Graphics] to write a graphics file into a postscript file to include in a TeX document. Unfortunately, ghostview doesn't read the ps file properly and I can't print it to a printer either. What is wrong?
- I have to change attributes for ListPlot every time I use it. Is there a way to save the attributes of it? For example, everytime I restore a Saved[] file, I want the aspect ratio to be 1 for all my plots.
- How does one make a "movie", or animated graphics on MMA?
- I keep seeing MMA graphs of vector fields. How is it done?
- I have a piecewise vector function of rho and phi, with components in the rho and phi hat directions. Can I plot the vector field as is, or do I need to convert the components and unit vectors to Cartesian coordinates?
- How do I get my plot axes to intersect at the origin?
- How do I get my plot to show the entire range of the function?
- Where do I find the functions
`LogLogPlot[]`and`LogPlot[]`? - How do I display two plots on the same graph without having them show individually first?

MMA's PS is broken (Wolfram would probably prefer the terminology "different" or "proprietary"). It's tailored for display by Mma; there are a bunch of definitions, which Mma already knows, which need to be added to the file to make it useable by any other PS display device. Assuming you're on a unix station, you'll need to run psfix (should be part of your MMA distribution) on the output from Display[].

Internally, MMA uses a non-standard dialect of PS to more efficiently represent MMA graphics. It defines a number of higher level operators that are understood by MMA's own PS interpreter but not by others. You simply need to add the definitions of these operators to your MMA PS file before passing it to, in your case, ghostview. You can do this using rasterps, which is distributed with MMA. If you're using a Unix version of MMA then at the Unix command line type: rasterps -format ps -file filename.ps. filename will take a file containing Mathematica PS ("filename") and convert it into a file containing standard PS ("filename.ps") which can be sent to a printer or viewed with an application like ghostview. For a more detailed description refer to the section on Converting Graphics to Other Formats in the MMA Users Guide for your System. If you require more help with this problem I'd suggest that you contact Wolfram Research Technical Support directly: support@wolfram.com).

See http://support.wolfram.com/Graphics/Formats/EPS/IncludeFonts.html.

You can use `SetOptions` to change the default option values for
functions. For example:

SetOptions[ Plot, DefaultFont -> {"Times-Bold", 14} ]

will change the default font for plots to 14pt Times bold. If you want a
given change to be present every time you run MMA you can place the command
in the **init.m** initialisation filer. For another example,

In[3]:= SetOptions[ListPlot, AspectRatio -> 1] Out[3]= {AspectRatio -> 1, Axes -> Automatic, AxesLabel -> None, ...etc}

All versions of MMA are able to display sequences of graphics as animations. The details vary on different platforms. The following command generates a sequence of graphics:

Table[ Plot[ Sin[ a x], {x, 0, 10}], {a, 1, 6}]

When using the notebook front end, double clicking on one of the resulting graphics will run the animation. If you are running a version of MMA without a notebook front end you'll want to use the Graphics`Animation` package which is documented in the "Guide to Standard MMA Packages Technical Report".

Whether you can make a movie depends on the particular implementation of MMA. Sometimes there is a function called Animate. Other times there is a menu item called Animate Selected Graphics. With this one, you just select the frames that you want to show in sequence and then go to that menu item.

You could animate the plots you've made by selecting all of them and using the "Animate Selected Graphics Command" which is somewhere in the menus (it depends on which system you are using). If you use a Mac, you can also save the graphs as a QuickTime movie by selecting all of them and use Convert To Quicktime in the Graph menu.

You might want to look at this:

(* Movie-2: An Attempt At Crude Animation of Wave Equation *) (* by Geoff Baldwin, 26 April 1996. *) (* PDE class, San Francisco State University *) (* Find Serviceable "Bump Function" *) Plot[ Exp[-(2 x)^2], {x, -1, 1}, PlotRange->{0,1}] f[y_] := Exp[-(2 x)^2] (* Make a list of plots *) t = Table [ Plot[f[x-t] + f[x+t], {x,0,10}, PlotRange->{0,2}], {t, -5,5,1}] (* Irrelevant, but interesting aside. Shows that list was built: *) Apply[Show,t] (* Show each element of the list, successively (crude animation): *) Do[ Show[t[[i]], {i,1,Count[t,_]}]

2D and 3D vector plots are defined in Graphics`PlotField` and Graphics `PlotField3D` respectively, two of the standard packages distributed with every copy of MMA. They're documented in the Guide to Standard MMA Packages Technical Report (pp 183-191). Here's a simple example taken from the documentation:

Needs[ "Graphics`PlotField`"] PlotVectorField[ {Sin[x], Cos[y]}, {x, 0, Pi}, {y, 0, Pi}]

You'll probably have to convert from polar to cartesian coordinates, but there should be some functions in Calculus`VectorAnalysis` to help you convert between the systems.

`Plot[f[r], {r, 0, 10}, AxesOrigin -> {0, 0}]`

`Plot[f[r], {r, 0, 10}, PlotRange->all]`

`LogPlot[]` and `LogLogPlot[]` are defined in
Graphics`Graphics`, one of the standard packages distributed with MMA. The
Graphics`Graphics` package is documented in "The Guide to Standard
Mathematica Packages Technical Report", pp 140-152.

This is surprisingly difficult for something that should be a very common operation. You'd think this would work:

p1=Plot[ x^2, {x, 0, 5} ]; p2=Plot[ x^3, {x, 0, 5} ]; Show[p1,p2]

But it doesn't. The semi-colon just supresses the "-Graphics-". You end up with three graphs. But try this:

hide = DisplayFunction->Identity; unHide = DisplayFunction->$DisplayFunction; p1=Plot[ x^2, {x, 0, 5}, Evaluate[hide] ]; p2=Plot[ x^3, {x, 0, 5}, Evaluate[hide] ]; Show[p1, p2, Evaluate[unHide]];