Resolving Mathematica 5.0 Problem with Graphs

  • Mathematica
  • Thread starter Pengwuino
  • Start date
  • Tags
    Mathematica
In summary, the conversation discusses the use of Mathematica to plot implicit functions. The code provided includes the definition of a function and its partial derivatives, as well as the creation of three plots using different colors. The issue of receiving garbage output is also mentioned, potentially due to using different versions of Mathematica.
  • #1
Pengwuino
Gold Member
5,124
20
Ok i type in all this stuff

<< Graphics`ImplicitPlot`
f[x_, y_] = 5 - 10 x*y - 4 x\^2 + 3 y - y\^4
fx[x_, y_] = D[f[x, y], x]
fy[x_, y_] = D[f[x, y], y]
p1 = ImplicitPlot[fx[x, y] == 0, {x, -4, 4}, {y, -4, 4}, PlotStyle -> RGBColor[1, 0, 0], PlotPoints -> 100]
p2 = ImplicitPlot[fy[x, y] == 0, {x, -4, 4}, {y, -4, 4}, PlotStyle -> RGBColor[0, 0, 1]]
Show[p1, p2]


And when i run it... i get a whole lot of trash. Hundreds of lines of just numbers. What i think the problem might be is that i used Mathematica 4.# at my university and emailed it to myself where i have 5.0. Does anyone know why i got all this garbage and the 2 graphs instead of just hte graphs?
 
Physics news on Phys.org
  • #2
This is how I wrote it:

<<Graphics`ImplicitPlot`

f1=[itex]5-10xy-4x^2+3y-y^4[/itex];
f1x=D[f1,x];
f1y=D[f1,y];

plt1=ImplicitPlot[f1==0,{x,-4,4},{y,-4,4},PlotStyle->RGBColor[1,0,1]];
plt2=ImplicitPlot[f1x==0,{x,-4,4},{y,-4,4},PlotStyle->RGBColor[0,1,0]];
plt3=ImplicitPlot[f1y==0,{x,-4,4},{y,-4,4},PlotStyle->RGBColor[0,0,1]];

Show[{plt1,plt2,plt3}];
 
  • #3


There could be a few reasons for the issue you are experiencing. One possibility is that there may be some compatibility issues between Mathematica 4.0 and 5.0. It is always recommended to use the same version of the software to avoid any compatibility issues.

Another possibility could be that there is an error in the code you have typed in. It is important to double check for any typos or errors in the code that could be causing the issue.

Additionally, it is possible that there may be some missing packages or libraries in your Mathematica 5.0 installation that are required for the code to run properly. You may need to check for any missing dependencies and install them in order for the code to run correctly.

If none of these solutions work, it may be helpful to consult the Mathematica documentation or reach out to their support team for further assistance. They may be able to help you troubleshoot the issue and find a solution.
 

1. How do I import data into Mathematica 5.0 to create a graph?

To import data into Mathematica 5.0, you can use the Import function and specify the format of the data. For example, if your data is in a CSV file, you would use the command Import["file.csv", "CSV"]. You can also use the Import menu option under the File menu to import data from various sources.

2. How do I create a basic graph in Mathematica 5.0?

To create a basic graph in Mathematica 5.0, you can use the Plot function. For example, if you want to plot a simple line graph, you would use the command Plot[x^2, {x, 0, 10}]. This will create a graph of the function x^2 from x=0 to x=10.

3. How can I customize the appearance of my graph in Mathematica 5.0?

To customize the appearance of your graph in Mathematica 5.0, you can use various options in the Plot function. For example, you can change the color of the graph by using the option PlotStyle -> Red. You can also add labels, titles, and legends using the options AxesLabel, PlotLabel, and PlotLegends respectively.

4. How do I add multiple graphs to the same plot in Mathematica 5.0?

To add multiple graphs to the same plot in Mathematica 5.0, you can use the Show function. This function allows you to combine multiple plots into one. For example, if you have two line graphs, you can use the command Show[Plot[x^2, {x, 0, 10}], Plot[x^3, {x, 0, 10}]] to display both graphs on the same plot.

5. Can I export my graph from Mathematica 5.0 to another program or file format?

Yes, you can export your graph from Mathematica 5.0 to various formats such as PNG, PDF, and EPS. To do so, you can use the Export function and specify the desired format. For example, Export["mygraph.png", Plot[x^2, {x, 0, 10}]] will export your graph as a PNG file. You can also use the menu option under the File menu to export your graph.

Similar threads

  • MATLAB, Maple, Mathematica, LaTeX
Replies
2
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
2
Views
2K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
2
Views
2K
  • Calculus and Beyond Homework Help
Replies
1
Views
416
  • MATLAB, Maple, Mathematica, LaTeX
Replies
9
Views
3K
  • Calculus
Replies
1
Views
978
  • MATLAB, Maple, Mathematica, LaTeX
Replies
8
Views
3K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
4
Views
2K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
6
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
2
Views
14K
Back
Top