Questions on the manipulation of List objects in Mathematica, and the functions used for these manipulations.

learn more… | top users | synonyms (5)

0
votes
1answer
77 views

How to ListContourPlot a functional eigenvalue spectrum?

We have a (Hermitian) matrix of some finite dimension (n) whose elements are functions of real variables x and y. We wish to plot contours of the spectrum (level sets of the n real eigenvalues) at ...
6
votes
1answer
73 views

Function that counts number of consecutive elements after iterator in Table command

I have a 1D Table, something like this, that I want to turn into musical notes: ...
7
votes
3answers
157 views

Nonzero element positions of a matrix

Let m={{1, 2, 0}, {4, 0, 9}}; I want to find the position of every nonzero element of the above matrix. The code ...
11
votes
2answers
264 views

How to mesh a region using adaptive cubic elements

Assume a list of {x,y,z} coordinates. The coordinates are arranged in a regular fashion through a fixed raster size (called ...
8
votes
5answers
291 views

What is the most efficient way to replace items in a list at periodic intervals?

For example, if I want a list of $\phi(n)$ for $1 \leq n \leq 100$ but if $n$ is a multiple of 3 I want to show a 3 instead of $\phi(n)$. I tried ...
1
vote
1answer
41 views

How to solve from a list

I have this equation: $y(t)=aE^{-bE^{-ct}}$ and I have this list: ...
0
votes
3answers
95 views

How can I extract the x and y values from a coordinate pair? [closed]

I think the question says it all. I have a coordinate pair, {x,y} and I want to extract x and y for use in further calculations. Can't find anything in the docs about this but it seems like it should ...
1
vote
1answer
53 views
6
votes
3answers
109 views

Differentiating between zero and “empty” in lists, and adding them?

(Edit: I mean 'differentiate' as in telling the difference between two things, not as in f'(x) ) I have n series of numbers, let's say two for example, with some "empty" spaces between the numbers, ...
3
votes
4answers
116 views

Assign a list of sums to indexed variables

I want to generate a list of sums {a, b, c, d, ..., z} and assign them to a list of variables such that ...
3
votes
1answer
64 views

Import Excel sheet into 3D array, 1st row and column as x- and y-axis

It might be simple, but for me, it took several hours working on, but still cannot figure out. Basically, I'd like to create 3 dimensional list data ({x,y,z}) from excel file, so I can plot them ...
4
votes
2answers
53 views

positions satisfying pattern and grouped

I have a list of numbers and I am looking for a way to most efficiently find positions of values that satisfy a certain condition and group those positions that are sequential. To illustrate, a simple ...
2
votes
3answers
81 views

How to get a C4-symmetric (coincides after 90° rotation) matrix via `ImageData` from `Graphics`?

I tried an easy example with Disk centered at {0,0} with radius 1. Obviously, that object is C4-symmetric. Further, ...
4
votes
1answer
129 views

Insert a symbol include first and last position [closed]

Assume we have a list list = {"a", "b", "c", "d", "e", "f"} Then use this code: StringRiffle[list,"*"] But ...
4
votes
1answer
73 views

Joining table of tuples with table of scalar values [closed]

I have a table of dimension $M \times N \times Q$ of 3-tuples {x,y,z} that represent points, and another table of dimension $M \times N \times Q$ of scalar values. ...
0
votes
0answers
23 views

Finding the percent difference between elements of a matrix and a list/vector [duplicate]

I have a large matrix of 24 columns, 11 rows, and a vector in the form of a one column, 11 row table. What would be the best method of finding the percent difference between each element of the matrix ...
3
votes
1answer
59 views

overlap of data

I have two individual Date lists as Date Objects: List 1 = {1 Jan 1991 9 :00 , 3 Jan 1991 11:00 ..etc } List 2 ={ 7 Jan 1991 14:00, 9 Jan 1991 15:00 ..etc} For ...
4
votes
2answers
113 views

Arc length parameterization of a list of points?

Suppose I have a curve represented by a list of points in the form $\{\{x_0, y_0\}, \{x_1, y_1\}, ...\}$. How to generate a list of numbers $\{s_0, s_1, ...\}$ where $s_i$ is the distance of ith point ...
0
votes
1answer
80 views

Breaking data sets into series for plotting

I have a generated a data set of a function $\alpha(\lambda_2,\varepsilon):\mathbb{R}_+ \times (0,1) \mapsto (0,1)$. I used mathematica to generate a list by varying $\lambda_2$ and $\varepsilon$; ...
1
vote
4answers
141 views

Non-rectangular pick of elements of a matrix

How to pick elements of a matrix that are inside a circle centered at the center of the matrix?
1
vote
2answers
92 views

How to make some mess points to be more smooth?

Background: The question is derive form this post.I have a another thinking about it.Some points in a suface you can give a certain equation but some points you cannot.So I wanna get a method to ...
3
votes
2answers
99 views

How to gather a list whitout no repeat element to nearest a certain number

Background: The question derive from this question.But some criteria is omited by me.So I try to post a new question for this.If my expression is dimness and you have got it,just tell me or edit my ...
5
votes
2answers
146 views

Multiply list of matrices by list of vectors

I have a list of vectors and a list of matrices for each vector, what i need is to multiply each list of matrices to respective vector. ...
4
votes
1answer
63 views

Creating a tensor from matrices

I have 3 nxn matrices that I'd like to combine into a nxnx3 tensor. Basically, I want a new nxn matrix where each element is a 3 tuple of the elements of the other 3 matrices at that same position. ...
0
votes
2answers
81 views
1
vote
1answer
66 views

How to sort a list by another list?

I have a list and a order ...
4
votes
3answers
140 views

Remove 2D points where nearest neighbor exceeds certain distance

I have the following 2D points: ...
3
votes
3answers
132 views

Selecting all the elements of different length that contain only numbers

If I have a list of lists with different lengths: {{1, 2, 3}, {1}, {1, 2, 3, 4}, {x}, {1, x}, {2}, {2, 3}} How can I extract all the sub-lists with no symbols: ...
0
votes
0answers
80 views

How to Extract and Rearrange Elements in Doubly-Nested Lists

Hopefully any easy problem for you guys to help me with! I'm currently having an issue with writing some Mathematica code that will extract the each nth element in each array within a matrix, and then ...
1
vote
1answer
43 views

list missing numbers [closed]

Let m=[1,2,3,4,5,6,7,8,9,10]; be a set and let s=[ 2,4,5,6,8,9]; be a subset of m. How do list all missing numbers in s from m. For example, the missing numbers in s from 1-->10 are 1,3,7,10. So, ...
2
votes
3answers
98 views

Select a list in MemberQ

I have bounch of code like: ...
3
votes
2answers
102 views

Find the first n pairs in a list whose difference is the nearest to some number

This is my list: list = {2.6135182051634342, -2.6690957180727297, 0.26060239174734157, -0.4182243295792278}; I wanna gather it every two number,which make ...
1
vote
3answers
81 views

Percent Difference between elements from 2 matrices

If i have a 22 by 25 table of values which depend on n and r, and a list of values that depends on r that is a 22 by 1 matrix, how can I find the percent difference between each element, by row in the ...
1
vote
3answers
66 views

Adding numbers to a list

Say you have the following list of 12 elements X={"x", "x", "x", "x", "x", "x", "x", "x", "x", "x", "x", "x"} And I want to turn it into the following sorted ...
0
votes
1answer
21 views

Define nonzero variables Varyx = z_xy from table with dimensions x,y and values z_xy

I'm trying to do the following. I have a table, call it TransTable. To give an example ...
1
vote
1answer
92 views

List Deconvolution

I have some experimental data to analyse. The function $f(t)$ that describes it is however convolved with a gaussian, due to finite resolution of our experiment. $f(t)$ is too complicated to be ...
1
vote
1answer
49 views

How to deal with repeating usage of same attributes

I am producing in my notebookfile many plots with the following example code: ...
3
votes
1answer
46 views

Corresponding list value and index in a list

I have a list and I know the maximum value of that list by using Max[list]. The thing is I want to find out the index number of this list that corresponds to this ...
6
votes
4answers
186 views

Group list elements in sequence

Suppose we have the following list: list1={1,2,4,6,8,9,10,14,15,17,21,22,72,76,80,96,106,116,117} Actually the real list has about 100K elements. What I want to ...
3
votes
3answers
110 views

Assigning to multiple variables in a list the values in another list

I have two lists, one contains the variables and the other the corresponding values that the variables should take. ...
1
vote
3answers
130 views
1
vote
1answer
47 views

Transform {x,y,…} and {a,b,…} in to {x->a,y->b,..} [closed]

How to merge two list and add -> to it. For instance, I have {x,y,z,...} and {a,b,c,...} ...
1
vote
1answer
65 views

Adding +2015 to each value of my x-axis [closed]

I want to change all of the values of my x-axis by +2015 The problem is, I evaluated a large expression using incremental values {i,1,85} and plotted that data. The Plot's x-axis is 1 to 85, as ...
0
votes
0answers
61 views
1
vote
1answer
58 views

Generating lists of data with ReplacePart

I have the following example: ...
2
votes
0answers
70 views

Function output

I would like a function that computes Cartesian product of two sets z=(Tuples@{#1,#2}), and computes the number of elements in this set(list) ...
3
votes
1answer
152 views

How can I optimize the search between two lists, one that is changing length?

I'm trying to identify unique arrays by comparing two lists, one which is growing in length. The number of elements in the list grows as 2^n^2, where ...
5
votes
3answers
125 views

Lazy form of Tuples/Outer to loop over list of lists

This is less a question and more asking if someone has implemented this already, with more skill. I need to perform the Outer-like generalized outer product of a ...
0
votes
1answer
48 views

Interactive Application using Manipulate for Fibonacci Series

I am working on creating interactive app using Manipulate function on fibonacci series using SeriesCoefficient. I want to plot the fibonacci numbers based on the slider of Manipulate function. I ...
2
votes
1answer
60 views

Pairing values with their indexes for MapThread

Several operations require you to map over a list of values and to know the index of each value as you process it. To accomplish this, my current somewhat ugly solution uses MapThread: ...