Why do we use open intervals in most proofs and definitions? In my class we  usually use intervals and balls in many proofs and definitions, but we almost never use closed intervals (for example, in Stokes Theorem, etc). On the other hand, many books use closed intervals.
Why is this preference? What would happen if we substituted "open" by "closed"?

The truth of many theorems requires that the domain being considered is either open or closed. For example, a continuous function on a closed bounded set is always bounded and obtains its bounds. This is most certainly not true for continuous functions on open sets.
One major difference between open and closed sets is that any point in an open set $U$ is contained in some open neighbourhood which is a subset of $U$. Thus problems on any arbitrary open set can often be reduced to problems on simpler open sets. (In metric spaces, when working with a point in an open set we can always consider a small open ball that contains the point, and open balls are somehow "nice" sets that we know how to deal with.)
Another thing to bear in mind is the idea of closures and interiors. The closure of a set $A$ is the intersection of all closed sets containing $A$ and the interior of $A$ is the union of all open sets contained within $A$. It is fairly easy to see that $ \operatorname{interior}(A)\subset A\subset\operatorname{closure}(A)$. Thus if we work with a closed set $A$, we can see that it will contain some open set (Although this may be the empty set) and anything that was true for all points in $A$ will be true for all points in $\operatorname{interior}(A)$. For example, if we have a continuous function on a closed ball around a point, the function is still continuous if we restrict it to the the interior of the ball (which is an open set) and so we can apply anything we know about continuous functions on open sets. What we can't always do is extend a continuous function on an open set to its closure in a way that keeps it continuous.
