Mathematica Weekly Newsletter
Mathematica Weekly Newsletter

Top new questions this week:

2D random walk within a bounded area

I want to simulate a random walk on two dimension in a bounded area such as a square or circle. I am thinking of using If statement to define a boundary. Is there a better way to define a bounded …

random geometry conditional  
asked by yashar 20 votes
answered by Pickett 23 votes

How to understand the usage of Inner and Outer figuratively?

Description: In Mathematica the functions like Thread, Inner, Outer etc. are very important and are used frequently. For the function Thread: ThreadUsage1: Thread[f[{a, b, c}]] {f[a], f[b], …

programming inner  
asked by Tangshutao 15 votes
answered by Timothy Wofford 5 votes

"Indexing" a vector

I need to "index" a vector according to the first occurence of its distinct elements. I have written index[list_] := Module[{x = list, p}, p = Flatten /@ Map[Position[x, #] &, …

matrix algorithm  
asked by eldo 13 votes
answered by Mr.Wizard 11 votes

Why does Mathematica simplify $x/x\to1$?

If I enter x/x, I get 1. Such behavior leads to this: Simplify[D[Sqrt[x^2], x, x]] 0 The same would be even if I use Together instead of Simplify. One could then think that $\sqrt{x^2}$ is …

simplifying-expressions assumptions  
asked by Ruslan 13 votes
answered by Jens 6 votes

Export Plots to PNG in Printout Style

When creating a plot in Mathematica 10 (OS X 10.9.4 and Win 7) the FrameLabel and Ticks are greyish and only the Frame itself is black (see Screenshot bellow). Only when exporting the plot to PDF all …

plotting export pdf-format rasterize  
asked by theDriver 12 votes
answered by denizb 11 votes

Incompatible InterpolatingFunction between V9 (and earlier) and V10

I am encountering compatibility issues when loading DumpSave(d) definitions in V10 that have been created with earlier versions. V10 appears to be unable to digest `InterpolatingFunction from earlier …

interpolation version-10 backward-compatibility  
asked by Markus Roellig 11 votes
answered by Mr.Wizard 7 votes

Why isn't Lookup treated like other symbols?

With Mathematica 10, I wanted to overload Lookup using TagSetDelayed, but it doesn't work. For instance, if I define two objects with head TempHead t1 = TempHead[a -> 1, b -> 2, c -> 3]; t2 …

functions programming upvalues  
asked by shopper 10 votes
answered by RunnyKine 8 votes

Greatest hits from previous weeks:

Get a "step by step" evaluation in Mathematica

Is it possible in Mathematica to get a step-by-step evaluation of some functions; that's to say, outputting not only the result but all the stages that have led to it? Example : Let's say I want to …

evaluation interactive  
asked by Skydreamer 53 votes
answered by J. M. 44 votes

How can I add drop shadows and specular highlights to 2D graphics?

I thought I'd share some code in the form of a self-answered question, but other answers are of course welcome. Drop shadows are a familiar visual effect, giving the impression of a graphical element …

graphics image-processing  
asked by Simon Woods 33 votes
answered by Simon Woods 37 votes

Can you answer these?

Wavelet expansion of given function (as opposed to DWT of given data)

To illustrate, say I take the following function (the reason for the square root will be apparent soon) dist = NormalDistribution[0.5,0.1]; f[x_] := Sqrt[PDF[dist,x]]; Then I can grab the Haar …

wavelet-analysis  
asked by caya 2 votes

Problem with hole filling using filledCurveToPolygons3D in MMA 10

I successfully used the filledCurveToPolygons3D function to create Graphics3D text in MMA 9 on a Windows 7 PC; see: How can I create a 3D FilledCurve object? However, when I installed MMA 10 on …

graphics  
asked by JohnS 2 votes

OpenCL vs. CUDA with Mathematica

I am thinking about using GPU programming with Mathematica using a MacBook Pro with a NVIDIA GPU. At this page, the Mathematica documentation says "Programming OpenCL in the Wolfram Language is simple …

parallel  
asked by Ted Ersek 2 votes
Subscribe to more Stack Exchange newsletters


Unsubscribe from this newsletter or change your email preferences by visiting your subscriptions page on stackexchange.com.

Questions? Comments? Let us know on our feedback site. If you no longer want to receive mail from Stack Exchange, unsubscribe from all stackexchange.com emails.

Stack Exchange, Inc. 110 William St, 28th Floor, NY NY 10038 <3