1
vote
0answers
6 views
Performance of Dispatch and lists of Rules
First of all, I have seen the question "Why is this parallel evaluation with Dispatch[] so slow?", but that seems to be a different matter.
My question arose when I tried to answer this question by ...
3
votes
1answer
25 views
Question about usage of Style as Dynamic object
I saw a Dynamic snippet in this answer, which wrote
...
0
votes
0answers
25 views
Question regarding function definition overloading / argument passing test
It is possible to define function dependently to passed argument type or condition this argument fulfills (somewhat like overloading):
...
0
votes
1answer
34 views
Weird vertical line when trying to plot a histogram
I'm trying to plot a histogram of a few data points and overlay a plot on it (it's a fit of a geometric distribution to my data). The weird thing is that a vertical line appears always next to the ...
1
vote
1answer
41 views
How to draw tiles with different height?
I have a random matrix RandomReal[{1,2},{20,20}], whose elements represent the height a tile. The cross sections of each tile are square and identical, viz, 10x10. ...
0
votes
1answer
29 views
Manipulating plot of random iterated function system fractal
I'm generating the Sierpinski Gasket by implementing a chaos game in mathematica. What I'd like to do is create an interactive manipulation with a slider, whereby moving it forward, plots all the ...
0
votes
0answers
26 views
FindRoot runs out of memory in Windows but not on Mac
I am using FindRoot to find solutions to a large, highly oscillatory equation which I generate using other code. When I run FindRoot in Mathematica 8 on my old macbook with OS 10.6, 1 GB Ram it takes ...
0
votes
1answer
74 views
Using Fors and Ifs
So, I am new to Mathematica, and I am trying to write something that involves taking values from one array and separating them into two different arrays. My code for doing this is:
...
1
vote
0answers
51 views
Precision of a complex number
In an output I'm getting a number like -0.33998187034939803 + 0.I. Finding ...
6
votes
1answer
56 views
create function that behaves like continuedFraction [duplicate]
I'm just starting to learn Mathematica and I got stuck at this question. This a noob question but please help.
I need to define a function named continuedFraction that takes user input of type list ...
12
votes
2answers
146 views
Why is there no PositionFunction in Mathematica?
Too often I have seen the programs of inexperienced users greatly slowed by using Position in an iterative fashion, when far faster would have been to compute a ...
7
votes
1answer
118 views
How can I detect an ellipse in a photo?
I tried to detect the rim of the following cup as an ellipse.
I've tried the solutions given in How to find circular objects in an image? to detect the ellipse, but the detection result was not ...
3
votes
1answer
37 views
How can I use Manipulate[] to click on a Graphics3D output and generate $(x,y)$ outputs on a projection plane parallel to my screen?
Say I have some Graphics3D object that I'm looking at from a top down perspective, e.g.:
...
0
votes
0answers
21 views
How do I automatically “trim” the bounding box for a Graphics3D output? [duplicate]
I noticed that, provided some Graphics3D output scaled with ImageSize, I can get rid of a lot of the empty space around the graphic by right-clicking and then selecting "Trim Bounding Box". Thinking ...
3
votes
1answer
50 views
undisputed FrontEndTokenExecute
Thanks to that great topic, I've found FrontEndToken i was looking for:
"DeleteGeneratedCells". Well it is also written in ...
-1
votes
1answer
69 views
How to insert big list of Data in DB?
I have a list of values with length is 60000.Earlier I used this list in my App by using ...
2
votes
1answer
46 views
How to keep ItemSize effect when export to HTML
Here's the simple code
Grid[Table[Item[1,ItemSize->{5,10}],{2},{2}],ItemSize->{5,10},Background->Red]
Save the output cell as .html file, ...
-3
votes
0answers
53 views
How to use older code in the latest release [closed]
I have some notebook files developed with an earlier version of Mathematica, but I encounter a lot of errors when running the program in version 9. The errors are as follows:
...
2
votes
0answers
47 views
Speeding up a numerical constrained quadratic optimization
I'm trying to solve a quadratic optimization problem in 35 variables, $\vec{α} = \left< α_1, \ldots, α_{35}\right>$:
$$
\begin{aligned}
&\operatorname*{maximize}_\vec{α}&&1.0\cdot ...
5
votes
1answer
90 views
Dynamic graph visualisation using JLink/Java and GraphStream
Visualising the addition of new nodes and edges to a graph to 'watch it grow' is to something Mathematica is not suited to by default. However this type of animation really helps convey the emergence ...
9
votes
0answers
109 views
5
votes
0answers
30 views
Setting OperatorSubstitution to False has issues with PDF and EPS exports. Are these bugs?
In Plot, I would like to use my own font, eg Inconsolata, for operators such as ×, so I set OperatorSubstitution to ...
-8
votes
0answers
73 views
Schrödinger equation in cylindrical coordinates [closed]
How can one numerically solve the nonlinear Schrödinger equation in cylindrical coordinates using Mathematica?
4
votes
1answer
74 views
Problems with RootLocusPlot
I am having some trouble to understand how the RootLocusPlot works (options, drawing and etc.)
Here is an example
...
3
votes
1answer
60 views
Problem with the Plot of Functions and PlotLegends
For some odd reason the PlotLegends output is not as expected.
...
1
vote
0answers
67 views
Solar System Orbital Parameters [duplicate]
I recently made an n-body simulation and thought it would be interesting to try and model it on the interior of our solar system (Sun to Mars), but I cannot find initial conditions for such an ...
6
votes
0answers
75 views
How to run an external program in parallel with a Mathematica package?
Under Mathematica 8 (Linux x84_64) I was able to run an external program in parallel from a Mathematica package. However this procedure breaks down under Mathematica 9.
Within my Mathematica package ...
0
votes
0answers
36 views
Manipulate NDSolve with Constants [closed]
I am trying to solve this system of equations. I am running into an error that I cannot quite figure out. In this code, I use the constants ktotal and xtotal, where ktotal is the total amount of the ...
1
vote
2answers
51 views
Counting a cardinality of a subset satisfying special property
Suppose that we have a set of 9 2-dimensional vectors $c$ by
m=3;
n=2;
c=Tuples[Range[m],n];
We want to define a subset $S$ of vectors in $c$ by the following:
...
-1
votes
0answers
40 views
Constants in NDSolve [closed]
I am trying to solve this system of equations. I am running into an error that I cannot quite figure out. In this code, I use the constants ktotal and xtotal, where ktotal is the total amount of the ...
1
vote
0answers
34 views
Unexpected error message from GraphPlot evaluation [closed]
(Running MMA 9 on Mac OSX 10.8.3, MacBook Pro, 16GB RAM)
I am trying to display a graph with GraphPlot. I want a few of the edges to be purple, and the rest red. I figured out a way to do this that I ...
3
votes
0answers
88 views
Does resizing plots produce new data? [duplicate]
What I do:
ListPlot,
Select the plot area,
A tooltip says: Double-click to edit,
Double-click the line or a point on the line,
Take a handle to resize the red ...
1
vote
2answers
123 views
extracting the rows of a matrix satisfying a condition (e.g. all elements negative)
I have a matrix with thousands of rows and want the submatrix comprising the rows of the original matrix that have, e.g. a negative element in column 3. How to do that?
7
votes
3answers
98 views
substitution rules excluding subscripted variables
Suppose I have an expression containing p,Subscript[p,1],Subscript[p,2],etc. I want to ...
2
votes
1answer
61 views
from complex function to a series
How can I express this complex function as a series?
Log[
(1 - E^((I Pi (1 - a))/(b - a)) z)/
(1 - E^(-((I Pi (1 - a))/(b - a))) z)
]
Where ...
2
votes
1answer
91 views
Evaluating double Integral
While trying to evaluate the integral $\int_{y=0}^{x_2}\int_{x=0}^{min(x_1,y)} n (n - 1) (1 - y)^{(n - 2)}dxdy $ , Mathematica does not seem to yield any results.
...
7
votes
0answers
72 views
Cell brackets on left side?
Is it possible to have the cell brackets on the left? I looked through the options and couldn't find anything, but maybe it's some kind of esoteric style setting or something.
The reason I'm looking ...
8
votes
1answer
72 views
Notebook[] vs. DocumentNotebook[]; display a Notebook[] inline, like a DocumentNotebook[]
If you evaluate a DocumentNotebook[] expression in the front-end, it nicely displays inline, inside of an output cell in the current notebook:
For my purposes, ...
0
votes
3answers
63 views
Evaluation in Manipulate [duplicate]
I have an expression assigned to a variable. For example:
exp1 = a*x+b
Now I would like to plot it using something like this
...
3
votes
1answer
27 views
Combination of CellPrint and PrintTemporary, or DisplayForm for Cells
I'm programmatically generating some formatted output that generates a cell in the form of a Cell[] expression. For instance, the output might be
...
-1
votes
1answer
99 views
I want to draw a graph using a weighted Adjacency matrix
I have a weighted adjacency matrix as follows:
...
7
votes
1answer
92 views
Visualizing vector-spherical waves
This is a follow-up question to this one on visualizing vector-spherical harmonics. This time, I would like to visualize the vector spherical waves (including the radial dependence). The functions ...
4
votes
2answers
107 views
How can I write a Do loop that iterates over N iterators when N is not known a-priori?
For any positive integer $n$ which is not specified a priori, I can make $n$-tuple vector $v$ by v = Array[a, 1, n]. Now, given that $n$ is a positive integer which ...
3
votes
1answer
93 views
Solving an inequality that contains Log expressions
How can I solve the following inequality? I tried the command Reduce, but the computer is still computing it (c is an real number).
...
6
votes
1answer
124 views
Does it make sense to ask for the color of a Graphics3D “voxel”?
Say I generate some Graphics3D object, e.g.:
Graphics3D[{Red, Sphere[{0, 0, 0}, 1], Blue, Sphere[{1, 0, 0}, 1]}]
Does it make sense to ask for the color of a ...
-1
votes
1answer
60 views
2
votes
2answers
70 views
Function returning Null along with other unexpected expressions
When I use some function, at the end along with the output I get some NULLs returned that I don't understand the reason for and are highly undesirable.
For example, when I define the reversal of list ...
4
votes
1answer
110 views
AR(1) Process first term
I'm trying to generate a very simple AR(1) Process with Mathematica using the ARProcess[] function. The process must have the following format:
$Y_t = \alpha + ...
1
vote
1answer
52 views
How to export results of an analysis in table format into MS word file
I'm working on a simulation study using Mathematica 8. At the end of the analysis I'll have a matrix of data containing my results (assume for three variables like x,y & z). I used these codes for ...
1
vote
0answers
58 views
How can I convert a plot to pdf or eps without errors?
Mathematica 9.0.1, Linux. I try to save a plot as a pdf. I tried four different options. In each case some errors appeared as blank space
( http://yadi.sk/d/h1koyDci4z3rc ). I also tried to save ...




