1
vote
0answers
2 views

Is there a built-in function to map a list of heads to a list of data?

Assume that this built-in function is called func. What I want is func[{f,g},{a,b,c}] will return the following result: ...
1
vote
3answers
43 views

Dependency injection - use a specific implementation of one function within another

Consider... f[x_]:=Body containing h[some args]... g[x_]:=Body containing h[some args]... However I want to define something like... ...
0
votes
0answers
7 views

Sinchronicity and probability

"Synchronicity is the experience of two or more events as meaningfully related, where they are unlikely to be causally related. The subject sees it as a meaningful coincidence." Wikipedia First, I am ...
0
votes
0answers
16 views

What are the best Mathematica tips in Michael Trott's beer/whiskey post?

Michael Trott posted this incredible tour-de-force on the wolfram blog: http://blog.wolfram.com/2014/08/19/which-is-closer-local-beer-or-local-whiskey/ The length of the post is overwhelming, so I'm ...
1
vote
2answers
27 views

Problem with machine number precision in compiled functions

When I compile a very big function and give it input the function returns error. I realized that this is because the value of the function becomes smaller than the smallest machine number. Is it ...
0
votes
2answers
30 views

How to graph the revolution of solid limited by 2 points in x axis

I'm learning how use this program. And I have problem with how graph the solid of revolution.Here i write one exercise. y=2-1/2x, y=0,x=1,x=2; about the x-axis. This is the graph also the volume ...
2
votes
2answers
60 views

Help with coding triangular nodes/elements

I'm trying to write a program where it will shoot out the triangle node numbers. For example, in the picture, if we choose to divide this triangle by 5 points, then the program will return out the ...
24
votes
4answers
2k views

How to find the period of an arbitrary mathematical function?

Is there a function to find the period of an arbitrary (possibly complex) function in Mathematica?
0
votes
0answers
49 views

Window ▶ Show Handwriting Input

How might I force Mathematica to display the Handwriting Input menu? Currently I'm on W7 using a Wacom Tablet and unable to find the Handwriting Input option. It doesn't display under Windows>.
3
votes
1answer
27 views

Part specification error only in LogPlot

I've a problem. I defined a simple list and a function like below: lst := {5, 10, 20} f[m_] := lst[[Floor[m/10]]]; and drew a plot ...
0
votes
1answer
54 views

Formula for a 15 - Puzzle game (Backwards and forward solution)

So I currently code a 15-Puzzle Game. Every tile has position starting between 1 and 16. For example has a tile which is at the position where number 3 should be the position 3. Now I need to find ...
14
votes
3answers
1k views

Checking if a point is in a convex 3D polyhedron

Extending from these questions How to check if a 3D point is in a planar polygon? and How to check if a 2D point is in a polygon?. I'm trying to do this to render specific shapes made up of spheres. ...
4
votes
3answers
135 views

How to test if all the elements in a list are Integers? [closed]

Consider a list such as s={1,2,3,3,5,6,3} With IntegerQ[number] , you know if number is an ...
11
votes
1answer
307 views

What is available for editing Mathematica source code with Emacs?

I can find several Emacs libraries for Mathematica, but I'm not aware of a clear favourite, a definitive list, or of a library which is actively maintained and developed. None of these appear to be in ...
6
votes
4answers
174 views

How to generate random points in a region?

The Mathematica 10 documentation was updated for FindInstance adding support for regions. In my use case I'm trying to sample points in a set of disks: ...
4
votes
1answer
86 views
11
votes
5answers
801 views

How to make a depth map from a 3D model?

Given a 3D .obj model, for example a rabbit. How can we make a depth map out of it? Any idea or help would be much appreciated.
2
votes
0answers
39 views

Find file names in directory

I am trying to find the list of any file in any directory of a given name (by in the directory, I mean directly in the directory, so in a directory which is in the directory would not count). For the ...
0
votes
1answer
49 views

What is this type of chart called? [on hold]

What is this type of chart called. I have heard pictorial mentioned but are there other names? Is it defined anywhere? Simply shows proportion and type. Thanks.
5
votes
2answers
65 views

Return value of Reap when using tags

I've noticed a behaviour of Reap that I don't quite understand yet. Suppose I want to Sow several values during a computation. ...
14
votes
0answers
261 views
+50

Proving the hairy ball theorem using xAct

I would to formally prove the hairy ball theorem in Mathematica, initially just for the $S^2$, and then see about generalizing. An approach I thought about to use the xAct package to define $S^2$ and ...
2
votes
3answers
394 views

Create a planar graph from a set of random points

A planar graph is a graph embedded in the plane in such a way that the edges intersect at vertices. This is an example of a planar graph: g = GridGraph[{3, 3}] ...
0
votes
0answers
44 views

Bad fonts in Mathematica 10

In Mathematica V10, the glyphs for mathematical and/or other special symbols are wrong. I see this in input cells and also in the Basic Math Assistant palette. How do I solve this problem?
2
votes
2answers
200 views

Integral converging in M9 but not in M10 [on hold]

Background: Mac OSX 10.9.4, Mathematica 9.0.1 vs. Mathematica 10.0 (both versions are Student Editions). I have a notebook. It used to evaluate fine in Mathematica 9. I upgraded to 10 and, without ...
1
vote
1answer
71 views

Horizontally compress a picture with varying compression ratio

I have a function c[x] whose domain and range are both [0,1]. And I have a picture with width W, height ...
4
votes
1answer
121 views

Export to PDF on OS X, font missing on Windows

Here is another problem with Mathematica plots and PDF. I have Mathematica 9.0.1 on Mac OS X. I want to export my plots to PDF to include them in a LaTeX document. If I export the plot with the ...
0
votes
0answers
25 views

Importing multiple images for machine learning classification

I want to create a ML classifier using images just like this example. I have two classes of images in two different folders. Is there an easier way to import all images from both folders rather than ...
2
votes
0answers
36 views

How to solve for exponents in an infinite product?

Say I have a power series, $f(x,y) \in 1 + x\mathbb{Z}[[x,y]]$ Then it admits a unique expansion $$f(x,y) = \prod_{i=1}^\infty \prod_{j=0}^\infty (1 - x^i y^j)^{n_{i,j}}$$ for some integers, $i, ...
11
votes
4answers
199 views

Make MapIndexed listable

My goal is to apply MapIndexed to every element of a nested list without destroying the arithmetic operations within the elements. For example, let's start with ...
4
votes
3answers
203 views

DSolve not finding solution I expected

Try to solve the following ODE via DSolve $$ \left\{\begin{aligned} y'(x)+2 y(x) e^x-y(x)^2 &= e^{2 x}+e^x \\ y'(0) &=1 \end{aligned}\right. $$ The ...
2
votes
0answers
30 views

Two problems with NDSolve when using Method -> Projection

I tried to solve a system first order differential equations together with a constraint equation. I use the Method -> Projection to check if the constraint holds ...
0
votes
2answers
228 views

Integrating polynomial functions over polytopes with an add-on package

There is a Mathematica package to evaluate integrals over polytopes: http://library.wolfram.com/infocenter/Books/3652/ In the documentation (Functions.nb file) I ...
7
votes
1answer
68 views

On using DiracDelta[t] in OutputResposne in version 10. Different result from version 9

I am baffled by this. I was trying to run same example I had working in version 9.01 and found now I get empty plots. The example is here . Here is a simplified version of the above. The same exact ...
4
votes
3answers
165 views

How to count the integer grid numbers defined by inequalities?

I have the following code to show a red area defined by inequalities: ...
4
votes
0answers
24 views

How to export .mtl files for 3D textured objects

I would really like to deploy my textured 3D graphics in the web with sketchfab in my blog. Unfortunately, Mathematica only exports the shape of the 3d graphics, i.e. the .obj file, but omits the ...
2
votes
2answers
222 views

Need help evaluating definite integral to a function of Y

Suppose $Y = \sqrt{2T}\cos(U)$, $ 0 \le u \le \pi $, and $ 0 \le \cos^{-1}(\frac{y}{\sqrt {2t}}) \le \pi ) $, so $ -1 \le \frac{y}{\sqrt{2t}} \le 1 $, with all $ \mathbb{R}$. The iterated integral ...
1
vote
1answer
34 views

Connect to Windows kernel from Linux computer

I've seen many questions regarding the connection to a Linux machine from a Windows one, but I need to do the opposite. Situation: I have Mathematica on my Linux laptop (...
10
votes
1answer
349 views

Map of Specific US States? (Isolated)

My question here is fairly basic, and I'm sure I'm overlooking something basic. I know about CountryData for creating shapes of entire countries, and it works, to ...
7
votes
2answers
156 views

Slow work of SQLInsert with SQLite

I want to store my data in SQLite database, but writing large numbers of data its too slow. For example: ...
6
votes
4answers
732 views

Can't compute definite integral

Consider a scalar field (in polar co-ordinates), $f(r) = l-r$. Now I want to evaluate the field integral over a circular region of radius $b$, centered at a distance of $x$ from the origin. According ...
6
votes
2answers
215 views

Using NSolve in the complex plane

I am trying to find numerical values for $\Im\ e^{\frac{1}{2} +i\ y} = \Im\ \zeta(\frac{1}{2} +i\ y)$ for a given range. I have tried: ...
1
vote
1answer
56 views

Appending to $Assumptions - Error “Nonatomic expression expected” [on hold]

I need to use lots of assumptions in my code. Therefore I put them into the $Assumptions variable. When I do it like this, all is well: ...
3
votes
2answers
80 views

Expectation of a composite Markov-Gamma distribution

In a model I have a discrete two-state first order Markov process, defined by a (2x2) transition matrix with two free parameters. If the first state occurs then the process outputs zero for that ...
2
votes
3answers
196 views

How can I get the function of a plotted trajectory? [on hold]

I solved two ODEs, which are a function of t, numerically. The first ODE is the vertical equation of motion and the second one is the horizontal equation of that ...
2
votes
1answer
87 views
-5
votes
0answers
31 views

Visualization of tangent plane [on hold]

Please send me comple source code of http://demonstrations.wolfram.com/TangentPlanesOnA3DGraph/
0
votes
0answers
35 views

Lightweight Grid preferences screen stopped working after v10 install

I am getting the following error when I try to open the Lightweight Grid "Preferences" tab... ...
9
votes
3answers
914 views

Replace expressions with symbols

First of all: I'm new to Mathematica, so I would appreciate it if the answers are quite complete. I have the result of calculation that is expressed in $\sin$ and $\cos$. Now, all of these can be ...
8
votes
2answers
81 views

Automatically add appropriate prefix to Quantity

Is there a function that automatically adds the appropriate prefix to a Quantity object? For example, I would like a function ...
12
votes
1answer
102 views

Is it possible to insert new colour schemes into ColorData?

Because of the standards in my field, for many plots I need to use (or at least end up using) rather narrowly defined colour schemes, and in particular the Matlab "Jet" scheme, which is well described ...

15 30 50 per page