(CNN) Mother Nature has had a hectic past couple of weeks of hurricanes, an earthquake , wildfires and flooding. But while our attention has been turned to these humanitarian crises, Earth ducked a cosmic bullet the likes of which could have crippled human technological civilization.

Over the last week or so, the sun has experienced a series of solar flares , including the most energetic one in a decade. A solar flare occurs when magnetic energy in the vicinity of a sunspot is released, resulting in a bright spot on the sun that takes place over a time scale of perhaps 10 minutes -- or even less.

The flare can shoot out a broad range of electromagnetic energy, from visible light to X-rays to the even more energetic gamma rays. If this emitted energy is aimed at the Earth, it can have a significant impact, including enhanced auroras at lower latitudes, and airline passengers can experience a higher radiation dose than usual, especially for flight paths near the Earth's poles. This radiation dose is not deadly, although during especially bright solar flares, the airlines alter flight paths to avoid getting closer than 780 nautical miles to the poles.

Solar flares are rated on an increasing scale: A, B, C, M, X, with each category being 10 times more powerful than the previous one. Every flare has an accompanying number that gives more information; for instance, an X3 flare has triple the energy of an X1, and so on.

While the energy emitted in these flares is substantial, the Earth's atmosphere protects people on its surface from adverse effects, although GPS and communication satellites can be disrupted. Indeed, these flares did temporarily block high-frequency radio communication and degraded performance of the GPS network.

A more dangerous phenomenon

While solar flares can interfere with satellites, an even more dangerous phenomenon is called a coronal mass ejection (or CME). CMEs often accompany a flare and occur when some of the sun's highly ionized material is ejected into space. Because a CME consists of matter and not the electromagnetic radiation of a flare, it can take a day or even more to travel from the sun to the Earth. Indeed, last week's flares were accompanied by a CME , but it didn't hit the Earth with its full fury.

If a CME happens to be aimed directly at Earth, the ionized particles can slam into the magnetic field that surrounds the Earth and distort its shape, a process called a geomagnetic storm . That's when things can get dangerous. Moving magnetic fields can induce electrical currents on the Earth's surface and damage equipment.

In 1989, a CME hit the Earth and knocked out power in Quebec and the northeast United States for nine hours. And in 1859, an enormous CME hit the Earth. Called the Carrington Event, after Richard Carrington, who observed and recorded it, this geomagnetic storm caused telegraph pylons and railroad rails to spark, shocked telegraph operators and was responsible for auroras visible at least as far south as Havana, Cuba, with some claims of auroras being observed near the Earth's equator.

CMEs are directional and must hit the Earth to cause damage. Given the much greater reliance on technology today than in 1859, a repeat of the Carrington Event would disrupt our modern world to an extraordinary degree. It could damage the electric grid in ways that would take years to repair. A report by Lloyd's of London in 2013 estimated that the damage to the US grid from a repeat of the Carrington Event would be in the range of $0.6-$2.3 trillion dollars and would require four to 10 years to repair.

"The total U.S. population at risk of extended power outage from a Carrington-level storm is between 20-40 million, with durations of 16 days to 1-2 years," the Lloyd's report said.

JUST WATCHED Beautiful solar flares caught on camera Replay More Videos ... MUST WATCH Beautiful solar flares caught on camera 02:58

And a Carrington Event isn't so rare. A Carrington-caliber event occurred in 2012, but that CME missed the Earth by a comfortable margin.

The danger of CMEs to modern society is difficult to overstate, and even lesser events can cause considerable disruption. Accordingly, it would be imprudent if the nations of the world did not employ a warning system so that satellite operators and electric companies could take sensible precautionary action.

For instance, satellite operators could put their equipment in a nonoperational safe mode during the CME. Likewise, utility operators could defer maintenance, rebalance the electric load and even disconnect vulnerable transformers from the grid to protect them from the deleterious effects of a direct-hit major CME.

Taking precautions

An Obama administration executive order in 2016 identified the energy and communication systems as being uniquely critical, and the Department of Homeland Security Science and Technology Directorate is working with NASA to identify ways to provide better warnings.

Follow CNN Opinion Join us on Twitter and Facebook

In addition, the directorate is working with Sandia National Laboratories to better model the grid to develop methodologies to react effectively to the effects of a CME. Currently, the Space Weather Prediction Center at the National Oceanic and Atmospheric Administration provides regional-level space weather warnings and alerts.

The flares of this week, accompanied by strong, but not catastrophic, CMEs provide an important reminder of the vulnerability of the system to a potentially severe disruption.