# Tag Info

13

You have to create your own mesh and you have to convert your u and v to mesh interpolations. (In the example in the documentation, NDSolveValue does this itself in constructing uif, vif.) Example: Needs["NDSolveFEM"] mesh = ToElementMesh[FullRegion[2], {{0, 5}, {0, 1}}]; u = Function[{x, y}, x (y - 0.5)/25]; v = Function[{x, y}, -x^2/50]; uif = ...

1

Here is a look at the color channel value mapping to the raster output: data = RandomReal[{0, 1}, {50, 50}]; mp = MatrixPlot[data, Mesh -> True, Frame -> False, ColorFunctionScaling -> True]; (out = Reverse[Cases[mp, _Raster, Infinity][[1, 1]]]); GraphicsRow@(ListPlot[ Transpose[{ Flatten[data], # }]] & /@ ...

1

Restrict the points using VectorPoints. Clear[myPoints, myVectors]; myPoints = Take[Select[ RandomVariate[ UniformDistribution[{{-1, 1}, {-1, 1}}], {1000}], .3 < Norm[#] < 1. &], 500]; myVectors = Table[{Cos[\[Theta] = RandomReal[{0, 2 \[Pi]}]], Sin[\[Theta]]}, {Length[myPoints]}]; ListVectorPlot[ Transpose[{myPoints, ...

1

You can use GraphLayout to arrange your Vertexes by SpringEmbedding or other function, then extract the full two-dimensional locations of the vertexes, then assign the x-coordinate of each vertex to your known or desired x coordinates and re-display the graph with these new vertex locations. g = CompleteGraph[20, GraphLayout -> ...

2

Just put the alternate functions in your MeshFunctions list: gr = ContourPlot3D[ x^2 + y^2 - z^2 == 0, {x, -2, 2}, {y, -2, 2}, {z, 0, 2}, Axes -> False, PlotPoints -> 30, MeshFunctions -> {Function[{x, y, z}, x], Function[{x, y, z}, 2 x + y]}, Mesh -> {{0.}}, MeshStyle -> Thick] But be sure to define your MeshFunctions ...

14

Update According to KennyColnago's advice, post-processing is not needed, as StreamColorFunction can handle it essentially by using VertexColors on Line-s: ListStreamPlot[ testdata, StreamPoints -> {samplePoints, Automatic, 10}, StreamStyle -> "Line", Background -> Black, ...

5

I'm sure there are lots of things one might try -- here is an attempt using some of the built in options that are available in ListStreamPlot: Show[Graphics[{Black, CountryData["USA", "Polygon"]}], ListStreamPlot[ Table[{{x, y}, Through[{Cos, Sin}[ WeatherData[{y, x}, "WindDirection"]]]}, {x, -140, -70, 5}, {y, 24, 50, 5}], StreamScale ...

3

On 10.0 for Mac OS X x86 (64-bit) (September 10, 2014) one uses: With[{f = # + 1/# &, center = 1/3 + 3 I/2, radius = 4/3}, ParametricPlot[ Through[{Re, Im}[f[center + r Exp[I \[Theta]]]]], {r, 0, radius}, {\[Theta], -\[Pi], \[Pi]}, PlotPoints -> 55, PlotRange -> All, Mesh -> Full]] So, Mesh seems to do the trick.

4

Use PlotTheme -> "Classic" to get V 9 output: With[ {f = # + 1/# &, center = 1/3 + 3 I/2, radius = 4/3}, ParametricPlot[Through[{Re, Im}[f[center + r Exp[I \[Theta]]]]], {r, 0, radius}, {\[Theta], -\[Pi], \[Pi]}, PlotPoints -> 30, PlotRange -> All, MaxRecursion -> 3, PlotTheme -> "Classic"] ] I am not sure why, might be a ...

20

Some function definitions first. AkimaInterpolation[] stolen from here (Thanks JM, wherever you are!): AkimaInterpolation[data_] := Module[{dy}, dy = #2/#1 & @@@ Differences[data]; Interpolation[Transpose[{List /@ data[[All, 1]], data[[All, -1]], With[{wp = Abs[#4 - #3], wm = Abs[#2 - #1]}, If[wp + wm == 0, (#2 + #3)/2, (wp #2 + wm ...

11

ListPlot[] isn't the "right" tool. It can be done with Epilog ->, but it's more natural to use Graphics[] and Nearest[]: (* Generate a distribution similar to your example *) n = 1000; rs = RandomVariate[TransformedDistribution[Sqrt@x,x\[Distributed] UniformDistribution[{.1, 1}]], n]; phis = RandomReal[{0, 2 Pi}, n]; pts = #1 {Cos@#2, Sin@#2} & @@@ ...

Top 50 recent answers are included