2
votes
1answer
8 views

What is the right place for user-defined init.m?

What is the right folder to put a file init.m which is run after all other init.m files applied by the various components of Mathematica have done their job? I would like to use it to do something ...
1
vote
1answer
14 views

Change string date/time to be understandable for mathematica

I'm trying to convert a string of a data and time to be understandable for mathematica (I want to make time related plots). However, I can get my head around how to do this. For example: ...
3
votes
0answers
54 views

How does Mathematica use system environment variables?

Is there a common way in which environment variables are accessed, stored, or used by the kernel? Some standard practice used by Mma programmers? There are built-in functions for querying and setting ...
0
votes
1answer
15 views

Generate a sequency of names such as a1, a2, a3

How do I generate the sequency {disp1, disp2, disp3, ...}? I tried the following but it didn't give me what I expected: ...
3
votes
2answers
242 views

How to create a function like in Python

I want to call a function that would perform a function rather than assigning an expression to them. I.e. ...
0
votes
0answers
14 views

How to make a real number parameter go 2 decimal precision?

im new at community and im starting with mathematica I am now having a trouble with something very simple problem which for many of you might be really obvious In documentation "N" suppose to give me ...
14
votes
1answer
673 views

How can I conveniently call igraph through RLink?

Mathematica has lots of functions for working with graphs, but this functionality is not yet as mature as the igraph library. It is useful to have access to igraph from Mathematica, both for ...
1
vote
0answers
27 views

How to Plot with different styles different InterpolatingFunction [duplicate]

Im sorry for this question I'm new and it may be a stupid question, but I can't find nothing specific. I have these differential equations and NDSolve give me ...
0
votes
0answers
26 views

Autocorrelation issue

I am analysing time series and want to know if it is autocorrelated. I use AutocorrelationTest[data, 1] and get The data contains ...
0
votes
0answers
13 views

Mathematica 10 Endnote 7 with mac

Given the new updates, are EndNote 7 and Mathematica 10 compatible in mac?
0
votes
0answers
24 views

Exporting Code to pdf

I want to export Mathematica Input and Output code to pdf (for usage with Latex). I select the cells and use "Save selection as". However, the font size of the pdfs is to large for Latex usage and if ...
14
votes
2answers
1k views

Obtaining joint distributions and conditional distributions using Mathematica

I have two multivariate Gaussian distributions $p(x)$ and $p(z)$ with mean vectors $m_x$ and $m_z$, and covariance matrices $\Sigma_x$ and $\Sigma_z$. my model is a simple linear model $x = W z+n$ ...
0
votes
0answers
33 views

NMinimize ignores constraints

I have a problem with NMinimize - I try to minimize quite a complicated function and use a couple of constraints (the way it is shown in the documentation). Now, ...
0
votes
0answers
20 views

Can you import/include a header file in Mathematica?

I use a lot of physical constants and would like to put them into an include file (like blah.h in c) and import this / include it at the top of my worksheets. Is this possible? Thanks.
0
votes
0answers
26 views

Plotting function with small values in Mathematica [on hold]

I've got an issue in Mathematica, just can't figure it out, I've looked on any reference I have available. I am doing something basic, need to plot two functions together. However, my plot shows ...
5
votes
2answers
210 views

Is there something wrong with VertexConnectivity

As I noticed in the documentation VertexConnectivity is defined as the following The vertex connectivity of a graph $g$ is the smallest number of vertices whose ...
4
votes
2answers
93 views

Manipulate showing the trajectory of a particle

I'm trying to plot the trajectory of a particle: ...
4
votes
3answers
236 views

Finding volume of a segment

I'm still pretty new to Mathematica, so I would like to seek advice regarding a geometrical problem. I am currently trying to define that as an extra condition in the Mathematica code below. ...
1
vote
0answers
64 views

ListContourPlot in V10

It seems that I obtain different results when using ListContourPlot under V9 and V10. Using this datafile http://pastebin.com/2p4ew0NJ (modified to use pastebin), ...
10
votes
4answers
448 views

Can (compiled) matrix permanent evaluation be further sped-up?

Update II  Sample code for simulating boson-sampling experiments has been added (as an answer). This code exploits new Mathematica capabilities relating to both empirical and smooth ...
0
votes
0answers
54 views

Analytical solution for bound state energies of infinite well [on hold]

I am trying to find bound state energies assuming infinite potential. I have been told it can be done by analytically solving Right Hand Side and Left Hand Side of an equation such as: $E^{1/2} ...
5
votes
2answers
190 views

How to generate a chirped signal

As there is no ChirpSignal function in Mathematica, can anyone tell me how to write a custom function to generate a sinusoid with a frequency that changes ...
6
votes
1answer
97 views

Vertex displacement/merging in graph?

Given a Graph such as the one produced with the following code ...
9
votes
0answers
57 views

Bug(?) in version 10: Tooltip and ListPointPlot3D

Bug introduced in 10.0.0 The coordinates of a point in a three dimensional graph can be shown in a tooltip: ...
0
votes
0answers
49 views

Why does my code produce NDSolveValue::ndnum?

I keep getting the error shown below. It appears to be valid, but I am not sure why my I am getting it. ...
0
votes
1answer
67 views

Mathematica 8 remove black background from image

How do I do that in Mathemtaica 8? I have found on this site many options like RemoveBackground[], but they don't work in Math.8. Are there any options? Here is ...
1
vote
0answers
37 views

Simultaneous fitting to multiple data sets with multiple variables and some common parameters

I am trying to fit two data sets to a function model described below which share a few common parameters. Say I have two functions with some common parameter(s) ...
0
votes
1answer
47 views

How to find all roots of a complex number [duplicate]

Finding all roots, and I know there are four f them, of this (1 - i)^(1/4)
1
vote
2answers
68 views

Change Temporary Directory

How to change the value of $TemporaryDirectory ? I need to change it because there is not enough space on the C drive and the calculation seems to stop after a while !
1
vote
0answers
37 views

Is there a summation notation for the sum of products made two by two? [migrated]

I have the following expression: $$x_1x_2+x_1x_3+\dots+x_1x_n+x_2x_3+x_2x_4+x_2x_5+\dots+x_2x_n+\dots+x_{n-1}x_n$$
1
vote
1answer
54 views

Compile with modification of arguments' values

Is it possible to compile while changing the value of the arguments the function receives, instead of just creating new variables, and then returning those new variables,i.e., is it possible to pass ...
9
votes
2answers
895 views

Mathematica Package for Bayesian Networks

Are there any packages that allow the simulation of Bayesian Networks with Mathematica? I found what seemed to be a promising package (Dynamics) on a Brown University URL, ...
0
votes
1answer
48 views

Define a Recurrence Table involving other tables

I'm relatively new to using Mathematica. Previously I used Matlab, but lately I noticed that the numbers i got in both of them do not match (mostly it seems that Matlab lacks precision...). The ...
2
votes
2answers
112 views

Mathematica data structures for analysis [on hold]

I'm starting to learn Mathematica and one thing that has been bugging me is the apparent lack of a good structure for keeping data and metadata for analysis. Something along R's ...
3
votes
2answers
59 views

Why doesn't FullSimplify simplify expressions with DiracDelta?

I want to simplify a complicated expression with some Dirac delta distributions, but FullSimplify does not do what I want. Specifically, I want ...
165
votes
19answers
17k views

What are the most common pitfalls awaiting new users?

As you may already know, Mathematica is a wonderful piece of software. However, it has a few characteristics that tend to confuse new (and sometimes not-so-new) users. That can be clearly seen from ...
0
votes
0answers
22 views

using numerical value of NDSolve solution

I have two differential equations solved using NDSolve ...
5
votes
1answer
171 views

Why doesn't this pattern work? [on hold]

I want the in-built function Count to count the elements in a list which are greater than a value. Example: Count[{1, 1, 2, 3}, (# > 1.5) &] Why doesn't ...
0
votes
0answers
25 views

Minimization of a non-linear objective function subject to linear constraints

I have solved a linear program in Mathematica using the LinearProgramming function with arguments of the form LinearProgramming[c,m,{{b1,s1},{b2,s2},...}] i.e. ...
6
votes
1answer
70 views

How do I format the output to include the function definition?

To explain, I do most of my probability homework in Mathematica, and use the typesetting built into Mathematica to finish answers. Often, I want to output a function as the answer to a problem, but I ...
1
vote
1answer
34 views

How to take derivative of a tensor leading to kronecker delta? [duplicate]

I'm trying to write a Mathematica program to find derivatives such as the following simple example: Could you please help?
3
votes
2answers
76 views

Find all roots in range

Is there any way to check for all roots in a range? Jens' findAllRoots function is pretty good, but runs at approx. 10% of roots missed when I ran a quick check on ...
4
votes
2answers
335 views

Colorize Grayscale Image

I have a grayscale image that contains two objects. The grayscale pixel values can be divided into three intervals where two of them represent objects and the third represents the background. The ...
7
votes
5answers
675 views

Check if two lists are equal in any order

Suppose I have two lists, how can I efficiently check if the two lists are identical up to permutations of the elements? For example I would like the function to output: ...
1
vote
2answers
37 views

Change of basis for a rank 3 Cartesian tensor

I have a Cartesian tensor $\chi_{ijk}$ and I want to express the elements in terms of a new basis to get $\chi_{ijk}^\prime$. The transformation is represented using $a_{ij}$. The tensor transforms ...
14
votes
1answer
345 views

What is the real default CellEvaluationFunction?

The default CellEvaluationFunction is Identity but one can quickly see that this is handled specially as an equivalent function, ...
13
votes
1answer
269 views

Is garbage collection broken in version 10.0.0?

Bug introduced in 10.0.0 and fixed in 10.0.1 In version 10.0.0 under Windows I am observing the following behavior: ...
8
votes
1answer
133 views

Strange behavior of BinCounts

Bug introduced in 8.0 and fixed in 10.0.0 Just try this example: ...
12
votes
2answers
231 views

Strange behavior when using Row with packed arrays

Bug fixed in 10.0.0 Today I lost a lot of time with a strange behavior and I narrowed it down to this small piece of code: ...
24
votes
2answers
459 views

eigenvector bug?

Bug introduced in 7.0.1 or earlier and fixed in 10.0.0 I have a fairly simple $3\times3$ complex matrix, $$ M=\left( \begin{array}{ccc} \frac{7}{2}-\frac{i}{2} & -1+i & \frac{1}{2}+\frac{5 ...

15 30 50 per page