1
vote
1answer
96 views

How to do this Function with compile

There is 4 lists, 3 of them are at same length (l0, l1 and l3). ...
1
vote
1answer
68 views

Running this expression in Minimize function

So I got this expression here (written in pure text): ...
4
votes
1answer
183 views

Recognize physical constants?

Is there some way to ask Mathematica to recognize physical constants, such as 32 or 9.81 (gravitational acceleration, in different units, at Earth's surface)? I have in mind something like the "...
1
vote
0answers
54 views

Select complex mutiple row [closed]

How can I make this select on Mathematica? Is possible?
4
votes
2answers
226 views

How can I encrypt/decrypt a directory?

I'd like to use Mathematica 10's new Encrypt and Decrypt functions to secure files and folders on my mac. Here's what I have so far but something goes wrong along the way, since by the end of this ...
0
votes
0answers
36 views

Symbolic root computation of a function that depens on parameters

I'm given list of real numbers $a_i, i=1,N$, where usually $N \le 100$. Consider a function $f_N = f_N(x,a_1,...,a_n)$. I need to find the roots of $f_N(x)$ on $[-1,1]$, assuming that $a_i \notin [-1,...
13
votes
2answers
271 views

Heat convection differential equations from 1952 - Mathematica “fails to converge”

I am trying to solve a fundamental problem in analytical convective heat transfer: laminar free convection flow and heat transfer from a flat plate parallel to the direction of the generating body ...
1
vote
0answers
79 views

FrameTicks not appearing with Export to .png file [duplicate]

I'm using 10.1 on Ubuntu 14.04. I am trying to export some plots. However, when I export the plots using Export[file.png, figure, ImageResolution->360], the <...
2
votes
1answer
273 views

Histograms of gray scale images

I have a large set of subsequent 8bit gray scale png images (50 Hz). They show the noise of a CMOS camera, with the lens covered. A subset of 50 images is available here: https://goo.gl/Sa3P9P I ...
1
vote
0answers
68 views

Using Classifier with NearestNeighbors methods

I am using a Machine learning toolbox on mathematica. I have 8 classes. Training data: for each class, there 100 samples with size 160. I used this code. ...
0
votes
1answer
55 views

Convolution of interpolated data with function doesn't work

I need to convolve one function with interpolated data: function: av1 = 1.3888*(12/20)*10^8; bv1 = 2.5; tr5[t_] = Exp[-(av1*t-bv1)^2]; Data: ...
4
votes
1answer
73 views

From built-in symbols to algebraic representation

If I have an expression with Mathematica's built-in functions like Probability[x > 0, x \[Distributed] UniformDistribution[{-1, 1}]] its algebraic ...
11
votes
3answers
325 views

Partition a list based on specific elements? Grab the sublists beginning with a certain marker elements

Say I have the list {{a}, {0, 2, 5}, {5, 4, 1}, {a}, {1, 1, 0}, {1, 4, 2}, {3, 3, 0}, {a}, {3, 2, 0}, {1, 4, 1}} I would like to make sublists of everything ...
1
vote
1answer
50 views

Pattern that matches numbers in the $\epsilon$-neighborhood of a given number?

I dfined the following function to create a pattern that matches the $\epsilon$-neighborhood of a given number. ep[x_, e_] := _?(x - e <= # <= x + e &) ...
1
vote
0answers
67 views

Import Excel data from within Manipulate

I am processing a set of data using Manipulate, as I need some user input as well and the whole code must be delivered as .cdf . The set of data should be imported from an Excel file which is selected ...
1
vote
1answer
89 views

How can I add flags to countries shapes? [duplicate]

Recently, I wanted to create a map showing the flags of the countries. From the documentation, I found and used the following: ...
3
votes
1answer
108 views

Map if-function on a list

I need to convert a battery charging mechanism from Excel into Mathematica. This Excel function is about deciding if the charge/decharge rate is positive, then multiply with efficiency factor, ...
2
votes
2answers
63 views

Remove an element of a list [duplicate]

I want to check if any element of a list contains Missing["NotAvailable"] If so I want to delete the entire list. If I am correct I need to have some ...
5
votes
1answer
281 views

Trouble with shooting method for a 4th-order stiff ODE

The ODE I need to solve is $$\left(y^3y^{\prime\prime\prime}\right)^\prime+\frac{5}{8}xy^\prime-\frac{1}{2}y+\frac{c}{y}=0$$ where $\prime$ denotes differentiation, $c$ is a constant and $0<c\le1$....
1
vote
2answers
92 views

Void elements / self closing tags export to HTML

There are some built in rules in exporting that automatically create Void elements / self closing tags for some tags: ...
0
votes
2answers
104 views

Getting image data values with coordinates in circular region

I have a number of gray level images (600, with size: 2400x2400 pixel, small instance see above). In this image there is a circular region of interest. The aim is to fit a function to the gray value ...
4
votes
2answers
62 views

Controlling evaluation in a custom summation function

I'm doing some computations that involve summations with many indices over the same range - consider the simplified example Sum[a[i,j],{i,1,2},{j,1,2}]. To prettify ...
7
votes
2answers
129 views

ListSliceContourPlot3D with non-opaque stacked planes

I'd like to make a ListSliceContourPlot3D in Mathematica with using the stacked planes (x, y, or z) for the contours, but I'd like the planes to have an opacity <...
1
vote
2answers
57 views

Superscript standalone text

How do I write a superscript text standalone, without implying power? E.g. ToExpression[25]<>"CNTRL+^oC" doesn't format well, italicizing o and leaving whitespace in-between the number and ...
-1
votes
1answer
82 views

How to get the intersection of three different curves [closed]

There are two functions, f(x,y)=x + y^2 - 8; g(x,y)=-3 x^2 + y^2 - 5; How can I get the intersection of these two curves? And how about the intersection among f(x,y),g(x,y) and z=0? Thanks
1
vote
2answers
49 views

Question regarding exporting of mx files

I want to export a bunch of data to .mx files. So I created a function str = (Print["a\n"]; Print[a]; Print["\nb\n"]; b); ...
1
vote
2answers
73 views

Dynamic Updating

I want to take some points, place them onto a graph and then use the locator pane. I then want to take the new locations that the user has moved the points too and remove the y coordinate and use just ...
1
vote
1answer
108 views

Output a 10*10 random color matrix withJPEG form in Cloud Application

I want to output 100 JPEG Images(in 10 * 10 matrix) in Cloud Application. I came to this code: ...
3
votes
1answer
68 views

How to make optional field in FormFunction?

I'm trying to make a quick form that has an optional input. This is what I have now: ...
5
votes
4answers
126 views

Solving an equation with rational expressions (step by step) [duplicate]

Consider the following equation with rational expressions: $$\frac{5}{x+4}=4+\frac{3}{x-2}$$ We will look at the plot. We will use the Solve command to check our answer. ...
0
votes
1answer
48 views

Lift and projection method in Least Squares Inverse Eigenvalue Problems [closed]

I need to implement the lift and projection method proposed by XUZHOU CHEN AND MOODY T. CHU in http://www4.ncsu.edu/~mtchu/Research/Papers/lsiep.pdf on page 7 in ...
1
vote
1answer
65 views

3D-plots of Complex-parametered trig-functions returns empty plot

I first tried to plot a parametric equation as follows; ...
6
votes
4answers
263 views

Average dataset with many repetitions?

I have a dataset where each item is of the form: <|"p1" -> x1, "p2" -> x2, "r1" -> y1, "r2" -> y2|> The interpretation is this: ...
5
votes
6answers
188 views

Replicate and expand a list

I have two lists a and b of the same length. And another list a2 which contains all elements ...
3
votes
1answer
145 views

How to speed up filling a matrix as much as possible in a loop?

In order to find the solution of an $n\times n$ system of nonlinear equations by the method $x_{k+1}=x_k-D_k^{-1}f(x_k)$ where $D_k$ is an approximation of the Jacobian and defined by \begin{equation}...
1
vote
2answers
76 views

Need VectorPlot to ignore centre of region

I'm trying to plot a vector field over the range $[-1, 1]\times [-1, 1]$, but only outside the circle of radius 0.2 centered at the origin. The function diverges at the origin so the magnitude of all ...
1
vote
0answers
35 views

Using DynamicModule and Locator with an external Module [closed]

I wish to call an external Module, called PCA inside a DynamicModule. Essentially, this ...
0
votes
1answer
69 views

LinearSolve on non-square matrices?

I just came across a strange behaviour for LinearSolve (on Mathematica 8.0.0.0). Consider the following definitions: ...
0
votes
1answer
67 views
0
votes
1answer
50 views

How to start at a given arbitrary PageNumber

I have a Script with several sub-notebooks. I want to start the page of the body-text at 1 with content and foreword before that page. How can I assign a page number to show up in the print-out? I ...
4
votes
6answers
940 views

Randomly Multiply OR Divide by a Random Number?

I want that Mathematica decides randomly if a given variable, gets multiplied or divided by a random number in a given range. The "naive" idea to just use ...
1
vote
2answers
235 views

Problem solving a second-order PDE

I am looking for numerical solutions for a class of equations of the type : e = Derivative[2,0][ps][x,w]+(2/x)*Derivative[1,0][ps][x,w]-r[x,w]==0 With r a ...
1
vote
1answer
81 views

DSolve - Complex Number Solutions

some of you know that I have been working on my dissertation of Game-Theoretic Modelling of Cybersecurity (Thank you again to everyone who has helped me with Mathematica so far). The differential ...
3
votes
0answers
83 views

LibraryLink: Asynchronous Examples

Inside the directory structure of LibraryLink there are several example files. Basically, they are divided in two types: Synchronous: demo.c, demo_error.c, ...
0
votes
2answers
50 views

How to find negative numbers for my recurrence formula?

The generalized recurrence formula is F[n_]:=F[n]=F[n-1]+F[n-p-1]; with the initial conditions ...
1
vote
0answers
62 views

License not released after kernel is stopped for KernelTimeLimit reached? [closed]

Using webMathematica, doing massive tests of our functions (each call can take from 0 to 15 seconds). After a while we started getting lots of 403 Forbidden errors. webMathematica.log: ...
2
votes
1answer
205 views

Maximized value of a function as an additional constraint on a variable

I want to maximize a function $f(b, h)$ with respect to its arguments and subject to some additional constraints. If these constraints are satisfied, $f$ is increasing in $h$. I then want to find an ...
3
votes
1answer
109 views

Plot Shown Differently in Mathematica 9 and 10.3 [duplicate]

I try the following code to put it as a second axis in a 2-y plot as overlay but it behaves differently in Mathematica 9.0.1 and 10.3 (Numbered labels are missing in MA 10.3) ...
0
votes
1answer
37 views

What's wrong when I use ImageApplyIndexed?

I am reading a ebook called Basic image processing in Mathematica which can download free in the iBooks. In the page 114,it introduce a function ImageApplyIndexed...

15 30 50 per page