This June, we received a letter from a reader asking why it seemed like there are fewer summer blackouts, especially in the western US, than there used to be.

This resonated with me. When I was a kid growing up in Southern California, summer always seemed to bring with it a couple of electrical blackouts. By 2001, the term "rolling blackouts" was a household phrase. The morning news would warn of a heat wave. My sister and I would head out to a friend’s house or some local summer camp, and when we returned home from pool-bleached adventures the power would go dead. Sometimes the blackouts lasted just a few minutes. But occasionally, hours passed and my parents would get cranky, sweating miserably with no way to know when we could get the air conditioner back on.

For me, it’s a trivial memory to think back on—my 20-years-younger parents wondering if they should wait for power to cook dinner or just have everyone fend for themselves in the slowly warming fridge. We were lucky. We were a young family with bodies that were able to withstand a couple hours of heat. But blackouts aren’t just a minor inconvenience for some people. Surely, there were less fortunate people who suffered hyperthermia during these heatwaves. The very old and the very young are particularly susceptible, but blackouts are problems for businesses, too. Back then, the fledgling world of the dot-com boom was just figuring out how to deal with overheating servers and dropped conference calls.

Today, the US grid infrastructure has, and certainly continues to, change. Energy efficiency has cooled demand, renewable energy is a growing slice of our electricity generation, and everything is getting increasingly digitized. Is it that simple—are those factors staving off the once-familiar blackouts?

Of course, the answer is complicated. The blackouts California faced in the late '90s and early '00s were economic. There just wasn’t enough electricity to go around, so some communities had to go dark. These days, the western US—California, Arizona, Nevada, Utah—are weathering increased demand better when it comes to maintaining power to all parts of the grid.

When there are power outages in the West in 2017, they tend to be mechanical in nature, like when the Sacramento Valley suffered blackouts this summer because transformers and other equipment overheated or when several thousand in Los Angeles found themselves offline because a transformer at the Department of Water and Power caught fire, again due to excessive heat. Modern blackouts can also still be caused by human error, like the Southwest Blackout of 2011 that left millions offline for hours.

Today, in fact, certain areas of the US are facing more blackouts than before due to climate change-related weather events.

But the demand-based outages of old are fairly uncommon in the West these days, even if managing summer’s astronomical electricity demand is still no small task. Air conditioning remains a power-hungry endeavor, and when millions turn their AC on (especially in the southwestern US), the grid continues to feel that stress. In an interview published on AZCentral, Arizona Public Service General Manager Jacob Tetlow said that peak demand in Arizona in the summer is about double what it is in the other three seasons.

This year is no different. In June, Southern California and Arizona experienced a heatwave so intense that it grounded planes in Phoenix. I was in the Eastern Sierras when the heat hit, and the visitor center outside of the turnoff to Death Valley warned of heat in the 120 degrees Fahrenheit range and beyond. Thermometers in the area reportedly read 130 degrees Fahrenheit. (In June and July this year, Death Valley actually set a record for the number of times the temperature registered more than 120 degrees Fahrenheit in a two month period—it happened 27 times.)

But despite the grueling heat in the urban areas of the Southwest, the electrical grid largely holds strong. Broadly speaking, the newfound success can be traced to things like market changes to promote fair dealing in California’s energy sector, smarter grid management, startups looking to bring alternative energy schemes to the forefront, and distributed energy production and use.

Balancing supply and demand fairly

A lot has changed in the last 20 years in energy, but that’s especially the case in California. Two decades ago, the most populous state in the region had a newly (and poorly, some may argue) deregulated market that was ripe for manipulation. Such an environment made some of the biggest names in energy notorious.

For the TL;DR version: in the mid-'90s, California opened its electricity market up to competition. The state founded the non-profit California Independent System Operator (or CAISO) to control transmission lines, and it incentivized utilities to sell their power generating stations to private companies. Companies traded energy on the also newly formed California Power Exchange, but the rules stipulated that trading was only allowed to be done in the day-ahead market.

The rationale for this was that customers would be able to transparently see how demand was affecting the rate they were going to pay for electricity that day in the newspaper. But it also meant utilities couldn’t enter into long-term deals with power suppliers to hedge against spikes in prices. Utilities were also prevented from charging rate-payers above a certain amount, but the wholesale price of energy wasn’t capped (a situation that would eventually lead to California’s largest utility, Pacific Gas & Electric, filing for bankruptcy in 2001).

A storm of external factors (PDF) was also brewing in California between 2000 and 2001: lower-than expected rainfall led to less hydroelectric power, hotter-than-average seasons hit the state, and a population and business boom led to increased demand for power.

On top of that, we have Enron. The company devised a variety of creative ways to drive up electricity prices considerably. One strategy was to divert supply from one area and then charge higher prices when that area was desperate to meet demand. Enron would “schedule power deliveries over lines already known to be heavily congested. Meanwhile, they would keep loads light in another part of the state,” according to a contemporary New York Times report.

California would also pay up to $750 per megawatt-hour to energy companies to relieve transmission line congestion. So Enron would sell power at a loss in a power-rich region, then collect the very high "congestion charge" that the state would pay to have the company divert its resources to another region in order to ease congestion.

Eventually, California capped the wholesale price for power at $250 per megawatt-hour. But the power-hungry state permitted electricity that was imported from out of state to be sold at more than $250 if the price could be justified. That lead to so-called "megawatt-laundering," in which Enron would buy power in California, schedule it for export to an out-of-state third party who charged a minimal fee per megawatt, then buy that power back from the third party to sell it back to California for a much higher price.

The effect of this market disaster is best seen in a summary of operations (PDF) that CAISO published in June 2017. That document describes emergency notices issued from 1998 to the present. The System Operator issues three kinds of emergency alerts if power supply dips too low:

Stage 1 Emergencies, when using power reserves is unavoidable; Stage 2 Emergencies, when operating reserves fall beneath five percent; and Stage 3 Emergencies, when operating reserves fall between 1.5 percent and 3 percent.

Stage 3 Emergencies are when rolling blackouts start happening.

In 1999 , there were four Stage 1 Emergencies and one Stage 2 Emergency.

, there were Stage 1 Emergencies and Stage 2 Emergency. In 2000 , there were 55 Stage 1 Emergencies, 36 Stage 2 Emergencies, and 1 Stage 3 Emergency.

, there were Stage 1 Emergencies, Stage 2 Emergencies, and Stage 3 Emergency. In 2001, there were 70 Stage 1 Emergencies, 65 Stage 2 Emergencies, and an astounding 38 Stage 3 Emergencies.

The Stage 3 Emergencies in 2001 didn’t just happen in the summer, either. The situation got so bad that manipulation of natural gas prices led to shortages in the electricity market, causing blackouts in January and March—usually times of relatively low electricity use.

Since 2001, CAISO has never had a Stage 3 Emergency, and since 2007, the system operator has never had a Stage 2 Emergency. In the last decade, CAISO has only had two instances when dipping into Stage 1 Emergency power reserves was unavoidable.

What happened? According to the Energy Information Administration, several factors contributed to the end of California’s electricity crisis, although there’s disagreement about which factors played the largest role. The state reformed some of the rules of its deregulated market, including allowing the Department of Water Resources to enter into long-term contracts with utilities and streamlining the permit process for building new generating plants. The Federal Energy Regulatory Commission (FERC) also intervened to give CAISO more control over planned power outages, and it began investigating possible market gaming. The Securities and Exchange Commission began investigating Enron in November 2001, and the company filed for bankruptcy in December 2001.

How grid managers do their thing

Since the turn of the millennium, the challenges of keeping electricity flowing have become more technical: transmission-line upgrades had to be made to serve a fast-expanding population, and more capacity had to be built. This wasn’t just true for California, which was growing at a steady 1.7-percent rate. Arizona also had a population explosion, as did Nevada and Utah.

In the last four or five years, huge renewable energy installations—mostly wind and solar—have come online in all of those states, but specifically in California, which has adopted policies favorable to renewables. Federal tax credits have also spurred some of the building. The economics are so favorable for wind and solar installations that CAISO has actually had trouble with negative rates. That’s when the grid has more electricity than is needed at a given moment, so the state will, in some cases, pay Arizona to take its excess solar, for example.

According to the LA Times, state utility Arizona Public Service often cuts its own solar production to accept California’s power (and its money) instead of cutting fossil fuel-based resources. That means renewable energy is not always being advanced through California’s oversupply problems, which in turn has created some friction in the state capital of Sacramento.

But is the increase in renewables playing any part in staving off blackouts? Not really, says CAISO spokesperson Steven Greenlee. The addition of renewable energy has certainly changed the electricity market in California, but the changes are more logistical for grid managers like CAISO. Now, managers see surges of supply in the morning from solar panels and surges of demand in the afternoon when people get home from work and turn up their air conditioners. Balancing the new patterns in supply and demand gets trickier, but that’s not causing or relieving blackouts.

Instead, the risk of blackouts in California and surrounding states comes from transmission issues—the lines that bring electricity to communities are the limiting factors. “Transmission lines are just like water pipes,” Greenlee says. “They can only hold so much." To determine the size of transmission lines into an area, CAISO depends on forecasting. “We look to see ‘how much do we need to meet the demand forecast’—not only the demand forecast in the short term, but also the demand forecast 10 years from now.”

Greenlee added that transmission lines cost hundreds of millions of dollars to build, so a good economic case has to be made to justify their construction. “One of the things we have to balance is how we use the line,” he said. “We have redundancy, but it isn’t quadruple redundancy.” Transmission-line builders couldn’t justify building out a line that’s used once every 10 years in an extreme heatwave. Instead, lines get built as communities get built, as population expands in urban areas, but not faster than that usually.

As for encouraging generating capacity development, Greenlee says CAISO always plans “to meet the most that we have ever had to push through the grid." Currently, that’s 50,270MW, which occurred on July 24, 2006.

“We’ve planned to at least meet that amount, but there still can be local areas that grow faster than [we] projected they would, in those local areas we can see congestion and... we’ll go out and ask them to ease up on using power," Greenlee told Ars. “For the most part during the summer, the biggest driver is air conditioners... We’ll say ‘please ease up on using electricity, set your thermostats for 78 degrees.’ Just those few degrees will help us get over our peak.”

That brings us to some of the demand mitigation tools that grid operators have at their disposal. Barring the building of new transmission lines, CAISO has successfully used three things to maintain operating reserves: flex alerts, flexible ramping, and computing power.