TITLE: Is the limit a function?
QUESTION [8 upvotes]: We're aware of the existence of the limit in the context of calculus, e.g. where $f:\mathbb{R}\to\mathbb{R}$, we may have:
$$\lim_{x\to z} f(x) = y$$
My question is whether it is valid to see the limit as a function. A limit takes two inputs: $f$, a function, and $z$, the value at which we take the limit of the function. These two inputs are a tuple $(f,z)$ where the first coordinate of the tuple is a function from some function space $F$[1] and the second coordinate is from $\mathbb{R}\cup[-\infty,+\infty]$, at least in standard one-variable calculus in the real numbers.
So, instead of writing $\lim_{x\to z} f(x) = y$, I could write $\lim(f,z) = y$. Specifically, I want to claim that $\lim$ is a function such that $\lim : F \times ((\mathbb{R}\cup[-\infty,+\infty])\setminus N) \to \mathbb{R}\cup[-\infty,+\infty]$, where $N$ is the set of values in the extended reals for which we cannot take that particular limit, so we conveniently exclude them. The last part in particular may not read too well, but I hope that the point is clear: I'm asking if it is possible to call a limit a function that maps a (function, value) tuple to some image.
[1] Matthew Leingang pointed out that different $f$ will have different $N$, which makes it hard to generally define an $F$ to suit an $N$. This is problematic for defining the domain of the limit, so I propose to define $F=\{f\}$, i.e. we define $F$ as containing only the particular function we're interested in taking the limit of.

REPLY [3 votes]: This is right up the alley of functional analysis. We can view the limit operation as a functional of sorts (a functional is a function defined on a vector space with values in its underlying field). First let's start with sequences. That is consider the space $c$ of convergent real sequences. We can define the following functional on $c$:
$$
T : c \to \mathbb{R} \\ \{x_n\}_{n \in \mathbb{N}} \mapsto \lim_{n \to \infty} x_n
$$
This operator actually has some nice properties, first off it's linear when you define addition of sequences to be coordinatewise (i.e. $(1,1,1,1,1,\ldots) + (2,1,2,1,2,1,\ldots) = (3,2,3,2,3,2,\ldots)$)
$$
T(\{x_n\} + \{y_n\}) = \lim_{n \to \infty} (x_n + y_n) = \lim_{n \to \infty} x_n + \lim_{n \to \infty} y_n = T(\{x_n\}) + T(\{y_n\})
$$
You can actually prove that this functional is continuous. If you're interested in what continuous means here I can explain more (just comment below) but for now I'm going to continue on.
Now we can consider $C[0, 1]$ the space of continuous functions defined on $[0, 1]$ (with values in $\mathbb{R}$) and define for each $z \in [0,1]$
$$
T_z : C[0, 1] \to \mathbb{R} \\ T_z(f) = \lim_{x \to z} \, f(x)
$$
A couple things should be pointed out here:

This is actually an evaluation map, since each $f$ is continuous we simply have
$$
T_z(f) = f(z)
$$
This again can be shown to be a continuous functional
We can view this as
$$
T : [0,1] \times C[0,1] \to \mathbb{R} \\ T(z, f) = \lim_{x \to z} \, f(x)
$$

Coming back to the first point above I don't think this is quite the type of map you were looking for. The issue is this operator may not be well defined if we don't consider it to be defined on the space of continuous functions (i.e. what happens if we have a jump discontinuity? What value should we take then?). I see you comment on this in your post ("conveniently remove this set $N$"), but what would our convenient set be? How would you define the domain then? Of course we can loosen our restrictions on the domain and come up with other operators, but I think that's enough functional analysis for now ;)

I saw the edit above about having your domain change based off the function and I have the following comments on that:

If we change the domain for each function, then you don't really have a single 'limit function', you have a function, which takes input a function, creates a function out of that and then this last function is where the limit operation actually lies. While this seems fine for functional programming, mathematically speaking this doesn't seem to elegant. In fact what use would this be to us? It certainly wouldn't be linear (I really like linearity)! Also I'm unsure how you would talk about continuity here; my point is you can do what you said to do but it isn't very useful.
I would rather change do a space like the following:
$$
E = \{ f : \mathbb{R} \to \mathbb{R} \mid f \text{ is continuous except at finitely many points} \}
$$
If we were to consider these functions only then it would indeed be a larger space than $C(\mathbb{R})$, but it still feels elegant enough to be able to do some maths with it. Note that we cannot consider $f$'s that are continuous except on a countable set (why?). If you want I could go into more detail why this space is fairly nice (would require some measure theory, though!).

Anyhow I hope this is what you were looking for!