Linked Questions

215 votes
26 answers
18k views

What are some useful, undocumented Mathematica functions?

There have already been some questions about some undocumented functionality in Mathematica. Such as (please add to these lists!) How can one find undocumented options or option values in Mathematica?...
33 votes
7 answers
4k views

How to Derive Tuples Without Replacement

Given a couple of lists like a={1,2,3,4,6} and b={2,3,4,6,9} I can use the built-in Mathematica symbol ...
Sinistar's user avatar
  • 1,029
9 votes
7 answers
2k views

What is the inverse of CoefficientList?

I have numbers in vector notation. I need to get polynomial notation from them. My numbers are {0, 1, 23, 5, 15, 0, 0, 0}. I want to get $x + 23x^2 + 5x^3 + 15x^4$...
Serkan's user avatar
  • 183
14 votes
7 answers
3k views

Find and highlight sequence patterns in a list

Again, I have a list like this: ...
holistic's user avatar
  • 3,045
20 votes
4 answers
879 views

What is the best way to flatten a linked list with lists as values?

By following the advice on this site I have ended up with a linked list like the following: acc = {{1, 2}, {{2, 3}, {{3, 4}, {{4, 5}, {{5, 6}, {}}}}}}; This was ...
Shredderroy's user avatar
  • 5,371
15 votes
6 answers
911 views

Partitioning an integer into $k$ equal parts

Say I have an integer $M$. Is there a one-line command to create a partition of $M$ into $k$ integers s.t. the difference between any two integers is as small as possible? For example, with $M = ...
Quantized's user avatar
  • 153
7 votes
11 answers
1k views

Convert list of lists to cumulative join

I have this: list[1]={1,2,3}; list[2]={7,8,9}; list[3]={15,20,22}; I want this: ...
Toph's user avatar
  • 179
10 votes
5 answers
543 views

Finding time-series direction reversal of certain magnitude

I'd like to find the points of a time-series that are a certain distance away (in value, not in time) from the previous maximum, which I consider a reversal. For example, for ...
Meh's user avatar
  • 1,637
13 votes
6 answers
403 views

Construct an infix operation from a list

Inspired by this question, if I have a list {a, p, b, q, c} where p and q are binary ...
rcollyer's user avatar
  • 34.1k
9 votes
3 answers
287 views

How to make a ReplaceAll Rule for adjacent items in a list?

I would like to make only one pass of a list of 2D items and replace adjacent items that have matching $x$ or $y$ coordinates with a series of linearly interpolated points between the two points. My ...
Edmund's user avatar
  • 43.2k
8 votes
3 answers
570 views

How do I achieve the function of Continue using Catch and Throw?

Procedural programming is considered a bad practice in writing Mathematica code. But for education's sake, is there any way I can do Continue using Catch and Throw? According to WRI's documentation, ...
btwiuse's user avatar
  • 567
13 votes
1 answer
1k views

Compose many Geometric Transformations for 3D Graphics

I'm struggling to understand what would be a good way to compose several geometrical transformations to create a single TransformationFunction to be applied to a <...
rhermans's user avatar
  • 37.4k
15 votes
2 answers
329 views

Globally loading packages while using a CellGroup as the default context

I have a notebook I wish to set up where the sections are conceptually related to each other. But, I wish to isolate them from each other programmatically, so that they do not interfere with one ...
rcollyer's user avatar
  • 34.1k
6 votes
4 answers
309 views

How can I get a list of the positions of the running minima in a list?

I want the positions of the (sequential) running minima in a list, that is, the positions of entries that have the minimum value of all the elements in that list, up to and including that entry. For ...
Geoffrey Critzer's user avatar
7 votes
3 answers
528 views

mixing color of individual parts of a function in DensityPlot

I have a function which is a sum of three terms and I want to plot it in a DensityPlot. However, I would like that the ColorFunction would be the RGBColor resulting of the mixed R color corresponding ...
José Antonio Díaz Navas's user avatar

15 30 50 per page