For nearly five decades, the venerable M16 rifle (and its M4 carbine variant, pictured above) has served as the U.S. Army's standard service rifle -- but perhaps not for much longer.

Pretty soon, every U.S. soldier could be packing a real-live ray gun.

OK, maybe not "phaser rifles" like the one Captain Kirk is hoisting here, but something close to it. Because as DefenseOne.com reported last month, the Army is already testing a precursor to such weapons, dubbed a "Burke Pulser."

Designed not for killing Klingons but for eliminating electronics, the Army's new ray gun comprises "two wide antennas, a piezoelectric generator and a few other small bits and pieces," DefenseOne says, all incorporated into an attachment the size of a silencer.

This device is attached to the barrel of a conventional M4A1 carbine. When the carbine is fired, the Burke Pulser converts the energy from the discharge into an electrical pulse. In theory at least, this electrical pulse could neutralize a Bluetooth-enabled IED, fry the brain of hostile drones -- or even help Jack Bauer stop terrorists from setting off remote-controlled bombs.

How much does a ray gun cost?

The U.S. Army's Armament Research, Development and Engineering Center, where the new ray gun was invented, estimates that mass-produced Burke Pulsers might cost as little as $1,000 per unit (more than doubling the cost of a $700 regulation M4). Purchasing enough Burke Pulsers to convert all M4 carbines in the U.S. Army inventory to potential directed energy weapons would then be a matter of some $500 million.

And how much is the ray gun market worth?

Now, $500 million sounds like a lot -- but really, it's just a shot in the dark at how big the market for "ray guns" might become. Recently, though, research firm MicroMarket Monitor attempted a more thorough examination of the market for "directed energy weapons," and came away with a startling conclusion:

This market is big.

And another:

This market is growing -- fast.

Who's who in ray guns

As recently as 2013, MMM estimated the value of directed energy weapon research, development, and sales in the U.S. at just under $3.1 billion. But over the next few years, MMM sees this market growing rapidly, and hitting $8.1 billion in sales by 2018.

MMM lists the primary movers in the directed energy weapons market as including most of the nation's biggest defense contractors -- companies such as Raytheon (NYSE: RTN), Boeing (NYSE: BA), Northrop Grumman (NYSE: NOC), and Lockheed Martin (NYSE: LMT). (Surprise, surprise -- we've come up with the exact same list of "usual suspects" here at The Motley Fool.)

For these companies, the advantages of investing in ray guns are obvious. Overall and across the defense industry, times are tough, and revenues are falling as the Pentagon tightens its belt. Even with cost cuts and stock buybacks, it's getting hard to grow profits. In fact, according to Yahoo! Finance, Raytheon, Northrop, and Lockheed are all expected to grow their profits at only single-digit rates over the next five years. (Boeing, at 12% projected growth, is the exception -- but its growth comes almost entirely from its Commercial Airplanes business, and with little help from Boeing Defense.) On the other hand, if MMM's predictions are anywhere close to accurate, directed energy weapons look like a 21.5% annual growth market.

Long story short: If there's a light at the end of the tunnel for America's defense industry, it's probably coming out of the barrel of a ray gun.