0
votes
2answers
58 views

Evaluate differentiation after replacement

The problem is Find two linearly independent solutions of $2x^2y'' -xy' + (-4 x + 1)y = 0, \, x>0$ of the form $y_1 = x^{r_1}(1 + a_1 x + a_2 x^2 + a_3 x^3 + \cdots)$ and $y_2 = x^{r_2}(1 + b_1 x ...
2
votes
2answers
989 views

Get positions of all non zero matrix elements

I want to find all non zero elements of a table and I want to create a list that contains the name of the table the element was removed from, the position of the element, and the value of the element. ...
20
votes
2answers
655 views

List of atomic expressions

I was surprised to see Graph objects are atomic. Is there a way (through documentation or programmatically) to find all atomic heads? The ones I know of are: ...
3
votes
1answer
125 views

Problem with PlanarGraphPlot And ConvexHull

I'm getting a lot of strange errors when using PlanarGraphPlot with a simple list of 11 points. This is using Mma 9.0.1 64-bit Mac OS X. ...
5
votes
2answers
555 views

Real and/or improved CForm of expressions

I'd quite like to be able to automatically generate C++ versions of certain mathematical expressions that I've manipulated in Mathematica. The resultant C++ code fragment is then going to be used ...
1
vote
1answer
63 views

Displaying an open Manipulator

Take something like: Manipulate[N[Pi]*s, {{s, 5}, 0, 10}] This results in the following: What I would really like is the following: Is there any way to ...
6
votes
3answers
321 views

Accumulate second elements in sublist

I want to accumulate the second elements in each sublist identified by its first element. ...
4
votes
1answer
153 views

References on functions FindGraphPartition and FindGraphCommunties

Does somebody have some interesting references on the FindGraphPartition and FindGraphCommunties[.., Method -> "Spectral"] ...
1
vote
1answer
79 views

Turning Off Error messages locally

I'm trying to turn Off an error in an expression. ...
3
votes
1answer
196 views

Dynamic inside Button

This bit of code runs a little animation of a stochastic process: ...
7
votes
0answers
519 views

Modelling Hysteresis with a Differential Equation

I want to implement the bulk ferromagnetic hysteresis model (mostly the Jiles-Atherton Model), see http://drum.lib.umd.edu/bitstream/1903/6043/1/PhD_99-1.pdf page 44 equation (30). The needed ...
0
votes
1answer
153 views

Rotating & Trimming grids

I want to draw a graphic $20\times20$ grid, rotate it by $\theta$ around $(0,0)$, and trim off the part on the right of the y-axis, so I came up with ...
1
vote
0answers
227 views

InstallJava::fail error when importing an image with a Raspberry Pi

I'm trying to import an image in Mathematica on my Raspberry Pi. The code is simple but I get an error when importing: ...
18
votes
6answers
830 views

Historical Exchange Rates via FinancialData

FinancialData["name"] and FinancialData["name", start] return respectively; the last known price, and the daily closing values ...
3
votes
2answers
299 views

Expectation of a family of random variables

I did some search here, but seems that no one asked about this. I want to define a family of independent and identically distributed random variables, $x_1,...,x_n$, and then calculates the expected ...
6
votes
1answer
149 views

Garbage collection for memoized functions on subkernels

I have a top-level function which operates on some data: findBestIntegers[data_]:=ParallelMap[optimize,data] which makes parallelized calls to an optimization ...
10
votes
1answer
358 views

Full documentation for AppearanceElements

As explained in this solution, ListAnimate[Table[Plot[Sin[n x], {x, 0, 2}], {n, 3}]]//InputForm will allow me to view the types of appearance element for the ...
0
votes
1answer
84 views

TeXForm without simplification

I'd like to be able to feed an expression into Mathematica, and have Mathematica convert that expression to TeXForm WITHOUT ANY SIMPLIFICATION WHATSOEVER. As a trivial example, currently, if I enter ...
2
votes
0answers
71 views

Complicated output from simple Eigenvalues problem

I have code that uses Eigenvalues on matrices of various sizes. But the output of what should be a very simple problem, namely finding the eigenvalue of a 1x1 matrix, is overly complicated. ...
-2
votes
1answer
205 views

How to solve a non-linear equation?

I am trying to solve the following non-linear equation: $\frac{i e^{-x^2} \sqrt{\pi } x}{K^2}+\left(-0.131251-0.0379031 x^2-0.0151154 x^4-0.0100462 x^6+0.5 \left(0.00273859 +0.0400003 K^2\right) ...
0
votes
1answer
95 views

Blank plot that shows up briefly when changing plot options

I wrote some code in Mathematica to calculate and plot, in tw0 different ways, a function depending of two variables. But the plots are empty even if it takes a few minutes to evaluate the plot ...
0
votes
1answer
692 views

Solving a large system of non-linear equations

I am new to Mathematica, and I am currently trying to use it to solve a large symbolic system of non-linear equations. I began the code below about 30 hrs ago, and the Mathematica Kernal has been ...
4
votes
1answer
111 views

Pattern matching and HoldForm

Create rules based on data. I have a system that picks out on date,based on some rules. I then want to generate a new rule based on this date and apply the rule to a new dataset. ...
2
votes
1answer
99 views

What is the proper way to the pattern form Repeated in my code?

I'm matching a pattern with Repeated (..) How can I use the repeat count in the replacement rule? Example: ...
2
votes
1answer
554 views

Truncate High order terms

Suppose I want to compute this : Series[Sin[1/f], {f, Infinity, 10}] but finally I prefer Sin[1/f] up to the fourth order in ...
0
votes
2answers
178 views

Fraction of fibers that have failed

I have the following to set into mathematica. Assume a stress(sigma) applied on a specimen which has a number of fibers within it. All fibers that have a strength less than the applied stress should ...
2
votes
1answer
139 views

Histogram scale error when using DistributionChart

I'm a novice Mathematica user that is having some problems using the HistogramDensity function in a DistributionChart. My observations are heavily skewed to one category and the height of the other ...
7
votes
2answers
1k views

Solving the Helmholtz equation in polar coordinates

I'm trying to (as a simple starter) find the solution to Helmholtz equation in polar coordinates -- I already know what it is and can derive it by hand, but just want to start here before asking ...
14
votes
1answer
4k views

How to request financial data from Yahoo's YQL and Quandl?

How can I download historical data from Yahoo ? Although Mathematica's FinancialData function uses Yahoo it could be useful to have more control on how to retrieve data from Yahoo's YQL. Edit ...
0
votes
1answer
100 views

Graphing the sequence {$p_k$} = $\frac{c - a + dp_{k-1}}{b}$ [duplicate]

Graphing the sequence {$p_k$} = $\frac{c - a + dp_{k-1}}{b}$ I need to know how to graph this function where it automatically plugs in the previous term for $p_{k-1}$, the coefficients are of my ...
5
votes
2answers
445 views

Manipulating slots in a pure function

How does one manipulate the slot numbers in a pure function? Some trick with Evaluate or Hold? I'm aiming for something along ...
12
votes
1answer
1k views

Creating a Mathieu stability diagram

I am attempting to re-create a Mathieu stability diagram like the one shown here: I expected that I could use MathieuC to generate this graph by assuming that ...
5
votes
1answer
87 views

MapIndexed stops at levelspec 1 if only the index is passed?

If the function passed to MapIndexed references the first (or data) argument, the following performs as expected: ...
4
votes
1answer
141 views

Strange ImageFilter results

I am trying to perform some neighborhood analysis on an image, but ImageFilter seems to be interfering with the results outputted by the provided filtering function. Initialization Given the hue ...
15
votes
2answers
414 views

Is there a better way to add elements to a Graphics expression repeatedly?

Consider simple example where a set of points is generated and some are displayed. ...
3
votes
2answers
155 views

Using MousePosition on the entire screen - Screencast with Linux

In order to record animations more easily while using Mathematica on Linux, I would need to know how to get the position of three clicks. The following picture (main part generated by ...
6
votes
1answer
151 views

Path construction using `Nearest` shows ill behavior?

I have a dataSet that I'm trying to sort choosing a starting point and going to its nearest neighbor, and then to its nearest neighbor and so on. To do so, I've ...
1
vote
1answer
109 views

How to create list of delayed rules? [duplicate]

I am trying to make a ButtonBar that prints the name of the card in question. What I have so far is as follows: ...
3
votes
0answers
306 views

Function with a sharp resonance which Mathematica fails to integrate. Why?

I'm a new user of Mathematica and I'm trying to use it to calculate the collisional cross-section as a function of energy for a given potential and decay rate. I know that the resulting function ...
-3
votes
1answer
153 views

How to show a general graphic (not a Plot) inside a Manipulate

I'm building a little interface, which consists only of a button, as you can see here: ...
0
votes
1answer
325 views

NMinimize holding problem

I have a function that I want to minimize numerically through an NMinimize command (because it's very complicated analytically). The minimizer call looks as follows: ...
0
votes
0answers
43 views

Verify “Type” of solution [duplicate]

I've written some Mathematica functions which allow the user to verify if a mathematical function has certain properties. What I'm basically doing is generating "random" functions in respect of ...
0
votes
1answer
215 views

Notebook keeps running when Solve for variable

This might be a simple question for the most of you, but I am very new to mathematica so please bear with me. I'll refer to the code below: ...
1
vote
2answers
89 views

List operation on specific elements [duplicate]

Let's consider two tables given by T1 = Table[{i,j,f1[i,j]},{i,0,2},{j,0,3}]; T2 = Table[{i,j,f2[i,j]},{i,0,2},{j,0,3}]; The functions ...
4
votes
2answers
1k views

What is the efficient way to code Successive Over-relaxation (SOR) method in Mathematica?

I have written a SOR method (SOR is this method) code using C-style procedural loops. However, I think there might be (much) better ways to achieve the same end in Mma avoiding these loops. So my ...
5
votes
1answer
573 views

Apply color function to matrix plot

I want to apply the following color rules to a large table of numbers. I have extracted a part of the table to use as an example. I would like to assign 5 different colors to 5 different ranges of ...
2
votes
1answer
104 views

Dynamic Syntax - Evaluate AppendTo as the second argument

I am attempting to Append a new value into my list paramMonitor whenever the value for B ...
1
vote
1answer
291 views

Simple subtraction question [duplicate]

I have two lists. a = {{2, 2}, {3, 3}, {4, 4}, {5, 5}}; b = {1, 1}; I want to subtract a from ...
3
votes
2answers
495 views

How to copy a function by value?

I need to change a function symbol multiple times by assigning another symbol to it, but when I'm trying to do that the symbols overwrite each other. I'm assuming this is because the assignment is by ...
2
votes
2answers
175 views

NIntegrate - WorkingPrecision

I am trying to NIntegrate this expression. It is very close to zero, and so gives all possible types of errors. More precisely, ...

15 30 50 per page