Are arrays functions?

18 points by brendan


jbert

Love this.

With regard to slicing, isn't this fmap plus a syntax for constructing ranges?

chriswarbo

I do not yet know when it might be useful to perform a matrix multiplication of functions, but I’d certainly like someone to figure it out and tell me about it.

We can think of matrices as a particular syntax/representation for linear maps/functions; in which case, matrix multiplication corresponds to function composition (i.e. the linear map represented by the matrix A×B is equal to the composition of the linear maps represented by A and B). So, if we apply this interpretation to arbitrary functions, then "matrix multiplication of functions" would presumably just be ordinary function composition?