0

How can I have a function that takes in a summation?

Say I have a function: $$f:\Bbb R\;\times\;?\to\Bbb R,\;\left(x, \sum_{n=a}^b\right) \mapsto \sum_{n=a}^bx$$ This is a very simple example of what I would like to do. As you can see I have a $?$. This is for the set that represents a sigma. How would one right this?

I will not be using the function defined above but rather constructing functions that take summations in.


Additional Questions

  1. How would one manipulate a summation as a set? (I am thinking along the lines of treating it as a function).
  2. More of a question on summation itself: How does the summation specifically manipulate input? eg. If treating it as a function (sorry) $$\sum:\Bbb N^2\times\Bbb R^\Bbb R?\to\Bbb R, \;(a, b, f)\mapsto\sum_{n=a}^bf(n)$$ Something along those lines.
Ali Caglayan
  • 5,726
  • I do not understand what you mean by 'take summations in'. A summation results in a value. A value, as such, does not distinguish how it was computed. – copper.hat Sep 20 '13 at 20:54

1 Answers1

1

In the usual mathematical symbolism, "$\sum$" or "$\sum_{n=a}^b$" are not things in themselves -- they are incomplete parts of a mathematical notation, and don't get any meaning before you have written what it is you sum over, any more than one of the crossing lines in "$+$" has a (relevant) meaning independently of the other one.

Since these particular shapes of ink do not denote things, they cannot be passed as an argument to a function.

Of course you're free to define your own deviant formalism where they do denote something, and it is even possible that you can do it such that the meaning of a complete summation ends up being identical to the usual meaning of the symbolism. But you shouldn't expect anyone to understand this formalism unless you explicitly explain it when you use it.

One particular problem you'll have to solve is that $\sum_{n=a}^b$ binds the variable $n$ in the expression that follows it, so your formalism will have to work with passing around reified expressions with free variables that later become bound. That can end up being pretty confusing. You'd be better off (but still in nonstandard territory) by letting your free-standing summation operator be $\sum_a^b$ and then apply it to the function $\lambda n.x$.

I think you may also find this old answer of mine instructive.