Early last week, the District of Columbia found it had forgotten to include anti-scalping language in its big rewrite of the part of the municipal code that also governs food trucks, effectively legalizing the practice -- by accident. Officials promised that the situation would be rectified promptly. But they never answered the question: Wait, why do D.C. and dozens of states still restrict scalping in the first place?

How to see Beyonce? (Robin Harper / Invision for Parkwood Entertainment)

After all, scalpers just make up for market inefficiency, by capturing the difference between what the venue decides the ticket is worth and what the market thinks it's actually worth. And shouldn't ticket vendors be able to cut scalpers out of the process by instituting a dynamic pricing system that charges more for in-demand tickets and increases ticket prices as the event comes closer? That way, there will always be some tickets available for people without having to resort to buying them on the street, and the seller gets the most possible money for them. Airlines do it, hotels do it -- heck, even Goldman Sachs does it to keep the lines down in its cafeteria.

For a few reasons, though, that's not how most live events work.

It's not for lack of thinking about how to make it work. Back in 2003, Ticketmaster tried to introduce ticket auctions. "The tickets are worth what they're worth,'' Ticketmaster CEO John Pleasants told the New York Times. ''If somebody wants to charge $50 for a ticket, but it's actually worth $1,000 on eBay, the ticket's worth $1,000. I think more and more, our clients -- the promoters, the clients in the buildings and the bands themselves -- are saying to themselves, 'Maybe that money should be coming to me instead of Bob the Broker.'''

Auctions never took off, but experimentation with dynamic pricing continued. In 2011, Ticketmaster announced a partnership with a data analysis firm to introduce dynamic pricing as an option for its events. A couple of years later, though, only a few have taken them up on it (witness the Anaheim Ducks).

LiveNation did not respond to requests to explain the current adoption of dynamic pricing by its clients. But an industry insider, who asked not to be named in order to protect business relationships, explained their reluctance.

"The promise to fans was that while this would allow for venues to capture more upside on the first few rows, it would also allow those same venues to blow out the last rows ever more cheaply, leaving no seat empty and making very cheap seats a reality," he said. "As I hear it, the hurdle there is that most venues are very resistant to let the latter play out -- they don't want to really set a precedent in having $8 reserved seats or actively discounting, because they're concerned that people will just learn to wait for the discount. So not a lot of venues are using it."

Besides the fear that fans would game the system, promoters worry about perception. A smaller ticketing site called TicketLeap thought about dynamic pricing too, and ended up taking a pass.

"At first glance, it seems that if a performer had 50,000 seats to fill and knew the perfect price that would generate 50,000 units of demand, then they would set that price," says TicketLeap's Allison Berger. "However, there is more to it. First, they would rather sell out fast. It helps with planning and it makes the event look more popular. Second, performers desire to share their craft with their audience at a fair price. Big ticket prices are bad PR, and right now scalpers absorb that criticism."

So, dynamic pricing appears to be an imperfect solution in the event context, which means the secondary market is here to stay. And it's not the people holding up tickets in a scrum outside an arena that Ticketmaster has to worry about -- it's eBay's StubHub platform, which has an estimated 40 to 50 percent of the resale market, having cut deals with dozens of major sports teams and rival concert promoters.

LiveNation has been trying to get in on the scalping business itself for a long time. In the mid-2000s, it tried to start its own ticket resale platform called TicketExchange. That didn't work out so well, and neither did buying another site called TicketsNow; LiveNation considered selling the business after merging with Ticketmaster in 2010. But the company affirmed the value of the secondary market in 2011, and kept trying to figure out how to capture some of it.

In its latest iteration, over the summer, Ticketmaster started merging the primary and secondary markets on its own site. Provided Ticketmaster doesn't artificially inflate prices by holding back tickets to sell on its own secondary site -- as some economists and scholars worry it might -- the new system might be a decent way to ensure the fluidity of a secondary market without allowing fans to be duped by black market operators.

Sure, LiveNation is still pushing for measures to cut down on the use of software that automatically snaps up batches of tickets before any real human even has a chance to buy them, and fighting for the right to issue paperless tickets that can't be transferred. But it's also decided that above-board ticket resales are an important part of the event economy. And if a few people still find it worth their while to stand outside Nats Stadium hawking marked-up tickets -- well, that's a small price to pay for a safer and slightly more efficient market.