# All Questions

238 views

### Millionaire quiz in mathematica

so here's the deal. I'm trying to write a millionare quiz in Mathematica. Now, this has been already done in other coding languages, specifically I've seen it done in C here: ...
366 views

### How to transform power of -1 into exponential [duplicate]

After FullSimplify, Mathematica usally gives some coefficients like ((-1)^(1/5)) But I don't want this form, I want ...
127 views

### Appending and Prepending columns to a dataset in 10.0.2.0

I just experience a problem in prepending columns to a dataset. I did this a hundred times in 10.0.1.0 - no problems. Now it seems as if it is only possible to append/prepend one column at a time. ...
69 views

### Is it possible to move .mx file from one server to other?

I have mathematica file in one server along with .mx file. Is there any way to move the .mx file from one server to other such ...
33 views

### How to avoid losing the done part of Table when stopping it? [duplicate]

Often, when I use Table, it takes too long to compute all the elements of the would-be table. I then stop it with Alt+. and ...
57 views

### Problem with automatic numbering [on hold]

I have a problem with the automatic numbering of figures within a notebook. I numbered the first five figures via "Insert Automatic numbering"... everything is fine, but when I tried to number the ...
152 views

### ListContourPlot interpolation fails if x and y axes have different scales

To summarize what is below: ListContourPlot doesn't work when the domain has different x and y scales (fails when x/y~10^4, which seems surprisingly small). Is it possible to call ListContourPlot ...
96 views

### about the design of Part related to Association

<|"a" -> 1, "b" -> 2, "c" -> 3, "d" -> 4|>[[1]] gives values 1 while ...
81 views

33 views

### Printing Mathematica Code that isn't cut off

I'm trying to print Mathematica code (no figures) that is often much wider than a typical 9x11 page. Printing to PDF or XPS or any type of file cuts of the edges. I can select "Print Multiple pages ...
54 views

### Can one generate the default output of Hash[expr] (from Mathematica <= 9) in Mathematica 10

Mathematica 10 silently changed the behavior of Hash when the algorithm is not specified explicitly using an option. Is there any way (such as an undocumented ...
68 views

### Performance Issue When Using Manipulate

Any help would be appreciated! I've been attempting to manipulate the graphics for time t. We need to have Di set to 11.2, however when it is set to any value greater than .1, we see a great deal of ...
97 views

### How do I understand this big difference in speed:

A friend of mine found a huge difference in runtime speed between these two ...
134 views

### Function that returns the second argument of Reap

I'm trying to create a function that returns only the second argument of Reap. Here's my naive guess of how it would go : Reap2[x_]:= Flatten[Reap[x][[2]],1] ...
47 views

### FindFit::nrlnum: error with FindFit

I am trying to write a code to fit actual data of the orbit of a star with Mathematica 8. First I tried to write a code to fit a mock orbit, using the Application with differential equations (the ...
28 views

### Order of operations [closed]

What should be correct order of operations in the following equation? 36 / 6 (2 + 2 + 2) Should it be 1 or 36 as a result?
31 views

### Series power with unusual denominator

I have a series whose terms are: (x^n)/(n+a) where n is a positive integer, x a real number that is greater than 0 and smaller than 1, and a is a real number smaller than 1. It is easy to proof that ...
71 views

### More Ticks::ticks errors in AbsoluteOptions in v10

Bug introduced in 10.0.0 While the specific bug affecting Plot described in AbsoluteOptions prints error messages in V10 has been fixed in 10.0.2 there remain ...
36 views

### Fourier and InverseFourier precision

I'm quite puzzled by Mathematica lack of precision with Fourier and InverseFourier. I tried the following code ...
38 views

### Using OpenRead to read an element from a list saved in .mx format

I have a set of large arrays 1D (1-2 million entries) where each element corresponds to a pixel value from a picture. I would like to know how a pixel value changes from image to image (how the value ...
33 views

### Break axes on listcontourplot

I would like to insert a break on both of the axes of a ListContourPlot near the origin, to include a datapoint which has axis values quite far away from the others. The question is similar in nature ...
22 views

### Inverse Fourier transform to get real function [duplicate]

I have got a sampled complex function, $H(\omega)$ and know that its inverse Fourier transform has to be real function $h(t)$, which means that $H(-\omega)=H^{\ast}(\omega)$ has to be fulfilled. If we ...
30 views

### Strange behaviour if FindSequenceFunction

Consider a sequence starting with 2, subtract 2 to get the next term, now add 3 to get the next term and so on according to the rule (-2,+3) consecutively which starts like ...
83 views

### Linux: Mathematica crashes when clicking documentation links very fast

Can someone confirm the following behavior: Open a new Mathematica and go to the documentation. Navigate to any reference page (I used RegionPlot) and click ...
77 views

### multivariate lognormal distribution in mathematica

Is the LogMultinormalDistribution function really the multivariate lognormal distribution? Because I get different results with the same parameters in ...
44 views

### RegionPlot[] using ImplicitRegion[] bug?

Defining R=ImplicitRegion[0 < Sin[x] Cos[y]< 0.5, {{x, Pi/2, Pi}, {y, 0, 2 Pi}}] a region plot RegionPlot@R returns ...
45 views

### NMinimize tries to find the fit to paramters which are not in the objective function

Consider the codes below: fun[x_] := (x - 4)^2 NMinimize[{fun[x]}, {x, y}] it returns: ...
55 views

### Coloring vertices according to a function using GraphPlot3D

This question is similar but not identical to a related question called: coloring-vertices-using-graphplot . I need to color the vertices of a graph according to a function, f that is defined on the ...
87 views

### Timing mathematica code

I have a collection of functions (Modules) and I wish to find out which sub-routines inside the code take up most time. I have done this by wrapping individual code blocks with ...
70 views

### Plotting: Is anyone familiar with field line command?

I am trying to plot this graph the electric field lines of finite line, but I do not know how to express the equations for plotting electric field lines of finite line. Can any one help? Thanks sooo ...
37 views

### NDSolve: Equation with interpolating function [closed]

I have a question regarding DSolve and NDSolve functions in Mathematica 10. For instance, I'd like to solve an ODE: ...
68 views

### Extend a function to all polynomials ( just 2 variables) when one knows its values on monomials

I need your help to make my code faster. I have a formula for computing a value from any monomial $x^i y^j$, say formular1[i_,j_]:=(Gamma[i]/Gamm[j] ). It is just ...
75 views

### Piecewise smooth rectangle pulse

I am wondering how to create a single rectangle pulse with nonlinear riding and falling edges on both sides. I don't know whether it is better to do it piecewise or to mathematically transform the ...
43 views

...
40 views

### Supervised Learning

Hi all I am just starting with mathematica. I wanted to train five fields as input and 3 fields as output in a total of 8 fields in database. I cannot find sample code for this
219 views

### Cut a polygon by a line

I have a polygon, says, Polygon[{0,0},{10,0},{10,10}{0,10}]. I would like to cut it by a line (through two points) and take one half of it. Could you please suggest ...
38 views

### Can mathematica be configured to auto pair different parenthese?

In DrRacket, the editor can auto pair different parentheses, for example code like (let [(x 3 and whether press ) or ...
119 views

### Finding largest Range in a list

In a list of positive integers, I would like to find the largest n such that Range[n] is a subset of the list. So for example ...
30 views

### Loops over multiple variables (negative i_min)

Can someone explain why i ranges from -3 to 3 in the output of Do[Print[{i, j}], {i, -3, 3}], but not in Do[Print[{i, j}], {i, -3, 3},{j,-i,i}]? I was thinking for the second input I would get ...
285 views

### Better answer to Santa's riddle about sum of a number's divisors?

I was hoping to find an elegant solution to this riddle, using only a line or two of Mathematica: Santa Claus was telling one of his elves: "If I multiply the age of three of my reindeer, I get ...
349 views

### Save as pdf broken in version 10.0.2?

It looks like the save as pdf is broken after I update to version 10.0.2. The labels in the plot become a mess. Are there ways to fix it? The Export function works ...
52 views

### I need to make and manipulate a group ( the quaternion)

I am trying to define a group and use it to defined its classes, its character table, and irreducible representations. I am having trouble finding code to define a group and use it.
36 views

### Defining the value of variable after expansion

I have an initial equation defined as: x = Subscript[a, 0] + (1 - r^2)/Sqrt[1 + r^2 - 2*r*Cos[\[Theta]]]; I want to taylor expand this after subbing in: ...
86 views

### Solve a differential equation with an integral inside?

I am trying to solve this differential equation in Mathematica: y'[t]+integral from 0 to t of y[x]dx =e^(-t) where y[0]=0. Is this possible?
94 views

### How would I rotate a table of Cuboids around the y axis?

Currently I can print out this using Graphics3d: Here's the code: ...