A technical survey on optimal power flow under uncertainty: An extended out-of-sample analysis With an increasing part of renewable energy generation connected into the grid, the share of uncertainty and intermittency in the electricity generation mix is also increasing. In parallel, the electricity sector liberalization, aiming at more investments into the power systems and electricity price reductions, introduced competition at the generation as well as the supply level. Each actor has now the economic objective of minimizing cost. The markets allow the different actors to exchange energy at different time scales. One goal of the market operator is to minimize the social costs by dispatching the units in a convenient way. Such a problem is called an optimal power flow (OPF). The overall system safe operation is guaranteed only if consumption is equal to generation at any time. This constraint has to be imposed when clearing the markets, in particular from day-ahead (DA) to real-time (RT). However, it is harder to reach because of the increasing uncertainty part in the electricity production. The goal of this master thesis is to implement stochastic optimization techniques on the OPF problem, aiming at improving the decisions with respect to the deterministic case, by including information about the uncertain parameters. The problem clears energy and reserve auctions simultaneously and takes into account the structure of the grid. Secondly, the implemented techniques are fairly compared through an out-an-sample analysis that assesses their performance with respect to, e.g. the expected social cost. The considered techniques are enumerated here and below. The structure of our problem is two-stage (DA and RT) and uses historical data to describe the uncertain parameters. Stochastic programming approximates the distribution function of the uncertainty by a finite set of scenarios and their corresponding occurrence probability. Risk management is also incorporated to the formulation in order to account for worst-case realizations through the Conditional Value-at-Risk. However, stochastic programming comes with some drawbacks. First, a high number of scenarios comes with a higher computational burden and second, the lack of risk aversion (scenario-based decisions may result in very high cost in some extreme cases). An alternative to stochastic programming is adaptive robust optimization. This technique aims at optimizing the objective function under the worst-case realization within an uncertainty set (that is, the space of plausible realizations) and ensures the feasibility for each realization within it. The bigger the uncertainty set is, the higher is the immunity of the decisions against extreme scenarios i.e. the more conservative are the decisions. Robust solutions, however, are linked to an overly risk-averse behaviour leading to higher expected costs (the savings made in case of the worst-case realization does not compensate the opportunity losses in other classical cases). To overcome the issue of conservativeness of the decisions, chance-constrained programming represents a trade-off between scenario-based and robust optimization. In this method, the system constraints are imposed with probability at least 1 − . There exist reformulations of such a chance-constrained problem based on historical data. Among them, the scenario and robust approaches are implemented and analyzed. Finally, an out-of-sample analysis is ran on consistent data and allows to compare the performances of each decision set (i.e. stochastic, robust and chance-constrained ones) in terms of expected social cost. The out-of-sample analysis consists in solving a real-time market for each computed day-ahead decision set and for each sample in the out-of-sample dataset, resulting in a total cost distribution. A general conclusion is that the more conservative the decisions are, the higher the expected cost is but the lower is its variation. The impact of the wind penetration level on the undertaken decisions is also discussed. 1