All Questions

218 views

new kernel for notebook

I know I can create a new kernel for my notebook from the evaluation menu but is there a command for this? I'd really like some of my notebooks to startup their own kernel as the first line of code.
68 views

Why does MemoryConstrained have an upper limit on the constraint?

When evaluating MemoryConstrained for a large memory limit: MemoryConstrained[Print["aaa"],10^10] I get: ...
372 views

I have ...
241 views

Why does one of my Manipulate integer variables get turned into a real?

I'm developing code for manipulating graphs. Spot the difference in the 2 Manipulates below: ...
137 views

Time Varying Payoffs?

I'm trying to write some code that will return the final value of an annuity whose monthly payouts may or may not be constant each month. Right now I have working code for constant payments, but I'm ...
976 views

Fast way of finding position of Interval containing an Integer

I have a large list (about 2.2 million) of pairs of integers. Each pair defines an Interval[{}]. Given some integer x, I need to ...
89 views

How can I change VertexWeights in a Graph?

Bug introduced in 9.0 or earlier and fixed in version 10.0.0 I evaluate ...
41 views

is there a way to construct a pattern that would trigger when an expression is used as a held/unevaluated in some form?

For example, consider the following code f[x_] := (Print["evaluated f"]; workWith[x]); We use it, then f evaluates: ...
122 views

Hide MathKernel Tab on Taskbar when using C++ [duplicate]

I am connecting to MathKernel.exe using C++ via MathLink on Windows. Hence, to create the link, this is what I use: ...
68 views

Conditional clustering of elements

I have a long list like: ...
114 views

This may be a simple question. Please close it if it is already answered. I have a nested list kr = {{35, 32, 27, 20}, {36, 33, 28, 21}, {37, 34, 29, 22}} I ...
111 views

How to apply RootLocusPlot correctly

I have to analyze the complex regions of variable c which is define obtained with InverseLaplace help in the form ...
77 views

Extension of harmonic number to the real domain

What is exactly the domain of validity of the identity: Sum[1/(k + j - 1), {j, 1, i}] == HarmonicNumber[k - 1 + i] - HarmonicNumber[k - 1] when ...
204 views

NDsolve with variable end-point

I want to plot the solution a coupled ODEs as a function of the end point only. Mathematica code: ...
72 views

Approximate to the speed of Build-In functions

In Mathematica, there is a function PowerMod[a,b,m], which computes a^b mod m. I will concern only this case: ...
700 views

What type of solver does Mathematica use in LinearSolve

I have a question regarding linear equation solvers. For a specific 9-diagonal matrix, every method I tried in C++ (Gaus, GCC, BICGTAB) didn't work (even though they worked for other matrices). But in ...
186 views

Computing Smith Normal form of a matrix with mod p coefficients

I would like to compute the Smith Normal form of a matrix with coefficients in GF(p). In particular, I am interested in GF(2). I have used the Smith normal form packages for integer and polynomial ...
231 views

Fourier Transform Help

I'm trying to do a Fourier Transform of the following Data, but I'm completely stuck. Here's what I've done so far: ...
57 views

Filter through list and lump data [duplicate]

I have a very large data set (around 3000) that looks like: ...
84 views

Invariant error plot for an arbitray system of ODE

i try to use InvariantErrorPlot command for a generic system of ODE but i find only example with pre-building equations from Mathematica Packages. This is one of ...
414 views

2D Cellular Automaton: Initial conditions

I'm trying to write in Mathematica for a 20x20 grid, with 100 colours, with 4 neighbours. I want the initial conditions to be a 20x20 matrix consisting mainly of zeros. ...
223 views

Export results to excel

I have the following problem solved in Mathematica ...
483 views

Combine Plots into a single non-rasterized Graphic with no spacing [duplicate]

Suppose that I have two plots, pl1 and pl2: ...
65 views

I need to cite the same reference several times. Mathematica citation manager messes up

Mathematica cannot seem to properly number citations when there are several citations to the same reference. Is there some trick to make this work?
367 views

What does rule 30 mean in this example? [closed]

This starts with the list given, then evolves rule 30 for four steps. ...
538 views

What does ImageSize -> 1 -> 1 mean?

On the page http://www.wolfram.com/language/gallery/blur-faces-in-an-image/ the example code has ImageSize -> 1 -> 1. I am unfamiliar with this chaining of ...
326 views

Wait / sleep miliseconds

Is there any way to make Mathematica stop for some miliseconds? I know about the Pause[] but it seems it only works with seconds.
139 views

Code Performance Tuning

The following code takes over 4 seconds to run. Any one has suggestions to make the expressions for qf, phi, ...
244 views

How to make an arbitrary number of plots have different labels/colors/etc?

I'm sorry but I'm not sure how to phrase this question well. Frequently I have a function that produces and returns a Plot[] or array of Plot[]'s, which I can then display with Show[], or combine with ...
67 views

Is there any way to define a new binary operator? [duplicate]

I am looking to define a new operator that would work similarly to the + or - operator. My end goal is to make a dice operator for calculating random distributions in the normal d20 fashion (e.g. 5d6 ...
781 views

Problem inserting data into a mysql table with column names having a space

I have a mysql table whose column name has space. I tried inserting the data into this column. I got an error I tried a sample code, which tests accessing the columns with a space and that returns ...
1k views

Parametric plot of multiple graphs on the same axes

I'm trying to plot on a single axes system multiple graphs but ran into a problem when tryinf to label my graphs. Here's what I've used so far Mathematica code: ...
2k views

I am the admin of a Facebook group for our year at university and wanted to graph the members of the group like you can with your own friends so we can find the isolated people and get rid of them (as ...
379 views

Sorting a large file

I have some huge logs, which are text files, containing up to a million rows each, and I need them sorted. Because trying to import one obviously makes Mathematica run out of memory, we must rule out ...
625 views

How to match a cyclically repeating sequence?

I have run across several times recently where I must match a sequence that is cyclically repeating. For example, with the sequence, Sequence[a, b, c] how would ...
215 views

Mapping the imaginary axis of the complex (s) plane

In this problem is very difficult to analyze the roots s. Firstly I thought that the problem is in precision, but I am not sure. The criterion which I want to obtain is that one of these roots has a ...
393 views

How to get a country's official languages?

According to Wikipedia Of the 193 widely recognized countries, 178 have an official language at the national level (NB:or more than one) The only exceptions are: Cyprus, Czech Republic, ...
609 views

Exporting data extensions in fits file

Context In Astronomy the de facto standard for images and data is FITS. I would like to export heterogenous data sets into a single fits file. Attempt I am ...
194 views

Exporting a list as RawData or Data

My problem is quite simple yet I do not seem to figure out the solution to it. I am simply trying to export a list in Mathematica, actually a list of lists of lists etc, something like ...
107 views

To help distinguish the various dimensions, I have a model which outputs a vector in a series of time intervals, I then construct a list of these models. Next, I would like to compute the outer ...
345 views

Drop selection of columns from a ragged array

I have an application where I need to drop some arbitrary list of columns from a ragged array (where of course the shortest array rows have at least all the specified columns). E.g., given a ragged ...
133 views

How to define a function that operate with a base case recursively? [duplicate]

Let's start from the simplest case: say I have a function $f(x)=x$, and let's say I want to define a new function (of $x$) to be its $n$-th power $(f(x))^n$. How should I write the code? I tried: ...
44 views

Functional derivatives in Feynman Path Integral [duplicate]

Is there any package that can simplify functional derivatives in path integrals? For instance the expression (integrate over, $x,y,z,u,v,r,s$): ...
774 views

Differential operator squared

I defined a one-dimensional momentum operator $\hat{p}=-i\hbar\frac{\partial}{\partial{x}}$ in Mathematica p = -I * h * D[#, x]& and I want to get the ...
413 views

Elliptic curve cryptography in Mathematica

I can find no resources for doing elliptic curve cryptography. I have used the finite field package, but I find it cumbersome and it does not seem to have any builtin methods for ECC. How can I get ...
92 views

Square root of a value defined in a finite field?

I am trying to find the right way to compute the square root of a number defined in a finite field. For example, ...
352 views

How to get CUDALink working on linux (Crunchbang Waldorf) with NVS 3100m

I am trying to get CUDALink working on my laptop. I am running Crunchbang "waldorf" which is based on Debian 7 "wheezy". I am a linux novice. The issue is that Mathematica can "see" the nVidia ...
109 views

Are there some other ways to solve a second PDE except DSolve?

I have a partial differential equation as follows: $$\frac{\partial p(x,t)}{\partial t}=\text{Dp} \frac{\partial ^2p(x,t)}{\partial x^2}-\frac{p(x,t)-\text{p0}}{\tau }$$ What I try to do was to get ...