Amphetamines, compounds found in legal drugs to treat Attention-Deficit / Hyperactivity Disorder (ADHD) and in illegal ones like meth and molly, are destroying streams around Baltimore, according to a study published Thursday in the journal Environmental Science & Technology.

The researchers behind the study suspect that amphetamines are getting into the ecosystem when people are excreting them. This has been shown to happen with lots of other chemicals — birth control and antidepressants are getting into fish, amphibians, and aquatic plants, putting their populations in jeopardy.

There’s reason to believe the effects of amphetamines might be growing. The number of children diagnosed with ADHD rose 42 percent between 2003 and 2011, and most (74 percent) of those treat the disorder with medications like Adderall or Ritalin, which contain amphetamines. The use of illegal drugs, too, has grown — the number of people who had used meth in the past year grew by more than 200,000 between 2010 and 2013.

“We have every reason to suspect that the release of stimulants to aquatic environments is on the rise across the globe, yet little is known about the ecological consequences of this pollution,” said Emma J. Rosi-Marshall, a freshwater ecologist at the Cary Institute, an environmental research organization, and a co-author on the current study, in a press release.

In the study, the researchers took samples from six streams around Baltimore. Using a common chemical analysis, they figured out the concentration of amphetamine in them. To see its effect on an ecosystem, the researchers then created eight artificial streams, each packed with algae, bacteria, and insects typical of local waterways. They even added some rocks from nearby creeks for authenticity. Then the researchers added amphetamines to half the artificial streams and used the other four as controls.

After three weeks, the researchers found that the amphetamines reduced the biological processes of the microbes and algae, shifting which species among them were the most populous. The insects, on the other hand, were more active, emerging earlier in the streams laced with amphetamines than in the control streams.

The good news is that amphetamines tend to be short-lived in the environment, often not lasting more than a few days. The downside is that most of those drugs are taken up by organisms like those tested in the study. And if the organisms closest to sewage plants get thrown out of whack, it could have a ripple effect throughout the entire stream ecosystem.

Now that researchers know this is an issue, they can start to understand the mechanisms that cause these particular effects. That may even help them find solutions that might spare the ecosystems without denying ADHD patients the medication they need.