0
votes
1answer
221 views

Using Plot and Piecewise to graph a roller coaster

I am graphing a roller coaster using Piecewise and Plot commands on Mathematica. I have the first 2 Piecewise functions and would like to add a loop to the end of it. Here is my initial graph: This ...
3
votes
1answer
79 views

NDSolve: obtain time difference when different solutions get same distance to equilibrium value

I have a numerically solved a differential equation which has an equilibrium value and a starting point, both included as a parameter. I want to plot the difference between the times it takes to come ...
3
votes
0answers
56 views

“Undo” not working for script, gothic, and double-struck letter forms?

Has anyone else experienced anomalous behavior using "Undo" (Ctrl-z) with notational alphabet letter forms? Since Mathematica's built-in functions are capitalized, one generally avoids beginning user-...
4
votes
1answer
211 views

DensityPlot: giving the same color to a range of values

The following command DensityPlot[x y, {x, -3, 3}, {y, -3, 3}, PlotLegends -> Automatic, ColorFunction -> {"Rainbow"}, PlotRange -> {{-3, 3}, {-3, 3}}] ...
5
votes
0answers
58 views

Can I customize the shell command line prompt?

Is there a way to customize the command line prompt (e.g., colorize it) for MathKernel when it runs as a shell command (in general, but specifically on OS X)?
3
votes
2answers
194 views

Automatically detect higher slope in numerical data (within a certain range)

Suppose the dataset data is part of some simulations whose results should follow a certain model. Here is data and its ...
2
votes
0answers
121 views

Brownian Bridge - Multiple Paths [closed]

I am attempting to simulate multiple Brownian Bridges on the interval [0, 1]. I have the following snippet: ...
0
votes
1answer
128 views

Integrating 2d exponential function symbolically with polynomials of 2nd order running for days

I'm trying to integrate this function by Mathematica ...
2
votes
0answers
149 views

import of a opj file (Origin)

Is there a way to import a file of opj-type? Or do you know a package to convert the data? The Import[] function seems not to know this format.
4
votes
2answers
164 views

Modifying the content of a list

If I have a long list of form {{1,2,3,4},{5,6,7,8}, ... {97,98,99,100}} how do I edit/convert it by adding the text as shown below ...
0
votes
1answer
83 views

ParametricPlot and Piecewise function

I want to create a ParametricPlot with multiple Piecewise functions in it. I have tried the following code but it doesn't work ...
15
votes
2answers
512 views

How to generate a closed B-spline curve?

I wrote a function called deBoor using the Cox-de Boor algorithm to generate a B-spline curve. ...
1
vote
1answer
142 views

How to DumpSave all variables or the whole notebook?

Is there a way to DumpSave all the variables in the notebook? Or better whole notebook so that opening it would restore all the definitions.
5
votes
1answer
374 views

Generating repeated elements in a list [closed]

Is there a function in mathematica that allows you to generate repeated elements inline within a list. For example, let's say you provided this as input text: {1, 2, 3, 4, Repeat[5,3], 6, 7} ...
1
vote
1answer
51 views

Extract list of values associated with specific header within an expression

I would like to have a function that can extract from an expression a list of values that are within the brackets of a certain header at any level: ...
5
votes
2answers
164 views

Why am I getting different answers for an integral depending on method?

I'm trying to carry out an integral and I'm finding different answers depending on which method I choose to integrate with. I assume this has something to do with divergent pieces but I don't ...
5
votes
1answer
237 views

Mathematica 10 on Ubuntu: Extremely slow input and random key inputs

I have some problems with my mathematica 10 on Ubuntu 12.04. First, the keyboard input is extremely slow. I press a key, and then the input comes with a delay. This makes typing very cumbersome. ...
1
vote
2answers
177 views

How to solve this two algebraic equation simultaneously for u and H ?(all real number)

I want to find the non-zero value of H when beta is changing(especially what value of beta when increasing will there be a non-zero H value). H is between [0,100]. This is actually the calculation ...
2
votes
1answer
157 views
6
votes
1answer
101 views

Searching for literal strings with TextSearch

The documentation indicates that TextSearch can be used to look for a "literal string" inside documents, but it appears Mathematica may be applying a regex-style ...
2
votes
0answers
39 views

How to stop auto loading of previously opened notebooks [closed]

I'm trying to prevent Mathematica from opening previously opened notebooks when I start it up. I'm using version 10.0.0.0 on Mac OS X Yosemite. I've dug around in the preferences, and have tried ...
6
votes
2answers
173 views

Techniques to find all local minima of black box function with n continuous derivatives?

I have a blackbox function f on [a,b] that is known to be continuous, and has n continuous derivatives. The function uses polynomial interpolations (but isn't a polynomial interpolation itself), so no ...
0
votes
0answers
53 views

Get Domain resp. implicit piecewise definition of numeric Function

Given the following quintic polynomial ...
3
votes
2answers
171 views

Maximizing a function defined using NIntegrate [duplicate]

I have two functions fn[x,y,z] which is in integral form and I have another function gn[x,y] which is also in integral form ...
7
votes
1answer
124 views

How to add a caption below a cell?

How can I change my stylesheet definition for a cell to optionally add a caption below? For example, I would like to add a caption to my "Program" cells shown here: like this (but with the option ...
2
votes
0answers
36 views

How to find the optimum word length of a group element?

I have a (large, finite, permutation) group, and a group element that I know is a product of length=20 of the generators. But when I ConvertGroupElementToWord, I get a word of length=118. Other, ...
59
votes
5answers
2k views

Advice for Mathematica as Mathematician's Aid

I use Mathematica mainly as an aid in symbolic attacks on problems, usually intermediate or harder and often number theoretic. While Reduce, ...
2
votes
1answer
88 views

2D plot using output from the other function

I would like to get 2D plot using output from the other function. FindInstance[0.5*x^2 + Cos[y + P] == 1, {x, y}, Reals] By changing values of P manually it gives ...
7
votes
2answers
276 views

How to do multi-dimensional principal value integration?

The toy model is: $$\int_{-2}^{2}\int_{-2}^{2}\frac{1}{1-(x^2+y^2)}\, dx\, dy$$ The integrand have opposite sign across the circle $x^2+y^2=1$, so one would expect that the integral has meaning only ...
3
votes
1answer
70 views

Area of a surface spanned by 2 parametric curves

I would like to find the area of a surface spanned by two parametric curves in 3D. I came up with this metric for distance between curves. The illustrations are in 2D for simplicity. ...
4
votes
1answer
42 views

Failure in use of SetPrecision with Filter

I am working with a narrow band filter and I wish to use a high precision version. The filter is defined using Integers with Laplace variable s. Here is the, rather horrific, equation: ...
4
votes
3answers
400 views

How to find a quotient group?

Given a normal subgroup H of a (large, finite permutation) group G, knowing a set of generators for each of H and G, how to find a subgroup K of G that is isomorphic to G/H? (Using Mathematica.)
0
votes
1answer
55 views

Avoiding misconversion of data with ToExpression function [closed]

I've got a list of data with the following structure which can be easily converted To expresion by some manipulation such as ...
1
vote
1answer
178 views

Linear Fit of multidimensional data

I am trying to find linear decomposition of vector B (of arbitrary dimension $n$) in the form : $B = \alpha_{1} C_{1} + \alpha_{2} C_{2} + ...$ where $C_{i}$ are known vectors (of dimension $n$) ...
1
vote
1answer
192 views

Kernel is crashing during evaluation of FindRoot [closed]

I have a bunch of aux functions and constants ...
8
votes
2answers
466 views

n-dimensional plot

I want to plot 6-dimensional data using parallel axes (https://en.wikipedia.org/wiki/Parallel_coordinates). The list looks like this: ...
15
votes
3answers
770 views

How to zero (or replace) the diagonal of a square matrix?

Zeroing the diagonal of a square matrix is an operation I need frequently, but somehow I still haven't managed to find an elegant solution that satisfies all these requirements: works with both ...
1
vote
3answers
126 views

Differentiation help [closed]

I am new in Mathematica. I want to differentiate ...
3
votes
2answers
268 views

Finding the FWHM of a NonlinearModelFit gaussian [duplicate]

I have a NonlinearModelFit in a very large program, f1 = NonlinearModelFit[d1, a Exp[-(b (x - c1))^2] + yoff, {a, b}, x] Which is used in my program to produce ...
5
votes
1answer
35 views

How could I set TimeConstrained globally?

I want to set TimeConstrained globally, I tried use $PrePrint as bellowed script: ...
24
votes
1answer
712 views

Efficient lazy weak compositions

In Mathematica all weak k-compositions of integer n can be generated using permutations of integer partitions: ...
17
votes
1answer
201 views

SeriesData sucks when it can. How do I keep SeriesData from sucking?

When I run Series[f[x]*Sin[x],{x,0,3}, Analytic->False] I get: f[x](x-x^3/3+O[x]^4) as expected. In ...
1
vote
0answers
46 views

What ratio of example per class gives best results and least overfitting?

For an n-class classifier or predictor, how many positive (or negative?) examples of each of the n classes should I put into my training and testing sets for the best results? I anticipate that ...
7
votes
1answer
147 views

What kind of creature is h[c] for definition h[c_][x_] := (* function of x and c *)

To implement "Hero's Method" for approximating $\sqrt{c}$, one iterates the function (x + c/x)/2 for a given number c (e.g., <...
3
votes
0answers
54 views

Importing binary structured C++ data file

I am trying to import a binary data file. It seems that BinaryReadList would be appropriate? However the data file is composed of c++ structures like this: ...
6
votes
3answers
120 views

Monitor the computation only if a certain Option is given to the function

Suppose I have the function heavyFunction[x_]:=Module[{n},Do[Pause[0.1],{n,100}]] representing some complicated and time-demanding computation. I want in some ...
4
votes
0answers
92 views

Optimization of recursive functions by using the //. operator [duplicate]

In some cases, recursion in Mathematica (without storing values) is not very efficient. For example, the recursive implementation of Fibonacci numbers (version which doesn't store the values) : <...
19
votes
5answers
687 views

How to delete subsets quickly?

I have some data like this: ...
3
votes
0answers
97 views

VS c# NetLink - pictureBox - MathCommand

Has anyone experiance or a running example how to use within VS C# the NetLink.UI pictureBox to plot graphics, especially using the pictureBox - "MathCommand" I use the code example below which throw ...
5
votes
3answers
230 views

Simple exercise using the function Cases

I'm having some trouble in the following exercise: Find which elements of the list are prime numbers or divisible by 3. list = Table[i^2 - 6 i - 1, {i, 0, 15}] ...

15 30 50 per page