11 questions linked to/from Add a vector to a list of vectors
290 views

### How to get this list with a terse method [duplicate]

If I have like {a,b} and I want to get {{a+1,b},{a-1,b},{a,b+1},{a,b-1}} We don't care about the ordering of the list....
• 26.9k
270 views

### How to sum a number over an element of each pair of a list? [duplicate]

Here's a following list: L={{a,b},{c,d},{e,f}}. I want a function such that it sums a number over the first element of each pair. For instance, take the number 1. I need: L={{a+1,b}, {c+1,d}, {e+1,f}...
75k views

### Elegant operations on matrix rows and columns

Question The Mathematica tutorial has a section 'Basic Matrix Operations', describing operations like transpose, inverse and determinant. These operations all work on entire matrices. I am missing a ...
• 7,787
874 views

### How can I multiply only a few columns of a table by some number in a compact way?

Consider a table tab = Table[{i,i^2,i^3,i^5,i^0.3,i^0.7},{i,0.2,3,0.1}]; I would like to multiply the 2rd and 5rd columns by some number. This is how I do it: <...
• 5,887
491 views

### Subtracting a list from each sublist in a nested list

I have a nested list with 1-D sublists of equal length. I want to subtract another list from each of these sublists. Task: Subtracting B from each element in ...
• 511
392 views

### Improving Map Function on Lists

Dealing with spectral data (2D lists) where offsets (corresponding 1D list) must be removed from each individual spectrum. Looking for feedback on improvements over my current method. ...
• 576
829 views

### Multiplying a list a vectors by the same matrix

I have a list of 2 vectors: x={{a,b},{x,y}}, and a matrix 2 by 2 A. I want the result to be ...
185 views

### add columns of list {a0,b0} to columns of list {{a0,b0} ,{a1,b1} ,{a2,b2} ...{ax,bx} } [closed]

If I want to add the columns of {1,2} to each of the columns of say {{1,2},{3,2},{4,2}} resulting in {{2, 4}, {4, 4}, {5, 4}} How would I do this? and for any ...
• 343
1 vote
190 views

### ListPlot problem

I have the following example: x = {1, 2, 3, 4} y = {{1, 2, 3, 4}, {2, 3, 4, 5}, {3, 4, 5, 6}, {4, 5, 6, 7}} Now I can plot: ...
• 11.7k
97 views

### How to add a vector list to a multiple dimension list of vectors [closed]

This problem is related to Add a vector to a list of vectors. Given: ...
• 2,788