This thesis consists of three self-contained parts, each with its own abstract, body, references and page numbering. Part I, "Potential theory, path integrals and the Laplacian of the indicator", finds the transition density of absorbed or reflected Brownian motion in a d-dimensional domain as a Feynman-Kac functional involving the Laplacian of the indicator, thereby relating the hitherto unrelated fields of classical potential theory and path integrals. Part II, "The problem of alternatives", considers parallel investment in alternative technologies or drugs developed over time, where there can be only one winner. Parallel investment accelerates the search for the winner, and increases the winner's expected performance, but is also costly. To determine which candidates show sufficient performance and/or promise, we find an integral equation for the boundary of the optimal continuation region. Part III, "Optimal support for renewable deployment", considers the role of government subsidies for renewable technologies. Rapidly diminishing subsidies are cheaper for taxpayers, but could prematurely kill otherwise successful technologies. By contrast, high subsidies are not only expensive but can also prop up uneconomical technologies. To analyse this trade-off we present a new model for technology learning that makes capacity expansion endogenous. There are two reasons for this standalone structure. First, the target readership is divergent. Part I concerns mathematical physics, Part II operations research, and Part III policy. Readers interested in specific parts can thus read these in isolation. Those interested in the thesis as a whole may prefer to read the three introductions first. Second, the separate parts are only partially interconnected. Each uses some theory from the preceding part, but not all of it; e.g. Part II uses only a subset of the theory from Part I. The quickest route to Part III is therefore not through the entirety of the preceding parts. Furthermore, those instances where results from previous parts are used are clearly indicated. / Research support from the Electricity Policy Research Group in Cambridge is gratefully acknowledged (http://www.eprg.group.cam.ac.uk).