Questions on creating visualizations from functions or data using high-level constructors such as Plot, ListPlot, Histogram, etc.

learn more… | top users | synonyms (4)

5
votes
4answers
168 views

ContourPlot refuses to show in-figure PlotLegends after turn on ContourShading

I would like to do a contour plot with a label inside the figure. For example, the following works well. Note there is a small "example" at the right bottom figure. ...
7
votes
2answers
216 views

Nothing appears in simple plot

I'm trying to get the following simple code to work. (The code is just supposed to graph the norm of the second derivative of a vector function). ...
1
vote
0answers
57 views
8
votes
4answers
700 views

Filling a curve between a line and the x-axis

I'm trying to plot the function $f(x)=\dfrac{1}{x^2}$, filling the square area from (0,0) to (1,1) with purple and filling the area under the curve from 1 to 4 with red. However, Mathematica is not ...
2
votes
1answer
129 views

Another one problem with legends on GraphicsGrid

I have used ListLinePlot to generate this grid of plots: and I want to add a legend in Row Layout below this grid. My code, has as follows: ...
0
votes
1answer
112 views

A problem with set values

The following code is just an example to clearly explain my problem. Assume that : ...
3
votes
1answer
491 views

Why the complicated pattern in this 3D plot?

ListPointPlot3D[ Table[{n, s, (Prime[n]^s/(Prime[n]^s - 1))}, {n, 1, 2000}, {s, 2, 80}], PlotRange -> All] Is the pattern the result of the data, the ...
2
votes
1answer
162 views

What are these strange shapes in my Plot3D[]? [closed]

Plotting a function, I noticed some strange spots away from the main feature, the dark purple here: You can see that they don't actually have any curvature themselves: Strangely, you don't see ...
0
votes
0answers
158 views

A problem with functions and Infinite expression 1/0 encountering

Following code (function) makes integrals and then replace f[x] with Cos functions and calculate the definite parametric ...
45
votes
4answers
5k views

How to make a 3D globe?

There are many ways to create a 3D Earth that is rotatable (see here, here, related here), but most of them have some drawbacks. These issues mainly stem from either ...
0
votes
1answer
123 views

How to work with Interpolating Function?

I'm starting using Mathematica. I have two coupled differential equations and after using NDSolve the output is in the form of a Interpolating Function. I want to Plot the square modulus of one of the ...
4
votes
1answer
124 views

How can I prevent a Plot expression from evaluating points forbidden by its RegionFunction?

I just ran into this and it had me scratching my head for a good while. Say I have a function which may produce error messages for certain inputs, like e.g. ...
0
votes
1answer
115 views
1
vote
1answer
116 views

Behaviour of OutputResponse in ListLinePlot

Ok, I think this is not the best way to do this, so I'm open minded for every suggestion doing it in a better way. The Question is why does ListLinePlot not plot ...
0
votes
0answers
39 views

How to plot a “pressed” hemisphere [duplicate]

What I'd need is to draw an hemisphere of given radius but then it should have a reduced height. I don't mean a section of an hemisphere, I mean that the hemisphere should be pressed/flattened...so ...
2
votes
1answer
129 views

Plotting Network with LayeredGraphPlot with specific order

I have a network and want to plot it. I use LayeredGraphPlot, and the network is described as: ...
26
votes
2answers
1k views

Sketch-type graphics with transparency and dashed hidden lines?

I'd like to create transparent graphs like the following from P1095, Calculus 6th Ed, by James Stewart. Can Mathematica accomplish this? By "transparent," I mean the ability to see the interior, ...
0
votes
1answer
184 views

predator prey model with prey refuge

I want to plot the phase diagram of prey predator versus prey refuge to see how the prey refuge influences the population of prey and predator.And this is the system $x'=\alpha ...
2
votes
1answer
131 views

Showing ListLogPlot and redrawing FrameTicks

I want to combine two ListLogPlot plots. For example ...
3
votes
2answers
109 views

Interpolation impossible for ListPlot with Missing?

I have a list of data to plot. I would like to plot them with lines but delete some data before plotting and leave the lines disconnected where data is deleted. For example, ...
0
votes
1answer
133 views

marking the points of x-intercept on a plot

OK, I have a nice plot of some oscillating motion. I can read some stuff off the graph, but I thought it would be cool to show a dot where the curve hits the x-axis and a little label showing the ...
0
votes
0answers
61 views
1
vote
2answers
243 views

Parametric 3D plot with parameters satisfying an implicit equation

I am trying to plot a function $ {\bf x}(t) = r(t)\hat{v} + {\bf b}(t) $, with unit vector $ \hat{v} $ and vector $ {\bf b}(t) $ given in spherical coordinates. For simplicity, assume that $ \hat{v} = ...
2
votes
1answer
95 views

Make a “ditch” function for electric field purpose

I'm trying to make a function to simulate a finite bar and get the electric field, i did it by put 22 funnels together but is too slow and is not very accurate; does anyone have any function to ...
5
votes
2answers
524 views

How to export 3D plot, without losing the specified view of rotation?

Sorry I am not sure if I got anything wrong with this version of Mathematica and Mac OS X i am running. But every time I export a 3D graph, to png or tiff, I lost the view angle, view vector viewpoint ...
2
votes
1answer
167 views

How to not include data value outside plot range in the plot

Consider this list plot ls = Table[Sin[t], {t, 0, 100, 0.1}]; p = ListPlot[ls, PlotRange -> {{0., 0.1}, All}, DataRange -> {0, 1}, Joined -> True] If ...
2
votes
1answer
198 views

Plot 3D boolean Array or matrix in Mathematica

I have been attempting several methods to plot a 3D diagram of a n by n boolean array in Mathematica but none of them produced satisfactory result. I want the $3D$ plot to have a cube when ...
0
votes
0answers
111 views
2
votes
2answers
181 views

Plotting a section of an hemisphere

I'm writing a little package in Mathematica for geology where a particular stone may be approximated as an hemisphere. Anyway this is a rough estimation because a real hemisphere has its height as ...
4
votes
2answers
453 views

Mathematica not plotting whole logarithmic function

I am trying to use the following input Plot[Log[E,x+1],{x,-50,50},PlotRange->50] however the output is: How can I adjust it so the line goes down to ...
3
votes
1answer
66 views

Creating a parallelizable DiscretePlot

To my knowledge, DiscretePlot cannot be parallelized, although one can simulate the default behavior of DiscretePlot and get the ...
7
votes
3answers
702 views

Smoothing ListContourPlot contours

I have some data of type {{x1, y1, f1}, {x2, y2, f2}, ...} and want to do ListContourPlot. However, there is a problem that the ...
0
votes
1answer
109 views

How to plot particular piecewise defined functions in mathematica

How to plot such functions in Mathematica? Let $a_0, p,g,c$ be any positive integers, defining: $$a_{n+1} = \begin{cases}\frac{a_n}{p} &, a_n \text{ divisible by p}\\ ga_n +c &, a_n \text{ ...
13
votes
4answers
2k views

Plotting Fourier spectrum versus frequency of a signal

I have looked around here, and i am sure this has been answered, but i don't understand it. The thing is, I have taken a introductory signal processing course, and we had to use Mathematica, and i had ...
2
votes
1answer
158 views

PlotLegends and ImageSize

I have Mathematica 9.0.1, and I have problems with PlotLegends breaking the ImageSize directive. I defined ...
0
votes
1answer
98 views

Why does evaluating an integral within a Plot expression take so long? [duplicate]

I want to evaluate Plot[Integrate[Sin[((1 + 1/2) x)] (1/(2 Sin[(x/2)]) - 1/x), {x, 0, t}], {t, 0, 5}] but it takes ages to load on Corei3 computer with ...
1
vote
1answer
90 views

Functions defined via inverse Laplace transform - plotting issue [closed]

I need to define a function $k(t,c_1,\alpha_1,c_2,\alpha_2)$ in the following manner: ...
1
vote
2answers
497 views

How to use ContourPlot3D for Piecewise 3D function

How would I plot in 3D: $\begin{cases} (4 - z^2) = x^2 + y^2, 2 \le z \le 4 \\ x^2 + y^2 = 4, -2 \le z \le 2 \end{cases}$. I tried http://reference.wolfram.com/mathematica/ref/Piecewise.html ...
0
votes
1answer
82 views

How to constrain the range of a plot o f a function to satisfy an inequality?

Given the function f[x_] := x^2, how can I plot f[x] over the region where f[x] >= 10 and ...
1
vote
1answer
122 views

How to replace a list with the result list after each iteration [closed]

I have some initial values such as L1 list: L1={10,20,30,40,50}; I want to use the L1 ...
0
votes
1answer
98 views

Plotting the discrete solution to a PDE

So I went through all the grunt work of solving a PDE in discrete form for a research project. Now I have a Temperature solution as a function of time and space: $$ T_{i}^{n+1}=\left( \dfrac ...
0
votes
1answer
95 views

Scaling the time axis of an interpolated function (as in a solution from NDSolve)

I'm wondering how I can change the units of the x (time) axis when plotting a solution from NDSolve. I have obtained three solutions to a system of differential equations, all of which exist over the ...
0
votes
1answer
76 views

Bar Chart: How to adjust the font size for the bar labels as the chart size is manipulated

I have data that represents the binding energy of oxygen on different surfaces. Each bar is a different transition metal, and the length of the bar is the binding energy of oxygen. How do I make the ...
4
votes
1answer
203 views

Creating a dynamic plot directly from the recurrence relation

I have the following recurrence relation that has no general solution: $$x(t+1) = \frac{x^2 + x(1-x)(1-sh)}{x^2 + 2x(1-x)(1-sh) + (1-x)^2(1-s)}$$ In Mathematica language it gives: ...
-8
votes
1answer
323 views

Plot The Cornu Parametric Spiral

How to plot the Cornu parametric Spiral in 3D With Mathematica. The 2D is quite easy. Thx. For more details you need to be familiar with the Cornu statement. $$\begin{cases} ...
1
vote
0answers
65 views

Finding undetermined coefficients with boundary conditions

I have 2 equations which are; To[x_] := c1 E^(-a1 x)/2 + c2 E^(a1 x)/2 + a2 Tu[x_] := c3 E^(-a3 x)/2 + c4 E^(a3 x)/2 Tu equals almost zero ...
3
votes
1answer
101 views

ListContourPlot memory problems?

I have a simple 3d dataset (size 7035 x 3, I put it on my site if you want to check) which I want to plot with ListContourPlot: ...
0
votes
1answer
493 views

representing triplet data set with color on 2d plot [duplicate]

I have a huge list of data in the form of triplets numbers (e.g. {x,y,z}) and I want 2d plot. In which I want to plot y vs x on which values of z should be shown with color depending on the value of z ...
0
votes
0answers
92 views

Visualizing 3D vector field on surface of sphere [duplicate]

I want to vizualize (quite complicated) 3D vector field which has both real and imaginary part and is expressed in spherical coordinates. I was thinking about expressing the field for certain r and ...