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

learn more… | top users | synonyms (3)

10
votes
0answers
180 views

Strategies to find curves on messy data using FindCurvePath

I have a set of data points that correspond to roots of a transcendental equation with respect to a parameter (the abscissa) which, by the properties of the system, define continuous curves (might be ...
9
votes
0answers
219 views

How to merge Datasets representing matrices with named rows/columns?

I am working with square (non-symmetric) matrices with named rows and columns. The data I receive is sometimes messy and rows/columns may come in various permutations. I usually need to ...
9
votes
0answers
308 views

Learning Resources for Data Science in the Wolfram Language

I'm delivering an upcoming course on Data Science with the programming/analysis done predominantly in the Wolfram Language. I created the following table to leverage students' familiarity with Lists ...
8
votes
0answers
106 views

TimeConstrained[Delete[Range[1],1]] causes kernel crash

Run these two samples of code here (AFTER SAVING YOUR CURRENT WORK): Do[ TimeConstrained[ While[True, Delete[{1}, 1]; ];, 0.1];, {100}] ...
8
votes
0answers
255 views

Using Compile to speed up Function with PermutationProduct

I have the following fairly simple routine dot involving PermutationProduct that I wish to speed up using ...
6
votes
0answers
66 views

Listable compiled functions used in NMinimize

This is an example from MMA: cListable = Compile[{x}, (x-1)^2, RuntimeAttributes -> {Listable}] In case of single entry: ...
5
votes
0answers
257 views

How to download and combine S&P 500 stock prices

I want to download historical S&P 500 stock prices and combined them into one big file, having only one column of date referencing all stocks. Here is what I have do so far. ...
4
votes
0answers
101 views

Gather dependency on list order?

I get intrigued about Gather behavior on this post. I thought that Gather was invariant under list order? Here is the result I ...
4
votes
0answers
228 views

Strange behavior of undocumented RawArray and ArrayObject expressions

I discovered several strange results and inconsistencies while trying to understand what undocumented RawArray and ArrayObject ...
3
votes
0answers
66 views

Map an Argument to a list of functions

I want to "map" an argument to a list of functions. Here is the concrete Problem. I generate a list "Messungfit" of functions: ...
3
votes
0answers
334 views

Taking real and imaginary parts of indexed functions and speeding up ComplexExpand

I am setting up a large system of ODEs and in order to use the IDA method (which is sig. faster for my system and thus attractive), I must split my equations into real and imaginary parts. I am ...
3
votes
0answers
200 views

Exporting Specific Cells of Many Workbooks into One using Mathematica

I currently have a large number of detailed files from which I would like to extract certain cells' information to make an Archive spreadsheet. There are approximately 9 parameters of each ...
2
votes
0answers
61 views

Choosing a List as VertexWeight for a TreeGraph

I would like to map every vertex of my TreeGraph to an List. ...
2
votes
0answers
101 views

ParallelTable and expensive functions

I would like to build up a 2D-Table using ParallelTable as follows ...
2
votes
0answers
204 views

Faster Ways to compute recursive summation

It takes a long time to compute the summation below, and I'd like to know if there are some better ways to compute things faster. I have used $3$ ways to calculate, but they are very unsatisfactory. I ...
2
votes
0answers
290 views

Derivatives of list elements

Could someone explain the odd behavior of the Derivative function when drawing arguments from lists? We have, ...
2
votes
0answers
389 views

Generating a function which outputs possible chemical reactions

I want to make a list of chemical reactions and I write them down in a $\require{mhchem}\LaTeX$ format. They are of the following form $$NA_n^i+MB_m^j \rightarrow \hat NA_{\hat n}^{\hat i}+\hat ...
1
vote
0answers
45 views

Fast construction and reshaping of large tensors

I'm trying to construct a large matrix which is derived from some higher rank tensor (the rank of interest to me changes case by case, so it needs to be a general method). Currently, the process of ...
1
vote
0answers
31 views

Tracking solutions over a Brillouin zone

Thanks to @bbgodfrey I have a function that finds the two solutions to a set of equations bounded by a hexagonal region (corresponding to the Brillouin zone). It takes the angle ...
1
vote
0answers
65 views

Disease Network Model Using NDSolve

I have a basic disease model using NDSolve: ...
1
vote
0answers
40 views

Substitution does not work while substituting with a value from list

I am writing a program which iteratively solve and make substitution from a list. As I have shown in the code substitution works when I enter the value directly (Input 100). When I extract the same ...
1
vote
0answers
69 views

Find algorithm or generator formula with automated procedure and pattern recognition

I am trying to find a generator formula for the discriminant of a polynomial and believe it would be an interesting problem for the Mathematica community to know how to automate evaluation of certain ...
1
vote
0answers
48 views

Compilation of a function that needs to call Subsets

I'm working on a code that runs many (easy) operations on combinations (subsets) of different size (6, 7, 8, 9) taken from a big set of numbers (normally more that 40). So, this means the code has to ...
1
vote
0answers
107 views

How to create a complex variable from dated list values

Can anyone help me to construct a variable "PI" from values of variable x. Variable x represents a group of two time series rj and ri on equal dates(joined two dated lists with states).Variable x have ...
1
vote
0answers
72 views

Programming for matrix manipulation

I want to write a programme which operates on nd x nd matrices. The programme looks the matrix as a n x n block matrix where ...
1
vote
0answers
134 views

How to sequentially select, from a large set of tuples (of matrices), those with a certain property

I'm interested in finding a computationally efficient way for selecting all tuples of matrices which have a certain property. The property I'm interested in is that I want the column sum, of f[the ...
1
vote
0answers
49 views

A more efficient way of fitting a non-linear model that returns an entire list?

I have a function that takes two parameters, del and nu, and returns a list npoints long ...
1
vote
0answers
307 views

Convolve two sets of (x,y) data sets

I have two sets of data in the form a={{.1,2},{.2,3},{.3,4},{.5,6}} b={{0,8},{.1,4},{.2,7},{.3,1},{.5,10},{.6,3}} Both data sets have even spacing, although ...
1
vote
0answers
103 views

New list generated from the sum of elements taken from two lists

I have been using mathematica for a while, but I have problem wrapping my head around list manipulation functions. I would appreciate any suggestions. Here is what I want to do. ListV is a list of ...
1
vote
0answers
238 views

Using Part within a Compiled Command

I'm looking to define a multi-line function that makes use of the "Part" command. A toy example: ...
1
vote
0answers
72 views

The number of real values assumed by combinations of complex roots of a decic

Define complex conjugate as the pair of complex numbers $a+bi,a-bi$. Assume you have 5 such pairs and they are the 10 roots $x_i$ of a 10th-deg equation with integer coefficients. In general, how many ...
1
vote
0answers
98 views

Optimized subset algorithm implementation

I was reading a paper from Mathematica Journal.It mentions a code for calculating subsets. ...
1
vote
0answers
149 views

Why doesn't ParallelMap improve the performance of FoldList?

This question arose during my analysis of the following problem: filling gaps. (The code used here is Simon Woods's work.) FoldList seems to not cooperate with ...
0
votes
0answers
31 views

Generating vectors with restrictions on a lattice

Suppose we are given a certain adjacency matrix that contains the information for a given lattice. I want to generate a configuration of vectors that satisfy a restriction. Specifically, if I have ...
0
votes
0answers
33 views

Standalone cdf with precalculated result

I'm wishing you a nice day. I needed some interactive plots so I used Manipulate. My function is function of several parameters, let's call it $f \left( L, \Gamma, ...
0
votes
0answers
37 views

BinLists for list of depth greater than 1

BinLists uses the bin specification assuming an interval that is closed on the left and open on the right (according to the documentation). So ...
0
votes
0answers
26 views

Exporting the NDSolve to matlab with the argument

a = Table[Evaluate[y[x] /. sol], {x, 0, 10, 0.01}]; Export["a.mat", a]; works just fine but ...
0
votes
0answers
55 views

How to handle substrings of a matrix by a named index

I am using open source code to run stochastic simulations. The output looks like this: ...
0
votes
0answers
66 views

Matrix iteration failing after second step

I am calculating 11x6 matrix using different logics as in below code. Problem is in Do loop in below code where I have two different criteria to update matrix "fd". I am expecting logic in IF which ...
0
votes
0answers
54 views

How to replace a part of array based on certain rules which involves usage of other array

I am trying to replace outermost column of array "fd" in below code. fd is matrix of dimension (nas1,nts) which is initially filled with 1. I want to replace outermost column of fd with result of Max ...
0
votes
0answers
24 views

NCAlgebra to calculate a Hermitian conjugate

I have to calculate a non-commutative product of this form: $(-H a+ J a b)**(-H a + K c)$ where $H,J,K$ are variables and $a,b,c$ are operators that don't commute. For this purpose I used the package ...
0
votes
0answers
25 views

Generating a list consisting of function values like in a triangular matrix

A goal is to generate a SymmetrizedArray of dimension n^k with specified symmetry (let it to be ...
0
votes
0answers
33 views

Copying an Imported List to another File

I have a file which begins with a large list of elements created by joining 12 different data imports, which I would now like to copy to another file so that the file can be sent by itself and not ...
0
votes
0answers
62 views

Unknown number of variables in a logical statement

Resolve[ ForAll[{i, y[i]}, Implies[i >= 0 && i < 3 && Implies[i < 3, y[i] > 0], Sum[y[i], {i, 0, 2}]>0]]] returns ...
0
votes
0answers
58 views

Improve performance of processing transactions in a large file

I want to work with a table which has 296,705 transactionslines and 172,147 transactions. ...
0
votes
0answers
69 views

Appending elements to a list in parallel table

Is there any way to store values in a list that is being computed in parallel? For example, if ParallelTable is computing some ...
0
votes
0answers
70 views

Autocorrelation of 3D Points

I'm trying to compute the autocorrelation of a list of points (x,y,z) in 3D. Can the CorrelationFunction or maybe ListCorrelate ...
0
votes
0answers
71 views

Selecting values over lists for discrete inputs in NDSolve

I'm currently trying to simulate a step response in a simple tank system with NDSolve. I would like it to start at say time 2 (the precise time is not important). ...
0
votes
0answers
88 views

Fourier Transformation of a List

As we know the FourierTransform goes a function of t ,for example, f[t] to ...