Although theories of extra dimensions establish a connection between string theory and cosmology, the developments of the past few years have pushed the connection much further. [For reviews, see [41, 42, 43].] The union of string theory and cosmology is barely past its honeymoon, but so far the marriage appears to be a happy one. Inflation, from its inception, was a phenomenologically very successful idea that has been in need of a fundamental theory to constrain its many variations. String theory, from its inception, has been a very well-constrained mathematical theory in need of a phenomenology to provide contact with observation. The match seems perfect, but time will be needed before we know for sure whether either marriage partner can fulfill the needs of the other. In the meantime, ideas are stirring that have the potential to radically alter our ideas about fundamental laws of physics.
For many years the possibility of describing inflation in terms of string theory seemed completely intractable, because the only string vacua that were understood were highly supersymmetric ones, with many massless scalar fields, called moduli, which have potential energy functions that vanish identically to all orders of perturbation theory. When the effects of gravity are included, the energy density of such supersymmetric states is never positive. Inflation, on the other hand, requires a positive energy density, and it requires a hill in the potential energy function. Inflation, therefore, could only be contemplated in the context of nonperturbative supersymmetry-breaking effects, of which there was very little understanding.
The situation changed dramatically with the realization that string theory contains not only strings, but also branes, and fluxes, which can be thought of as higher-dimensional generalizations of magnetic fields. The combination of these two ingredients makes it possible to construct string theory states that break supersymmetry, and that give nontrivial potential energy functions to all the scalar fields.
One very attractive idea for incorporating inflation into string theory is to use the positions of branes to play the role of the scalar field that drives inflation. The earliest version of this theory was proposed in 1998 by Dvali and Tye , shortly after the possibility of large extra dimensions was proposed in . In the Dvali-Tye model, the observed universe is described not by a single three-dimensional brane, but instead by a number of three-dimensional branes which in the vacuum state would sit on top of each other. If some of the branes were displaced, however, in a fourth spatial direction, then the energy would be increased. The brane separation would be a function of time and the three spatial coordinates along the branes, and so from the point of view of an observer on the brane, it would act like a scalar field that could drive inflation. At this stage, however, the authors needed to invoke unknown mechanisms to break supersymmetry and to give the moduli fields nonzero potential energy functions.
In 2003, Kachru, Kallosh, Linde, and Trivedi  showed how to construct complicated string theory states for which all the moduli have nontrivial potentials, for which the energy density is positive, and for which the approximations that were used in the calculations appeared justifiable. These states are only metastable, but their lifetimes can be vastly longer than the 10 billion years that have elapsed since the big bang. There was nothing elegant about this construction - the six extra dimensions implied by string theory are curled not into circles, but into complicated manifolds with a number of internal loops that can be threaded by several different types of flux, and populated by a hodgepodge of branes. Joined by Maldacena and McAllister, this group  went on to construct states that can describe inflation, in which a parameter corresponding to a brane position can roll down a hill in its potential energy diagram. Generically the potential energy function is not flat enough for successful inflation, but the authors argued that the number of possible constructions was so large that there may well be a large class of states for which sufficient inflation is achieved. Iizuka and Trivedi  showed that successful inflation can be attained by curling the extra dimensions into a manifold that has a special kind of symmetry.
A tantalizing feature of these models is that at the end of inflation, a network of strings would be produced . These could be fundamental strings, or branes with one spatial dimension. The CMB data of Fig. 4 rule out the possibility that these strings are major sources of density fluctuations, but they are still allowed if they are light enough so that they don't disturb the density fluctuations from inflation. String theorists are hoping that such strings may be able to provide an observational window on string physics.
A key feature of the constructions of inflating states or vacuumlike states in string theory is that they are far from unique. The number might be something like 10500 [48, 49, 50], forming what Susskind has dubbed the "landscape of string theory." Although the rules of string theory are unique, the low-energy laws that describe the physics that we can in practice observe would depend strongly on which vacuum state our universe was built upon. Other vacuum states could give rise to different values of "fundamental" constants, or even to altogether different types of "elementary" particles, and even different numbers of large spatial dimensions! Furthermore, because inflation is generically eternal, one would expect that the resulting eternally inflating spacetime would sample every one of these states, each an infinite number of times. Because all of these states are possible, the important problem is to learn which states are probable. This problem involves comparison of one infinity with another, which is in general not a well-defined question . Proposals have been made and arguments have been given to justify them , but no conclusive solution to this problem has been found.
What, then, determined the vacuum state for our observable universe? Although many physicists (including the authors) hope that some principle can be found to understand how this choice was determined, there are no persuasive ideas about what form such a principle might take. It is possible that inflation helps to control the choice of state, because perhaps one state or a subset of states expands faster than any others. Because inflation is generically eternal, the state that inflates the fastest, along with the states that it decays into, might dominate over any others by an infinite amount. Progress in implementing this idea, however, has so far been nil, in part because we cannot identify the state that inflates the fastest, and in part because we cannot calculate probabilities in any case. If we could calculate the decay chain of the most rapidly inflating state, we would have no guarantee that the number of states with significant probability would be much smaller than the total number of possible states.
Another possibility, now widely discussed, is that nothing determines the choice of vacuum for our universe; instead, the observable universe is viewed as a tiny speck within a multiverse that contains every possible type of vacuum. If this point of view is right, then a quantity such as the electron-to-proton mass ratio would be on the same footing as the distance between our planet and the sun. Neither is fixed by the fundamental laws, but instead both are determined by historical accidents, restricted only by the fact that if these quantities did not lie within a suitable range, we would not be here to make the observations. This idea - that the laws of physics that we observe are determined not by fundamental principles, but instead by the requirement that intelligent life can exist to observe them - is often called the anthropic principle. Although in some contexts this principle might sound patently religious, the combination of inflationary cosmology and the landscape of string theory gives the anthropic principle a scientifically viable framework.
A key reason why the anthropic approach is gaining attention is the observed fact that the expansion of the universe today is accelerating, rather than slowing down under the influence of normal gravity. In the context of general relativity, this requires that the energy of the observable universe is dominated by dark energy. The identity of the dark energy is unknown, but the simplest possibility is that it is the energy density of the vacuum, which is equivalent to what Einstein called the cosmological constant. To particle physicists it is not surprising that the vacuum has nonzero energy density, because the vacuum is known to be a very complicated state, in which particle-antiparticle pairs are constantly materializing and disappearing, and fields such as the electromagnetic field are constantly undergoing wild fluctuations. From the standpoint of the particle physicist, the shocking thing is that the energy density of the vacuum is so low. No one really knows how to calculate the energy density of the vacuum, but naïve estimates lead to numbers that are about 10120 times larger than the observational upper limit. There are both positive and negative contributions, but physicists have been trying for decades to find some reason why the positive and negative contributions should cancel, but so far to no avail. It seems even more hopeless to find a reason why the net energy density should be nonzero, but 120 orders of magnitude smaller than its expected value. However, if one adopts the anthropic point of view, it was argued as early as 1987 by Weinberg  that an explanation is at hand: If the multiverse contained regions with all conceivable values of the cosmological constant, galaxies and hence life could appear only in those very rare regions where the value is small, because otherwise the huge gravitational repulsion would blow matter apart without allowing it to collect into galaxies.
The landscape of string theory and the evolution of the universe through the landscape are of course still not well understood, and some have argued  that the landscape might not even exist. It seems too early to draw any firm conclusions, but clearly the question of whether the laws of physics are uniquely determined, or whether they are environmental accidents, is an issue too fundamental to ignore.