1
vote
1answer
102 views

Why does Mathematica add Hold to the result of my user defined symbol?

In the code below I have defined a symbol that multiplies two block-matrices (I can't use the builtin Dot since Dot assumes that the matrix coefficients commute): ...
3
votes
1answer
70 views

Bug in associated Legendre Polynomials?

Mathematica's definition of the connection of associated Legendre polynomials with $m$ and $-m$ is: $P_l^{-m}=(-1)^m \frac{(l-m)!}{(l+m)!} P_l^m$. We also now that $|m|>l \Rightarrow P_l^m=0$. ...
0
votes
0answers
41 views

Why NMinimize doesn't work [closed]

I have some problem with my code. I need to find root for functional equation F(x)=0, where function F is complex subroutine that uses some external programs for calculation and after all routines ...
0
votes
0answers
31 views

SumConvergence with product $\sum_1^\infty{\frac{1\times3\times5\times…\times(2n-1)}{n!}}$

SumConvergence[( Product[(2 n - 1), {n, 1, infinity}])/n!, n] $$\sum_1^\infty{\frac{1\times3\times5\times...\times(2n-1)}{n!}}$$ However this returns true but it ...
4
votes
1answer
111 views

What is “MouseDragged”?

Maybe I'm picky but I don't consider static pressed button: "dragging". EventHandler[Framed[1], {"MouseDragged" :> (Print@RandomReal[])}] neither does ...
2
votes
2answers
35 views

Coloring specific elements of sets with a prime modified order in an array plot

I have a set of sets: {{1}, {0}, {1, 1}, {0}, {1, 0, 1}, {0}, {1, 1, 1, 1}, {0}, {1, 0, 0, 0, 1}} I’m seeking to apply a color rule to only every other set, starting from the first (from left to ...
6
votes
1answer
114 views

Long running ToElementMesh with very “large” domains

I'm trying to solve a system of PDE over a large domain. This doesn't means I need to have a huge amount of mesh points and mesh elements to discretize the domain. Just that the domains has a big ...
0
votes
1answer
51 views

Correcting a gap in ListPlot

This is a small sample of my data ...
0
votes
0answers
37 views

Coloring all elements in prime ordered sets amongst a set of sets

So I have a set of sets. I want only those sets whose order amongst the sets plus one is prime to be colored (all the same, anything but the standard black). Any ideas? ArrayPlot[{{1}, {1, 1}, {1, 1, ...
6
votes
0answers
69 views

ListPlot3D. Only plots about half of the data in a 3D matrix

Here is the data and the exact command I'm trying to run. I've had success with other datasets generated and written out to a file by the exact same program in the exact same manner but for some ...
1
vote
0answers
51 views

Find the smallest eigenvalue (not absolute value ) for a generalized eigenvalue problem

Related post Find the eigenvector associated with the smallest eigenvalue, not smallest in magnitude I tried to find the smallest eigenvalue for a generalized eigenvalue problem A c= \lambda B c ...
1
vote
1answer
68 views

$L = \lim_{z \rightarrow 1} \frac{1-z}{1-z^*}$ Evaluates incorrectly

I'm about 90% certain this is a Mathematica issue, not me making a silly mistake. I'm trying to evaluate $$ L = \lim_{z \rightarrow 1} \frac{1-z}{1-z^*}. $$ Naively entering ...
0
votes
0answers
64 views

CPU usage ~18%, but Mathematica is fully running

I run some very long Mathematica code, and the CPU usage of the kernel is 18% only. Why is not all of the CPU used, can I find the reason easily? Are there known ways to tell Mathematica to use more ...
4
votes
0answers
41 views

Extraneous reaped data with NDSolve and WhenEvent

In exploring What is the range of values $x$ for which $f(x)$ is higher than $k$ over a given domain?, I came across the following strange behavior: ...
0
votes
1answer
68 views

The 1st approximation of multi-viables which contains the differential [closed]

When I input to Mathematica as following, ...
0
votes
1answer
35 views

Defining Solutions to FindRoot a functions of parameters-Part II

Here's a similar question as the the preceding question with the same title, but this time with vectors, which I need to use. I followed the suggestion in the answer the the previous question, but it ...
0
votes
1answer
66 views

Weird behavior when solving a simple physics problem

I have the following code in Mathematica that represents two balls being thrown, one with a velocity v10 (6 in this case) and another ball thrown with a velocity v20 (its just dropped) one second ...
6
votes
6answers
842 views

Can't comment strings with '*)' inside it

I believe it's a bug in notebook's comment parser. I can't comment strings with *) inside it. Something like: ...
0
votes
1answer
39 views

Defining solutions to FindRoot as a function of parameters in Mathematica

This works: f[a_] := x /. FindRoot[x^2 - a == 0, {x, 1}] f[3] (* 1.73205 *) I need this to work, but it doesn't: ...
0
votes
1answer
46 views

Assuming: what am I doing wrong? [duplicate]

Why doesn't this simple line work? Assuming[Element[#, Reals] & /@ {x}, Reduce[x^4 == 1]] (* x==-1||x==-I||x==I||x==1 *) I'm trying to do something a little ...
2
votes
2answers
92 views

KeyMap on a flat Dataset (i.e. Dataset@Association)

How can I go from Dataset[<|"A" -> 1, "B" -> 2, "C" -> 3|>] to ...
1
vote
0answers
47 views

Problem with ParallelTable?

I am trying to numerically solve Bloch equations using Euler's method. My code is the following ...
3
votes
1answer
36 views

Is it possible to generate a message when precision upgrade occur?

I use Mathematica mostly for numerical simulation, so most of the time double precision (or machine precision) is enough for me. Mathematica has this nice feature of automatically upgrade to arbitrary ...
3
votes
6answers
102 views

What is the range of values $x$ for which $f(x)$ is higher than $k$ over a given domain?

What is the easiest way to answer the following question in Mathematica: Given a function $f(x)=y$, what is the range of values $x$ for which $y$ is higher than some number $k$ over the domain of $x$ ...
0
votes
0answers
44 views

Writing rules for Einstein summation

I'm trying to write a list of rules for tensor manipulations and in particular, Einstein summation convention. What I've tried, so far is to write something that would take a generic functions with ...
0
votes
0answers
28 views

ErrorBarFunction styles [duplicate]

I am having trouble making sense of the help I have found for the ErrorBarFunction command. I am looking for basic instructions on how to change the width, style, and color of my error bars. ...
7
votes
2answers
77 views

Why does ToRules return a Sequence?

Why does ToRules return a Sequence expression? Why doesn't it return directly what ...
1
vote
0answers
34 views

Confusing NullSpace Method behaviour

The background of this question is that I'm trying to get the bottom of when the output of NullSpace outputs a list of pairwise orthogonal vectors. On my route to ...
0
votes
1answer
45 views

Why `FindMaximum` doesn't work in my example

Consider the following function ...
2
votes
3answers
102 views

Custom Grid Lines for ProbabilityScalePlot

I'm plotting up some data using a ProbabilityScalePlot in Mathematica 8. It currently looks like so: Code: ...
0
votes
1answer
49 views

Why does `Table` returns values but `Plot` doesn't plot them?

The Table function works fine and return a nice list of values ...
0
votes
2answers
65 views

How to exract the roots from “Roots”? [duplicate]

Given how the output looks like, as in a set of "==" assignments, is it possible to extract specific roots from the output of, http://reference.wolfram.com/language/ref/Roots.html ? And then do a ...
0
votes
1answer
105 views

How do I write nested for-loops?

Looking through the reference.wolfram, I couldn't see an example of how to write a multiple line "for" loop in Mathematica. I need to nest many for-loops in such a way I can do many things in the ...
20
votes
2answers
368 views

Can Mathematica solve Plateau's problem (finding a minimal surface with specified boundary)?

Given a closed curve $\mathcal C$ in three dimensions, is it possible to use Mathematica's built-in functionality to compute a minimal surface whose boundary is $\mathcal C$? For simplicity, let us ...
0
votes
1answer
59 views
1
vote
0answers
43 views
1
vote
0answers
36 views

Multi-named Nodes (or Overlapping Nodes) in TreePlot, or Merging Trees

If there is a series of rules from which a TreePlot is made: {D->C, C->B, B->A} And a new node is added that is technically the same as an existing ...
1
vote
1answer
69 views

Simultaneous use of Set AND SetDelayed

Tha Mathematica documentation gives a good example of the simultaneous use of Set and SetDelayed in dynamic programming for the Fibonacci sequence under "neat examples" for SetDelayed ...
1
vote
1answer
34 views

pure functions in nested select

I want to select certain rows from a list by using two nested Select commands ...
0
votes
0answers
21 views

How to use Mathlink mprep to compile external C program [closed]

The reference guide of Mathlink says that a program called mprep takes the template file as input and produces a C file that gives the MathLink interface between your external functions and ...
2
votes
1answer
64 views

Are there methods to serialize and deserialize large calculation runs? [closed]

I have a fairly large calculation to map an electric field over large areas (square kilometers). This runs for a fairly long time. Are there ways to serialize the current state of a running ...
0
votes
0answers
43 views

How to calculate electronic Band structure of cristal [closed]

I need a notebook to calcolate the band structure of a cristal, please can someone help me?
2
votes
1answer
174 views

Drawing all lines between a set of points

Given that I have the array of points, ...
1
vote
1answer
69 views

Initial Value Problem with initial conditions as closed region

Does Mathematica have functionality to solve an Initial Value Problem when the initial conditions consist of a closed region (rectangle) instead of a point? That is, instead of initial conditions as ...
0
votes
1answer
43 views

Exporting A4 size

I have a few tables and graphs that I want to export to a PDF file using Export[....,"PDF"], but I would like to be able to print this PDF-file and still be able to read it. So how can I control the ...
0
votes
0answers
45 views

Generating a list of overlapping end coordinates [duplicate]

I'm a very new user to mathematica so this may be a silly question. i'm trying to evaluate some integral between end coordinates of some evenly spaced range. my range is defined by the number of ...
0
votes
2answers
67 views

How to contourplot a function defined via findroot? [duplicate]

when I use contourplot, the system will simplify the expression first with its parameters holded. However some expressions can not be simplified first without inputting parameters, for example, ...
0
votes
0answers
25 views

Failed to use SetPrecision

I am calculating the below formula: $$ \text{ER2}(\alpha,\text{K},\text{q})\text{:=}1+\sum _{m=0}^{K-1} \binom{K+\alpha }{m} \sum _{r=0}^m \frac{(-1)^r \binom{m}{r}}{\left(\frac{1}{q}\right)^{\alpha ...
-1
votes
1answer
75 views

Finding the pixel positions for the straight line joining two points [duplicate]

Please help me solve the given problem. Find the pixel positions for the straight line joining P1 (10, 20) and P2 (18, 25)
0
votes
0answers
58 views

A confusion about comparing WolframAlpha results with Sage [closed]

The following is a characteristic polynomial of a 4 dimensional Hermitian matrix and hence I expect 4 real roots! So I have the equation, $f(x) = (x^2 - 6)x^2 - 4x(e^{(2/5)i\pi} + e^{-(2/5)i\pi}) ...

15 30 50 per page