# All Questions

221 views

### J/Link doesn't work with Java 8?

I have some code that successfully uses J/Link (well... until today when something I was doing something with it that crashed the JVM, so), and I recently tried running it under Java 8. I then get a ...
59 views

### How to Overwrite the DisplayFunction?

How to overwrite the display function of TemplateBox? For example, if I have: ...
111 views

### Casting Dataset internal type from Assoc to Struct

Using: planets = ExampleData[{"Dataset", "Planets"}]; The full form of this projection displays the internal type def: ...
357 views

### How to replace the first occurance in an expression instead of replacing all?

Is there a function that replaces the first occurance of the expression instead of replacing all? For example, if I have HoldForm[x + 2 + 4 + x] /. x -> 4, is ...
420 views

### How do I store values in a for loop into an array and then plot that array? [duplicate]

What my title said and I want to plot the values of the array. still new to mathematica and programming so its hard to formulate my question just right
63 views

### Invisible number?

Is there a way to define invisible numbers? Invisible[x] only gives the space of x, what if I want to have, for example ...
1k views

### How to assign a list of numbers into letter grades

Here is my list: ...
108 views

### Help explain a piece of code [closed]

I am a beginner of mathematica. I don't fully understand the following code from Another weird plotting result. ...
59 views

### solving nonlinear equation

I typed this below code in mathematica 9.0 but wasn't solved: ...
804 views

### Finding the surface area of a 3D convex hull

I have noted several instances here and here where ConvexHullMesh, introduced in v10 has been used to greatly simplify some geometry problems. Determining the ...
24 views

### Coloring problem in plot3D with transparent texture [duplicate]

I need to plot multiple surfaces with textures. Each texture is a matrix plot with transparent background. In this way, we can see the multiple surfaces from the top. ...
225 views

### Another weird plotting result

I asked a question this morning here, which has been resolved. However, I got another problem. I want to add some lines to the graph, which turns out glitched. The code is as follows, ...
313 views

### Random Integer Sequences

I want to construct a random square matrix in the following manner: a) Three states [0 | 1 | 2] are repeated ...
83 views

### JordanDecomposition in Mathematica

I'm trying to find the Jordan Decomposition in Mathematica for  A=\left( \begin{matrix} 2& -5& 8&-12\\ 1& -2& 4&-8\\ 0&0&2&-5\\ 0&0&1&-2 \end{matrix} ...
145 views

### Unable to compile to C

I used to be able to compile to C without problems, but from one day to the next, when I try to compile something, e.g. ...
61 views

### parsing a list or vector

I have a table of elements that generate a list q[i_]=i; B=Table[q[i],{i,1,50}] I would like to parse the list meaning, take the first 10 elements, then take ...
99 views

### Make a partition with a rule [duplicate]

I wrote this line of code : {{1, 1, 1}, {1, 1}} /. ((x___ /; Length[x] > 2) -> Partition[x, 2, 1]) generates this error : Partition::pdep: Depth 1 ...
199 views

### Import displays DICOM images as black rectangles (Mma v. 10)

My problem concerns Mathematica version 10.0.1.0 with OS X 10.9.4, OS X 10.9.5 and it does not occur in Mathematica version 9.0.1.0 (on the same computer and OS). About 90% of my DICOM images are ...
113 views

### Dealing with implicit function [closed]

I encounter a big problem when I use Mathematica to deal with implicit functions. ...
408 views

### Combining many plots with Show produces wrong x-axis position and wrong filling

The code is as follows, ...
574 views

### Drawing an arrow or a solid dot on a curve?

I want to draw arrows and the solid dot like in this picture on a curve.
112 views

### Question about using NDSolve with a matrix equation

I tried to use NDSolve to study a matrix-valued differential backward equation. The following program seems to work: ...
486 views

### WSTP broken by upgrade to 10.0.1?

Bug introduced v10.0.1 and fixed in 10.0.2 Everything was working fine with WSTP (the successor to MathLink) in 10.0.0. But I upgraded to 10.0.1 today and now I can't compile either my programs ...
94 views

### Similarity of two plot to each other [closed]

I want get the similarity of two different plot by Percent ... I have many plots for comparison like below : y : ...
124 views

### How to avoid the initialization cell evaluation dialog box?

I have a Mathematica notebook, a 940 NB file divided into 25 Sections. When I evaluate a cell with Shift+Enter, I always get a dialog box as shown below: Question: Is it possible to avoid it by ...
252 views

### NDSolve giving the wrong solution?

I'm considering the non-linear second order ODE DE $=0$, with DE given by ...
2k views

### How to generate a cartoon of a face

I want to use Mathematica to generate a cartoon of a face. For example, some thing like this: I think it can be done using Mathematica, but I really don't know how to do it. How can it be done, and ...
995 views

### How to make a 3D topographic globe?

I've made some attempt with this dataset of elevation. But I have some trouble with ListSurfacePlot3D, which can not show the globe correctly: And I've checked that the data is out of problem, ...
407 views

### How to use SparseArray in CUDA?

Sparse arrays are widely used in many scientific applications where memory and time are strictly limited. For a considerable speedup one can use CUDA. Since Mathematica 8 we can conveniently use CUDA ...
96 views

### Verify positive definiteness using random numbers

I wish to verify whether T'T - IdentityMatrix[2] is always positive definite for a certain choice of elements of T'T. ...
92 views

### how to depict a network with a legend

Because my network nodes have real world names more than a few characters long, I'd like to label them with a shortcut, e.g., n1, n2, n3, ..., and put a legend on the side something like this: n1 - ...
658 views

### Mathematica's equivalent to the Python's Zip command in List-comprehension? [closed]

What is Mathematica's equivalent to Python's ZIP command? Is this called nesting? It means iterating over sub-sets of values like the below example. How can I do it in Mathematica? Example in Python ...
151 views

### getting vertices in order from spanning tree

I've got spanning tree for some weighted graph (edges labeled 1-6) - for example: ...
75 views

### Right data format when EmpiricalDistribution expects “Rectangular Array”

I have the following code to generate random data (these are the eigenvalues of a non-central Wishart matrix, and I am interested in their distribution). ...
219 views

### Finding Hamiltonian path in Graph

I have weighted, undirected full graph (generated from points in R^2), where weight between every two vertices are euclidean distance between corresponding pair of points. What I'm trying to do is ...
110 views

### The “Save” under “File” and “Undo” under “Edit” do not work in Mathematica 10.0 [duplicate]

Bug introduced in 10.0 and fixed in 10.0.2 Each time I click "Save" or "Undo" button from the notebook menu, some new notebook window similar to this pops up: And the file is not actually saved ...
1k views

### Creating a foggy image

I want to create foggy images like this one (produced with Adobe Photoshop): Not at least familiar with Mathematica's Image processing capabilities, the only ...
107 views

### Save value computed in the loop and delete it

I am using For loop to calculate a value $z$ in every cycle. I would like to create a text file, save the current value $z$ in this file and afterwards delete the value from Mathematica's memory. I ...
78 views

### NMinimize ignoring conditions imposed on solution [closed]

I have to solve a problem about Linear Programming (optimization) which is stated as follows: Minimize: 0.75x + 0.5y + 0.15z Conditions: x > 0 y > 0 z > 0 35x + 0.5y + 0.5z >= 0.5 60x ...
178 views

### FindMinimum and NMinimize to solve equations

I know that I'm not a Jedi in solving Equations and minimizing functions; but now I've this problem, and the solution is far to me. I want to solve this equation: ...
145 views

### How smart is Solve? Figuring out what tricks I should try

I'm trying to solve a large system (~10000) of linear equations using Solve, but the process keeps failing. As-is, I don't know whether it's failing because it's using too much memory or too much time ...
676 views

### An intuitive way to form an augmented matrix

Given an $m\times n$ matrix $A$ and a $m\times 1$ vector $b$, what is the most "intuitive" way of forming the augmented matrix $[ A\ b]$? The most concise way that I know of is ...
228 views

### Combining solutions while solving

Here is a simple representation of my problem. I want to solve Solve[(w^2*c^2 /. #) - 1 == 0, w]& /@ {{c -> 1}, {c -> 2}} ...
178 views

### NDSolve Wave Equation - Triangular Wave Pulse Inital Condition

I am trying to solve a simple damped wave equation with transparent boundary conditions with triangular shaped piecewise function as my initial condition. I understand that there are issues with this ...
264 views

### How to restore function attributes to default

Adding an attribute to a function is easy and clearing attribute is easy also. But I don't know really how to restore the attributes of a function to its defaults. All I do is quit the kernel or close ...
120 views

### Export textanalysis to pdf

In the helpfile there is a nice axample of text analysis (example/LexicalAnalysis) ...
325 views

### Can I use the values of interpolating points from NDSolve's output? And How?‎

The output of NDSolve is a (list of)InterpolatingFunction(s). In standard output format the ‎elements of interpolation are not ...
81 views

### Elementwise operation, part deux [closed]

There are many answers to this question: which are forms of Mathematica's map, but languages like Scheme (I think also Python in recent years) also provide a ...