# All Questions

4 views

### Performance of custom color maps

In the question Is there an easy way to use Matteo Niccoli's perceptual color maps for 2D plots in Mathematica?, Jason B. shows how to use color maps such as Parula in Mathematica. However, I ...
6 views

### Major slowdown when using a ColorFunction with more than one named scheme

Earlier Kuba noted a major slowdown with code Simon Woods posted. Here is a simplified example. First a color function using two different named gradient schemes: ...
6 views

### What are all the Properties that ColorData supports?

The documentation for ColorData reads: Possible properties in ColorData["scheme","property"] include: ...
221 views
+50

### Find permutations with constraints without using Permutations

EDIT: To clarify, the bottleneck right now is available RAM, so any answer should keep that in mind (I cannot store all T! lists of length ...
552 views

### Probability problem — Rube Goldberg solution?

A user posted this question on StackOverflow which was closed as off topic: 3 people are playing a game with a standard 52 card deck. Each player is given 2 cards each, possible cards and their ...
38 views

### Estimating inherent parameters for projectile under influence of wind in 3D based on lists of measured data

The goal of this is to be able to estimate the drag constant $k$ and mass $m$ for a projectile based on measured landing coordinates $P$, start speed $v$ and launch angles $\varphi$ and $\theta$ ...
33 views

### How to solve and plot this 2nd order non linear ODE?

Is this the correct way to plot the solution of this ODE from $(-8, 8)$? $$y'' - (1 - (y')^2)y' + y = 0$$ ...
115 views

### How to Map a function with HoldAll attribute

First of all, I'm not sure about the title of this question, so please correct me if there is any title more sensible than mine. The problem is the following: I have a function f that checks if a ...
98 views

### Coloring an image with two Color schemes based on a Range

I would like to color an image generated from some data using two colorschemes based on two ranges of the data. This is my attempt. ...
20 views

### Fredholm Integral Equations

Please i'm having problem obtaining the solution of the.homogeneous Fredholm Integral Equation of the 2nd kind, with separable kernel.. I always get a zero if i use the normal method i was taught for ...
868 views

### Manipulate (Linux version of Mathematica)

I'm runnning Mathematica 9 on Ubuntu 11.10. After installing CDF player I still have problem (most of time) with Manipulate. Only way I'm able to change value of a ...
42 views

### How can I convert a Piecewise into a nested If?

For later conversion into a programming language where if is the only conditional construct, I would like to convert a Piecewise ...
17 views

### Mathematica on Linux Ubuntu: antialiasing issue

I'm working on a webMathematica application using a linux server (Ubuntu 12.0.4 LTS) with Xtightvnc. Even though the system administrator has done all the possible to set the anti-alising features, we ...
36 views

### SIR Model with Dynamic module

I am having trouble with generating a parametric plot with the following code: ...
56 views

### Como generar aleatoriamente listado de operaciones con racionales con seleccion multiple

Edit: Necesito que Mathematica me genere al azar una lista de operaciones (+,-,*,:) con numeros racionales . La cantidad de elementos de la lista asi como la dificultad de los racionales queda ...
28 views

### Export to JSON format specifically for MongoDB

It is a nice thing that, if you have a data as a list of rules (even nested), Mathematica can export them in JSON format. After generating useful data in Mathematica, Therefore, it seems it ought to ...
78 views

### Font style in Mathematica and .tex file

I am using Mathematica 8. I want to label the axes of figure in "Times" font. ...
27 views

### Solve For X inside arc-cos function (with division) [on hold]

Very basic but I've been stuck for more than 12 hours trying to solver this equation 20=360/(arccos(X/3200)*2) Can anyone solve X? and explain what exactly you ...
44 views

### Importing 2D array of image

Suppose images = {{1.jpg,2.jpg},{3.jpg,4.jpg}} Now I try to import all of them in level 2, Map[Import[#],image,{2}] Why Mathematica says it is invalid file? (error= Import::chtype)
294 views

### Finding solutions of polynomials system

Let $f_1,...,f_n$ be a set of polynomials in $x_1,...,x_n$ with rational coefficients. I need to check whether a system $$f_1=a_1,...,f_n=a_n$$ has a real solution for large enough count of points. ...
119 views

### How to set up a simple Monte Carlo Simulation

there is a 1% chance that there will be a scattering event, if there is a scattering event the direction of scattering will be determined by a random sample of the custom[a_] function and if there is ...
698 views

### Integro-differential eqn with double integral

I am looking at the following variation of a integro-differential, with y[0]=1. The output is not great, any solutions to this? ...
27 views

### RecurrenceTable [on hold]

I got an error saying ...
47 views

### Extract a part of Series

If I have the output of Series, in terms of powers of my variable $x$, what is the quickest way to extract a part of the series, say for example the terms from $x^2$ to $x^5$, excluding those with ...
37 views

### How can I import a pickled file?

I have a file generated from a python script that dumped a dataset into a pickle "data.pickle", I am at a loss as to how to Import the file, since "PICKLE" is not ...
43 views

### Infinite Sum with exclusion

From another question I tried to implement something like: Sum[r^(1 - l[n]) DD[n], {n, Complement[Range[1, Infinity], {4}]}] but this does not work because ...
29 views

### Truncate a sum in a 'smart' way

Consider a series like this: $$\sum_{n=1}^{\infty} (c_n r^{2-n/2}+d_n r^{-n/2})$$ Sum[c[n]r^(2-n/2)+d[n]r^(-n/2),{n,Infinity}] I want, now, to keep only the ...
75 views
+50

### Header and footer banners in Slide Show style

I would like to create Mathematica slide shows that contain several tailored, fixed banners as headers and footers, much as MS Powerpoint, MS Word, Apple Pages, and LaTeX documents allow one to ...
32 views

### How to do n-fold cross validation with Classify?

Other machine learning libraries have utilities to generate indices that can be used to generate dataset splits according to different cross validation strategies. How do I tell ...
1k views

### Sum or Product with Exclusions

Is there a built-in feature for handling things like: $$\sum_{\substack{i=0\\i\ne j}}^n\frac{a-a_i}{a_i-a_j}$$ and $$\prod_{\substack{i=0\\i\ne j}}^n\frac{a-a_i}{a_i-a_j}$$ or should I work out some ...
9 views

### Assigning some results after a solve procedure to the coefficients of a matrix

I have a matrix M[3,3]. After a solve procedure, I obtained these results. {{M[1, 2] -> Cos[ψ[t]], M[1, 3] -> 0, M[2, 3] -> 0, Cos[θ[t]] -> M[3, 1], M[3, 2] -> 0, M[3, 3] -> 1, M[2, 1] -> ...
16 views

### Extract the divergent/bounded part of a certain expression

Consider I have a power series which is function of $x$. A part of this expression is bounded when $x->\infty$, some remainder is on the other hand divergent when $x$ goes to infinity. What is the ...
40 views

### Interpolating a non-continuous set of points

I'm trying to create a pure function that I can feed into OutputResponse[ ] as the input u[t]. In order to do this, I've written code to create a square wave pulse train in the form of a collection of ...
60 views

### How do I use an image as a ChartLabel?

I'm trying to use an image as a ChartLabel and I'm getting strange results. Here is a bar chart, with labels, that looks ok: But when I try to replace the "A" ...
18 views

### Extract a term of Series output

Say I have the output of series, with all the coefficients of the different powers of my variable $x$. What is the quickest way of extracting the coefficient of the $n$-th power of $x$?
32 views

### How to use If to compare a function [on hold]

I'm trying to write a Manipulate demonstration where you can select one of a number of functions. At one point I need to test if the function chosen is a particular one, and it seems to work if the ...
30 views

### Calculating the rank of an abstract matrix

I'm trying to compute the rank of a 4x4 matrix with 4 parameters and 2 variables. I tried to calculate its rank under some assumptions on those conditions and I kept getting rank 4. So I did an ...
15 views

### Somebody imported .mdt files (3d graphics) in Mathematica?

Hello maybe someone did or import this format in math for subsequent presentation in 3D
36 views

### Unknown number of variables in a logical statement [on hold]

Resolve[ ForAll[{i, y[i]}, Implies[i >= 0 && i < 3 && Implies[i < 3, y[i] > 0], Sum[y[i], {i, 0, 2}]>0]]] returns ...
34 views

### Series identity with binomial coefficients [duplicate]

I have this apparently simple equation: ...
37 views

### how to reduce noise in time series data?how to do interpolation for missing value data?

i have done this coding to plot the data. the problem is some value is missing for certain date and the graph is not smooth and noisy. one way to smooth the data is by interpolation but i dont know ...
18 views

### Generating a C/C++ Code with a Non-Linear Vector Function [on hold]

In Mathematica, I have a vector RES = {f1,f2,f3, ..., f7} where f1 thru f7 are non-linear functions of my degrees of freedom: a1 thru a7. I know that I can use: ...
52 views

### Removing characters from non-strings

I have a large list of lists that contains mixed data, some real, some strings. The lists are of various lengths and depths. Some of the real data values have an asterisk appended to them, e.g.: ...
64 views

### How to solve a heat flow equation [on hold]

I am a beginner in Mathematica. I was wondering if anyone could give me some pointers as to how to solve following type of equations. During a particular time interval, ...
32 views

### FindMinimum's WorkingPrecision behaviour

I discovered the following behaviour when using FindMinimum for constrained optimization: ...
104 views

I am familiar with regular expressions in other languages (e.g., Perl, Python, ViM), but the Mathematica StringExpression is baffling me. I'd like to match strings ...
84 views

215 views

### Median household income for each county in Maryland

I found that Wolfram|Alpha knows the median household income for every county in the US. I wanted to get a list of all counties in Maryland, and the median income in each county. The only way I could ...
I'm trying to access my environment variables in Mathematica, but I get a Failed result every time. For example: $echo$USER jlconlin but in Mathematica I do: ...