Unbounded operators vs compact operators The operator $L:\operatorname{dom}(L)\subset C[0,1]\to C[0,1]$ given by $Lx=x'$
a) is closed, unbounded and densely defined
b) also has a compact right inverse, namely $K:C[0,1] \to C[0,1]$ given by $Kx=\int_{0}^t x$.
How connected are the two facts? Is this situation part of a more general characterization of operators with compact right inverse between Banach spaces?
 A: The following ramblings are just night thoughts kicked off by your question  (and so should really be a comment, but I am not entitled) which I am posting in the hope that they may be of interest to you.
Firstly, your operator $K$ has more properties than you mention.  It is not just a right inverse—it is, as near as can be, also a left inverse, just missing this by one dimension.  This fact was used by Sebastião e Silva to give an elementary construction of the space of distributions on $[0,1]$—it takes half a page and only uses methods and results of a freshman univariate analysis course (see the site jss100.campus.ciencias.ulisboa.pt).  At a less elementary level, it is an integral operator (a functional analytical property stronger than compactness) and this is the reason that the above space of distributions is nuclear (Grothendieck).
In the case of self-adjoint operators (which yours isn't but see below), the situation is quite transparent:  there is a duality via inversion between suitable compact s.a. operators on a separable Hilbert space and unbounded s.a. ones with discrete spectrum and eigenvalues $(\lambda_n)$ which diverges to infinity in absolute value. (By the way, the inverse is nuclear iff $\sum \frac {1}{|\lambda_n|}<\infty$.) One can then ape Sebastião e Silva‘s construction in this more sophisticated context to obtain a unified approach to most of the distribution spaces of relevance in mathematical physics (typical candidates for the seed operator—Laplace, Laplace-Beltrami, Schrödinger).
One can recover information on the relation between a general (i.e., not necessarily self-adjoint) compact operator $A$ and a (one-sided) inverse $K$ by looking at the related s.a. operators obtained by multiplying them by their adjoints.
A: Well, if $A$ is bounded and $B$ is compact then $AB$ is compact, so $AB$ cannot be the identity unless the Banach space is finite dimensional. Thus the left (or right) inverse of a compact operator on an infinite dimensional Banach space, if it exists, must be unbounded. There's no implication in the other direction --- the inverse of an unbounded operator could be compact, or bounded, or unbounded, as one can easily see by considering multiplication operators on $L^2$ spaces.
A: In Hilbert spaces the situation is crystal clear by singular value decomposition: If $K$ is compact between two Hilbert spaces then one can write $K$ as
$$
Kx = \sum \lambda_n\langle v_n,x\rangle u_n
$$
where $\lambda_n>0$, $(u_n)$ is an orthonormal basis for the range of $K$, and $(v_n)$ is an orthonormal basis for orthogonal complement of the null space of $K$. Moreover, if the range is infinite dimensional, then $\lambda_n\to 0$.
Hence, the inverse is unbounded exactly if the range is infinite dimensional.
