# All Questions

44 views

### How should I provide Dataset slot names in function definitions? [on hold]

Say I have a Dataset like the following: ...
37 views

### ColorFunction - custom colors and scaling

I am trying to implement my own colors and scaling into the ColorFunction which I use in ListDensityPlot. I have several lists of 2D values which I plot in multiple images and I want to scale the data ...
46 views

### Optimization in MMA for time resolved spectroscopy

I want to fit some spectroscopic data with a model. I detect the fluorescence of something over different wavelengths. The detection over each wavelength is one data set in time. The lifetimes of ...
41 views

### How to display a list using numerical values? [duplicate]

Suppose I compute the eigenvectors of a matrix like this Eigenvectors [{{3, 2, 3, 1}, {2, 3, 1, 1}, {0, 0, 2, 1}, {2, 3, 2, 1}}] The result I get looks like: ...
34 views

### how do I multiply two arrays in Javascript? [on hold]

I want to multiply two arrays, as in element per element: [1,2,3,4,5] * [2,3,4,5,6] = [2,6,12,25,30] I am new to JS and just have no clue... Thanks, Pam
39 views

### Multiway Systems Rules List Management

I'm working with a multiway system and I have a number of different mutation rule lists. I need an efficient way of managing which rule lists I apply. Here is the basic multiway system code that I'm ...
23 views

### ErrorListPlot Not Plotting

I'm on Mathematica 6.0, it's the copy my school gave me for a lab course. ErrorListPlot produces a graph, but there is nothing on it. I have checked the table constructed using ErrorBar and it's good. ...
115 views

### How to do algebra on unsolved integrals?

I am working with functions calculated from a set of general basis functions. ...
39 views

### How to append data in an already existing data .txt file in newline or in tab separtion?

Say I have an already existing .txt file containing data in the following format. $a \qquad b$ Now at different times I will successively have data like ...
34 views

### Understanding TransformedDistribution behavior on two similar lines of code

The two following lines of code does not give the same output. Mathematica manages to calculate the first one but fails to calculate the second one. ...
39 views

### How to get grid items with a gradient background to behave well?

I have a table that looks something like this ...
106 views

### Compute the average distance from the base of a rectangular pyramid to its apex

How can I compute the average distance from the base of a rectangular pyramid to its apex? For example, if the base of the pyramid is 30 feet by 8 feet, and the height of the pyramid is 12 feet, then ...
48 views

### Usage of @ symbol in Mathematica [duplicate]

What is the purpose of @ symbol? Also, I would appreciate if somebody could provide a webpage where such functional special symbols are documented
119 views

### Symbolic combinations

If I have 3 lists: {a,a},{b,b},{c,c}, then the desired output is ...
372 views

### Phase portrait on a cylinder

It is very nice and very easy to make a sketch of a phase portrait with StreamPlot. For example, for the classical pendulum, defined by $$\dot x=y,\\ \dot y=-\sin x,$$ The code ...
217 views

### Quick way to tell if matrix is integer-only?

What's the most shortest one-liner code to tell whether a matrix is integer-only? I've come up with: Length@Cases[A // Flatten, _?(Not@*IntegerQ)] == 0 but ...
50 views

### Include more padding between tick marks and plot [duplicate]

How can I modify the code below to add some padding between my tick marks and 3D plot? It is not a problem in this example, but often my tick marks collide with my axes. ...
49 views

### Clustering image data by intensity and position

I'd like to apply FindClusters or ClusteringComponents to image data of an indistinct edge, with the goal of segmenting the ...
46 views

### Temporary variable not removed in Mathematica 10

In Mathematica 10, the documentation still states that a symbol with attribute Temporary will automatically be removed when it is no longer needed. Now consider ...
34 views

### Exporting mixed data of matrices and vectors / lists

thank you for reading my question. I have a problem trying to export mixed data from Mathematica. I have different matrices and vectors, which should be combined to a output file. Here a ...
44 views

### How to get data from DB into dataset with keys

I'm a Mathematica newbie and I have the following problem: I connect to a Oracle DB and read out a set of variables, further on I want to histogram some of the variables. A Dataset seems to be the ...
89 views

### How to separate factors by dependent variables (arguments)?

How can I separate factors in an expression by their dependent variables? For example: expr = b * c[2] * a[x] * 2 * x^2 * g[x,y] * z[r] * D[q[x], {x, 4}]; I ...
50 views

### PenaltyFunction Option in NMinimize

I am curious if anybody has some experience in using the built-in Option "PenaltyFunction" in any of the numerical optimization functions like NMinimize. According to the documentation the user ...
59 views

### High-Precision NSolve

I need to calculate the intersection of two curves f1[x_] := ((Zl ρ ) Exp[-x]) f2[x_] := (α k e^2 /x^2) Where ...
15 views

### Numeric-type attributes for symbols (analog of NumericFunction)

Is there an attribute for symbols that makes NumericQ give True? For example Pi and ...
83 views

### How to extract arguments of functions in an expression?

How can I extract the argument of a function in an expression? expr=b[c]; I need some f[expr] that will return c. d[f[expr]] -> d[c]
129 views

### Plotting Integral equation

I want to plot the following indefinite integral : $C_l^{CC}=\int k^2\mathrm{d}k\: [e^{-2k^{2}}P_{Cl}^2(k\eta)|\dot{h}(\eta)|^2]$ with k from 0 to some large value (considered to be $\infty$), ...
9 views

### Difference Equation System constructed with SetDelayed: How I can set Non-exploding break?

I have a Difference Equation System constructed with SetDelayed. The system is like as follow. ...
38 views

### How to use Expected values in symbolic solving

How can I create a function that brackets off terms of an expectation value? For example, I have : f = a[x] + c1*b[x] + c2*c[x]; g = Expand[f*f]; ...
101 views

### Making a list of rules form the list of elements

Starting from the list: {f[q1, q2], f[q3, q4], g[q1], g[q2, q3, q4], d[k1 - q1], d[k2 - q2 - q3 -q4]} I would like to get the result: ...
92 views

### Problem on limit involving complex numbers

I have $${\frac{(6 k+1)^{k}}{(2 k+5)^{k}}}*(z-2 i)^k$$ and I need to find it's limit for $k$ approaching infinity. ...
35 views

### what's the meaning of “-mathlink” as part of Arg for LinkLaunch?

LinkLaunch["MathKernel -mathlink"] LinkLaunch["MathKernel"] The both code line above can launch a MathKernel. What's the difference of them? what's the meaning of ...
65 views

### Scale coloring of ContourPlot

The answer given here solved how to use the same color scale across multiple plots within the function ListContourPlot. I can't for the life of me map this solution onto the function ContourPlot that ...
47 views

### Display trailing zeros in ticks

When I specify tick marks in ArrayPlot I want to keep the number of trailing zero's that I specify. One work around is to use a label for that tick mark (i.e. Ticks->{0.8,0.9,{1.0,"1.0"},1.1,1.2}), ...
34 views

### ChartLegends only displays the last two legends in the list

I would like to add 4 legends on a simple bar chart below, but only the last 2 legends appear on the graph. ...
25 views

### How to set the step in NMinimize

I want to fit multiple data sets with 104 variables. I use NMinimize to do that. I minimize the difference between data and my objective function. How can I tell ...
63 views

### RegionPlot with PlotRange vs RegionPlot with domain

Consider you want to plot R = ImplicitRegion[x > 0 && y == -((5 x)/3), {x, y}]; In ContourPlot of an ImplicitRegion defined by the intersecton of ...
64 views

### Plotting a function in {X(Y),Y} space

The code below generates some data and defines a function f[x,cb]:=NMaximize[expr,x] that upon being evaluated returns: {function value at max $x$,the function maximizing $x$}. ...
165 views

### Is there a way to use Table[] without having to calculate my function twice?

I'm trying to use Table[] more to be more in the spirit of Mathematica. So for example, I might replace this piece of code: ...
64 views

### Raster to Image conversion problem

There are 3 ways to convert a Raster into an Image : only 1 works for me with version 10.0.1, and 2 work with version 9 (same computer, OS X 10.9.5) Has anyone the same problem or is it localized to ...
99 views

### Neighbourhood - Calculations

SeedRandom[0]; n = 5; (m = N @ RandomInteger[{1, 3}, {n, n}]) // MatrixForm result1 = MeanFilter[m, 1] // MatrixForm ...
27 views

### Max iterations in K-means clustering algorithm

I want to use k-means for clustering. I have used the ClusteringComponents function but I said how can I control the max-iteration for k-means ?
57 views

### Tangled up in sequences and recurrence relations

I took a trip through sequences and recurrence relations and I got tangled up since the documentation didn't help much. I'm sure you can. Given a sequence ...
56 views

### Finding the equation for the upper frontier of the convex hull of a 2 dimensional set of points

Suppose you have ...
74 views

### Use separate options for different elements in Show

I have a few plots of different type. plot1 has gridlines and the rest do not. I use the option Method -> {"GridLinesInFront" -> True}] when plotting plot1. When I use Show to combine the plots the ...
47 views

### Set the same color scale across multiple ListContourPlots?

This is probably straightforward - but how would I set the same color scale across multiple ListContourPlots? if I have values from 10 to 25 on one ListContourPlot and values from 40 to 100 on ...
60 views

### NIntegrate on tetrahedron

I've been trying to numerically calculate an integral in a tetrahedron of a discretized domain. In some cases when I specify a method I've been getting the error message NIntegrate::femonly ...
14 views

I have a .NET program which will connect to MathKernel. When the program runs, there will be a icon of MathKernel on the taskbar. ...