A university professor is being investigated after allegedly getting his students to produce ecstasy in a Breaking Bad-style lesson.

The 61-year-old pharmacology professor at Matsuyama University in western Japan is suspected of instructing students to make MDMA in 2013, according to Kyodo News agency.

It is also believed he may have made another drug known as 5F-QUPIC last year.

The professor allegedly claimed he set the task to help his students’ “learning”.

It is suspected 11 former students were involved in producing the drug, the news agency reported.

Japan in bloom: cherry blossoms in 2019 Show all 13 1 /13 Japan in bloom: cherry blossoms in 2019 Japan in bloom: cherry blossoms in 2019 Blossom along Tokyo's Chidorigafuchi Moat Getty Japan in bloom: cherry blossoms in 2019 Cherry blossom-watching on the Meguro River Getty Japan in bloom: cherry blossoms in 2019 Blossom along the Meguro River in Tokyo Getty Japan in bloom: cherry blossoms in 2019 Riding a boat underneath cherry blossom along Tokyo's Meguro River Getty Japan in bloom: cherry blossoms in 2019 Tokyo's Meguro River Getty Japan in bloom: cherry blossoms in 2019 Japan cherry blossom Tokyo's Meguro River Getty Japan in bloom: cherry blossoms in 2019 Illuminated cherry trees with the Roppongi Hills Mori Tower in the distance Getty Japan in bloom: cherry blossoms in 2019 Illuminated cherry trees along the Meguro River Getty Japan in bloom: cherry blossoms in 2019 Cherry blossom along the Chidorigafuchi Moat Getty Japan in bloom: cherry blossoms in 2019 Admiring cherry blossoms during a tea ceremony in Yokohama AP Japan in bloom: cherry blossoms in 2019 Taking a selfie underneath the cherry blossom in Yokohama AP Japan in bloom: cherry blossoms in 2019 Japanese Emperor Akihito, left, and Empress Michiko see weeping cherry in Kyoto AP Japan in bloom: cherry blossoms in 2019 Cherry blossom in Asakusa, Tokyo AFP/Getty

The case, which also involves an assistant professor, is said to have been passed from the regional drug enforcement authority to prosecutors.

Tatsuya Mizogami, president of the university, “sincerely apologised” to students and parents.

Echoes: The character Walter White in ‘Breaking Bad’ (Sony Pictures Television)

In Japanese law, a researcher must obtain a licence from regional government authorities to make narcotics for academic research.

The professor is understood to have been carrying out research into drugs that cause hallucinations or have a stimulant effect.

MDMA is a synthetic psychoactive drug, commonly used in party drug ecstasy, which is taken to give a heightened sensation of energy, empathy and pleasure.

5F-QUPIC, also known as 5F-PB-22, is a designer cannabis-like drug.

The case of the Matsuyama University professor has echoes of the character Walter White in US TV series Breaking Bad.