1
vote
3answers
263 views

List of Tribonacci Polynomials with Mathematica? [duplicate]

I want to list top ten of Tribonacci polynomials. I have following algorithm, but it doesnt work. ...
2
votes
1answer
181 views

How to combine SparseArray and If

Because I am dealing with huge matrixes, my computer can not handle it, because of the memory. But, in my matrix, a very small percentage of the elements are non-zero. So I should use SparseArray as ...
6
votes
2answers
246 views

What is the underlying algorithm for GroupElementToWord?

What algorithm is Mathematica 9 using for GroupElementToWord[group, g]?
1
vote
2answers
453 views

Translating a “Point-to-Triangle” distance script from MATLAB to Mathematica

Update - Thanks everyone for your responses! After fixing a problem with vector normalization, the code below now works. I'm a new user, and I was attempting to port some Mathematica code from ...
6
votes
0answers
174 views

Is it possible to run Mathematica on an HPC cluster with Torque?

I'm installing Wolfram gridMathematica in HPC cluster with TORQUE Resource Manager. There is a big problem because Mathematica suppost PBS pro. Can you help me or give some advice or coments?
0
votes
1answer
144 views

Dynamic Updating CreateDialog Problem

In this code, one cannot close the dialog window: {TogglerBar[Dynamic[x], Range[5]], Dynamic[x], Dynamic[CreateDialog[x]]} If I use ...
11
votes
2answers
212 views

How to generate characters by a function which works like the Esc + a + ESC

How to generate characters by a function which works like the Esc + a + ESC ...
4
votes
2answers
171 views

Graphics3D: the box vertices do not coincide with triangle

I have drawn a triangle using Line graphics primitive and Graphics3D function: ...
2
votes
2answers
343 views

Write a function that returns the logarithmic derivative

How can we write a function that if we input an expression f, it returns the log derivative $\frac{1}{f} \frac{df}{dx}$. We have to use a conditional or pattern test so that the function accepts any ...
0
votes
0answers
34 views

How to tell Mathematica to use Real Only Mode [duplicate]

How do I tell Mathematica to use real only mode. For example if I want to graph $(x-1)^{1/3}$ for $-3<x<3$, I need to use Real Only mode to get the right graph.
5
votes
1answer
160 views

Is it possible to save an interrupted computation?

I've got this really time consuming factoring problem. To decouple things a bit, I decided to start Mathematica using the command line interface (under screen). ...
2
votes
3answers
314 views

Problem with simplifying Sinc function

$Assumptions = x ∈ Reals && y ∈ Reals && a ∈ Reals && b ∈ Reals; These work: ...
5
votes
1answer
137 views

How can I substitute something using only map?

For example, I have the equation x^2 + y^2 == x*y and I want to apply the rule y -> s*x I can do it easily by ...
0
votes
0answers
39 views

Generating partitions of a set with a specified size of the parts [duplicate]

I tried the following (inspired by the answer here) myList = {a, b, c}; Needs["Combinatorica`"]; SetPartitions[myList] and I got this answer, ...
5
votes
1answer
187 views

Preventing cell height adjustment when rotating 3D graphics

I have a large dataset of scattered x,y,z coordinates. I am trying to use ListPointPlot3D to identify outliers in 3D. This involves generating a plot and then ...
3
votes
2answers
178 views

Bounds on random number

I have a Markov Chain Monte Carlo code that uses a chi squared function to fit some data. I am running into an issue now with getting unrealistic values for some of the free parameters in the code. ...
0
votes
2answers
2k views

Visualize Plot of a function of 3 Variables using color and contours

I would like to plot a function of three variables, say for example: $$f(x,y,z) = x^2+y^3+z^4$$ over $[-1, +1]$. I want my plot to use colors and maybe contours to make this visualization possible ...
3
votes
0answers
606 views

Using NDSolve for Integro-Differential Equations

I have a fairly complicated set of coupled non-linear integro-differential equations that I am trying to solve using NDSolve. The equations are: ...
9
votes
1answer
162 views

Creating a NearestFunction that returns an index

I use Nearest repeatedly for large data sets. For example pts = RandomReal[{-1, 1}, {1000, 3}]; Nearest[pts, {0, 0, 0}] I ...
0
votes
0answers
283 views

Performance in parameter estimation from ParametricNDSolve using varied initial conditions

I have 250 data points from a timecourse exeriment in a list, with columns specifying (1) time, (2-4) initial conditions, (5) absorbance reading. I want to fit 4 parameters (k1, k2, k3, k4) in a DAE ...
2
votes
2answers
237 views

Expanding Matrix Expressions

I want Mathematica to recognize that A.(-B.C)+A.B.C = 0 Yet FullSimplify and the like leaves the expression as it is. How do I get around this?
4
votes
3answers
297 views

Unexpected behavior of Unevaluated

Maybe it is about time I read some proper text about the main loop. Maybe I should not care (so much) about Unevaluated (as Leonid suggests). But I think this is an interesting question anyway. This ...
-3
votes
1answer
129 views

Mathematica output in ASCII or larger text size for the output?

I am trying to read the output of this code that has crosses, circles and spaces. For some reason, the output is in very-very small alphabets so I would like to get it in ASCII and/or in larger ...
9
votes
3answers
323 views

Why is this parallel evaluation with Dispatch[] so slow?

Can you efficiently parallelize this? The parallel versions are much slower than the sequential version, and I'm not sure why. Does SetSharedVariable allow ...
4
votes
2answers
178 views

How to enumerate multisets?

Given the eight-element set {1,2,3,4,5,6,7,8}, I would like to enumerate all multisets (subsets with repetition) of size n, ...
2
votes
1answer
357 views

NDSolve with vector function

(Possible duplicate yet I still can't understand.) Basic 2D revolving around origin: ...
2
votes
3answers
284 views

Using ImageTransformation[] with a lookup table

I need to transform images by ImageTransformation in a time critical application. Therefore I precalculate a lookup table lut of ...
0
votes
0answers
46 views
1
vote
1answer
231 views

How to crop graphics outside PlotRange with Show? [duplicate]

Is there an option or method to prevent Graphics from being displayed outside the PlotRange region? The problem is illustrated ...
2
votes
2answers
497 views

A Symbol with Subscript and Superscript as an Axis Label

I am trying to have the symbol $\epsilon_{9/2,4}^-$ as the axis label in a graph in Mathematica. First problem is that: when I use Subscript[$\epsilon$,9/2,4], 9/2 changes to $\frac{9}{2}$ (which I ...
1
vote
2answers
450 views

Plotting points and functions in one graphic

I have this plot: Plot[{0 x, -x, x, -Sqrt[2 - x^2], Sqrt[2 - x^2]}, {x, -3, 3}, PlotStyle -> {Purple}] Now I want to do the following. I want to plot the ...
0
votes
1answer
135 views

TextRecognize with crosses, circles and spaces results into oddities, why?

I am investigating this answer here about detecting crosses and circles with TextRecognize. I tried to solve this problem here by directly using the builtin command TextRecognize but it does not work ...
1
vote
0answers
100 views

CDF Player: MathKernel.exe uses a lot of memory

When I run this CDF document http://x6174x.blogspot.pt/2013/04/bankroll-growth-simulator.html on my desktop, each time I press "Run again" the Task Manager shows that the MathKernel.exe process ...
8
votes
2answers
197 views

How to simplify an expression with special functions to zero

The following is a well-known Bessel function identity: $$J_{-n}(z)=(-1)^n J_n(z),\qquad n\in\mathbb Z$$ To check this, I used the following code and the result is as what I expected. ...
3
votes
0answers
39 views

Behavior of $PreRead in Kernel

I am interested in making a simple accounting style line calculator that allows me to interact with it something like this: ...
2
votes
2answers
175 views

How to select elements from a 4D Array?

I am very new to Mathematica (first time!) and I'm already having troubles with arrays. I basically have a 4D tensor, that is a matrix (call it M) which has for ...
2
votes
1answer
281 views

Normalize the PlotLegends and z values for two DensityPlot

I'm trying to compare two DensityPlots: ...
0
votes
2answers
162 views

List Plot 3D the same colour scale

I have a transient problem of pressure disipation. I want to plot severals 3D plot but I have a problem with colours. Case: One of my ListPlot3D presents pressure ...
0
votes
1answer
134 views

Monitor the list for changes

I wrote a function to monitor the list of variable. What it does is if the variable in list change, the changed variable will be separated from others. check the function and output ...
17
votes
1answer
1k views

The Orbit and Perigee of the Flamsteed comet

Historical context This year we have the 330-th anniversary of the Battle of Vienna - one of the great formative events of European history, it took place on September 12, 1683. Kara Mustafa, Grand ...
2
votes
1answer
145 views

Integration of a rational function

I am trying to solve the following rational integral (I got assistance here): $$\int_{-\infty}^{\infty}{\frac{a+x}{b^2 + (a+x)^2}\frac{1}{1+c(a-x)^2}}dx$$ where $\{a, b, c\}\in \mathbb{R}$. I would ...
2
votes
1answer
71 views

Use Initialization Cells to open a CellGroup

I would like to use "Evaluate Initialization Cells" to open a CellGroup in a notebook. However, the following code doesn't work if placed in an initialization cell: ...
5
votes
2answers
373 views

Reducing exponential inequalities fails

I am quite stumped by this problem : Reduce[ N^(x-y) <1 && N > 0 , x, Reals] gives the expected result ...
1
vote
1answer
318 views

Concerning ShowLegend in Mathematica

I found a code for Mie Scattering from 2007, written for Mathematica. I have edited it quite a bit, since there are package definitions that we don't need, etc. But I am having difficulties ...
4
votes
0answers
416 views

When using NMinimize[…,Method->“DifferentialEvolution”] is an “iteration” different than a “step”?

Hopefully this question has a simple answer. I have the following bit of code: ...
1
vote
1answer
240 views

How do I operate on a set of ordered pairs? [closed]

I have a calculation that will give me a lot of ordered pairs. For each such pair in a list, I want to square the elements and add them together. Here is an example of the kind of list I have ...
5
votes
1answer
379 views

Solving homogeneous Fredholm Equation of the second kind

I am trying to solve a homogeneous Fredholm integral equation of the second kind, i.e. $\lambda y(x) = \int\limits_a^b e^{i[\phi(t)+k(t-x/M)^2]} y(t)\,dt$ where $\lambda$ is the eigenvalue (to be ...
3
votes
0answers
148 views

Mathlink and multithreading

In order to make my computations faster I have developed a C/C++ application calling Mathematica kernel and performing many operations using Mathematica functions for equation solving. Now I want to ...
3
votes
1answer
669 views

White noise $\eta(t)$

How to make a random function $\eta(t)$ to insert in a differential equation for NDSolve? Edit: example: to solve equations like $\frac{dx}{dt}=\eta(t)$
3
votes
2answers
208 views

How to replace Do loops by Inner

I need to replace Do loops by something else because it takes forever with big programs. I have been hinted towards Inner, but ...

15 30 50 per page