All Questions

Filter by
Sorted by
Tagged with
29
votes
3answers
10k views

What are the advantages of using .nb rather than .m files?

I can edit a notebook within the mathematica front end and then Save As a .m file, which produces output like this: ...
10
votes
1answer
391 views

Import converter that can import, split, and compress files?

I'm working with a data format that prescribes separate header and data files, so for instance "file.hdr" and "file.dat". They ...
5
votes
2answers
238 views

How to fit a one-dimensional dataset with respect to several bounded parameters?

I have this set of data ...
0
votes
0answers
75 views

Defining functions in a loop [duplicate]

I have a symbolic solution to a linear system with respect to some variables a[i,j] which depend on a parameter t. sol=Solve[...,Table[a[i,j],{i,0,n},{j,0,n}]] I ...
21
votes
1answer
291 views

How to format usage messages such that function templates are parsed correctly?

Is it possible to format usage messages (with italic arguments etc) such that Mathematica 9 still parses function templates correctly? For example, plain usage messages work when pressing Ctrl+Shift+K:...
3
votes
1answer
139 views

Why don't rules applied inside ContourPlot3D work?

The output of the following code is the same as the input. ...
0
votes
2answers
122 views

Cases Message Valid Notebook Structure

Note: Spelunking will likely be needed. Execute the following. You should get back and error along the lines of First::first:... This error is unimportant except ...
3
votes
2answers
133 views

How to add a label to a CopyEvaluate button?

I found a definition of a button Button[Defer[ Information[ \[SelectionPlaceholder], LongForm -> False]], None, BaseStyle -> "CopyEvaluate"] that is ...
2
votes
0answers
457 views

Positive integrand giving negative answer

I'm integrating a positive function f(t) times sin(t) from 0 to pi/5 and get -38. Actually f is slightly negative for a short time (smallest value ~ -0.0005), but far from enough to explain this. ...
6
votes
2answers
734 views

How to add a graphics frame to an image without resampling

Using Inset to place an image inside a Graphics expression with Frame -> True provides a ...
0
votes
1answer
225 views
1
vote
2answers
1k views

Peak Signal to Noise Ratio of Images

I am filtering a blurred image, and want to evaluate the performance of Peak Signal to Noise Ratio (PSNR) in Mathematica version 9.0. But I am facing the problem of evaluating the PSNR. Could anyone ...
0
votes
1answer
1k views

Use the same scale for two ListContour plots [duplicate]

I have two ListContourPlots which have different min and max height values. ...
1
vote
2answers
110 views

The order of the result $x^2 \left(b-\frac{a}{2}\right)+(a-2) x^3+\left(2-\frac{b}{2}\right) x+4 x^4-1$ [duplicate]

Can you explain me a little how Mathematica sort this result, and how to sort in descending powers of $x$ ...
6
votes
2answers
645 views

Package relative file path specification

I have some packages inside a folder (named Packs) that is in the same file level of some executed package. ...
7
votes
4answers
2k views

Identifying and counting closely spaced particles

Following in the footsteps of this blog post: http://blog.wolfram.com/2011/09/09/building-a-microscopy-application-in-mathematica/, I took a microscope picture of some particles on a surface, and ...
5
votes
2answers
1k views

How can I speed up my code?

...
16
votes
3answers
2k views

What is the right way to construct DynamicModule

When I'm creating DynamicModules for CDF purposes I'm usualy basing on my experience with that, particular goal and content rather than on deep insight. I want to ...
2
votes
1answer
343 views

Confidence level for Binomial

For 617519 first time births there were 317528 boys. Give an estimate with 99% confidence interval for the probability that the first time birth is a boy. I have searched for the confidence interval ...
3
votes
3answers
458 views

How to construct a stacked barchart

UPDATED to clearify I want to construct a stacked barchart from a list with three elements: list = Table[{i, x, y}, {i, 10}] where x has a value between 0 and ...
8
votes
2answers
223 views

Alternative to NotebookLocate or NotebookFind

In Mathematica 8.0 and older, there are two ways to select cells based on cell tags. NotebookLocate["CellTag"]; NotebookGet[EvaluationNotebook[]] and ...
-4
votes
2answers
634 views

Image Processing Mag and Phase Spectrum of Sobel, Roberts Mask [closed]

How to find the Magnitude and Phase Spectrum of Sobel, Roberts etc. etc. Mask of Image Processing using MATHEMATICA 9.0 platform....
1
vote
1answer
254 views

Linear interpolation between defined anchorpoints in an array (where anchorpoints are set each time we see a new element)

This question is an update and a correction my earlier question: Linear interpolation of a list between periodic anchorpoints (which was nicely answered). Imagine I have a list of the form: ...
3
votes
2answers
166 views

Linear interpolation of a list between periodic anchorpoints

I have a list of the form: list = {1,1,1,2,2,2,3,3,3,4,4,4,7,7,7,19,19,19}; Where we can see that there are an ordered set of integer values that repeat ...
8
votes
0answers
252 views

What range of ports do remote kernels use?

I'm trying to run a remote kernel, but my local system administrator is wary of opening up ports for incoming connections. Is there are particular range of ports that Mathematica uses for remote ...
45
votes
5answers
1k views

How can the behavior of InterpolationOrder->0 be controlled?

In ListPlot and Interpolation, the option InterpolationOrder->0 uses two different ...
3
votes
1answer
938 views

Limitations of ParametricNDSolve family w.r.t objective functions

Observation: I can see even for very simple modification in case of an scalar objective involving an definite integral in time ParametricNDSolve fails. Here is an ...
7
votes
1answer
599 views

Rotation of Graphics3D like rotating Plot3D

I like the way 3D plots are rotated with the z-axis always pointing up-down. Is there an elegant way of forcing that type of rotation on Graphics3D? I have tried the following: Using an invisible ...
5
votes
1answer
175 views

How do I make two styles in a stylesheet inherit the same style

Specifically I want different versions of 'Item1Numbered'. For example one with a frame and another with a background colour. How is that done?
6
votes
5answers
410 views

Is there an analogue of the Variables command for general expressions? [duplicate]

The command Variables[poly] gives me a list of all variables that appear in the expression poly, which involved sums, ...
3
votes
1answer
63 views

Search function stops working after converting to CDF

My problem is, that when a make a notebook and convert it to CDF using the 'CDF-Export', the search field, which appears on CDF player, does not work. When trying to search for a word, the computer ...
4
votes
1answer
466 views

How to demonstrate lack of stability with advection equation

I am trying to that using a coarse grid with an explicit method for, say, the advection equation leads to an unstable solution. The trouble is Mathematica avoids unstable solutions with good ...
6
votes
1answer
231 views

Force Dispatch to generate dispatch tables

Dispatch creates hash tables only for lists of length larger than 3. Is there any way to force MMA to create hash tables even for lists of length smaller than 4? ...
4
votes
1answer
177 views

How to make a list/matrix out of an expression?

I would like to make a matrix out out of the following expression: $$ (\Omega^2 (2 d\theta^2 + d\phi^2 - d\phi^2 \cos(2 \theta) \coth(\chi)^2) + (2 d\Omega^2 + (2 d\theta^2 + d\phi^2 - 2 d\chi^2)...
22
votes
3answers
1k views

How to create a simple cross eyed 3d plot

I wanted to create a stereoscopic view of my threedimensional plots, so I can interpret them better. The basic things, one would need, are two plot windows which are somehow connected to each other ...
5
votes
1answer
1k views

Evaluating function only when its optional argument is numeric

I want to have the argument 'a' for myf2 in form of optional argument, but at the same time I need to evaluate the function only if 'a' is Numeric, see also my previous question. ...
7
votes
3answers
733 views

Manipulate changing controls

Is it possible to use Manipulate and Switch to change the Manipulate controls? ...
3
votes
1answer
205 views

Stop use of Scientific Notation in Tooltips

I have a list of pairs of values that I am plotting in a ListLinePlot. I can use the tooltip functionality fine but I want to stop them from displaying in scientific notation. I have tried the ...
6
votes
3answers
1k views

ListPolarPlot not showing full plot range even with PlotRange -> All

Bug introduced in 8.0 and fixed in 9.0 I have a list of data dpdOt (given below) with associated angular coordinates thetaplot, ...
8
votes
1answer
684 views

How to evaluate an input cell automatically after evaluating the previous one

Is there any way to automatically evaluate an input cell after evaluating the previous one without the need to press ENTER?
3
votes
3answers
506 views

Extracting the coordinates of a point of interest from a ListDensityPlot

How can I extract coordinates from a list density plot. Example plot of interest: I need to place two points on either side of the center white circle and calculate the distance between them. My ...
1
vote
1answer
708 views

NMaximize problem

Could anybody explain to me why the following code fails ? ...
9
votes
0answers
116 views

Fast two dimensional version of Range[] [duplicate]

I have need of a two dimensional version of Range[]. I have a few ideas of varying speeds, and I was wondering if anyone knew a better way to do this. ...
2
votes
0answers
105 views

Is FinancialData for India available? [duplicate]

FinancialData["IndiaNSE", "Members"] // Shallow gives ...
5
votes
2answers
443 views

Dropping value of one variable when another changes

Context: There is a list of lists list where lists are different length. Using one control I change a part of list to view, and with another one — what certain ...
0
votes
1answer
702 views

Export of 3D Plot

I finally got my 3D Graph :) Unfortunately, when I export I get a bad image quality. How can I export the image without the white stripes? Here is the code for reproducing the error ...
0
votes
1answer
235 views

Convert probability example to a distribution

Consider a box which contains 30 balls. 10 red, 10 white and 10 blue balls. There will be picked 4 balls randomly, without putting the balls back to the experiment. My question is: How do I create a ...
0
votes
1answer
2k views

How to plot 2D plot against two functions [closed]

I need to Plot two functions one is on x-axis and second on y-axis, both function have common variable $x$. The two functions are ...
12
votes
1answer
2k views

How to open/close all collapsed/open cells?

Is there a way to open/close all collapsed/open cells? The reason is for a long notebook, it is convenient to see all the section and subsection headings at once.
0
votes
1answer
1k views

How Do I Plot Histograms and Binomial Distributions Side by Side?

Here is the code I thought might yield up two histograms and two binomial distributions plotted side by side: ...

15 30 50 per page