# All Questions

170 views

### How to create a recursive TreeGraph

How could I create a recursive tree graph, such as one defined by the following: A family of trees $T_n$ are defined recursively as follows, for all integers $n \ge 1$. The tree $T_1$ consists of a ...
163 views

### Apply an accumulative function to each column of a dataset

Given a dataset with many columns, how can apply a function (in this case Count[Missing_]) to each column? ...
79 views

### Smart use of ParallelMap over Plus

I'm looking for ways to speed up calculation of a integral with a many-terms integrant. The obvious way is to go in parallel. I was surprised, but for some tests integration by ...
100 views

### Accumulating elements of lists taking the criteria out of another list

In order to find the critical values for the significance of a discrete distribution, for example BinomialDistribution[20,0.6], i need a function which works on the ...
200 views

### Forcing solutions to avoid Root[]

I'm solving a system of ordinary non-homogeneous differential equations (4 equations). The solutions will include some algebraic equations solutions as known from text books due to the use of an eigen ...
309 views

### Plotting curves with different filling styles and gridlines? [duplicate]

Here's a plot of some lines with different styles of filling and one gridline displayed: ...
170 views

### Imposing constraints to NMinimize/NMaximize leads to wrong function values

I wrote a function that uses NMaximize to find certain parameters (using NelderMead simplex algorithm). My objective functional $J({x_i})$ is real-valued and its ...
558 views

### Random polyhedra walk

I would like to recreate ssch's random polyhedra random walk, which he posted in the chat. For convenience here it is again: This is my best attempt so far: You can download the notebook with ...
209 views

### Tooltip pointer in ParametricPlots

ParametricPlot[{ Cos[u]^v , u}, {v, 0, 1}, {u, 0, Pi/2 }, Mesh -> {5, 5}] ParametricPlot[Tootip[{ Cos[u]^v , u}, {v, 0, 1}], {u, 0, Pi/2 }] How to introduce ...
71 views

### RunScheduledTask and return the result

I created a task that removes itself when an external variable x,is changed: ...
77 views

### Optimising prime number test code

Is it possible to speed-up this code ? Also, It would be great if people could test this algorithm. I only have a Raspberry Pi to test it on, so I can't be certain it's not a strong probable prime ...
226 views

### How to sort the list of all possible 3-tuples of elements from list constrained by a condition?

I want to know if there's a way to impose desired condition on Tuple command output. I have generated a list of 3-tuple of elements from {1,2,3,4,5,6,7,8,9,10} ...
44 views

### Is association in mathematica ordered or not? [duplicate]

Does the association <|a -> 1, b -> 2, c -> 3|> in Mathematica have order or not? If I iterate the association multiple times, is it guaranteed that ...
53 views

### Combine nested list entries [closed]

I have a list with stock index data (which I load from a database) as follows: ...
158 views

### Compute expectation numerically

I want to compute this expectation numerically with Mathematica. I could not figure out how to solve it numerically. Could you please help me? E(x|p)=\sum _{i=0}^m \sum _{j=0}^m ...
402 views

### Mathematical morphology: removing text features from image, while keeping connectivity

I have this image of London's road networks. ...
165 views

99 views

...
104 views

### Tree-like nesting of function

Is there an elegant way to nest a function in a similar fashion to tree graphs; i.e., create and follow branches until some criterion is met (until we reach a leaf)? An example: We want to ...
477 views

### Count elements of a list

Let's create a random list n = 100; data = Table[{RandomReal[{0, 2}], RandomReal[{-1, 1}]}, {i, 0, n}] Now we divide the $(x,y)$ plane into four sectors with the ...
187 views

### Draw and Quantity

I'd like to use Quantity in my graphics, but I can't figure out how to do it even for a very simple Circle. ...
262 views

### How can I subtract one surface from another?

I have one surface for which I have an analytical solution, and another represented by a list of 3D points. My question is: how can I plot the part of one that lies outside the other? The first ...
113 views

### Transforming/exporting text to image

I have a string in a .txt which I process as follow: ...
138 views

### Manipulating list based on Euclidean distance

I have an array of 101 matrices. Each matrix contains information like id, position (x,y,z), time etc about a collection of particles, looks like this ...
112 views

386 views

### ContourPlot: format numbers in contour labels and legend

Can you suggest me a simple way to specify custom display format (for example ScientificForm) for such large values in contour labels and legend please? Thank you! ...
165 views

### White Lines in Contour Plot and 3D Plot

This is a follow up question to the original question here (has a solution). I am plotting another different total potentials and for this particular case the repulsive potential is a rectangle (open ...
57 views

### Execute code when it's saved [duplicate]

How do I execute code on save? This is a similar question: Running a package automatically when it's saved
158 views

### Plotting Intersecting Circles On A 2-D Plane

I am new to Mathematica and I would like to plot a number of circles all onto the same graph. I would like to visually observe which circles intersect each other. One constraint on all the circles is ...
663 views

### What is the difference between Composition (@*) and sequential applications (@)?

What is the difference between f@*g@*h@x and f@g@h@x Both evaluate to f[g[h[x]]] ...
334 views

### How can I tally continuous sequences in a list?

I have a stream of data like this: 0001100111100000111111001110000001111111111000000111000111110000... (I can represent them as a list, like in {0,0,0,1,1,...}, ...
265 views

### How to find critical points of trig function over an interval?

I need to find the critical points (maxima, minima and points of inflection) of the function $f(x)= \sin(x)+\ln(\frac{1}{4}x^2-\frac{1}{4}x+\frac{3}{2})$ over the interval $-3\leq x\leq5$. To do this ...
167 views

### How to convert string to integer list?

Saying we have a string: "1 2 3 4 5 6" I want to convert this to integer list. First I do: ...
157 views

### How to delete a pattern from String?

Having a string like : "{Aaaa -> a, Bbbb- > b, Cccc -> , Ddddd -> c, Eeeee -> , Fffff -> e}" I want to delete the parts that contain ...
64 views

### Plot of a R -> R^2 fuction [closed]

I have an algorithm that when you insert the parameter B, the function gives a solution {x,y}. How can I plot that? I tried ...
380 views

### Length of a word

Probably my problem is very simple but I couldn't have found a solution to it anywhere else. How can I find a word of a certain length using a DictionaryLookup ...