We model the yield curve in any given country as an object lying in an infinite-dimensional Hilbert space, the evolution of which is driven by a "cylindrical Brownian motion". We assume that volatilities and correlations do not depend on rates (which hence are Gaussian). We prove that a principal component analysis (PCA) can be made. These components are called "eigenmodes" or "principal deformations" of the yield curve in this space. We then proceed to provide the best approximation of the curve evolution by a Gaussian Heath-Jarrow-Morton model that has a given finite number of factors. Infinite dimensional models raise the issue of perfect arbitrage. We show that arbitrage in the classic sense is not appropriate and introduce the notion of quasi-arbitrage. Finally, we describe a method, based on finite elements, to compute the eigenmodes using historical interest rate data series and show how it can be used to compute approximate hedges which optimise a criterion depending on transaction costs and residual variance.