Questions tagged [graphics]

Questions on the construction of 2D and 3D graphics through the direct use of primitives, directives, and functions. Include the graphics3d tag for questions specifically on 3D graphics. This tag is not to be used for basic questions on visualizing functions and lists using the various flavors of Plot commands.

Filter by
Sorted by
Tagged with
14
votes
4answers
3k views

Plot a 2D vector path onto a surface

In my calculus 3 course, we're studying gradients and have a project that takes a combination of 3D Gaussian radial surfaces and a basic parametric path $r(t) = \{x(t),y(t)\}$ to see how the gradient ...
31
votes
1answer
547 views

Is there a way to access the (lexically) current colour inside Graphics?

Note that this is not a duplicate of the question over there. That one asks for a given point, while I'm asking about the lexical structure (which, of course, is not directly related to any point in ...
37
votes
4answers
5k views

How to create a wind rose with Mathematica?

I am trying to plot wind rose in Mathematica, but have no idea how to do this. Any suggestions ?
17
votes
2answers
697 views

Allow multiple GUI elements to react dynamically to interaction with a single element

I was looking at how to reproduce the interactivity in this visualization (the layout can be done like this). Hovering a node with the mouse highlights all edges that are connected to it. How can we ...
13
votes
3answers
8k views

Labeling points of intersection between plots

There are several answers where Mathematica used mesh points to show graphically where curve intersections exist. For example: Marking points of intersection between two curves or Is there a better ...
20
votes
8answers
3k views

How can I create a rectangular graphic with curved edges?

I want to make some button shaped graphics that would essentially be a rectangular shape with curved edges. In the example below I have used Polygon rather than <...
21
votes
1answer
1k views

Transparent textures don't show

EDIT For now, I'm going to accept Brett's answer. It's a way to get transparency back by having 3D calculations done in software instead of hardware. It addresses the symptoms but not the causes. ...
18
votes
4answers
828 views

Can TreeForm be displayed “sideways”?

One recurrent problem I'm having with displays generated with TreeForm is that the expressions to be so displayed often at least one level with many (> 20) nodes at,...
19
votes
5answers
8k views

Labeling a bar chart, changing how rotated labels are centered

I'm trying to label a bar chart with rotated labels see this simple example: ...
15
votes
3answers
3k views

How can I ensure graphics exported in WMF format don't have text-spacing problems?

A lot of my work involves manipulating data, drawing a pretty plot of it and then inserting that graphic into a report written in Microsoft Word, under Windows.1 The fun comes with the exporting part. ...
14
votes
1answer
892 views

Can a LatticeData image be displayed in a space filled fashion

I'd like a FaceCenteredCubic image as in the in LatticeData docs, but space packed, and cropped on all the boundaries, so that it illustrates the geometry of the calculation that leads to the $\pi/\...
33
votes
1answer
2k views

What is wrong with triangle PlotMarkers in v.10.0.0?

Bug introduced in 10.0.0 and fixed in 10.0.1 In Mathematica 10.0.0 we have built-in graphical triangle PlotMarkers. Let us look closer on them: ...
15
votes
4answers
2k views

Is it Possible to change dashes into circles with Plot command?

Is it possible to change the Dashed Style of a curve into circles with Plot command ? ...
21
votes
4answers
9k views

How do I draw a DensityPlot in polar coordinates?

I am trying to plot $J_m(\chi_{mn} r) \cos(m\phi),$ where $J_m(\chi_{mn}) =0,$ as a DensityPlot in polar coordinates (solution to 2D wave equation in polar ...
10
votes
3answers
1k views

How to ensure that Polygon[list] plots a simple polygon?

Consider the following code which plots a triangle. p = {{0, 0}, {.2, 0}, {0, .2}}; {Cyan, Polygon[Dynamic[p]]} // Graphics Then adding (for example) ...
9
votes
2answers
5k views

Formatting Ticks and FrameTicks labels with a function

Is there a convenient way to format tick labels? In this example I would like to use the default Mathematica tick intervals, but simply convert the X axis labels to strings with "s" added. As you ...
5
votes
1answer
2k views

How do I reverse the axis in ParametricPlot?

In astronomy, right ascension is usually plotted with positive values that increase from right to left. I have seen discussions of successful and unsuccessful attempts to reverse the order of an axis ...
9
votes
1answer
3k views

How does epilog position work in logplots?

I'm trying to use Epilog in my plots but the way that Epilog uses coordinate positions isn't making sense to me. As a minimal ...
63
votes
4answers
4k views

Speeding up this fractal-generating code

I used the code below (which is a sample from this gist containing more similar code) in my answer to my own question about Mandelbrot-like sets for functions other than the simple quadratic on Math....
32
votes
1answer
6k views

Autorotating 3D plots

These days, I have to produce quite a few 3D surface plots (mostly functions of the type $\rho(\theta,\phi)$ plotted with SphericalPlot3D). To exchange these ...
30
votes
5answers
3k views

Rounding the Corners of a Shape

I was wondering whether there is an option in Mathematica that enables me to smooth the corners of a shape. The example I want to start with is the pentagon. This can be crudely specified as ...
33
votes
3answers
7k views

How do I add arrowheads to circular arcs?

I have figures containing several arcs showing the extend of angular measures, and would like to indicate the directions in which angles are measured with arrowheads. How do I add an arrowhead at the "...
44
votes
9answers
10k views

How to draw a spring?

I am new to Mathematica and have recently been exploring graphical animations. So I was experimenting with simple concepts in periodic motion and hence wondered how can I draw a simple spring? Is ...
21
votes
4answers
2k views

Find the minima and maxima of a list

I have a list, such as: ...
26
votes
3answers
6k views

how to make graphic timelines in mathematica

Hi does anyone know how to make timelines with mathematica? Something like that would be great!
16
votes
3answers
2k views

How to make Mathematica graphs in Microsoft Word independent from Mathematica?

When I open a .docx file containing Mathematica graphs on a computer without Mathematica software installed, the graphs look corrupted. For example, ...
15
votes
1answer
7k views

Image Processing: Finding Orientation and Position of Symmetry Axes

Background I'm currently toying with Principles of Design by Charlotte Jirousek in order to learn some basics of image processing. As main principals she suggests Balance, Proportion, Rhythm, ...
23
votes
3answers
17k views

How to express ticks in scientific form? [duplicate]

I want to express the ticks in scientific form. I tried two ways as following ...
25
votes
1answer
1k views

Convert Graphics3D containing BSpline to polygon primitives for export to 3DS?

Graphics3D[] objects created with BSpline functions will not export to 3DS format, which only supports the more basic primitives. Is there any straightforward way ...
19
votes
2answers
2k views

Change base font for all graphics objects

How can I change the base font style for all graphics objects, including the ones generated using plotting functions? I would like to change this a single time and have it affect all graphics ...
19
votes
3answers
668 views

Generic contour smoothing with shading

Context It would be nice to have a function which smooths contours plots once they have been done. There are various solutions which involve smoothing the data before making the contours, but here I ...
16
votes
2answers
882 views

Plotting an additional axis with ticks

When preparing non-standard graphs, it is common that one needs an "extra" axis, parallel but displaced from a traditional axis. This might happen in many cases: When you want to plot two curves ...
12
votes
2answers
2k views

StreamPlot for Bifurcation Diagram

When we do a StreamPlot, I want to show the bifurcation when $a = 0$ transitions to $a >0$, but do not see a better way to do this than the following. ...
20
votes
2answers
1k views

Equidistant points on a polyline

Set of 2D-points connected by a polyline B-spline function: ...
13
votes
1answer
2k views

Remove the extra white-space padding introduced by implicit use of Inset in GraphicsColumn

Simple Context This is a question about understanding how Inset really works and how GraphicsColumn and the like automatically ...
12
votes
4answers
2k views

Dynamic Epicycles

Thanks to all the thorough answers and comments, I've written the following code for an arbitrary number of epicycles. However, when I apply the formula $\gamma(t)=e^{it}+\frac{1}{2}e^{7it}+\frac{i}{3}...
22
votes
3answers
885 views

Memory Leak in Frontend - anyone know a workaround?

When using Rasterize on a Graphics expression composed of many differently coloured Graphics objects memory is allocated in the frontend which is then not released or reused when a similar graphic ...
12
votes
4answers
5k views

Creating an animation illustrating the time-evolution of a pre-computed orbit

As the title says, I would like to use Mathematica in order to create an animation depicting the time-evolution of a three-dimensional (3D) orbit. To begin with, I have an ASCII file which contains ...
12
votes
2answers
872 views

How can I prevent ColorFunction from disabling antialiasing in graphics?

When I use ColorFunction, the appearance of my plots is ruined, changing from this which has the normal smooth lines and antialiased fonts, to this in which the ...
17
votes
3answers
2k views

PDF exports of ArrayPlot's are fuzzy (OS X)

This is fixed for in version 10.3 by disabling interpolation in the PDF (see Romwell's answer). However, Preview.app on OS X simply ignores this flag. Thus, in practice, the problem remains for all ...
13
votes
1answer
781 views

How to discretize a BezierCurve?

Bug introduced in version 10.0 and fixed in version 12.0 DiscretizeGraphics is new in 10.0. I need to create a discretized region from a ...
12
votes
3answers
3k views

How can I completely remove the ListAnimate controls?

I want to use ListAnimate to show an animation but I want to remove the slider and all of the buttons from the top and show the animation panel only. There is an <...
12
votes
8answers
5k views

How to make a resizable chess board?

For some reason I need to create a chess board. I can create a chess board by following command: ...
12
votes
2answers
2k views

How To interactively create a Polygon in a Graphic?

Background: suppose I start with the following (working) snippet. Manipulate[Graphics[Line[{{0, 0}, p}], PlotRange -> 2], {{p, {1, 1}}, Locator}] Ideally, I ...
15
votes
1answer
26k views

Adding a point to an already existing graphic

This is just a follow-up of this post: Animating a rotating disk Part of the code is: ...
14
votes
2answers
1k views

Dimensions of the results of Text[] within Graphics[]

Is there a way to get the dimensions that the results of a Text[] will occupy within a Graphics[]? Specifically, if I run ...
13
votes
2answers
614 views

Anti-aliasing with the multiple-object form of Polygon?

Observe: rand = RandomReal[1, {4, 3, 2}]; Graphics @ Polygon @ rand Graphics[Polygon /@ rand] I am losing anti-aliasing ...
10
votes
4answers
3k views

Coloring Points in a Plot, based on their position in the list

Before I describe the question, I'd like to say that I've seen the excellent answers posted here but have not managed to get them to work for my own data. I have a list of values that I would like to ...
6
votes
1answer
291 views

Is it possible to render Graphics with more than “Byte” bitdepth?

I wonder is it possible to render Graphics in Mathematica with bitdepth higher than "Byte" which is the maximum bitdepth ...
5
votes
2answers
3k views

Add coordinate axes to a 3D plot of concentric spheres

I want to add coordinate axis to a figure of nested spheres. I have the command. ...

1 2
3
4 5
23