40 questions linked to/from Scan vs. Map vs. Apply
179 views

### Two-slot pure function [closed]

I come across this problem in many different forms when doing arithmetic in MMA and have until now just suffered along doing it the long way – having given up trying to figure it out myself – but now ...
• 1,176
173 views

### How to I use Map to apply a defined function to a list?

Problem: How to map a function onto a list. My (example input: mylist = {{1, 2}, {3, 4}} gg[x_, y_] := {N[x + y], N[x y]} Map[gg, mylist] Expected output: ...
• 61
1 vote
584 views

### Map over multidimensional matrix [closed]

Suppose I have a 8by6by4by2by2 matrix called m. There is in total 8*6*4 2by2 matrices. I want to map a function over these 2by2 matrices. Each dimension in ...
• 3,854
180 views

### Chained sums with Nest

I'm looking to calculate a chained sum like this  C_m = \sum\limits_{i_1=1}^N \;\sum\limits_{i_2=i_1+1}^N \;\sum\limits_{i_3=i_2+1}^N \cdots \;\sum\limits_{i_m=i_{m-1}+1}^N A_{i_1}A_{i_2}A_{...
• 1,085
242 views

### TogglerBar with arbitrary dimensions

I'd like to split my TogglerBar into several rows, with it's length given in a list. I found the Appearance options, but they ...
• 119
144 views

### How can I adjust the global input variable of a function to the value of a local variable within the function

I am trying to define a function f[l_] that will perform an operation on whatever input variable I use (normally I use l which ...
• 31
150 views

### Tutorial for Map, Apply, etc

I have this code: ...
• 117
167 views

### How to ScanThread and ScanIndexed?

Why are there MapThread and MapIndexed but no analogous functions for Scan? What is the ...
• 19.6k
1 vote
113 views

### Emulating Case Pattern replacement

As most regular users, I have developed utility functions complementing the Wolfram language for frequent tasks. In particular, I have variations on Cases (see ...
• 957